Add an unwind log Printf to note when an eh_frame section is
loaded/parsed. Should add timers to this eventually.
Delay getting a full UnwindPlan if it's possible to unwind with
just a fast UnwindPlan. This keeps us from reading the eh_frame
section unless we hit something built -fomit-frame pointer or we
hit a frame with no symbol (read: no start address) available.
It doesn't look like it is correctly falling back to using the
full UnwindPlan to provide additional registers that the fast
UnwindPlan doesn't supply; e.g. go to the middle of a stack and
ask for r12 and it will show you the value of r12 in frame 0.
That's a bug for tomorrow.
git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@117361 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Symbol/DWARFCallFrameInfo.cpp b/source/Symbol/DWARFCallFrameInfo.cpp
index 9456a94..ee2c68b 100644
--- a/source/Symbol/DWARFCallFrameInfo.cpp
+++ b/source/Symbol/DWARFCallFrameInfo.cpp
@@ -12,6 +12,7 @@
// C++ Includes
#include <list>
+#include "lldb/Core/Log.h"
#include "lldb/Core/Section.h"
#include "lldb/Symbol/DWARFCallFrameInfo.h"
#include "lldb/Core/ArchSpec.h"
@@ -284,9 +285,15 @@
if (m_fde_index_initialized)
return;
+
dw_offset_t offset = 0;
if (m_cfi_data_initialized == false)
{
+ Log *log = GetLogIfAllCategoriesSet (LIBLLDB_LOG_UNWIND);
+ if (log)
+ {
+ log->Printf ("Reading eh_frame information for %s", m_objfile.GetFileSpec().GetFilename().GetCString());
+ }
m_section->ReadSectionDataFromObjectFile (&m_objfile, m_cfi_data);
m_cfi_data_initialized = true;
}