nak: Rework opcode printing to use a new trait

The new trait has separate fmt functions for dsts and the rest of the
op.  There's a generic implementation of Display built on top of it
which just prints `{dsts} = {op}`.  The new trait also has a default
implementation of fmt_dsts() which just walks the dsts using
dsts_as_slice() and auto-formats them all.  This should be what we want
for 95% of cases and we can hand-implement the rest.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26291>
This commit is contained in:
Faith Ekstrand 2023-11-20 03:13:17 -06:00 committed by Marge Bot
parent 503c4b1d5d
commit 9d1afb7533

File diff suppressed because it is too large Load diff