Skip to content

RISC-V: Tidying (batch 2025-04-11) #1769

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

Merged
merged 4 commits into from
Apr 12, 2025

Conversation

a4lg
Copy link
Contributor

@a4lg a4lg commented Apr 11, 2025

This PR updates the RISC-V definition file (arch/riscv.rs; mainly its documentation) for various parts (better links, indentation, more consistency on the extension naming and its capitalization).

This is a subset of upcoming PR but separate for being:

  1. independent from the rest and
  2. probably unarguable.

This PR consists of four commits:

  1. Improve extension consistency (capitalization)
  2. Move ratified extensions and make some clarification changes (by sorting or raising / lowering indentation)
  3. Changing the ISA manual link (before / after)
    while GitHub is a good place to browse the latest draft, it's hard to determine which is the ratified specification. So, I think a page in RISC-V International would be better.
  4. Fix minor section separation issue

@rustbot
Copy link
Collaborator

rustbot commented Apr 11, 2025

r? @Amanieu

rustbot has assigned @Amanieu.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

a4lg added 4 commits April 12, 2025 01:31
RISC-V extension names are capitalized for consistency.
Some extensions are ratified at least on the ISA specification version
20240411.  This commit moves such extensions.

This commit also changes that:

1.  Lower indentation of "Zk*" and "Zbk*" extensions to avoid extension
    groups from being misleading inside this section.
2.  Raise indentation of "Zfhmin" and "Zhinxmin" extensions to show that
    they are a strict subset of "Zfh" and "Zhinx" (respectively).
3.  Clarify that "s" is not an extension but a feature notifying
    the existence of the supervisor-level ISA.
4.  Clarify that "h" is not just an existence of the hypervisor-level ISA
    but is also an extension name ("H").
Not only moving the link to the end of the section, this commit changes
the link so that we can reach to the *ratified* ISA manuals (note that,
while the original URL (GitHub) is a good place to browse the latest
draft, it's not easy to know which is the ratified version; even
"Releases" page is not helpful since it's regularly updated).
The author intended to split:

1.  Former "I" extensions
2.  Other "I"-related extensions

but incorrectly separated between "Zihpm" (a supplement of "Zicntr" which is
a former "I" extension) and "Zifencei" (a former "I" extension) while the
author intended making a separation between "Zifencei" and "Zihintpause"
(not a part of "I").

This commit fixes the separation.
@a4lg a4lg force-pushed the 20250411-riscv-tidying branch from 468abfe to eab39c6 Compare April 12, 2025 01:32
@Amanieu Amanieu added this pull request to the merge queue Apr 12, 2025
Merged via the queue into rust-lang:master with commit 54c8837 Apr 12, 2025
60 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants