This is an archive of the discontinued LLVM Phabricator instance.

[ARM] Use MCInstrInfo::get in ARMDisassembler instead of reinventing it
ClosedPublic

Authored by foad on Jan 11 2023, 8:33 AM.

Diff Detail

Event Timeline

foad created this revision.Jan 11 2023, 8:33 AM
foad requested review of this revision.Jan 11 2023, 8:33 AM
Herald added a project: Restricted Project. · View Herald TranscriptJan 11 2023, 8:33 AM
foad added inline comments.
llvm/lib/Target/ARM/Disassembler/ARMDisassembler.cpp
133

This is the pattern used by AArch64 and other disassemblers I looked at.

1638

It is slightly ugly having to down-cast here but I assume it is safe.

simon_tatham accepted this revision.Jan 12 2023, 5:36 AM
simon_tatham added inline comments.
llvm/lib/Target/ARM/Disassembler/ARMDisassembler.cpp
1638

It happens in several other places already in this file, and in similar situations in quite a few other backends, so I agree that looks safe.

This revision is now accepted and ready to land.Jan 12 2023, 5:36 AM
This revision was landed with ongoing or failed builds.Jan 12 2023, 6:06 AM
This revision was automatically updated to reflect the committed changes.