Issue 86646
Summary Why doesn't LLDB use Clang's MCDisassembler class to decode RISCV instructions?
Labels clang
Assignees
Reporter zzh1010016195
    https://github.com/llvm/llvm-project/blob/6a6f9bf38e65ec45b32da4b578e2830341a9b364/lldb/source/Plugins/Instruction/RISCV/EmulateInstructionRISCV.cpp#L70C1-L76C1

I'm glad to see that LLDB supports debugging of RISCV programs. I have a little doubt. Why did the RISCV Instruction plugin choose to decode the instructions itself instead of using the MCDisassembler class provided by Clang? RISCV is an extensible instruction set, and if someone adds a custom instruction, LLDB will have to be updated to support it. If LLDB uses MCDisassembler, it can offload all of this work to Clang, which is what I noticed with the MIPS Instruction plugin. What is the reason that makes LLDB decide to implement the instruction decoding by itself?

I sincerely hope to receive an answer, thank you. @bulbazord 
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to