[llvm] [TableGen] Added submulticlass typechecking to template arg values. (PR #112904)

Jay Foad via llvm-commits llvm-commits at lists.llvm.org
Fri Oct 18 07:25:08 PDT 2024


================
@@ -37,7 +37,7 @@ defvar VOPDX_Max_Index = 12;
 
 class VOPD_Component<bits<5> OpIn, string vOPDName> {
   Instruction BaseVOP = !cast<Instruction>(NAME);
-  string VOPDName = "v_dual_" # !substr(vOPDName, 2);
+  string VOPDName = "v_dual_" # !if(!le(!size(vOPDName), 2), "", !substr(vOPDName, 2));
----------------
jayfoad wrote:

How is this change related to template arg type checking?

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


More information about the llvm-commits mailing list