diff options
author | Dan Gohman <gohman@apple.com> | 2010-02-14 03:12:47 +0000 |
---|---|---|
committer | Dan Gohman <gohman@apple.com> | 2010-02-14 03:12:47 +0000 |
commit | 1d826a76f591afea445489b9a5485c345e66bf87 (patch) | |
tree | 832e56ae519da4b5d513425249705e5420cdce00 /include | |
parent | 0402577f3888889afb7a2bd18399987daefdecbe (diff) | |
download | external_llvm-1d826a76f591afea445489b9a5485c345e66bf87.zip external_llvm-1d826a76f591afea445489b9a5485c345e66bf87.tar.gz external_llvm-1d826a76f591afea445489b9a5485c345e66bf87.tar.bz2 |
In rememberInstruction, if the value being remembered is the
current insertion point, advance the current insertion point.
This avoids a use-before-def situation in a testcase extracted
from clang which is difficult to reduce to a reasonable-sized
regression test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@96151 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r-- | include/llvm/Analysis/ScalarEvolutionExpander.h | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/include/llvm/Analysis/ScalarEvolutionExpander.h b/include/llvm/Analysis/ScalarEvolutionExpander.h index a9a70cb..303bc1e 100644 --- a/include/llvm/Analysis/ScalarEvolutionExpander.h +++ b/include/llvm/Analysis/ScalarEvolutionExpander.h @@ -168,9 +168,7 @@ namespace llvm { return S->getValue(); } - void rememberInstruction(Value *I) { - if (!PostIncLoop) InsertedValues.insert(I); - } + void rememberInstruction(Value *I); Value *expandAddRecExprLiterally(const SCEVAddRecExpr *); PHINode *getAddRecExprPHILiterally(const SCEVAddRecExpr *Normalized, |