Fix printing of instructions with null operands.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@79243 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Dan Gohman 2009-08-17 15:28:08 +00:00
parent e04853ca78
commit 48cc73d9c7

View File

@ -689,7 +689,7 @@ void SlotTracker::processFunction() {
!I->hasName())
CreateFunctionSlot(I);
for (unsigned i = 0, e = I->getNumOperands(); i != e; ++i)
if (MDNode *N = dyn_cast<MDNode>(I->getOperand(i)))
if (MDNode *N = dyn_cast_or_null<MDNode>(I->getOperand(i)))
CreateMetadataSlot(N);
}
}