riscv/riscv-isa-manual

Wavedrom encodings are inconsistently formatted

christian-herber-nxp opened this issue · 11 comments

I am failing to understand the logic behind the formatting of instruction encodings in wavedrom.
For one, it is quite inconsistent between extensions (e.g. compare C to Zc).
But even within extensions, or even a single instruction, I do not understand how the type is assigned (that translates to the background color). See e.g.:
image

Two parts of one immediate have different colors. One operand red, one operand green.

Having clarity on how to format the instructions will greatly help authors of extensions to do it right from the start.

wmat commented

I feel the color code is arbitrary and perhaps not intentional. The version 2.2 manual had no such color scheme.

@wmat : thanks, i updated the colors in riscv/riscv-zilsd#18.
From that, I can for sure say that the types in C need to be revisited.

Given that the "old" ISA manuals did not use color coding, should we drop all color coding in the new manuals? Or should we have Bill identify one standard color coding that we will gradually convert to?

IMO: The colors are a bit distracting and don't add much. The look and feel of the "old" manual was better.

wmat commented

Let's see if @aswaterman concurs with dropping all color coding.

personally, I like the colors, if used meaningfully and consistently.
Especially in less regular encodings like C/Zc, helps to get an overview.

I think the two valid resolutions are to drop the colors or to use the colors consistently. Given the latter option is much more work, and isn't exactly of high priority, I'd be fine with dropping them. We can always reverse course in the future if we have the bandwidth.

wmat commented

Right, they’re just there to improve the visual appearance and help readers see the boundaries between fields. There’s no semantic content.