[PATCH] D28988: [X86]Enable the use of 'mov' with a 64bit GPR and a large immediate

coby via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 24 23:20:59 PST 2017


This revision was automatically updated to reflect the committed changes.
Closed by commit rL293030: [X86]Enable the use of 'mov' with a 64bit GPR and a large immediate (authored by coby).

Changed prior to commit:
  https://reviews.llvm.org/D28988?vs=85275&id=85699#toc

Repository:
  rL LLVM

https://reviews.llvm.org/D28988

Files:
  llvm/trunk/lib/Target/X86/X86InstrInfo.td
  llvm/trunk/test/MC/X86/intel-syntax.s


Index: llvm/trunk/test/MC/X86/intel-syntax.s
===================================================================
--- llvm/trunk/test/MC/X86/intel-syntax.s
+++ llvm/trunk/test/MC/X86/intel-syntax.s
@@ -19,6 +19,8 @@
 	mov	EAX, DWORD PTR [RSP - 4]
 // CHECK:	movq    (%rsp), %rax
 	mov     RAX, QWORD PTR [RSP]
+// CHECK: movabsq $4294967289, %rax
+	mov     RAX, 4294967289
 // CHECK:	movl	$-4, -4(%rsp)
 	mov	DWORD PTR [RSP - 4], -4
 // CHECK:	movq	0, %rcx
Index: llvm/trunk/lib/Target/X86/X86InstrInfo.td
===================================================================
--- llvm/trunk/lib/Target/X86/X86InstrInfo.td
+++ llvm/trunk/lib/Target/X86/X86InstrInfo.td
@@ -2984,7 +2984,7 @@
 def : InstAlias<"mov\t{$seg, $mem|$mem, $seg}", (MOV32ms i32mem:$mem, SEGMENT_REG:$seg), 0>;
 
 // Match 'movq <largeimm>, <reg>' as an alias for movabsq.
-def : InstAlias<"movq\t{$imm, $reg|$reg, $imm}", (MOV64ri GR64:$reg, i64imm:$imm), 0>;
+def : InstAlias<"mov{q}\t{$imm, $reg|$reg, $imm}", (MOV64ri GR64:$reg, i64imm:$imm), 0>;
 
 // Match 'movq GR64, MMX' as an alias for movd.
 def : InstAlias<"movq\t{$src, $dst|$dst, $src}",


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D28988.85699.patch
Type: text/x-patch
Size: 1122 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170125/921df79e/attachment.bin>


More information about the llvm-commits mailing list