[Lldb-commits] [lldb] r139897 - in /lldb/trunk/source/Plugins: Process/Utility/RegisterContextLLDB.cpp UnwindAssembly/InstEmulation/UnwindAssemblyInstEmulation.cpp

Jason Molenda jmolenda at apple.com
Thu Sep 15 18:32:11 PDT 2011


Author: jmolenda
Date: Thu Sep 15 20:32:10 2011
New Revision: 139897

URL: http://llvm.org/viewvc/llvm-project?rev=139897&view=rev
Log:
Tighten up the 'log enable lldb unwind' printing for
the arm emulate instruction unwinder so you can leave it
on by default and not be overwhelmed.  Set verbose mode to
get the full story on how the unwindplans were created.

Modified:
    lldb/trunk/source/Plugins/Process/Utility/RegisterContextLLDB.cpp
    lldb/trunk/source/Plugins/UnwindAssembly/InstEmulation/UnwindAssemblyInstEmulation.cpp

Modified: lldb/trunk/source/Plugins/Process/Utility/RegisterContextLLDB.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/Process/Utility/RegisterContextLLDB.cpp?rev=139897&r1=139896&r2=139897&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/Process/Utility/RegisterContextLLDB.cpp (original)
+++ lldb/trunk/source/Plugins/Process/Utility/RegisterContextLLDB.cpp Thu Sep 15 20:32:10 2011
@@ -886,7 +886,7 @@
             if (active_row->GetRegisterInfo (row_regnum, unwindplan_regloc))
             {
                 have_unwindplan_regloc = true;
-                if (log && IsLogVerbose ())
+                if (log)
                 {                
                     log->Printf("%*sFrame %u supplying caller's saved reg %d's location using %s UnwindPlan",
                                 m_frame_number < 100 ? m_frame_number : 100, "", m_frame_number,
@@ -906,7 +906,7 @@
             const RegisterInfo *reg_info = GetRegisterInfoAtIndex(lldb_regnum);
             if (reg_info && abi->RegisterIsVolatile (reg_info))
             {
-                if (log)
+                if (log && IsLogVerbose ())
                 {
                     log->Printf("%*sFrame %u did not supply reg location for %d because it is volatile",
                                 m_frame_number < 100 ? m_frame_number : 100, "", m_frame_number,
@@ -1136,7 +1136,7 @@
     // If this is the 0th frame, hand this over to the live register context
     if (IsFrameZero ())
     {
-        if (log)
+        if (log && IsLogVerbose ())
         {
             log->Printf("%*sFrame %u passing along to the live register context for reg %d",
                         m_frame_number < 100 ? m_frame_number : 100, "", m_frame_number,
@@ -1171,7 +1171,7 @@
     // If this is the 0th frame, hand this over to the live register context
     if (IsFrameZero ())
     {
-        if (log)
+        if (log && IsLogVerbose ())
         {
             log->Printf("%*sFrame %u passing along to the live register context for reg %d",
                         m_frame_number < 100 ? m_frame_number : 100, "", m_frame_number,

Modified: lldb/trunk/source/Plugins/UnwindAssembly/InstEmulation/UnwindAssemblyInstEmulation.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/UnwindAssembly/InstEmulation/UnwindAssemblyInstEmulation.cpp?rev=139897&r1=139896&r2=139897&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/UnwindAssembly/InstEmulation/UnwindAssemblyInstEmulation.cpp (original)
+++ lldb/trunk/source/Plugins/UnwindAssembly/InstEmulation/UnwindAssemblyInstEmulation.cpp Thu Sep 15 20:32:10 2011
@@ -104,7 +104,7 @@
                     if (inst)
                     {
 
-                        if (log)
+                        if (log && IsLogVerbose ())
                         {
                             StreamString strm;
                             inst->Dump(&strm, inst_list.GetMaxOpcocdeByteSize (), show_address, show_bytes, &exe_ctx, raw);
@@ -130,7 +130,7 @@
             }
         }
         
-        if (log)
+        if (log && IsLogVerbose ())
         {
             StreamString strm;
             lldb::addr_t base_addr = range.GetBaseAddress().GetLoadAddress(&thread.GetProcess().GetTarget());
@@ -264,7 +264,7 @@
 {
     LogSP log(GetLogIfAllCategoriesSet (LIBLLDB_LOG_UNWIND));
 
-    if (log)
+    if (log && IsLogVerbose ())
     {
         StreamString strm;
         strm.Printf ("UnwindAssemblyInstEmulation::ReadMemory    (addr = 0x%16.16llx, dst = %p, dst_len = %zu, context = ", 
@@ -304,7 +304,7 @@
 
     LogSP log(GetLogIfAllCategoriesSet (LIBLLDB_LOG_UNWIND));
 
-    if (log)
+    if (log && IsLogVerbose ())
     {
         StreamString strm;
 
@@ -407,7 +407,7 @@
 
     LogSP log(GetLogIfAllCategoriesSet (LIBLLDB_LOG_UNWIND));
     
-    if (log)
+    if (log && IsLogVerbose ())
     {
         
         StreamString strm;
@@ -437,7 +437,7 @@
 {
     LogSP log(GetLogIfAllCategoriesSet (LIBLLDB_LOG_UNWIND));
 
-    if (log)
+    if (log && IsLogVerbose ())
     {
         
         StreamString strm;





More information about the lldb-commits mailing list