mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-12 17:32:19 +00:00
Remove VirtRegMap::getRegAllocPref().
Now that there can be multiple hint registers from targets, it doesn't make sense to have a function that returns 'the' preferred register. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@169190 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
980bddfb1c
commit
46f6fe7a45
@ -126,9 +126,6 @@ namespace llvm {
|
||||
grow();
|
||||
}
|
||||
|
||||
/// @brief returns the register allocation preference.
|
||||
unsigned getRegAllocPref(unsigned virtReg);
|
||||
|
||||
/// @brief returns true if VirtReg is assigned to its preferred physreg.
|
||||
bool hasPreferredPhys(unsigned VirtReg);
|
||||
|
||||
|
@ -77,17 +77,6 @@ unsigned VirtRegMap::createSpillSlot(const TargetRegisterClass *RC) {
|
||||
return SS;
|
||||
}
|
||||
|
||||
unsigned VirtRegMap::getRegAllocPref(unsigned virtReg) {
|
||||
std::pair<unsigned, unsigned> Hint = MRI->getRegAllocationHint(virtReg);
|
||||
unsigned physReg = Hint.second;
|
||||
if (TargetRegisterInfo::isVirtualRegister(physReg) && hasPhys(physReg))
|
||||
physReg = getPhys(physReg);
|
||||
if (Hint.first == 0)
|
||||
return (TargetRegisterInfo::isPhysicalRegister(physReg))
|
||||
? physReg : 0;
|
||||
return TRI->ResolveRegAllocHint(Hint.first, physReg, *MF);
|
||||
}
|
||||
|
||||
bool VirtRegMap::hasPreferredPhys(unsigned VirtReg) {
|
||||
unsigned Hint = MRI->getSimpleHint(VirtReg);
|
||||
if (!Hint)
|
||||
|
Loading…
x
Reference in New Issue
Block a user