X86: change MOV64ri64i32 into MOV32ri64
authorTim Northover <tnorthover@apple.com>
Fri, 31 May 2013 09:57:13 +0000 (09:57 +0000)
committerTim Northover <tnorthover@apple.com>
Fri, 31 May 2013 09:57:13 +0000 (09:57 +0000)
commit43887bf3e62daab1c8571be8a73741c9275f866a
tree2eda3f1064130d09963fff6d35c9671baeb3ff9c
parent5434f123e9c3b31cc7783ab06be0358026212cd2
X86: change MOV64ri64i32 into MOV32ri64

The MOV64ri64i32 instruction required hacky MCInst lowering because it was
allocated as setting a GR64, but the eventual instruction ("movl") only set a
GR32. This converts it into a so-called "MOV32ri64" which still accepts a
(appropriate) 64-bit immediate but defines a GR32. This is then converted to
the full GR64 by a SUBREG_TO_REG operation, thus keeping everyone happy.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@182991 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/X86/X86CodeEmitter.cpp
lib/Target/X86/X86ISelDAGToDAG.cpp
lib/Target/X86/X86InstrCompiler.td
lib/Target/X86/X86MCInstLower.cpp
test/CodeGen/X86/abi-isel.ll