From 20b92c4d0d5f6371592f613063eca4cd96a8cc29 Mon Sep 17 00:00:00 2001 From: George Rimar Date: Tue, 10 Jul 2018 10:16:48 +0000 Subject: [PATCH] [ELF] - Report call graph profile file names in error messages. We did not report file names for some reason. llvm-svn: 336650 --- lld/ELF/Driver.cpp | 4 ++-- lld/test/ELF/cgprofile-warn.s | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lld/ELF/Driver.cpp b/lld/ELF/Driver.cpp index 386c63a..645c78f 100644 --- a/lld/ELF/Driver.cpp +++ b/lld/ELF/Driver.cpp @@ -640,9 +640,9 @@ static void readCallGraph(MemoryBufferRef MB) { const Symbol *ToSym = SymbolNameToSymbol.lookup(Fields[1]); if (Config->WarnSymbolOrdering) { if (!FromSym) - warn("call graph file: no such symbol: " + Fields[0]); + warn(MB.getBufferIdentifier() + ": no such symbol: " + Fields[0]); if (!ToSym) - warn("call graph file: no such symbol: " + Fields[1]); + warn(MB.getBufferIdentifier() + ": no such symbol: " + Fields[1]); } if (!FromSym || !ToSym || Count == 0) continue; diff --git a/lld/test/ELF/cgprofile-warn.s b/lld/test/ELF/cgprofile-warn.s index 471dc18..d6c6462a 100644 --- a/lld/test/ELF/cgprofile-warn.s +++ b/lld/test/ELF/cgprofile-warn.s @@ -25,5 +25,5 @@ A: retq # CHECK: unable to order absolute symbol: B -# CHECK: call graph file: no such symbol: adena +# CHECK: {{.*}}.call_graph: no such symbol: adena # CHECK: unable to order undefined symbol: poppy -- 2.7.4