aboutsummaryrefslogtreecommitdiff
path: root/riscv/zvk_ext_macros.h
AgeCommit message (Collapse)AuthorFilesLines
2023-11-15Don't enforce alignment constraints vwsll.v[xi] rs1 argAndrew Waterman1-2/+2
rs1 doesn't represent a vector arg in this case, so the instructions were broken for (rs1 % ceil(LMUL)) != 0. Resolves #1505
2023-10-23Fixing minor typo Gallois -> GaloisNicolas Brunie1-1/+1
Signed-off-by: Nicolas Brunie <82109999+nibrunieAtSi5@users.noreply.github.com>
2023-06-19Zvk: Implement Zvkg, Vector GCM/GMAC instructionEric Gouriou1-2/+14
Implement the proposed instruction in Zvkg, vghmac.vv, Vector Carryless Multiply Accumulate over GHASH Galois-Field. The instruction performs one step of GHASH routine as described in "NIST Special Publication 800-38D" a.k.a the AES-GCM specification. The logic was written to closely track the pseudo-code in the Zvk specification. Signed-off-by: Eric Gouriou <ego@rivosinc.com> Co-authored-by: Kornel Duleba <mindal@semihalf.com> Signed-off-by: Eric Gouriou <ego@rivosinc.com>
2023-06-19Zvk: Infrastructure for Zvk extensions, element group handlingEric Gouriou1-0/+1023
Introduce types and macros useful across multiple Zvk sub-extensions, including Zvbb and Zvbc. Those will be used by upcoming per-sub-extension commits. In particular we introduce "Element Group" types and loop macros handling those element groups. The concept of element group is described in <https://github.com/riscv/riscv-crypto/blob/master/doc/vector/riscv-crypto-vector-element-groups.adoc>. Note that the element group access method is not implemented for WORDS_BIGENDIAN setup. As such, isa_parser.cc is modified to emit an error when WORDS_BIGENDIAN is defined and extensions using element groups are enabled. Signed-off-by: Eric Gouriou <ego@rivosinc.com>