From: Xinliang David Li Date: Fri, 24 Aug 2018 21:38:24 +0000 (+0000) Subject: [PGO] add target md5sum in warning message for icall X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=bcf726a32d1cc341a25d0218359cf21825e12d83;p=platform%2Fupstream%2Fllvm.git [PGO] add target md5sum in warning message for icall Differential revision: http://reviews.llvm.org/D51193 llvm-svn: 340657 --- diff --git a/llvm/lib/Transforms/Instrumentation/IndirectCallPromotion.cpp b/llvm/lib/Transforms/Instrumentation/IndirectCallPromotion.cpp index 27fb0e4..d839dd2 100644 --- a/llvm/lib/Transforms/Instrumentation/IndirectCallPromotion.cpp +++ b/llvm/lib/Transforms/Instrumentation/IndirectCallPromotion.cpp @@ -269,7 +269,8 @@ ICallPromotionFunc::getPromotionCandidatesForCallSite( LLVM_DEBUG(dbgs() << " Not promote: Cannot find the target\n"); ORE.emit([&]() { return OptimizationRemarkMissed(DEBUG_TYPE, "UnableToFindTarget", Inst) - << "Cannot promote indirect call: target not found"; + << "Cannot promote indirect call: target with md5sum " + << ore::NV("target md5sum", Target) << " not found"; }); break; } diff --git a/llvm/test/Transforms/PGOProfile/icp_mismatch_msg.ll b/llvm/test/Transforms/PGOProfile/icp_mismatch_msg.ll index 5ad4760..5484d22 100644 --- a/llvm/test/Transforms/PGOProfile/icp_mismatch_msg.ll +++ b/llvm/test/Transforms/PGOProfile/icp_mismatch_msg.ll @@ -2,7 +2,7 @@ ; RUN: opt < %s -passes=pgo-icall-prom -pass-remarks-missed=pgo-icall-prom -S 2>& 1 | FileCheck %s ; CHECK: remark: :0:0: Cannot promote indirect call to func4 with count of 1234: The number of arguments mismatch -; CHECK: remark: :0:0: Cannot promote indirect call: target not found +; CHECK: remark: :0:0: Cannot promote indirect call: target with md5sum{{.*}} not found ; CHECK: remark: :0:0: Cannot promote indirect call to func2 with count of 7890: Return type mismatch target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"