[PATCH] D20644: [NVPTX] Added NVVMIntrRange pass

Justin Lebar via llvm-commits llvm-commits at lists.llvm.org
Wed May 25 15:33:38 PDT 2016


jlebar added a comment.

> it looks like there's enough work for a separate patch.


I'm happy if you want to do it in a separate patch, but we should definitely add testing of important intrinsics like these, one way or another.

LGTM aside from the apparent integer overlow.


================
Comment at: lib/Target/NVPTX/NVVMIntrRange.cpp:61
@@ +60,3 @@
+// passed-in call instruction.
+static bool addRangeMetadata(int Low, int High, CallInst *C) {
+  LLVMContext &Context = C->getParent()->getContext();
----------------
MaxGridSize.x is INT_MAX for sm_30+.  Then we add 1 to it, and store in a signed int...


http://reviews.llvm.org/D20644





More information about the llvm-commits mailing list