summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorMatthias Braun <matze@braunis.de>2014-12-24 02:11:43 +0000
committerMatthias Braun <matze@braunis.de>2014-12-24 02:11:43 +0000
commitf603c88d13f583ef25afbcab122007a897e59e61 (patch)
tree0716d03ca0e2c12a5866a254c0c1eae8f4398ded /llvm/lib
parent283e20219e42607d97638c85b31f1e68c99c15ad (diff)
downloadbcm5719-llvm-f603c88d13f583ef25afbcab122007a897e59e61.tar.gz
bcm5719-llvm-f603c88d13f583ef25afbcab122007a897e59e61.zip
LiveIntervalAnalysis: Fix performance bug that I introduced in r224663.
Without a reference the code did not remember when moving the iterators of the subranges/registerunit ranges forward and instead would scan from the beginning again at the next position. llvm-svn: 224803
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/CodeGen/LiveIntervalAnalysis.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/LiveIntervalAnalysis.cpp b/llvm/lib/CodeGen/LiveIntervalAnalysis.cpp
index 8c53658595c..56f38b6407d 100644
--- a/llvm/lib/CodeGen/LiveIntervalAnalysis.cpp
+++ b/llvm/lib/CodeGen/LiveIntervalAnalysis.cpp
@@ -676,7 +676,7 @@ void LiveIntervals::addKillFlags(const VirtRegMap *VRM) {
// There should be no kill flag on FOO when %vreg5 is rewritten as %EAX.
for (auto &RUP : RU) {
const LiveRange &RURange = *RUP.first;
- LiveRange::const_iterator I = RUP.second;
+ LiveRange::const_iterator &I = RUP.second;
if (I == RURange.end())
continue;
I = RURange.advanceTo(I, RI->end);
@@ -704,7 +704,7 @@ void LiveIntervals::addKillFlags(const VirtRegMap *VRM) {
DefinedLanesMask = 0;
for (auto &SRP : SRs) {
const LiveInterval::SubRange &SR = *SRP.first;
- LiveRange::const_iterator I = SRP.second;
+ LiveRange::const_iterator &I = SRP.second;
if (I == SR.end())
continue;
I = SR.advanceTo(I, RI->end);
OpenPOWER on IntegriCloud