Anastasia added inline comments.

================
Comment at: lib/AST/MicrosoftMangle.cpp:1386
@@ -1385,1 +1385,3 @@
 
+  if (Quals.hasAddressSpace()) {
+    // Address space extension:
----------------
I was just wondering since this code appears to be a repetition from 
ItaniumMangler.cpp, could we just factor it out to a common function.

I think Mangler.cpp could be a good place for having its definition then next 
to ObjC specific functions (see for example mangleObjCMethodName()). We would 
just have to update  comments in this file accordingly to reflect that it now 
contains OpenCL and CUDA functionality as well.

================
Comment at: test/CodeGenOpenCL/generic-mangling-itanium.cl:1
@@ +1,2 @@
+// RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -emit-llvm -x cl 
-cl-std=CL2.0 -o - %s | FileCheck %s
+
----------------
Could we extend test/CodeGenOpenCL/address-spaces-mangling.cl instead of adding 
another file?

================
Comment at: test/CodeGenOpenCL/generic-mangling-itanium.cl:5
@@ +4,3 @@
+bool __attribute__((__overloadable__)) atomic_compare_exchange_strong(
+       volatile  __global atomic_int *object,
+  int  *expected,
----------------
Did you mean to test generic not global?

================
Comment at: test/CodeGenOpenCL/generic-mangling-microsoft.cl:1
@@ +1,2 @@
+// RUN: %clang_cc1 -triple i686-pc-windows-msvc -emit-llvm -x cl -cl-std=CL2.0 
-o - %s | FileCheck %s
+
----------------
I would very much like to have test/CodeGenOpenCL/address-spaces-mangling.cl 
extended here too. You can just add a new RUN line along with a new 
-check-prefix option.


http://reviews.llvm.org/D16539



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to