mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-12-26 13:36:28 +00:00
Adjust processFunctionBeforeCalleeSavedScan() to correctly reserve a stack
slot for the register scavenger when compiling Thumb1 functions. llvm-svn: 83023
This commit is contained in:
parent
74e63461d2
commit
9cb82ce219
@ -536,7 +536,8 @@ ARMBaseRegisterInfo::processFunctionBeforeCalleeSavedScan(MachineFunction &MF,
|
||||
}
|
||||
}
|
||||
|
||||
if (CSRegClasses[i] == ARM::GPRRegisterClass) {
|
||||
if (CSRegClasses[i] == ARM::GPRRegisterClass ||
|
||||
CSRegClasses[i] == ARM::tGPRRegisterClass) {
|
||||
if (Spilled) {
|
||||
NumGPRSpills++;
|
||||
|
||||
@ -667,7 +668,8 @@ ARMBaseRegisterInfo::processFunctionBeforeCalleeSavedScan(MachineFunction &MF,
|
||||
NumExtras--;
|
||||
}
|
||||
}
|
||||
while (NumExtras && !UnspilledCS2GPRs.empty()) {
|
||||
while (NumExtras && !UnspilledCS2GPRs.empty() &&
|
||||
!AFI->isThumb1OnlyFunction()) {
|
||||
unsigned Reg = UnspilledCS2GPRs.back();
|
||||
UnspilledCS2GPRs.pop_back();
|
||||
if (!isReservedReg(MF, Reg)) {
|
||||
|
Loading…
Reference in New Issue
Block a user