aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Transforms/IPO/InlineSimple.cpp
diff options
context:
space:
mode:
authorNick Lewycky <nicholas@mxc.ca>2010-05-12 21:48:15 +0000
committerNick Lewycky <nicholas@mxc.ca>2010-05-12 21:48:15 +0000
commitc63aa1e8ab8d622a34f6df147acb35acdb6cf2d6 (patch)
treedfc836217dace6abc9c7c75b05fe6c0e3322d769 /llvm/lib/Transforms/IPO/InlineSimple.cpp
parent12a78f502a613dceedd8a9c7a361f5efabcbe28b (diff)
downloadllvm-c63aa1e8ab8d622a34f6df147acb35acdb6cf2d6.zip
llvm-c63aa1e8ab8d622a34f6df147acb35acdb6cf2d6.tar.gz
llvm-c63aa1e8ab8d622a34f6df147acb35acdb6cf2d6.tar.bz2
Clear CachedFunctionInfo upon Pass::releaseMemory. Because ValueMap will abort
on RAUW of functions, this is a correctness issue instead of a mere memory usage problem. No testcase until the new MergeFunctions can land. llvm-svn: 103653
Diffstat (limited to 'llvm/lib/Transforms/IPO/InlineSimple.cpp')
-rw-r--r--llvm/lib/Transforms/IPO/InlineSimple.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/llvm/lib/Transforms/IPO/InlineSimple.cpp b/llvm/lib/Transforms/IPO/InlineSimple.cpp
index 46cf4b2..74b4a1c 100644
--- a/llvm/lib/Transforms/IPO/InlineSimple.cpp
+++ b/llvm/lib/Transforms/IPO/InlineSimple.cpp
@@ -49,6 +49,9 @@ namespace {
CA.growCachedCostInfo(Caller, Callee);
}
virtual bool doInitialization(CallGraph &CG);
+ void releaseMemory() {
+ CA.clear();
+ }
};
}