From: Bob Wilson Date: Tue, 23 Feb 2010 05:55:00 +0000 (+0000) Subject: Update memdep when load PRE inserts a new load, and add some debug output. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=188f428e4e76d465ac89c275318521bdfbe028eb;p=oota-llvm.git Update memdep when load PRE inserts a new load, and add some debug output. I don't have a small testcase for this. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@96890 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Transforms/Scalar/GVN.cpp b/lib/Transforms/Scalar/GVN.cpp index f015def98f0..164730c3ca0 100644 --- a/lib/Transforms/Scalar/GVN.cpp +++ b/lib/Transforms/Scalar/GVN.cpp @@ -1707,6 +1707,8 @@ bool GVN::processNonLocalLoad(LoadInst *LI, // Add the newly created load. ValuesPerBlock.push_back(AvailableValueInBlock::get(UnavailablePred, NewLoad)); + MD->invalidateCachedPointerInfo(LoadPtr); + DEBUG(dbgs() << "GVN INSERTED " << *NewLoad << '\n'); } // Perform PHI construction.