[clang] [llvm] [NVPTX] Revamp NVVMIntrRange pass (PR #94422)

via cfe-commits cfe-commits at lists.llvm.org
Thu Jun 6 07:45:57 PDT 2024


================
@@ -6,21 +6,21 @@
 __attribute__((global))
 void kernel(int *out) {
   int i = 0;
-  out[i++] = threadIdx.x; // CHECK: call noundef i32 @llvm.nvvm.read.ptx.sreg.tid.x()
-  out[i++] = threadIdx.y; // CHECK: call noundef i32 @llvm.nvvm.read.ptx.sreg.tid.y()
-  out[i++] = threadIdx.z; // CHECK: call noundef i32 @llvm.nvvm.read.ptx.sreg.tid.z()
+  out[i++] = threadIdx.x; // CHECK: call noundef {{.*}} i32 @llvm.nvvm.read.ptx.sreg.tid.x()
----------------
dyung wrote:

This change appears to be causing the test to fail on some bots where there are no extra arguments in this location, causing a single space ` ` to not match the expected double space `  `. You can probably fix this by just removing either the leading or trailing space that you added for each of these.

Bot failure:
https://lab.llvm.org/buildbot/#/builders/139/builds/67000
```

 out[i++] = threadIdx.x; // CHECK: call noundef {{.*}} i32 @llvm.nvvm.read.ptx.sreg.tid.x()
                                   ^
<stdin>:17:53: note: scanning from here
define dso_local void @_Z6kernelPi(ptr noundef %out) #0 {
                                                    ^
<stdin>:23:7: note: possible intended match here
 %0 = call noundef i32 @llvm.nvvm.read.ptx.sreg.tid.x()
      ^
```

https://github.com/llvm/llvm-project/pull/94422


More information about the cfe-commits mailing list