[llvm] [TableGen][DecoderEmitter] Add option to emit type-specialized code (PR #146593)
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 22 21:05:55 PDT 2025
topperc wrote:
> Let me try going back to a templated decodeInstruction / single copy of decodeInstruction. Note that it will have to dynamically dispatch to both decodeToMCInst and fieldFromInstruction, but that will likely help reduce the code size. A single non-templated one for the widest type is a possibility as well, but that may be a bitset<> type for some targets, like AMDGPU.
>
Why would we need to dynamically dispatch to fieldFromInstruction? Can't it use the same template type as decodeInstruction and just work?
https://github.com/llvm/llvm-project/pull/146593
More information about the llvm-commits
mailing list