[lldb-dev] [RFC] lldb integration with (user mode) qemu

Pavel Labath via lldb-dev lldb-dev at lists.llvm.org
Fri Nov 5 07:03:06 PDT 2021


On 03/11/2021 14:53, David Spickett wrote:
>> Yeah, I think we can start with that.
> 
> No need to consider this now but it could easily be adapted to
> qemu-system as well. Spinning up qemu-system for Cortex-M debug might
> be a future use case. Once you've got a "run this program and connect
> to this port" platform you can sub in almost anything that talks GDB.
> 

I actually did consider this, but it was not clear to me how this would 
tie in to the rest of lldb. The "run qemu and connect to it" part could 
be reused, of course, but what else? What would be the "executable" that 
we "run" in system mode. Is it the kernel image? Disk image?

I have a feeling there wouldn't be much added value in this "platform" 
over say a python command which implements the start-up dance. OTOH, a 
proper user-mode platform enables one to hook in to all the usual lldb 
goodies like specifying the application's command line arguments, 
environment variables, can help with locating shared libraries, etc.

pl


More information about the lldb-dev mailing list