[all-commits] [llvm/llvm-project] c60420: lldb/ObjectFile, Disassembler: read some state from...
Saleem Abdulrasool via All-commits
all-commits at lists.llvm.org
Thu Mar 10 13:42:53 PST 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: c6042076081025bc8060637b05fbeb24dbb82538
https://github.com/llvm/llvm-project/commit/c6042076081025bc8060637b05fbeb24dbb82538
Author: Saleem Abdulrasool <compnerd at compnerd.org>
Date: 2022-03-10 (Thu, 10 Mar 2022)
Changed paths:
M lldb/include/lldb/Utility/ArchSpec.h
M lldb/source/Plugins/Disassembler/LLVMC/DisassemblerLLVMC.cpp
M lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp
Log Message:
-----------
lldb/ObjectFile,Disassembler: read some state from the executable
Add support to inspect the ELF headers for RISCV targets to determine if
RVC or RVE are enabled and the floating point support to enable. As per
the RISCV specification, d implies f, q implies d implies f, which gives
us the cascading effect that is used to enable the features when setting
up the disassembler. With this change, it is now possible to attach the
debugger to a remote process and be able to disassemble the instruction
stream.
~~~
$ bin/lldb tmp/reduced
(lldb) target create "reduced"
Current executable set to '/tmp/reduced' (riscv64).
(lldb) gdb-remote localhost:1234
(lldb) Process 5737 stopped
* thread #1, name = 'reduced', stop reason = signal SIGTRAP
frame #0: 0x0000003ff7fe1b20
-> 0x3ff7fe1b20: mv a0, sp
0x3ff7fe1b22: jal 1936
0x3ff7fe1b26: mv s0, a0
0x3ff7fe1b28: auipc a0, 27
~~~
More information about the All-commits
mailing list