[PATCH] D32215: Updated PPCG Code Generation for OpenCL compatibility

Siddharth via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 20 09:41:50 PDT 2017


bollu added inline comments.


================
Comment at: lib/CodeGen/PPCGCodeGeneration.cpp:1283
+  } else {
+    Ret += "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:" \
+            "64-f32:32:32-f64:64:64-v16:16:16-v32:32:32-v64:64:" \
----------------
Please add a test case to check that both code paths are taken. 


================
Comment at: lib/CodeGen/PPCGCodeGeneration.cpp:1306
     } else {
-      Args.push_back(Builder.getInt8PtrTy());
+      Args.push_back(Builder.getInt8Ty()->getPointerTo(1));
     }
----------------
1. Change the magic constant `1` to a `static const GlobalMemory = 1` or something of the sort.
2. This change seems unrelated to the initial change. Can this be split into two separate patches?
3. Please add a test case that makes sure that the correct code is generated.


Repository:
  rL LLVM

https://reviews.llvm.org/D32215





More information about the llvm-commits mailing list