diff options
author | Dan Gohman <gohman@apple.com> | 2009-04-17 00:43:09 +0000 |
---|---|---|
committer | Dan Gohman <gohman@apple.com> | 2009-04-17 00:43:09 +0000 |
commit | d51def353cb74e18e459cc03dfb501ae631b9334 (patch) | |
tree | f966071d83c590ed75e98b61beea0f43fb56ce85 | |
parent | 9062d9a55b0b8b473b927d8b020e36990e147a58 (diff) | |
download | external_llvm-d51def353cb74e18e459cc03dfb501ae631b9334.zip external_llvm-d51def353cb74e18e459cc03dfb501ae631b9334.tar.gz external_llvm-d51def353cb74e18e459cc03dfb501ae631b9334.tar.bz2 |
Don't use MOV8rr_NOREX on x86-32. It doesn't actually hurt anything at
present, but it's inconsistent.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@69335 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/Target/X86/X86InstrInfo.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/Target/X86/X86InstrInfo.cpp b/lib/Target/X86/X86InstrInfo.cpp index e123ae7..c024365 100644 --- a/lib/Target/X86/X86InstrInfo.cpp +++ b/lib/Target/X86/X86InstrInfo.cpp @@ -1664,9 +1664,10 @@ bool X86InstrInfo::copyRegToReg(MachineBasicBlock &MBB, } else if (DestRC == &X86::GR16RegClass) { Opc = X86::MOV16rr; } else if (DestRC == &X86::GR8RegClass) { - // Copying two or from a physical H register requires a NOREX move. - // Otherwise use a normal move. - if (isHReg(DestReg) || isHReg(SrcReg)) + // Copying two or from a physical H register on x86-64 requires a NOREX + // move. Otherwise use a normal move. + if ((isHReg(DestReg) || isHReg(SrcReg)) && + TM.getSubtarget<X86Subtarget>().is64Bit()) Opc = X86::MOV8rr_NOREX; else Opc = X86::MOV8rr; |