aboutsummaryrefslogtreecommitdiff
path: root/llvm/tools/llvm-objdump/llvm-objdump.cpp
diff options
context:
space:
mode:
authorVenkata Ramanaiah Nalamothu <quic_vnalamot@quicinc.com>2023-08-05 14:10:12 +0530
committerVenkata Ramanaiah Nalamothu <quic_vnalamot@quicinc.com>2023-08-14 08:37:41 +0530
commit254a31273a27728bb7937b27417eba083781f7eb (patch)
tree37fecb311eab4ab6d67cd4b1306a235f54c9132b /llvm/tools/llvm-objdump/llvm-objdump.cpp
parent8a98f24ec51ea12a50f1e63dd030482e387534a1 (diff)
downloadllvm-254a31273a27728bb7937b27417eba083781f7eb.zip
llvm-254a31273a27728bb7937b27417eba083781f7eb.tar.gz
llvm-254a31273a27728bb7937b27417eba083781f7eb.tar.bz2
[lldb][NFC] Use MCInstrAnalysis when available in the disassembler plugin
Since the info in MCInstrDesc is based on opcodes only, it is often quite inaccurate. The MCInstrAnalysis has been added so that targets can provide accurate info, which is based on registers used by the instruction, through the own versions of MCInstrDesc functions. The RISCVMCInstrAnalysis, which needs to refine several MCInstrDesc methods, is a good example for this. Given the llvm-objdump also uses MCInstrAnalysis, I think this change is in the right direction. The default implementation of MCInstrAnalysis methods forward the query to MCInstrDesc functions. Hence, no functional change is intended/expected. To avoid bloating up MCInstrAnalysis, only the methods provided by it and the ones used by disassembler plugin are changed to use MCInstrAnalysis when available. Though I am not sure if it will be useful, making MCInstrAnalysis available in the disassembler plugin would allow enabling symbolize operands (D84191) feature in lldb's disassembler as well. Reviewed By: jasonmolenda Differential Revision: https://reviews.llvm.org/D156086
Diffstat (limited to 'llvm/tools/llvm-objdump/llvm-objdump.cpp')
0 files changed, 0 insertions, 0 deletions