[clang] [llvm] [HIP][HIPSTDPAR][NFC] Re-order & adapt `hipstdpar` specific passes (PR #134753)

Matt Arsenault via cfe-commits cfe-commits at lists.llvm.org
Sat Apr 12 04:16:11 PDT 2025


================
@@ -0,0 +1,11 @@
+// Check that if we are compiling with fgpu-rdc amdgpu-enable-hipstdpar is not
+// passed to CC1, to avoid eager, per TU, removal of potentially accessible
+// functions.
+
+// RUN: %clang -### --hipstdpar --offload-arch=gfx906 %s -nogpulib -nogpuinc \
+// RUN:   2>&1 | FileCheck -check-prefix=NORDC %s
+// NORDC: {{.*}}"-mllvm" "-amdgpu-enable-hipstdpar"
+
+// RUN: %clang -### --hipstdpar --offload-arch=gfx906 %s -nogpulib -nogpuinc -fgpu-rdc \
+// RUN:   2>&1 | FileCheck -check-prefix=RDC %s
+// RDC-NOT: {{.*}}"-mllvm" "-amdgpu-enable-hipstdpar"
----------------
arsenm wrote:

```suggestion
// RDC-NOT: -amdgpu-enable-hipstdpar
```

-NOT checks are hazardous and should be as permissive as possible 
```suggestion
// RDC-NOT: {{.*}}"-mllvm" "-amdgpu-enable-hipstdpar"
```

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


More information about the cfe-commits mailing list