Fix the encoding of t2ISB by using the right class and also parse it correctly
authorBruno Cardoso Lopes <bruno.cardoso@gmail.com>
Tue, 18 Jan 2011 21:17:09 +0000 (21:17 +0000)
committerBruno Cardoso Lopes <bruno.cardoso@gmail.com>
Tue, 18 Jan 2011 21:17:09 +0000 (21:17 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123776 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/ARM/ARMInstrThumb2.td
lib/Target/ARM/AsmParser/ARMAsmParser.cpp
test/MC/ARM/arm_instructions.s
test/MC/ARM/thumb2.s

index 1bd853005e1af488c41d54628f8f4658de867e7e..98e587a3d075bc12bc245ad29b2fe5e2aefd07c3 100644 (file)
@@ -2808,7 +2808,7 @@ def t2DSB : AInoP<(outs), (ins memb_opt:$opt), ThumbFrm, NoItinerary,
 }
 
 // ISB has only full system option -- for disassembly only
-def t2ISB : T2I<(outs), (ins), NoItinerary, "isb", "",
+def t2ISB : AInoP<(outs), (ins), ThumbFrm, NoItinerary, "isb", "",
                   [/* For disassembly only; pattern left blank */]>,
                   Requires<[IsThumb2, HasV7]> {
   let Inst{31-4} = 0xf3bf8f6;
index 4948ad5e625353aa854662390255ffea26f160e4..6a8b6582157de6ab8d61cf5a8afb88aef7695315 100644 (file)
@@ -1193,7 +1193,7 @@ GetMnemonicAcceptInfo(StringRef Mnemonic, bool &CanAcceptCarrySet,
       Mnemonic == "cps" || Mnemonic == "mcr2" || Mnemonic == "it" ||
       Mnemonic == "mcrr2" || Mnemonic == "cbz" || Mnemonic == "cdp2" ||
       Mnemonic == "trap" || Mnemonic == "mrc2" || Mnemonic == "mrrc2" ||
-      Mnemonic == "dsb" || Mnemonic == "movs" ||
+      Mnemonic == "dsb" || Mnemonic == "movs" || Mnemonic == "isb" ||
       (isThumb && Mnemonic == "bkpt")) {
     CanAcceptPredicationCode = false;
   } else {
index cbcb09f13bdf2b035a9974a631094383b3a1209c..6820f0275066671e14a538a0fe097cea23b785c4 100644 (file)
 
 @ CHECK: bkpt  #10 @ encoding: [0x7a,0x00,0x20,0xe1]
         bkpt  #10
+
+@ CHECK: isb @ encoding: [0x6f,0xf0,0x7f,0xf5]
+        isb
index ceaf0a424f952940ddb9b2bfcda19210d402a8e7..e68105e07f0eb76b24f8c8eb0a2ff8d64692e576 100644 (file)
   ldrsh.w      r0, [r0]
 @ CHECK: bfi  r0, r0, #5, #7 @ encoding: [0x60,0xf3,0x4b,0x10]
   bfi  r0, r0, #5, #7
+@ CHECK: isb @ encoding: [0xbf,0xf3,0x6f,0x8f]
+  isb