projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3188cab
)
Expand the scope to include global values because they are now constants
author
Reid Spencer
<rspencer@reidspencer.com>
Sun, 18 Jul 2004 08:32:10 +0000
(08:32 +0000)
committer
Reid Spencer
<rspencer@reidspencer.com>
Sun, 18 Jul 2004 08:32:10 +0000
(08:32 +0000)
too.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14964
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/Transforms/Scalar/GCSE.cpp
patch
|
blob
|
history
diff --git
a/lib/Transforms/Scalar/GCSE.cpp
b/lib/Transforms/Scalar/GCSE.cpp
index c24941320fc89fc4ffedbe21e6c23d74b628857f..a3452a3f847101f361b282266d68f24d411172cd 100644
(file)
--- a/
lib/Transforms/Scalar/GCSE.cpp
+++ b/
lib/Transforms/Scalar/GCSE.cpp
@@
-185,7
+185,7
@@
void GCSE::ReplaceInstructionWith(Instruction *I, Value *V) {
// If we are not replacing the instruction with a constant, we cannot do
// anything special.
- if (!isa<Constant>(V)
|| isa<GlobalValue>(V)
) {
+ if (!isa<Constant>(V)) {
I->replaceAllUsesWith(V);
if (InvokeInst *II = dyn_cast<InvokeInst>(I)) {