mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-13 04:30:23 +00:00
Addressing mode 6 (load/store) instructions can't encode an immediate offset
for stack references. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92871 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
80c2b0d9ef
commit
ce3e769c15
@ -523,7 +523,7 @@ static unsigned estimateStackSize(MachineFunction &MF, MachineFrameInfo *MFI) {
|
||||
|
||||
/// estimateRSStackSizeLimit - Look at each instruction that references stack
|
||||
/// frames and return the stack size limit beyond which some of these
|
||||
/// instructions will require scratch register during their expansion later.
|
||||
/// instructions will require a scratch register during their expansion later.
|
||||
unsigned
|
||||
ARMBaseRegisterInfo::estimateRSStackSizeLimit(MachineFunction &MF) const {
|
||||
unsigned Limit = (1 << 12) - 1;
|
||||
@ -547,6 +547,9 @@ ARMBaseRegisterInfo::estimateRSStackSizeLimit(MachineFunction &MF) const {
|
||||
// When the stack offset is negative, we will end up using
|
||||
// the i8 instructions instead.
|
||||
return (1 << 8) - 1;
|
||||
|
||||
if (AddrMode == ARMII::AddrMode6)
|
||||
return 0;
|
||||
break; // At most one FI per instruction
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user