Clear VisitedPHIs after use.

llvm-svn: 84080
This commit is contained in:
Evan Cheng 2009-10-14 06:46:26 +00:00
parent 907fd9c3fb
commit 37a7a18748

View File

@ -203,8 +203,10 @@ namespace {
BasicAliasAnalysis() : NoAA(&ID) {} BasicAliasAnalysis() : NoAA(&ID) {}
AliasResult alias(const Value *V1, unsigned V1Size, AliasResult alias(const Value *V1, unsigned V1Size,
const Value *V2, unsigned V2Size) { const Value *V2, unsigned V2Size) {
assert(VisitedPHIs.empty() && "VisitedPHIs must be cleared after use!");
AliasResult Alias = aliasCheck(V1, V1Size, V2, V2Size);
VisitedPHIs.clear(); VisitedPHIs.clear();
return aliasCheck(V1, V1Size, V2, V2Size); return Alias;
} }
ModRefResult getModRefInfo(CallSite CS, Value *P, unsigned Size); ModRefResult getModRefInfo(CallSite CS, Value *P, unsigned Size);