Author Topic: [Feature request] support lldb debugger  (Read 2850 times)

Offline SpaceCadet

  • Multiple posting newcomer
  • *
  • Posts: 22
[Feature request] support lldb debugger
« on: August 17, 2022, 07:30:10 pm »
the lldb debugger works very much like gdb.  i suspect it would function in parallel to the existing debugger.  lldb is just one of many tools that make up llvm.  the documentation is pretty good.  the code is robust.

Offline Pecan

  • Plugin developer
  • Lives here!
  • ****
  • Posts: 2750
Re: [Feature request] support lldb debugger
« Reply #1 on: August 17, 2022, 08:55:46 pm »
@AndrewCot

Is it possible to use lldb against a binary built with GDB?
Or do you have to build with the clang compiler?

Offline AndrewCot

  • Plugin developer
  • Lives here!
  • ****
  • Posts: 678
Re: [Feature request] support lldb debugger
« Reply #2 on: August 18, 2022, 03:51:58 am »
You cannot replace GDB with LLDB as LLDB's interfaces are not compatible with either of GDB's interfaces (either GDB annotations or GDB/MI interface).

What are you trying to do with C::B and LLDB?
Are you trying to use C::B for debugging on a MAC?

Let me say LLDB does NOT compare with GDB when you start really working with both of them. As a new developer you will probably not see any differences between them for a while.


Offline SpaceCadet

  • Multiple posting newcomer
  • *
  • Posts: 22
Re: [Feature request] support lldb debugger
« Reply #3 on: August 18, 2022, 07:51:48 pm »
Is it possible to use lldb against a binary built with GDB?
Or do you have to build with the clang compiler?

Do you mean built with the gnu compiler?  I do not know.  I have only used lldb with binaries built with clang.

You cannot replace GDB with LLDB as LLDB's interfaces are not compatible with either of GDB's interfaces (either GDB annotations or GDB/MI interface).

I know you can't drop lldb in to gdb interface and have it work.  But the ability to use stdio to talk to the debugger is analogous.  The idea is that lldb would be available as an option.  getting an image list, a back trace, add break points,
remove them, step in step over etc are all mapable commands on both command line interfaces.  so the existing code could be modified up to a point and a pretty good instance could be created to support lldb with minimal impact on cb.

the quality of the llvm project is very high.  the licensing is less restrictive.  i think long term it would make sense for cb to add this support.