mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-24 19:52:54 +01:00
Now that we are deleting unused live intervals during allocation, pointers may be reused.
Use the virtual register number as a cache tag instead. They are not reused. llvm-svn: 127561
This commit is contained in:
parent
2d87d5139b
commit
7d23be25ab
@ -163,7 +163,7 @@ public:
|
||||
bool CheckedFirstInterference;
|
||||
bool SeenAllInterferences;
|
||||
bool SeenUnspillableVReg;
|
||||
unsigned Tag;
|
||||
unsigned Tag, VTag;
|
||||
|
||||
public:
|
||||
Query(): LiveUnion(), VirtReg() {}
|
||||
@ -181,11 +181,12 @@ public:
|
||||
SeenAllInterferences = false;
|
||||
SeenUnspillableVReg = false;
|
||||
Tag = 0;
|
||||
VTag = 0;
|
||||
}
|
||||
|
||||
void init(LiveInterval *VReg, LiveIntervalUnion *LIU) {
|
||||
assert(VReg && LIU && "Invalid arguments");
|
||||
if (VirtReg == VReg && LiveUnion == LIU && !LIU->changedSince(Tag)) {
|
||||
if (VReg->reg == VTag && LiveUnion == LIU && !LIU->changedSince(Tag)) {
|
||||
// Retain cached results, e.g. firstInterference.
|
||||
return;
|
||||
}
|
||||
@ -193,6 +194,7 @@ public:
|
||||
LiveUnion = LIU;
|
||||
VirtReg = VReg;
|
||||
Tag = LIU->getTag();
|
||||
VTag = VReg->reg;
|
||||
}
|
||||
|
||||
LiveInterval &virtReg() const {
|
||||
|
Loading…
Reference in New Issue
Block a user