Add Zvbc32e and Zvkgs specifications (into vector crypto chapter)#2369
Add Zvbc32e and Zvkgs specifications (into vector crypto chapter)#2369Nicolas Brunie (nibrunieAtSi5) wants to merge 7 commits into
Conversation
c7fedf7 to
6d2a882
Compare
008b48c to
588b85a
Compare
588b85a to
f8cb394
Compare
| The Zabha extension addresses these limitations by adding support for _byte_ and | ||
| _halfword_ atomic memory operations to the RISC-V Unprivileged ISA. | ||
|
|
||
| === "Zvbc32e" Extension for Vector Carry-less Multiplication for `SEW <= 32` |
There was a problem hiding this comment.
Please replace all of the <= with {le} and >= with {ge}.
…apter This changes introduces a new extension, dubbed Zvbc32e, which extends the instructions defined in Zvbc (vclmul.v[x,v] and vclmulh.v[x,v]) to support SEW 8, 16 or 32. It was developped in the context of a fast track supported by RVIA Cryptography SIG and was submitted after Zvbc had been ratified.
Co-authored-by: Craig Topper <craig.topper@sifive.com> Signed-off-by: Nicolas Brunie <82109999+nibrunieAtSi5@users.noreply.github.com>
e37c040 to
45f0de6
Compare
|
|
||
|
|
||
| <<Zvbc>> defines vector carry-less multiplication instructions for `SEW`=64 only. | ||
| It is not suitable for implementations with small `ELEN` (32) and incurs some inefficiencies for algorithms where at least one of the multiplication operands is limited to 32 bits (or less). |
There was a problem hiding this comment.
| It is not suitable for implementations with small `ELEN` (32) and incurs some inefficiencies for algorithms where at least one of the multiplication operands is limited to 32 bits (or less). | |
| It is not suitable for implementations with small `ELEN` (32) and incurs some inefficiencies for algorithms where at least one of the multiplication operands is limited to 32-bit (or narrower). |
|
Just a quick update from ISCAS: we have implemented preliminary toolchain support for Zvbc32e and Zvkgs in both GCC and Binutils. The current development branches are available here:
We will keep tracking this ISA manual PR and the related riscv-opcodes / rvv-intrinsic changes, and are happy to adjust the implementation if the specification or intrinsic naming changes before finalization. Please feel free to add these branches to the related toolchain support list if that is useful. Thanks. |
Thank you Jiawei (@pz9115), this is definitely useful. I need to update this PR (rebase) but no material changes are expected at the moment. |
|
Hi, I have a question regarding the extension versioning used in this implementation. The upstream specification for Zvbc32e/Zvkgs is currently at v0.0.7 (a three-component version: major.minor.patch = 0.0.7). |
Thanks for pointing this out. The version was encoded as 0p7 intentionally. My understanding is that Since the RISC-V toolchain ISA string only represents extension versions I agree the transition from the previous 0.0.7 document version to the |
Following the ARC review on #1306, I am opening this pull-request to integrate the specifications following the ARC recommendations.
Eventually this PR will represent the frozen specifications for both Zvbc32e and Zvkgs.
RVIA tracking
This pull requests draft the changes associated with two fast track extensions for vector crypto.
Fast track is tracked in https://riscv.atlassian.net/browse/RVS-1915
New features:
Related changes:
spike-isa-simmodificationsZvbc32eandZvkgs: Vector crypto additional riscv-software-src/riscv-isa-sim#1748Zvbce32https://github.com/riscv/riscv-crypto/blob/main/doc/vector/code-samples/zvbc-test.cZvkgshttps://github.com/riscv/riscv-crypto/blob/main/doc/vector/code-samples/zvkg-test.cZvkgs: Adding support for (project) fast track extension Zvkgs sail-riscv#1017Zvbc32e: Adding support for Zvbc32e sail-riscv#931History
During the specification process for vector crypto 1.0.0 a few items had to be discarded because they appeared too late in the process. This fast track extension tries to address some of them.
The official demand that will be discussed in the Task Group and submitted to the Unpriv Committee is being drafter here: https://docs.google.com/document/d/1zpYhnZi2NxhjfcBGvPOy0oDhx6lTXchscG17Qcl6wv8/edit?usp=sharing
This pull request follows a previous PR against riscv-isa-manual, #1306, which itself was the follow-up to a pull request started on the riscv-crypto repo: riscv/riscv-crypto#362.