fix a bogus assertion

llvm-svn: 20675
This commit is contained in:
Chris Lattner 2005-03-18 23:18:30 +00:00
parent 5bd948b4d7
commit 30525a04c1
1 changed files with 1 additions and 1 deletions

View File

@ -190,7 +190,7 @@ DSAA::getModRefInfo(CallSite CS, Value *P, unsigned Size) {
DSScalarMap &CallerSM = CallerTDGraph.getScalarMap();
DSScalarMap::iterator NI = CallerSM.find(P);
if (NI == CallerSM.end()) {
if (isa<ConstantPointerNull>(P))
if (isa<ConstantPointerNull>(P) || isa<UndefValue>(P))
Result = NoModRef; // null is never modified :)
else {
assert(isa<GlobalVariable>(P) &&