summaryrefslogtreecommitdiff
path: root/lib/Transforms/Scalar/SCCP.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Transforms/Scalar/SCCP.cpp')
-rw-r--r--lib/Transforms/Scalar/SCCP.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/Transforms/Scalar/SCCP.cpp b/lib/Transforms/Scalar/SCCP.cpp
index 6ada2882e3..7fa1a08f8a 100644
--- a/lib/Transforms/Scalar/SCCP.cpp
+++ b/lib/Transforms/Scalar/SCCP.cpp
@@ -1662,7 +1662,10 @@ static bool AddressIsTaken(GlobalValue *GV) {
}
bool IPSCCP::runOnModule(Module &M) {
+ Context = &M.getContext();
+
SCCPSolver Solver;
+ Solver.setContext(Context);
// Loop over all functions, marking arguments to those with their addresses
// taken or that are external as overdefined.