isaspec: Add "displayname" for altering {NAME} when decoding
authorConnor Abbott <cwabbott0@gmail.com>
Wed, 21 Jun 2023 16:27:42 +0000 (18:27 +0200)
committerMarge Bot <emma+marge@anholt.net>
Fri, 28 Jul 2023 18:41:57 +0000 (18:41 +0000)
commit86b17d96b3af5940c61b88ac915ca431b271223b
tree48aa0d73cb1a0bda6f1bf0af624ffab818455bfd
parentc237539d62184ce3b78c502067da6b696b95538f
isaspec: Add "displayname" for altering {NAME} when decoding

In afuc, we have the situation where there are a number of ALU
instructions with two (almost) completely different encodings, including
a different opcode location, etc. These need to be different leaf
bitsets with different names for the encoder to work, because otherwise
the encoder has no way of descriminating between them, but when
displaying them we want to use the same name. This adds a small facility
to make the name used for {NAME} when displaying and for the opcode
when encoding different, so that e.g. OPC_ADDI can display as "add"
instead of "addi".

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23949>
docs/drivers/freedreno/isaspec.rst
src/compiler/isaspec/decode.py
src/compiler/isaspec/isa.py