[llvm-commits] [llvm] r71783 - /llvm/trunk/lib/Transforms/Utils/SimplifyCFG.cpp
Eli Friedman
eli.friedman at gmail.com
Thu May 14 11:45:18 PDT 2009
On Thu, May 14, 2009 at 11:41 AM, Dale Johannesen <dalej at apple.com> wrote:
> + Value *V2 = I->getOperand(0)->getUnderlyingObject();
> + if (V2) {
> + GlobalVariable* GV = dyn_cast<GlobalVariable>(V2);
> + if (GV && GV->hasExternalWeakLinkage())
> + return false;
> + }
Ah, hmm, I'm not sure how I missed this when I looked at it
originally, but it's unsafe to continue if V2 or GV is null. In those
cases, you have no clue what the pointer points at.
-Eli
More information about the llvm-commits
mailing list