Fix PR3486. Fix a bug in code that manually patch physical register live interval after its sub-register is coalesced with a virtual register.
llvm-svn: 64082
This commit is contained in:
@@ -824,11 +824,18 @@ bool LiveIntervals::findReachableMBBs(unsigned Start, unsigned End,
|
||||
}
|
||||
|
||||
LiveInterval* LiveIntervals::createInterval(unsigned reg) {
|
||||
float Weight = TargetRegisterInfo::isPhysicalRegister(reg) ?
|
||||
HUGE_VALF : 0.0F;
|
||||
float Weight = TargetRegisterInfo::isPhysicalRegister(reg) ? HUGE_VALF : 0.0F;
|
||||
return new LiveInterval(reg, Weight);
|
||||
}
|
||||
|
||||
/// dupInterval - Duplicate a live interval. The caller is responsible for
|
||||
/// managing the allocated memory.
|
||||
LiveInterval* LiveIntervals::dupInterval(LiveInterval *li) {
|
||||
LiveInterval *NewLI = createInterval(li->reg);
|
||||
NewLI->Copy(*li, getVNInfoAllocator());
|
||||
return NewLI;
|
||||
}
|
||||
|
||||
/// getVNInfoSourceReg - Helper function that parses the specified VNInfo
|
||||
/// copy field and returns the source register that defines it.
|
||||
unsigned LiveIntervals::getVNInfoSourceReg(const VNInfo *VNI) const {
|
||||
|
||||
Reference in New Issue
Block a user