mirror of
https://github.com/RPCS3/llvm.git
synced 2024-12-28 15:33:16 +00:00
revert r95689: getX86RegNum(BaseReg) != N86::ESP is
a confusing idiom to check for ESP or RSP. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@95690 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
203efab2a5
commit
32f9a2c54e
@ -389,8 +389,8 @@ void Emitter<CodeEmitter>::emitMemModRMByte(const MachineInstr &MI,
|
||||
// 2-7) and absolute references.
|
||||
if ((!Is64BitMode || DispForReloc || BaseReg != 0) &&
|
||||
IndexReg.getReg() == 0 &&
|
||||
((BaseReg == 0 && IsPCRel) || BaseReg == X86::RIP ||
|
||||
(BaseReg != 0 && BaseReg != X86::ESP))) {
|
||||
((BaseReg == 0 && MCE.earlyResolveAddresses()) || BaseReg == X86::RIP ||
|
||||
(BaseReg != 0 && getX86RegNum(BaseReg) != N86::ESP))) {
|
||||
if (BaseReg == 0 || BaseReg == X86::RIP) { // Just a displacement?
|
||||
// Emit special case [disp32] encoding
|
||||
MCE.emitByte(ModRMByte(0, RegOpcodeField, 5));
|
||||
|
Loading…
Reference in New Issue
Block a user