[llvm-commits] [llvm] r68948 - /llvm/trunk/lib/Target/X86/X86InstrInfo.cpp
Dan Gohman
gohman at apple.com
Mon Apr 13 08:04:32 PDT 2009
Author: djg
Date: Mon Apr 13 10:04:25 2009
New Revision: 68948
URL: http://llvm.org/viewvc/llvm-project?rev=68948&view=rev
Log:
Fix another hard-coded constant to use X86AddrNumOperands.
This unbreaks the JIT on x86-64.
Modified:
llvm/trunk/lib/Target/X86/X86InstrInfo.cpp
Modified: llvm/trunk/lib/Target/X86/X86InstrInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86InstrInfo.cpp?rev=68948&r1=68947&r2=68948&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86InstrInfo.cpp (original)
+++ llvm/trunk/lib/Target/X86/X86InstrInfo.cpp Mon Apr 13 10:04:25 2009
@@ -2602,7 +2602,7 @@
case X86II::MRM4m: case X86II::MRM5m:
case X86II::MRM6m: case X86II::MRM7m:
case X86II::MRMDestMem: {
- unsigned e = isTwoAddr ? 5 : 4;
+ unsigned e = (isTwoAddr ? X86AddrNumOperands+1 : X86AddrNumOperands);
i = isTwoAddr ? 1 : 0;
if (NumOps > e && isX86_64ExtendedReg(MI.getOperand(e)))
REX |= 1 << 2;
More information about the llvm-commits
mailing list