[PATCH] D49027: [TableGen] FixedLenDecoderEmitter: allow for dummy operand in MCInst
Nicolai Hähnle via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 30 04:24:10 PDT 2018
nhaehnle added a comment.
As far as I can tell, there are four kinds of operands when it comes to fixed-length encoding / decoding:
1. Normal operands that are used and encoded and decoded normally using the automatic machinery.
2. Tied operands.
3. Operands that are used, but for some reason need a special mechanism for encoding and decoding.
4. Operands that aren't used and aren't encoded / decoded.
As far as I can tell, this new mechanism would only make sense for the last category of operands. The obvious question is: why do we have such operands in the first place?
>From the other patch, an example of this is the src2_modifier on multiply-accumulate V_MAC & friends instructions in AMDGPU. But since this operand isn't actually ever used, why don't we remove it instead?
Would it be possible to remove src2_modifiers from V_MAC_* instead? It seems odd to me to have operands in a MachineInstruction that are not actually ever used and must be 0.
Repository:
rL LLVM
https://reviews.llvm.org/D49027
More information about the llvm-commits
mailing list