set the ppc64 stack pointer right, dynamic alloca now works for ppc64

llvm-svn: 31028
This commit is contained in:
Chris Lattner 2006-10-18 01:20:43 +00:00
parent 6c403f7102
commit 0f686ec438

View File

@ -261,7 +261,11 @@ PPCTargetLowering::PPCTargetLowering(TargetMachine &TM)
setSetCCResultType(MVT::i32);
setShiftAmountType(MVT::i32);
setSetCCResultContents(ZeroOrOneSetCCResult);
setStackPointerRegisterToSaveRestore(PPC::R1);
if (TM.getSubtarget<PPCSubtarget>().isPPC64())
setStackPointerRegisterToSaveRestore(PPC::X1);
else
setStackPointerRegisterToSaveRestore(PPC::R1);
// We have target-specific dag combine patterns for the following nodes:
setTargetDAGCombine(ISD::SINT_TO_FP);