diff options
| author | Dan Gohman <gohman@apple.com> | 2008-07-17 23:49:46 +0000 |
|---|---|---|
| committer | Dan Gohman <gohman@apple.com> | 2008-07-17 23:49:46 +0000 |
| commit | 0ece94384582605f64f5b90e79cfd561f9269c5f (patch) | |
| tree | afb5f97e88e5be1262666dce98a5bb52d4c81dec /llvm/lib/CodeGen/LiveIntervalAnalysis.cpp | |
| parent | e330aacbed0eff3704198f7162f5a3a3b8be36fe (diff) | |
| download | bcm5719-llvm-0ece94384582605f64f5b90e79cfd561f9269c5f.tar.gz bcm5719-llvm-0ece94384582605f64f5b90e79cfd561f9269c5f.zip | |
Re-introduce LeakDetector support for MachineInstrs and MachineBasicBlocks.
Fix a leak that this turned up in LowerSubregs.cpp.
And, comment a leak in LiveIntervalAnalysis.cpp.
llvm-svn: 53746
Diffstat (limited to 'llvm/lib/CodeGen/LiveIntervalAnalysis.cpp')
| -rw-r--r-- | llvm/lib/CodeGen/LiveIntervalAnalysis.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/CodeGen/LiveIntervalAnalysis.cpp b/llvm/lib/CodeGen/LiveIntervalAnalysis.cpp index 4f79696d00c..8c99831de18 100644 --- a/llvm/lib/CodeGen/LiveIntervalAnalysis.cpp +++ b/llvm/lib/CodeGen/LiveIntervalAnalysis.cpp @@ -1585,9 +1585,9 @@ addIntervalsForSpills(const LiveInterval &li, if (ReMatDefMI && isReMaterializable(li, VNI, ReMatDefMI, dummy)) { // Remember how to remat the def of this val#. ReMatOrigDefs[VN] = ReMatDefMI; - // Original def may be modified so we have to make a copy here. vrm must - // delete these! - ReMatDefs[VN] = ReMatDefMI = mf_->CloneMachineInstr(ReMatDefMI); + // Original def may be modified so we have to make a copy here. + // FIXME: This is a memory leak. vrm should delete these! + ReMatDefs[VN] = mf_->CloneMachineInstr(ReMatDefMI); bool CanDelete = true; if (VNI->hasPHIKill) { |

