diff options
author | Chris Lattner <sabre@nondot.org> | 2006-01-13 18:00:54 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2006-01-13 18:00:54 +0000 |
commit | 9edba7605e48aaf2b99cf0c8204db3fa1bd4d2f8 (patch) | |
tree | 3eabdb517b6e67c102e060f88569a25143005172 /lib | |
parent | cadd7420f9e705735b794e61cd24aab16ce2fa18 (diff) | |
download | external_llvm-9edba7605e48aaf2b99cf0c8204db3fa1bd4d2f8.zip external_llvm-9edba7605e48aaf2b99cf0c8204db3fa1bd4d2f8.tar.gz external_llvm-9edba7605e48aaf2b99cf0c8204db3fa1bd4d2f8.tar.bz2 |
Enable X86 support for savestack/restorestack
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25278 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Target/X86/X86ISelLowering.cpp | 1 | ||||
-rw-r--r-- | lib/Target/X86/X86ISelPattern.cpp | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/lib/Target/X86/X86ISelLowering.cpp b/lib/Target/X86/X86ISelLowering.cpp index 6a2fb68..776780f 100644 --- a/lib/Target/X86/X86ISelLowering.cpp +++ b/lib/Target/X86/X86ISelLowering.cpp @@ -39,6 +39,7 @@ X86TargetLowering::X86TargetLowering(TargetMachine &TM) setSetCCResultType(MVT::i8); setSetCCResultContents(ZeroOrOneSetCCResult); setShiftAmountFlavor(Mask); // shl X, 32 == shl X, 0 + setStackPointerRegisterToSaveRestore(X86::ESP); // Set up the register classes. addRegisterClass(MVT::i8, X86::R8RegisterClass); diff --git a/lib/Target/X86/X86ISelPattern.cpp b/lib/Target/X86/X86ISelPattern.cpp index cb18354..c5d5a26 100644 --- a/lib/Target/X86/X86ISelPattern.cpp +++ b/lib/Target/X86/X86ISelPattern.cpp @@ -1229,7 +1229,7 @@ unsigned ISel::SelectExpr(SDOperand N) { cast<RegisterSDNode>(Node->getOperand(1))->getReg() : cast<RegisterSDNode>(Node)->getReg(); // Just use the specified register as our input if we can. - if (MRegisterInfo::isVirtualRegister(Reg) || Reg == X86::ESP) + if (MRegisterInfo::isVirtualRegister(Reg)) return Reg; } |