[llvm] Add extended mnemonics (PR #97571)

Kai Nacke via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 3 11:54:29 PDT 2024


================
@@ -111,11 +111,16 @@ let isBranch = 1, isTerminator = 1, isBarrier = 1 in {
 // NOPs.  These are again variants of the conditional branches, with the
 // condition mask set to "never".  NOP_bare can't be an InstAlias since it
 // would need R0D hard coded which is not part of ADDR64BitRegClass.
-def NOP  : InstAlias<"nop\t$XBD", (BCAsm 0, bdxaddr12only:$XBD), 0>;
+def NOP : NeverCondBranchRX<"nop", 0x47>;
 let isAsmParserOnly = 1, hasNoSchedulingInfo = 1, M1 = 0, X2 = 0, B2 = 0, D2 = 0 in
   def NOP_bare  : InstRXb<0x47,(outs), (ins), "nop", []>;
-def NOPR : InstAlias<"nopr\t$R", (BCRAsm 0, GR64:$R), 0>;
-def NOPR_bare : InstAlias<"nopr", (BCRAsm 0, R0D), 0>;
+def NOPR : NeverCondBranchRR<"nopr", 0x07>;
+def NOPR_bare : InstAlias<"nopr", (NOPR R0D), 0>;
+// def NOP  : InstAlias<"nop\t$XBD", (BCAsm 0, bdxaddr12only:$XBD), 0>;
+// let isAsmParserOnly = 1, hasNoSchedulingInfo = 1, M1 = 0, X2 = 0, B2 = 0, D2 = 0 in
+//   def NOP_bare  : InstRXb<0x47,(outs), (ins), "nop", []>;
+// def NOPR : InstAlias<"nopr\t$R", (BCRAsm 0, GR64:$R), 0>;
+// def NOPR_bare : InstAlias<"nopr", (BCRAsm 0, R0D), 0>;
----------------
redstar wrote:

No dead code in comments please.

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


More information about the llvm-commits mailing list