forked from OSchip/llvm-project
When testing whether a given SCEV depends on a temporary symbolic
name, test whether the SCEV itself is that temporary symbolic name, in addition to checking whether the symbolic name appears as a possibly-indirect operand. llvm-svn: 96216
This commit is contained in:
parent
b02cdaaa9c
commit
fefbff9cd8
|
@ -2566,7 +2566,7 @@ ScalarEvolution::ForgetSymbolicName(Instruction *I, const SCEV *SymName) {
|
|||
if (It != Scalars.end()) {
|
||||
// Short-circuit the def-use traversal if the symbolic name
|
||||
// ceases to appear in expressions.
|
||||
if (!It->second->hasOperand(SymName))
|
||||
if (It->second != SymName && !It->second->hasOperand(SymName))
|
||||
continue;
|
||||
|
||||
// SCEVUnknown for a PHI either means that it has an unrecognized
|
||||
|
|
Loading…
Reference in New Issue