| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245 |
- .\" -*- mode: troff; coding: utf-8 -*-
- .\" Automatically generated by Pod::Man 5.01 (Pod::Simple 3.43)
- .\"
- .\" Standard preamble:
- .\" ========================================================================
- .de Sp \" Vertical space (when we can't use .PP)
- .if t .sp .5v
- .if n .sp
- ..
- .de Vb \" Begin verbatim text
- .ft CW
- .nf
- .ne \\$1
- ..
- .de Ve \" End verbatim text
- .ft R
- .fi
- ..
- .\" \*(C` and \*(C' are quotes in nroff, nothing in troff, for use with C<>.
- .ie n \{\
- . ds C` ""
- . ds C' ""
- 'br\}
- .el\{\
- . ds C`
- . ds C'
- 'br\}
- .\"
- .\" Escape single quotes in literal strings from groff's Unicode transform.
- .ie \n(.g .ds Aq \(aq
- .el .ds Aq '
- .\"
- .\" If the F register is >0, we'll generate index entries on stderr for
- .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
- .\" entries marked with X<> in POD. Of course, you'll have to process the
- .\" output yourself in some meaningful fashion.
- .\"
- .\" Avoid warning from groff about undefined register 'F'.
- .de IX
- ..
- .nr rF 0
- .if \n(.g .if rF .nr rF 1
- .if (\n(rF:(\n(.g==0)) \{\
- . if \nF \{\
- . de IX
- . tm Index:\\$1\t\\n%\t"\\$2"
- ..
- . if !\nF==2 \{\
- . nr % 0
- . nr F 2
- . \}
- . \}
- .\}
- .rr rF
- .\" ========================================================================
- .\"
- .IX Title "OPENSSL_RISCVCAP 3ossl"
- .TH OPENSSL_RISCVCAP 3ossl 2025-01-17 3.4.0 OpenSSL
- .\" For nroff, turn off justification. Always turn off hyphenation; it makes
- .\" way too many mistakes in technical documents.
- .if n .ad l
- .nh
- .SH NAME
- OPENSSL_riscvcap \- the RISC\-V processor capabilities vector
- .SH SYNOPSIS
- .IX Header "SYNOPSIS"
- .Vb 1
- \& env OPENSSL_riscvcap=... <application>
- .Ve
- .SH DESCRIPTION
- .IX Header "DESCRIPTION"
- libcrypto supports RISC-V instruction set extensions. These
- extensions are denoted by individual extension names in the capabilities
- vector. For Linux platform, when libcrypto is initialized, the results
- returned by the RISC-V Hardware Probing syscall (hwprobe) are stored
- in the vector. Otherwise all capabilities are disabled.
- .PP
- To override the set of instructions available to an application, you can
- set the \fBOPENSSL_riscvcap\fR environment variable before you start the
- application.
- .PP
- The environment variable is similar to the RISC-V ISA string defined in the
- RISC-V Instruction Set Manual. It is case insensitive. Though due to the limit
- of the environment variable parser inside libcrypto, an extension must be
- prefixed with an underscore to make it recognizable. This also applies to the
- Vector extension.
- .PP
- .Vb 1
- \& OPENSSL_riscvcap="rv64gc_v_zba_zbb_zbs..."
- .Ve
- .PP
- Note that extension implication is currently not implemented.
- For example, when "rv64gc_b" is provided as the environment variable,
- zba/zbb/zbs would not be implied in the capability vector.
- .PP
- Currently only these extensions are recognized:
- .IP ZBA 4
- .IX Item "ZBA"
- Address Generation
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.5
- .IP ZBB 4
- .IX Item "ZBB"
- Basic bit-manipulation
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.5
- .IP ZBC 4
- .IX Item "ZBC"
- Carry-less multiplication
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP ZBS 4
- .IX Item "ZBS"
- Single-bit instructions
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.5
- .IP ZBKB 4
- .IX Item "ZBKB"
- Bit-manipulation for Cryptography
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP ZBKC 4
- .IX Item "ZBKC"
- Carry-less multiplication for Cryptography
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP ZBKX 4
- .IX Item "ZBKX"
- Crossbar permutations
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP ZKND 4
- .IX Item "ZKND"
- NIST Suite: AES Decryption
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP ZKNE 4
- .IX Item "ZKNE"
- NIST Suite: AES Encryption
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP ZKNH 4
- .IX Item "ZKNH"
- NIST Suite: Hash Function Instructions
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP ZKSED 4
- .IX Item "ZKSED"
- ShangMi Suite: SM4 Block Cipher Instructions
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP ZKSH 4
- .IX Item "ZKSH"
- ShangMi Suite: SM3 Hash Function Instructions
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP ZKR 4
- .IX Item "ZKR"
- Entropy Source Extension
- .IP ZKT 4
- .IX Item "ZKT"
- Data Independent Execution Latency
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP V 4
- .IX Item "V"
- Vector Extension for Application Processors
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.5
- .IP ZVBB 4
- .IX Item "ZVBB"
- Vector Basic Bit-manipulation
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP ZVBC 4
- .IX Item "ZVBC"
- Vector Carryless Multiplication
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP ZVKB 4
- .IX Item "ZVKB"
- Vector Cryptography Bit-manipulation
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP ZVKG 4
- .IX Item "ZVKG"
- Vector GCM/GMAC
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP ZVKNED 4
- .IX Item "ZVKNED"
- NIST Suite: Vector AES Block Cipher
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP ZVKNHA 4
- .IX Item "ZVKNHA"
- NIST Suite: Vector SHA\-2 Secure Hash
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP ZVKNHB 4
- .IX Item "ZVKNHB"
- NIST Suite: Vector SHA\-2 Secure Hash
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP ZVKSED 4
- .IX Item "ZVKSED"
- ShangMi Suite: SM4 Block Cipher
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .IP ZVKSH 4
- .IX Item "ZVKSH"
- ShangMi Suite: SM3 Secure Hash
- .Sp
- Could be detected using hwprobe for Linux kernel >= 6.8
- .SH "RETURN VALUES"
- .IX Header "RETURN VALUES"
- Not available.
- .SH EXAMPLES
- .IX Header "EXAMPLES"
- Check currently detected capabilities
- .PP
- .Vb 2
- \& $ openssl info \-cpusettings
- \& OPENSSL_riscvcap=ZBA_ZBB_ZBC_ZBS_V
- .Ve
- .PP
- Disables all instruction set extensions:
- .PP
- .Vb 1
- \& OPENSSL_riscvcap="rv64gc"
- .Ve
- .PP
- Only enable the vector extension:
- .PP
- .Vb 1
- \& OPENSSL_riscvcap="rv64gc_v"
- .Ve
- .SH COPYRIGHT
- .IX Header "COPYRIGHT"
- Copyright 2024 The OpenSSL Project Authors. All Rights Reserved.
- .PP
- Licensed under the Apache License 2.0 (the "License"). You may not use
- this file except in compliance with the License. You can obtain a copy
- in the file LICENSE in the source distribution or at
- <https://www.openssl.org/source/license.html>.
|