[Mlir-commits] [mlir] [MLIR][TableGen] Add genMnemonicAlias field for OpAsm{Type, Attr}Interface (PR #131504)

Jacques Pienaar llvmlistbot at llvm.org
Tue May 6 22:32:22 PDT 2025


================
@@ -1182,6 +1188,14 @@ Note that these are mechanisms intended for long-tail cases by power users; for
 not-yet-implemented widely-applicable cases, improving the infrastructure is
 preferable.
 
+### Mnemonic Alias in Assembly
+
+Attribute and Type might want to use aliases in the assembly to reduce verbosity.
----------------
jpienaar wrote:

How about a bit more active voice (something like):

Attribute and Type can use aliases in the assembly to reduce verbosity. In such cases, OpAsmAttrInterface and OpAsmTypeInterface can be used to generate aliases. Often, a simple mnemonic alias is enough; then enabling genMnemonicAlias automatically generates an getAlias implementation using the Attribute or Type's mnemonic.

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


More information about the Mlir-commits mailing list