[PATCH] D29905: [OpenMP] Pass argument to device kernel by reference when map is used.

Alexey Bataev via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Apr 12 08:25:33 PDT 2017


ABataev added inline comments.


================
Comment at: lib/Sema/SemaOpenMP.cpp:343
+    for (unsigned I = Stack.size() - 1; I > 0; --I)
+      if (checkMappableExprComponentListsForDeclAtLevel(VD, I - 2, Check))
+        return true;
----------------
Are you sure this is correct? If I is 1, I-2 will give you 0xFFFFFFFF. Please, check everything one more time


================
Comment at: lib/Sema/SemaOpenMP.cpp:355
+               OpenMPClauseKind)> &Check) {
+    // auto StartI = std::next(Stack.begin());
+    auto StartI = Stack.begin();
----------------
Please, remove this commented code


Repository:
  rL LLVM

https://reviews.llvm.org/D29905





More information about the cfe-commits mailing list