From: Matt Arsenault Date: Fri, 25 Apr 2014 22:22:01 +0000 (+0000) Subject: R600: Fix function name printing in LowerCall X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=d1f361aa39a94593a6f15a6ed25249c41c714c3a;p=oota-llvm.git R600: Fix function name printing in LowerCall v2: Check both ExternalSymbol and GlobalAddress Patch by: Jan Vesely git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207282 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Target/R600/AMDGPUISelLowering.cpp b/lib/Target/R600/AMDGPUISelLowering.cpp index 97107a58e71..015f0ae4d78 100644 --- a/lib/Target/R600/AMDGPUISelLowering.cpp +++ b/lib/Target/R600/AMDGPUISelLowering.cpp @@ -362,7 +362,9 @@ SDValue AMDGPUTargetLowering::LowerCall(CallLoweringInfo &CLI, StringRef FuncName(""); - if (const GlobalAddressSDNode *G = dyn_cast(Callee)) + if (const ExternalSymbolSDNode *G = dyn_cast(Callee)) + FuncName = G->getSymbol(); + else if (const GlobalAddressSDNode *G = dyn_cast(Callee)) FuncName = G->getGlobal()->getName(); DiagnosticInfoUnsupported NoCalls(Fn, "call to function " + FuncName);