[LLDB][RISCV] Make software single stepping work
authorEmmmer <yjhdandan@163.com>
Tue, 16 Aug 2022 07:38:18 +0000 (15:38 +0800)
committerEmmmer <yjhdandan@163.com>
Tue, 16 Aug 2022 15:44:50 +0000 (23:44 +0800)
commit4fc7e9cba24b3f96f274126218a7985f31aa5861
tree34eb3de870d3538d5ebf0a2295d2c239c3d10668
parent8ed3e75c96d987e294067e2fe0ab5b02a5bcc89d
[LLDB][RISCV] Make software single stepping work

Add:
- `EmulateInstructionRISCV`, which can be used for riscv32 and riscv64.
- Add unittests for EmulateInstructionRISCV.

Note: Compressed instructions set (RVC) was still not supported in this patch.

Reviewed By: DavidSpickett

Differential Revision: https://reviews.llvm.org/D131759
lldb/source/Plugins/Instruction/CMakeLists.txt
lldb/source/Plugins/Instruction/RISCV/CMakeLists.txt [new file with mode: 0644]
lldb/source/Plugins/Instruction/RISCV/EmulateInstructionRISCV.cpp [new file with mode: 0644]
lldb/source/Plugins/Instruction/RISCV/EmulateInstructionRISCV.h [new file with mode: 0644]
lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp
lldb/source/Plugins/Process/Utility/NativeProcessSoftwareSingleStep.cpp
lldb/tools/lldb-server/CMakeLists.txt
lldb/tools/lldb-server/SystemInitializerLLGS.cpp
lldb/unittests/Instruction/ARM64/TestAArch64Emulator.cpp [moved from lldb/unittests/Instruction/TestAArch64Emulator.cpp with 100% similarity]
lldb/unittests/Instruction/CMakeLists.txt
lldb/unittests/Instruction/RISCV/TestRISCVEmulator.cpp [new file with mode: 0644]