[llvm-commits] [llvm] r139193 - in /llvm/trunk: lib/Target/ARM/ARMInstrThumb2.td test/MC/ARM/basic-thumb2-instructions.s
Jim Grosbach
grosbach at apple.com
Tue Sep 6 15:14:58 PDT 2011
Author: grosbach
Date: Tue Sep 6 17:14:58 2011
New Revision: 139193
URL: http://llvm.org/viewvc/llvm-project?rev=139193&view=rev
Log:
Thumb2 parsing and encoding for DMB.
Modified:
llvm/trunk/lib/Target/ARM/ARMInstrThumb2.td
llvm/trunk/test/MC/ARM/basic-thumb2-instructions.s
Modified: llvm/trunk/lib/Target/ARM/ARMInstrThumb2.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/ARMInstrThumb2.td?rev=139193&r1=139192&r2=139193&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/ARMInstrThumb2.td (original)
+++ llvm/trunk/lib/Target/ARM/ARMInstrThumb2.td Tue Sep 6 17:14:58 2011
@@ -3588,3 +3588,7 @@
def : t2InstAlias<"tst${p} $Rn, $Rm",
(t2TSTrr GPRnopc:$Rn, rGPR:$Rm, pred:$p)>;
+// Memory barriers
+def : InstAlias<"dmb", (t2DMB 0xf)>, Requires<[IsThumb2, HasDB]>;
+def : InstAlias<"dsb", (t2DSB 0xf)>, Requires<[IsThumb2, HasDB]>;
+//def : InstAlias<"isb", (t2ISB 0xf)>, Requires<[IsThumb2, HasDB]>;
Modified: llvm/trunk/test/MC/ARM/basic-thumb2-instructions.s
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/MC/ARM/basic-thumb2-instructions.s?rev=139193&r1=139192&r2=139193&view=diff
==============================================================================
--- llvm/trunk/test/MC/ARM/basic-thumb2-instructions.s (original)
+++ llvm/trunk/test/MC/ARM/basic-thumb2-instructions.s Tue Sep 6 17:14:58 2011
@@ -369,6 +369,38 @@
@------------------------------------------------------------------------------
+@ DMB
+ at ------------------------------------------------------------------------------
+ dmb sy
+ dmb st
+ dmb sh
+ dmb ish
+ dmb shst
+ dmb ishst
+ dmb un
+ dmb nsh
+ dmb unst
+ dmb nshst
+ dmb osh
+ dmb oshst
+ dmb
+
+@ CHECK: dmb sy @ encoding: [0xbf,0xf3,0x5f,0x8f]
+@ CHECK: dmb st @ encoding: [0xbf,0xf3,0x5e,0x8f]
+@ CHECK: dmb ish @ encoding: [0xbf,0xf3,0x5b,0x8f]
+@ CHECK: dmb ish @ encoding: [0xbf,0xf3,0x5b,0x8f]
+@ CHECK: dmb ishst @ encoding: [0xbf,0xf3,0x5a,0x8f]
+@ CHECK: dmb ishst @ encoding: [0xbf,0xf3,0x5a,0x8f]
+@ CHECK: dmb nsh @ encoding: [0xbf,0xf3,0x57,0x8f]
+@ CHECK: dmb nsh @ encoding: [0xbf,0xf3,0x57,0x8f]
+@ CHECK: dmb nshst @ encoding: [0xbf,0xf3,0x56,0x8f]
+@ CHECK: dmb nshst @ encoding: [0xbf,0xf3,0x56,0x8f]
+@ CHECK: dmb osh @ encoding: [0xbf,0xf3,0x53,0x8f]
+@ CHECK: dmb oshst @ encoding: [0xbf,0xf3,0x52,0x8f]
+@ CHECK: dmb sy @ encoding: [0xbf,0xf3,0x5f,0x8f]
+
+
+ at ------------------------------------------------------------------------------
@ IT
@------------------------------------------------------------------------------
@ Test encodings of a few full IT blocks, not just the IT instruction
More information about the llvm-commits
mailing list