Is lldb for riscv ready to use?

Hello, I tried to use lldb to remote debug program, but I got the same issue described in Problems using LLDB to remotely debug a RISCV program running on QEMU, is lldb riscv support ready for use like riscv gdb.

I also tried to use riscv gdb to debug llvm generated elf, but met issue below.

Transfer rate: 75 KB/sec, 7199 bytes/write.
/Local/xl_ci/toolchain/riscv-gnu-toolchain/riscv-gdb/gdb/dwarf2/attribute.h:232: internal-error: void attribute::set_unsigned_reprocess(ULONGEST): Assertion `form_requires_reprocessing ()' failed.
A problem internal to GDB has been detected,
further debugging may prove unreliable.
Quit this debugging session? (y or n) [answered Y; input not from terminal]

This is a bug, please report it.  For instructions, see:
<https://www.gnu.org/software/gdb/bugs/>.

/Local/xl_ci/toolchain/riscv-gnu-toolchain/riscv-gdb/gdb/dwarf2/attribute.h:232: internal-error: void attribute::set_unsigned_reprocess(ULONGEST): Assertion `form_requires_reprocessing ()' failed.

So it seems I can’t debug llvm compiled elf using riscv gdb, is it correct?

Thanks

Currently, lldb only supports debugging riscv64 programs locally, due to the unfinished ABI support (which is necessary for remote-gdb debugging).

For your problems, we lack information about the version of your compiler, your program source code, and your command line to compile the program and launch the emulator and the debugger. I can confirm gdb is able to debug llvm compiled executables, which is used in differentiation testing. It is hard to say what is wrong with only this error message.

I find this patch helpful if you are interested: ⚙ D62732 [RISCV] Add SystemV ABI

Hi @Emmmer , thanks for the information.

I will also confirm my steps to use gdb to debug llvm compiled elf.

Hi, I tried with riscv gdb GNU gdb (GDB) 11.0.50.20210206-git, it didn’t work, but GNU gdb (GDB) 12.1 works.