[Mlir-commits] [mlir] [mlir][gpu] Correctly retrieve kernel function name for nested references (PR #152106)
Guray Ozen
llvmlistbot at llvm.org
Tue Aug 5 02:39:40 PDT 2025
================
@@ -530,6 +530,24 @@ func.func @testKernelAttributes() {
return
}
+// -----
+
+// This test tests the kernelFunc has nested references.
+
+// CHECK-LABEL: func.func @testKernelAttributesWithNestedFunc
+// CHECK: gpu.launch_func @test_module::@test_kernel_func
+// CHECK: gpu.module @test_module
+// CHECK: gpu.func @test_kernel_func()
+// CHECK-NOT: gpu.func @test_module()
+func.func @testKernelAttributesWithNestedFunc(%arg0 : index) {
+ gpu.launch blocks(%bx, %by, %bz) in (%grid_x = %arg0, %grid_y = %arg0, %grid_z = %arg0)
+ threads(%tx, %ty, %tz) in (%block_x = %arg0, %block_y = %arg0, %block_z = %arg0) {
+ "some_op"(%bx, %tx) : (index, index) -> ()
+ gpu.terminator
+ } {kernelModule = @test_module, kernelFunc = @test_module::@test_kernel_func}
----------------
grypp wrote:
These attributes is camel case. Can we change them to following?
```
{module = @test_module, func = @test_module::@test_kernel_func}
```
https://github.com/llvm/llvm-project/pull/152106
More information about the Mlir-commits
mailing list