diff options
author | Owen Anderson <resistor@mac.com> | 2008-08-13 21:49:13 +0000 |
---|---|---|
committer | Owen Anderson <resistor@mac.com> | 2008-08-13 21:49:13 +0000 |
commit | 51f689a6521ad68aa10c1ad238d6f3a6b6a60120 (patch) | |
tree | 22d1fae0f92a0efa19e44ab98313c90be9b67752 /llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp | |
parent | 16306107cf7d7678f27ae583fb1967d440fe0737 (diff) | |
download | bcm5719-llvm-51f689a6521ad68aa10c1ad238d6f3a6b6a60120.tar.gz bcm5719-llvm-51f689a6521ad68aa10c1ad238d6f3a6b6a60120.zip |
Make the allocation of LiveIntervals explicit, rather than holding them in the r2iMap_ by value. This will prevent references to them from being invalidated
if the map is changed.
llvm-svn: 54763
Diffstat (limited to 'llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp')
-rw-r--r-- | llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp b/llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp index 933465b0004..b3e3409da34 100644 --- a/llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp +++ b/llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp @@ -2091,7 +2091,7 @@ bool SimpleRegisterCoalescing::runOnMachineFunction(MachineFunction &fn) { joinIntervals(); DOUT << "********** INTERVALS POST JOINING **********\n"; for (LiveIntervals::iterator I = li_->begin(), E = li_->end(); I != E; ++I){ - I->second.print(DOUT, tri_); + I->second->print(DOUT, tri_); DOUT << "\n"; } } @@ -2164,7 +2164,7 @@ bool SimpleRegisterCoalescing::runOnMachineFunction(MachineFunction &fn) { } for (LiveIntervals::iterator I = li_->begin(), E = li_->end(); I != E; ++I) { - LiveInterval &LI = I->second; + LiveInterval &LI = *I->second; if (TargetRegisterInfo::isVirtualRegister(LI.reg)) { // If the live interval length is essentially zero, i.e. in every live // range the use follows def immediately, it doesn't make sense to spill |