Revert "[VENTUS][fix] No need to spill/restore callee saved registers for kernel function"
This reverts commit 85df9000bb
.
This commit is contained in:
parent
2d8205dd54
commit
6491bdfb02
|
@ -735,9 +735,6 @@ bool RISCVFrameLowering::spillCalleeSavedRegisters(
|
|||
return true;
|
||||
|
||||
MachineFunction *MF = MBB.getParent();
|
||||
// For kernel function, no need to spill callee saved register
|
||||
if(MF->getInfo<RISCVMachineFunctionInfo>()->isEntryFunction())
|
||||
return true;
|
||||
const TargetInstrInfo &TII = *MF->getSubtarget().getInstrInfo();
|
||||
DebugLoc DL;
|
||||
if (MI != MBB.end() && !MI->isDebugInstr())
|
||||
|
@ -785,9 +782,6 @@ bool RISCVFrameLowering::restoreCalleeSavedRegisters(
|
|||
return true;
|
||||
|
||||
MachineFunction *MF = MBB.getParent();
|
||||
// If kernel function, no need to restore CalleeSavedRegisters
|
||||
if(MF->getInfo<RISCVMachineFunctionInfo>()->isEntryFunction())
|
||||
return true;
|
||||
const TargetInstrInfo &TII = *MF->getSubtarget().getInstrInfo();
|
||||
DebugLoc DL;
|
||||
if (MI != MBB.end() && !MI->isDebugInstr())
|
||||
|
|
Loading…
Reference in New Issue