summaryrefslogtreecommitdiffstats
path: root/llvm/lib/ExecutionEngine
diff options
context:
space:
mode:
authorLang Hames <lhames@gmail.com>2018-09-10 22:09:11 +0000
committerLang Hames <lhames@gmail.com>2018-09-10 22:09:11 +0000
commitafb8b5d95430eed2148e58c88319dded587010c5 (patch)
treee4bd7d215ed7994db5a0a2ba1314fd0f0fb0a873 /llvm/lib/ExecutionEngine
parent7c4814306d8a1460b28e9042d95697eadf3e8df0 (diff)
downloadbcm5719-llvm-afb8b5d95430eed2148e58c88319dded587010c5.tar.gz
bcm5719-llvm-afb8b5d95430eed2148e58c88319dded587010c5.zip
[ORC] Render unresolved symbol addresses as "<not resolved>" in JITDylib::dump.
This is easier to spot among the real addresses than "0x0000000000000000". llvm-svn: 341873
Diffstat (limited to 'llvm/lib/ExecutionEngine')
-rw-r--r--llvm/lib/ExecutionEngine/Orc/Core.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/llvm/lib/ExecutionEngine/Orc/Core.cpp b/llvm/lib/ExecutionEngine/Orc/Core.cpp
index baee50eefde..1a1fd6384fc 100644
--- a/llvm/lib/ExecutionEngine/Orc/Core.cpp
+++ b/llvm/lib/ExecutionEngine/Orc/Core.cpp
@@ -1508,8 +1508,11 @@ void JITDylib::dump(raw_ostream &OS) {
<< "Symbol table:\n";
for (auto &KV : Symbols) {
- OS << " \"" << *KV.first
- << "\": " << format("0x%016x", KV.second.getAddress());
+ OS << " \"" << *KV.first << "\": ";
+ if (auto Addr = KV.second.getAddress())
+ OS << format("0x%016x", Addr);
+ else
+ OS << "<not resolved>";
if (KV.second.getFlags().isLazy() ||
KV.second.getFlags().isMaterializing()) {
OS << " (";
OpenPOWER on IntegriCloud