-
Notifications
You must be signed in to change notification settings - Fork 307
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/improved latex table #160
base: master
Are you sure you want to change the base?
Conversation
Now automatically generates the list of instruction types based on the encodings used in the list of instructions to be printed, instead of requiring the headers to be passed alongside the data. Also inserts new pages whenever the table grows to such a length that entries would spill over to the next one.
Note that I've not yet removed the |
@tovine This definitely looks cleaner and better. I will need sometime to verify this at my end. However, does this still produce the same tables as currently seen in the riscv-isa-manual ? If not @aswaterman should indicate if this change is acceptable. |
Codecov Report
📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more @@ Coverage Diff @@
## master #160 +/- ##
==========================================
- Coverage 94.18% 94.10% -0.09%
==========================================
Files 3 3
Lines 688 729 +41
==========================================
+ Hits 648 686 +38
- Misses 40 43 +3
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
It should be exactly the same if only the same dataset is used, yes. # Zc* extensions
caption = '\\caption{Zc* extensions for code size reduction on RISC-V}'
dataset_list = [(['_zcb'], 'RV32Zcb (basic compressed ops) extension', [], True)]
dataset_list.append((['64_zcb'], 'RV64Zcb extension (in addition to RV32Zcb)', [], True))
dataset_list.append((['_zcmp'], 'Zcmp (push/pop) extension', [], True))
dataset_list.append((['_zcmt'], 'Zcmt (table jump) extension', [], True))
make_ext_latex_table(type_list, dataset_list, latex_file, 16, caption) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the feedback, a bit busy this week but will make sure to take a look at fixing it when that changes! |
If it turns out to be more difficult than expected to generate the original tables exactly, then it might not be worth pursuing, since (as you said) we'll be moving to asciidoc in the next few months anyway. Your call, of course. |
Sorry, I've been too swamped lately and haven't really had time to work on this at all. And the generated tables work well enough for my use so I can't justify working more on it. |
I've made some changes to the LaTeX table generation (even though future documentation is supposed to be going towards AsciiDoc it's still useful to be able to generate full instruction set listings in the classical format.
This pull request includes automatic extraction of which instruction format headers to print (based on the actual instructions in the list), so there's no longer any need to provide them manually.
It also handles breaking up tables when they expand past a page boundary so longer extensions can be printed without manually splitting them (no idea why LaTeX can't do that automatically though).
Here's an example 16-bit table generated by this (see commented Zc* extensions in the diff):
And here's an example of multi-page table splitting: