diff --git a/lib/IR/Verifier.cpp b/lib/IR/Verifier.cpp index f49cca5a3e3..158601226ab 100644 --- a/lib/IR/Verifier.cpp +++ b/lib/IR/Verifier.cpp @@ -2239,8 +2239,10 @@ void Verifier::visitIntrinsicFunctionCall(Intrinsic::ID ID, CallInst &CI) { // know they are legal for the intrinsic!) get the intrinsic name through the // usual means. This allows us to verify the mangling of argument types into // the name. - Assert1(Intrinsic::getName(ID, ArgTys) == IF->getName(), - "Intrinsic name not mangled correctly for type arguments!", IF); + const std::string ExpectedName = Intrinsic::getName(ID, ArgTys); + Assert1(ExpectedName == IF->getName(), + "Intrinsic name not mangled correctly for type arguments! " + "Should be: " + ExpectedName, IF); // If the intrinsic takes MDNode arguments, verify that they are either global // or are local to *this* function.