[Mlir-commits] [mlir] [MLIR][GPU-LLVM] Convert `gpu.func` to `llvm.func` (PR #101664)

Mehdi Amini llvmlistbot at llvm.org
Mon Aug 5 07:11:27 PDT 2024


================
@@ -58,6 +58,10 @@ def LLVM_Dialect : Dialect {
     /// effect when lowering to the LLVMDialect.
     static StringRef getReadnoneAttrName() { return "llvm.readnone"; }
 
+    /// Name of the helper attribute to keep GPU workgroup attribution size
+    /// information when converting from GPU to LLVM.
+    static StringRef getWorkgroupAttribSizeAttrName() { return "llvm.mlir.workgroup_attrib_size"; }
----------------
joker-eph wrote:

It helps in that it caches automatically a StringAttr on the Dialect instead. You can cache it manually if you prefer, but StringRef-based APIs are inefficient and we should just avoid these in general IMO.

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


More information about the Mlir-commits mailing list