diff options
Diffstat (limited to 'lib/Analysis/IPA/GlobalsModRef.cpp')
-rw-r--r-- | lib/Analysis/IPA/GlobalsModRef.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Analysis/IPA/GlobalsModRef.cpp b/lib/Analysis/IPA/GlobalsModRef.cpp index 7c305b7a5e..e34d03bbdd 100644 --- a/lib/Analysis/IPA/GlobalsModRef.cpp +++ b/lib/Analysis/IPA/GlobalsModRef.cpp @@ -251,8 +251,8 @@ bool GlobalsModRef::AnalyzeUsesOfPointer(Value *V, } else { return true; } - } else if (SetCondInst *SCI = dyn_cast<SetCondInst>(*UI)) { - if (!isa<ConstantPointerNull>(SCI->getOperand(1))) + } else if (ICmpInst *ICI = dyn_cast<ICmpInst>(*UI)) { + if (!isa<ConstantPointerNull>(ICI->getOperand(1))) return true; // Allow comparison against null. } else if (FreeInst *F = dyn_cast<FreeInst>(*UI)) { Writers.push_back(F->getParent()->getParent()); |