From a6fcb69f2863930740d73e32140763f6d299c6ff Mon Sep 17 00:00:00 2001 From: Alexei Starovoitov Date: Tue, 17 Jan 2017 21:14:00 +0000 Subject: [PATCH] [bpf] fix stack-use-after-scope Signed-off-by: Alexei Starovoitov git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@292258 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/BPF/BPFISelLowering.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/lib/Target/BPF/BPFISelLowering.cpp b/lib/Target/BPF/BPFISelLowering.cpp index b222022f065..b9b3dff95c0 100644 --- a/lib/Target/BPF/BPFISelLowering.cpp +++ b/lib/Target/BPF/BPFISelLowering.cpp @@ -308,13 +308,13 @@ SDValue BPFTargetLowering::LowerCall(TargetLowering::CallLoweringInfo &CLI, // Likewise ExternalSymbol -> TargetExternalSymbol. if (GlobalAddressSDNode *G = dyn_cast(Callee)) { auto GV = G->getGlobal(); - Twine Msg("A call to global function '" + StringRef(GV->getName()) - + "' is not supported. " - + (GV->isDeclaration() ? - "Only calls to predefined BPF helpers are allowed." : - "Please use __attribute__((always_inline) to make sure" - " this function is inlined.")); - fail(CLI.DL, DAG, Msg); + fail(CLI.DL, DAG, + "A call to global function '" + StringRef(GV->getName()) + + "' is not supported. " + + (GV->isDeclaration() ? + "Only calls to predefined BPF helpers are allowed." : + "Please use __attribute__((always_inline) to make sure" + " this function is inlined.")); Callee = DAG.getTargetGlobalAddress(G->getGlobal(), CLI.DL, PtrVT, G->getOffset(), 0); } else if (ExternalSymbolSDNode *E = dyn_cast(Callee)) { -- 2.40.0