[llvm-branch-commits] [llvm-branch] r104345 - in /llvm/branches/Apple/whitney: lib/Target/X86/X86InstrSSE.td test/MC/AsmParser/X86/x86_32-bit_cat.s test/MC/AsmParser/X86/x86_32-new-encoder.s
Daniel Dunbar
daniel at zuster.org
Fri May 21 12:06:13 PDT 2010
Author: ddunbar
Date: Fri May 21 14:06:13 2010
New Revision: 104345
URL: http://llvm.org/viewvc/llvm-project?rev=104345&view=rev
Log:
Define the x86 pause instruction.
Modified:
llvm/branches/Apple/whitney/lib/Target/X86/X86InstrSSE.td
llvm/branches/Apple/whitney/test/MC/AsmParser/X86/x86_32-bit_cat.s
llvm/branches/Apple/whitney/test/MC/AsmParser/X86/x86_32-new-encoder.s
Modified: llvm/branches/Apple/whitney/lib/Target/X86/X86InstrSSE.td
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/Apple/whitney/lib/Target/X86/X86InstrSSE.td?rev=104345&r1=104344&r2=104345&view=diff
==============================================================================
--- llvm/branches/Apple/whitney/lib/Target/X86/X86InstrSSE.td (original)
+++ llvm/branches/Apple/whitney/lib/Target/X86/X86InstrSSE.td Fri May 21 14:06:13 2010
@@ -2417,6 +2417,10 @@
def MFENCE : I<0xAE, MRM_F0, (outs), (ins),
"mfence", [(int_x86_sse2_mfence)]>, TB, Requires<[HasSSE2]>;
+// Pause. This "instruction" is encoded as "rep; nop", so even though it
+// was introduced with SSE2, it's backward compabitle.
+def PAUSE : I<0x90, RawFrm, (outs), (ins), "pause", []>, REP;
+
//TODO: custom lower this so as to never even generate the noop
def : Pat<(membarrier (i8 imm), (i8 imm), (i8 imm), (i8 imm),
(i8 0)), (NOOP)>;
Modified: llvm/branches/Apple/whitney/test/MC/AsmParser/X86/x86_32-bit_cat.s
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/Apple/whitney/test/MC/AsmParser/X86/x86_32-bit_cat.s?rev=104345&r1=104344&r2=104345&view=diff
==============================================================================
--- llvm/branches/Apple/whitney/test/MC/AsmParser/X86/x86_32-bit_cat.s (original)
+++ llvm/branches/Apple/whitney/test/MC/AsmParser/X86/x86_32-bit_cat.s Fri May 21 14:06:13 2010
@@ -2482,6 +2482,12 @@
// CHECK: clflush 305419896
clflush 0x12345678
+// CHECK: pause
+ pause
+
+// CHECK: sfence
+ sfence
+
// CHECK: lfence
lfence
Modified: llvm/branches/Apple/whitney/test/MC/AsmParser/X86/x86_32-new-encoder.s
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/Apple/whitney/test/MC/AsmParser/X86/x86_32-new-encoder.s?rev=104345&r1=104344&r2=104345&view=diff
==============================================================================
--- llvm/branches/Apple/whitney/test/MC/AsmParser/X86/x86_32-new-encoder.s (original)
+++ llvm/branches/Apple/whitney/test/MC/AsmParser/X86/x86_32-new-encoder.s Fri May 21 14:06:13 2010
@@ -1,5 +1,8 @@
// RUN: llvm-mc -triple i386-unknown-unknown --show-encoding %s | FileCheck %s
+ pause
+// CHECK: pause
+// CHECK: encoding: [0xf3,0x90]
sfence
// CHECK: sfence
// CHECK: encoding: [0x0f,0xae,0xf8]
More information about the llvm-branch-commits
mailing list