diff options
author | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2011-03-17 20:37:07 +0000 |
---|---|---|
committer | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2011-03-17 20:37:07 +0000 |
commit | 8630840c30a99e54414c0ee9b39928813301dcfc (patch) | |
tree | 72387a2f78bd3a5a2c92d3ba40eca404749dd3d5 /llvm/lib/CodeGen/SplitKit.cpp | |
parent | 35944dda103ed588b68970c24bcd79b26d1b2dfd (diff) | |
download | llvm-8630840c30a99e54414c0ee9b39928813301dcfc.zip llvm-8630840c30a99e54414c0ee9b39928813301dcfc.tar.gz llvm-8630840c30a99e54414c0ee9b39928813301dcfc.tar.bz2 |
Dead code elimination may separate the live interval into multiple connected components.
I have convinced myself that it can only happen when a phi value dies. When it
happens, allocate new virtual registers for the components.
llvm-svn: 127827
Diffstat (limited to 'llvm/lib/CodeGen/SplitKit.cpp')
-rw-r--r-- | llvm/lib/CodeGen/SplitKit.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/CodeGen/SplitKit.cpp b/llvm/lib/CodeGen/SplitKit.cpp index 6f7b972..ff00bd8 100644 --- a/llvm/lib/CodeGen/SplitKit.cpp +++ b/llvm/lib/CodeGen/SplitKit.cpp @@ -538,11 +538,11 @@ void SplitEditor::openIntv() { // Create the complement as index 0. if (Edit->empty()) - Edit->create(MRI, LIS, VRM); + Edit->create(LIS, VRM); // Create the open interval. OpenIdx = Edit->size(); - Edit->create(MRI, LIS, VRM); + Edit->create(LIS, VRM); } SlotIndex SplitEditor::enterIntvBefore(SlotIndex Idx) { @@ -802,7 +802,7 @@ void SplitEditor::deleteRematVictims() { if (Dead.empty()) return; - Edit->eliminateDeadDefs(Dead, LIS, TII); + Edit->eliminateDeadDefs(Dead, LIS, VRM, TII); } void SplitEditor::finish() { @@ -866,7 +866,7 @@ void SplitEditor::finish() { SmallVector<LiveInterval*, 8> dups; dups.push_back(li); for (unsigned i = 1; i != NumComp; ++i) - dups.push_back(&Edit->create(MRI, LIS, VRM)); + dups.push_back(&Edit->create(LIS, VRM)); ConEQ.Distribute(&dups[0], MRI); } |