forked from OSchip/llvm-project
bug 122:
- Correct an assert to not have redundant isa<GlobalValue> llvm-svn: 14934
This commit is contained in:
parent
bbddbf3aed
commit
49fc8a746e
|
|
@ -123,8 +123,6 @@ namespace { // Anonymous namespace for class
|
||||||
for (Module::giterator I = M.gbegin(), E = M.gend(); I != E; ++I)
|
for (Module::giterator I = M.gbegin(), E = M.gend(); I != E; ++I)
|
||||||
visitGlobalValue(*I);
|
visitGlobalValue(*I);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// If the module is broken, abort at this time.
|
// If the module is broken, abort at this time.
|
||||||
abortIfBroken();
|
abortIfBroken();
|
||||||
return false;
|
return false;
|
||||||
|
|
@ -709,8 +707,7 @@ void Verifier::visitIntrinsicFunctionCall(Intrinsic::ID ID, CallInst &CI) {
|
||||||
case Intrinsic::gcroot:
|
case Intrinsic::gcroot:
|
||||||
Assert1(FT->getNumParams() == 2,
|
Assert1(FT->getNumParams() == 2,
|
||||||
"Illegal # arguments for intrinsic function!", IF);
|
"Illegal # arguments for intrinsic function!", IF);
|
||||||
Assert1(isa<Constant>(CI.getOperand(2)) ||
|
Assert1(isa<Constant>(CI.getOperand(2)),
|
||||||
isa<GlobalValue>(CI.getOperand(2)),
|
|
||||||
"Second argument to llvm.gcroot must be a constant!", &CI);
|
"Second argument to llvm.gcroot must be a constant!", &CI);
|
||||||
NumArgs = 2;
|
NumArgs = 2;
|
||||||
break;
|
break;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue