[llvm-commits] [llvm] r77956 - in /llvm/trunk: lib/Target/X86/X86InstrMMX.td test/CodeGen/X86/mmx-bitcast-to-i64.ll
Rafael Espindola
rafael.espindola at gmail.com
Sun Aug 2 22:21:05 PDT 2009
Author: rafael
Date: Mon Aug 3 00:21:05 2009
New Revision: 77956
URL: http://llvm.org/viewvc/llvm-project?rev=77956&view=rev
Log:
Use movd instead of movq
Modified:
llvm/trunk/lib/Target/X86/X86InstrMMX.td
llvm/trunk/test/CodeGen/X86/mmx-bitcast-to-i64.ll
Modified: llvm/trunk/lib/Target/X86/X86InstrMMX.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86InstrMMX.td?rev=77956&r1=77955&r2=77956&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86InstrMMX.td (original)
+++ llvm/trunk/lib/Target/X86/X86InstrMMX.td Mon Aug 3 00:21:05 2009
@@ -164,11 +164,14 @@
[]>;
let neverHasSideEffects = 1 in {
+// These are 64 bit moves, but since the OS X assembler doesn't
+// recognize a register-register movq, we write them as
+// movd.
def MMX_MOVD64from64rr : MMXRI<0x7E, MRMDestReg,
(outs GR64:$dst), (ins VR64:$src),
- "movq\t{$src, $dst|$dst, $src}", []>;
+ "movd\t{$src, $dst|$dst, $src}", []>;
def MMX_MOVD64rrv164 : MMXI<0x6E, MRMSrcReg, (outs VR64:$dst), (ins GR64:$src),
- "movq\t{$src, $dst|$dst, $src}",
+ "movd\t{$src, $dst|$dst, $src}",
[(set VR64:$dst, (v1i64 (scalar_to_vector GR64:$src)))]>;
}
Modified: llvm/trunk/test/CodeGen/X86/mmx-bitcast-to-i64.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/mmx-bitcast-to-i64.ll?rev=77956&r1=77955&r2=77956&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/X86/mmx-bitcast-to-i64.ll (original)
+++ llvm/trunk/test/CodeGen/X86/mmx-bitcast-to-i64.ll Mon Aug 3 00:21:05 2009
@@ -1,4 +1,4 @@
-; RUN: llvm-as < %s | llc -march=x86-64 | grep movq | count 8
+; RUN: llvm-as < %s | llc -march=x86-64 | grep movd | count 4
define i64 @foo(<1 x i64>* %p) {
%t = load <1 x i64>* %p
More information about the llvm-commits
mailing list