[Lldb-commits] [PATCH] Allow specification of no source display on stop

Randy Smith rdsmith at chromium.org
Thu Jul 3 11:42:23 PDT 2014

Based on r212225.  I've sketched out my rationale for this change in
http://llvm.org/bugs/show_bug.cgi?id=20149.  It's fairly simple; is someone
willing to take a look?

Note that I don't (yet) have commit access, so if this patch is approved
someone will need to land it for me.  (I found the LLVM and LLDB pages not
completely consistent around the process for gaining commit access, so I'm
going with the LLVM "contribute several patches and then ask".)

I ran the "check-lldb" test suite on Linux, and found no difference in
results between r212225 and r212225+my patch.  (As a side note, what should
I expect from the Linux test suite?  TestConvenienceVariables.py is failing
for me at top of tree.)

-- Randy
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20140703/3f13a8d0/attachment.html>
-------------- next part --------------
diff --git a/source/Target/StackFrame.cpp b/source/Target/StackFrame.cpp
index 0ba30be..3cafcdc 100644
--- a/source/Target/StackFrame.cpp
+++ b/source/Target/StackFrame.cpp
@@ -1444,13 +1444,12 @@ StackFrame::GetStatus (Stream& strm,
             const uint32_t source_lines_after = debugger.GetStopSourceLineCount(false);
             disasm_display = debugger.GetStopDisassemblyDisplay ();
-            if (source_lines_before > 0 || source_lines_after > 0)
+            GetSymbolContext(eSymbolContextCompUnit | eSymbolContextLineEntry);
+            if (m_sc.comp_unit && m_sc.line_entry.IsValid())
-                GetSymbolContext(eSymbolContextCompUnit | eSymbolContextLineEntry);
-                if (m_sc.comp_unit && m_sc.line_entry.IsValid())
+                have_source = true;
+                if (source_lines_before > 0 || source_lines_after > 0)
-                    have_source = true;
                     target->GetSourceManager().DisplaySourceLinesWithLineNumbers (m_sc.line_entry.file,

More information about the lldb-commits mailing list