mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-02-08 13:26:19 +00:00
When checking whether a def of an aliased register is dead, ask the
machineinstr whether the aliased register is dead, rather than the original register is dead. This allows it to get the correct answer when examining an instruction like this: CALLpcrel32 <ga:foo>, %AL<imp-def>, %EAX<imp-def,dead> where EAX is dead but a subregister of it is still live. This fixes PR5294. llvm-svn: 85135
This commit is contained in:
parent
7ea628e8db
commit
97690f7a2a
@ -208,7 +208,7 @@ void ScheduleDAGInstrs::BuildSchedGraph(AliasAnalysis *AA) {
|
||||
SUnit *DefSU = DefList[i];
|
||||
if (DefSU != SU &&
|
||||
(Kind != SDep::Output || !MO.isDead() ||
|
||||
!DefSU->getInstr()->registerDefIsDead(Reg)))
|
||||
!DefSU->getInstr()->registerDefIsDead(*Alias)))
|
||||
DefSU->addPred(SDep(SU, Kind, AOLatency, /*Reg=*/ *Alias));
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user