summaryrefslogtreecommitdiffstats
path: root/lldb
diff options
context:
space:
mode:
authorGreg Clayton <gclayton@apple.com>2014-03-12 18:26:18 +0000
committerGreg Clayton <gclayton@apple.com>2014-03-12 18:26:18 +0000
commit88e193a0533278bfa1f1ff407665ef0e84509a13 (patch)
treecb04f80422931bf27176d58104885f070067fef8 /lldb
parent0fc7bdc821787fa55837b49d932fc13eac49f5b8 (diff)
downloadbcm5719-llvm-88e193a0533278bfa1f1ff407665ef0e84509a13.tar.gz
bcm5719-llvm-88e193a0533278bfa1f1ff407665ef0e84509a13.zip
If DWARF debug info and verbose mode is enabled ("log enable dwarf info verbose"), then dump all DIEs for a compile unit after all DIEs have been parsed for a compile unit.
llvm-svn: 203692
Diffstat (limited to 'lldb')
-rw-r--r--lldb/source/Plugins/SymbolFile/DWARF/DWARFCompileUnit.cpp12
1 files changed, 8 insertions, 4 deletions
diff --git a/lldb/source/Plugins/SymbolFile/DWARF/DWARFCompileUnit.cpp b/lldb/source/Plugins/SymbolFile/DWARF/DWARFCompileUnit.cpp
index cf664db28ac..c63def1dc20 100644
--- a/lldb/source/Plugins/SymbolFile/DWARF/DWARFCompileUnit.cpp
+++ b/lldb/source/Plugins/SymbolFile/DWARF/DWARFCompileUnit.cpp
@@ -265,12 +265,16 @@ DWARFCompileUnit::ExtractDIEsIfNeeded (bool cu_die_only)
DWARFDebugInfoEntry::collection exact_size_die_array (m_die_array.begin(), m_die_array.end());
exact_size_die_array.swap (m_die_array);
}
- Log *log (LogChannelDWARF::GetLogIfAll (DWARF_LOG_DEBUG_INFO | DWARF_LOG_VERBOSE));
- if (log)
+ Log *verbose_log (LogChannelDWARF::GetLogIfAll (DWARF_LOG_DEBUG_INFO | DWARF_LOG_VERBOSE));
+ if (verbose_log)
{
StreamString strm;
- DWARFDebugInfoEntry::DumpDIECollection (strm, m_die_array);
- log->PutCString (strm.GetString().c_str());
+ Dump(&strm);
+ if (m_die_array.empty())
+ strm.Printf("error: no DIE for compile unit");
+ else
+ m_die_array[0].Dump(m_dwarf2Data, this, strm, UINT32_MAX);
+ verbose_log->PutCString (strm.GetString().c_str());
}
return m_die_array.size();
OpenPOWER on IntegriCloud