Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Documentation for LLDB's GUI

I've been recently been playing around with LLDB's gui feature. (A stackoverflow link about this feature is described here. My current lldb is lldb-320.4.156)

So far, it seems very convenient, especially the ability to view local variables in the current stack frame. But is there any documentation (or tutorial) on how to use the LLDB's GUI mode?


Aside: I specifically have a few questions:

  1. How to show the source code upon going into GUI mode. (Unless I stop at a breakpoint and type gui within LLDB, I can never get source code to show up.)
  2. How to rerun a program while in GUI mode. (There is nowhere to type while in GUI mode.)
  3. Are there colors in GUI mode? I notice if you type lldb --help in the command line, lldb tells you you could invoke it with a --no-use-colors option. (That being said, I've never seen colors with normal lldb mode...)
  4. Is there a way to set breakpoints, prior to running lldb?
like image 590
hlin117 Avatar asked Jan 15 '15 04:01

hlin117


People also ask

How do I run a LLDB program?

Loading a Program into lldb First we need to set the program to debug. As with gdb, you can start lldb and specify the file you wish to debug on the command line: $ lldb /Projects/Sketch/build/Debug/Sketch. app Current executable set to '/Projects/Sketch/build/Debug/Sketch.

What is LLDB command?

lldb is a next generation, high-performance debugger. It is built as a set of reusable components which highly leverage existing libraries in the larger LLVM Project, such as the Clang expression parser and LLVM disassembler.

Does LLDB have Tui?

You can also expand the regsiters by register class: I'd like to know how to resize the various windows. If you resize the terminal, the size of the stack view pane seems to remain fixed, so the symbol names always end up truncated.

How do I quit LLDB?

Type quit to exit the lldb session.


1 Answers

The GUI mode in lldb is a feature that Greg Clayton did over a few weeks of nights & weekends -- it's a really cool hack. But it's not completed to product-quality level and there's no documentation short of the command key tips that you can see with its built in help system. The biggest omission is definitely the lack of a console window where you could type arbitrary lldb commands - but adding a console pane like that was where things started to get tricky. :)

Hopefully an interested developer will pick up the gui mode work and add these features. For people who can't use a full IDE, it can be really helpful to have a text mode windowed UI when using a debugger.

like image 189
Jason Molenda Avatar answered Nov 15 '22 07:11

Jason Molenda