projects
/
platform
/
upstream
/
llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
acb857b
)
GVN-hoist: invalidate MD cache (PR29144)
author
Sebastian Pop
<sebpop@gmail.com>
Sat, 27 Aug 2016 02:48:41 +0000
(
02:48
+0000)
committer
Sebastian Pop
<sebpop@gmail.com>
Sat, 27 Aug 2016 02:48:41 +0000
(
02:48
+0000)
Without invalidating the entries in the MD cache we would try to access instructions
that were removed in previous iterations of hoisting.
Differential Revision: https://reviews.llvm.org/D23927
llvm-svn: 279907
llvm/lib/Transforms/Scalar/GVNHoist.cpp
patch
|
blob
|
history
diff --git
a/llvm/lib/Transforms/Scalar/GVNHoist.cpp
b/llvm/lib/Transforms/Scalar/GVNHoist.cpp
index
e287ba7
..
4a6e934
100644
(file)
--- a/
llvm/lib/Transforms/Scalar/GVNHoist.cpp
+++ b/
llvm/lib/Transforms/Scalar/GVNHoist.cpp
@@
-846,6
+846,8
@@
private:
Repl->intersectOptionalDataWith(I);
combineKnownMetadata(Repl, I);
I->replaceAllUsesWith(Repl);
+ // Also invalidate the Alias Analysis cache.
+ MD->removeInstruction(I);
I->eraseFromParent();
}