From 80fc4349707d3c5827fecd7342127ee2a0f8ea32 Mon Sep 17 00:00:00 2001 From: Ruchira Sasanka Date: Sun, 11 Nov 2001 22:37:51 +0000 Subject: Fixed FP and SP usage. SP for outgoing args - for everything else FP llvm-svn: 1258 --- llvm/lib/Target/Sparc/SparcRegInfo.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'llvm/lib/Target/Sparc') diff --git a/llvm/lib/Target/Sparc/SparcRegInfo.cpp b/llvm/lib/Target/Sparc/SparcRegInfo.cpp index 9e830632dc0..cb7009d4de0 100644 --- a/llvm/lib/Target/Sparc/SparcRegInfo.cpp +++ b/llvm/lib/Target/Sparc/SparcRegInfo.cpp @@ -665,7 +665,7 @@ void UltraSparcRegInfo::colorCallArgs(const MachineInstr *const CallMI, int argOffset = PRA.mcInfo.allocateOptionalArg(target, LR->getType()); - AdMI = cpReg2MemMI(UniLRReg, getFramePointer(), argOffset, RegType ); + AdMI = cpReg2MemMI(UniLRReg, getStackPointer(), argOffset, RegType ); } AddedInstrnsBefore.push_back( AdMI ); // Now add the instruction @@ -716,7 +716,7 @@ void UltraSparcRegInfo::colorCallArgs(const MachineInstr *const CallMI, Ad1 = cpReg2MemMI(TReg, getFramePointer(), TmpOff, RegType ); Ad2 = cpMem2RegMI(getFramePointer(), LR->getSpillOffFromFP(), TReg, RegType ); - Ad3 = cpReg2MemMI(TReg, getFramePointer(), argOffset, RegType ); + Ad3 = cpReg2MemMI(TReg, getStackPointer(), argOffset, RegType ); Ad4 = cpMem2RegMI(getFramePointer(), TmpOff, TReg, RegType ); // We directly add to CallAI->InstrnsBefore instead of adding to -- cgit v1.2.3