mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-09-15 22:25:31 +00:00
Fix a bug where we were counting the alias sets as completely used
registers for fast allocation a different way. This has us updating used registers only when we're using that exact register. Fixes rdar://9207598 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129711 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -396,7 +396,6 @@ void RAFast::definePhysReg(MachineInstr *MI, unsigned PhysReg,
|
||||
PhysRegState[PhysReg] = NewState;
|
||||
for (const unsigned *AS = TRI->getAliasSet(PhysReg);
|
||||
unsigned Alias = *AS; ++AS) {
|
||||
UsedInInstr.set(Alias);
|
||||
switch (unsigned VirtReg = PhysRegState[Alias]) {
|
||||
case regDisabled:
|
||||
break;
|
||||
@@ -734,10 +733,6 @@ void RAFast::handleThroughOperands(MachineInstr *MI,
|
||||
if (!Reg || !TargetRegisterInfo::isPhysicalRegister(Reg)) continue;
|
||||
DEBUG(dbgs() << "\tSetting reg " << Reg << " as used in instr\n");
|
||||
UsedInInstr.set(Reg);
|
||||
for (const unsigned *AS = TRI->getAliasSet(Reg); *AS; ++AS) {
|
||||
DEBUG(dbgs() << "\tSetting alias reg " << *AS << " as used in instr\n");
|
||||
UsedInInstr.set(*AS);
|
||||
}
|
||||
}
|
||||
|
||||
// Also mark PartialDefs as used to avoid reallocation.
|
||||
|
Reference in New Issue
Block a user