162306a36Sopenharmony_ci# SPDX-License-Identifier: (GPL-2.0 OR MIT) 262306a36Sopenharmony_ci%YAML 1.2 362306a36Sopenharmony_ci--- 462306a36Sopenharmony_ci$id: http://devicetree.org/schemas/riscv/extensions.yaml# 562306a36Sopenharmony_ci$schema: http://devicetree.org/meta-schemas/core.yaml# 662306a36Sopenharmony_ci 762306a36Sopenharmony_cititle: RISC-V ISA extensions 862306a36Sopenharmony_ci 962306a36Sopenharmony_cimaintainers: 1062306a36Sopenharmony_ci - Paul Walmsley <paul.walmsley@sifive.com> 1162306a36Sopenharmony_ci - Palmer Dabbelt <palmer@sifive.com> 1262306a36Sopenharmony_ci - Conor Dooley <conor@kernel.org> 1362306a36Sopenharmony_ci 1462306a36Sopenharmony_cidescription: | 1562306a36Sopenharmony_ci RISC-V has a large number of extensions, some of which are "standard" 1662306a36Sopenharmony_ci extensions, meaning they are ratified by RISC-V International, and others 1762306a36Sopenharmony_ci are "vendor" extensions. 1862306a36Sopenharmony_ci This document defines properties that indicate whether a hart supports a 1962306a36Sopenharmony_ci given extension. 2062306a36Sopenharmony_ci 2162306a36Sopenharmony_ci Once a standard extension has been ratified, no changes in behaviour can be 2262306a36Sopenharmony_ci made without the creation of a new extension. 2362306a36Sopenharmony_ci The properties for standard extensions therefore map to their originally 2462306a36Sopenharmony_ci ratified states, with the exception of the I, Zicntr & Zihpm extensions. 2562306a36Sopenharmony_ci See the "i" property for more information. 2662306a36Sopenharmony_ci 2762306a36Sopenharmony_ciselect: 2862306a36Sopenharmony_ci properties: 2962306a36Sopenharmony_ci compatible: 3062306a36Sopenharmony_ci contains: 3162306a36Sopenharmony_ci const: riscv 3262306a36Sopenharmony_ci 3362306a36Sopenharmony_ciproperties: 3462306a36Sopenharmony_ci riscv,isa: 3562306a36Sopenharmony_ci description: 3662306a36Sopenharmony_ci Identifies the specific RISC-V instruction set architecture 3762306a36Sopenharmony_ci supported by the hart. These are documented in the RISC-V 3862306a36Sopenharmony_ci User-Level ISA document, available from 3962306a36Sopenharmony_ci https://riscv.org/specifications/ 4062306a36Sopenharmony_ci 4162306a36Sopenharmony_ci Due to revisions of the ISA specification, some deviations 4262306a36Sopenharmony_ci have arisen over time. 4362306a36Sopenharmony_ci Notably, riscv,isa was defined prior to the creation of the 4462306a36Sopenharmony_ci Zicntr, Zicsr, Zifencei and Zihpm extensions and thus "i" 4562306a36Sopenharmony_ci implies "zicntr_zicsr_zifencei_zihpm". 4662306a36Sopenharmony_ci 4762306a36Sopenharmony_ci While the isa strings in ISA specification are case 4862306a36Sopenharmony_ci insensitive, letters in the riscv,isa string must be all 4962306a36Sopenharmony_ci lowercase. 5062306a36Sopenharmony_ci $ref: /schemas/types.yaml#/definitions/string 5162306a36Sopenharmony_ci pattern: ^rv(?:64|32)imaf?d?q?c?b?k?j?p?v?h?(?:[hsxz](?:[a-z])+)?(?:_[hsxz](?:[a-z])+)*$ 5262306a36Sopenharmony_ci deprecated: true 5362306a36Sopenharmony_ci 5462306a36Sopenharmony_ci riscv,isa-base: 5562306a36Sopenharmony_ci description: 5662306a36Sopenharmony_ci The base ISA implemented by this hart, as described by the 20191213 5762306a36Sopenharmony_ci version of the unprivileged ISA specification. 5862306a36Sopenharmony_ci enum: 5962306a36Sopenharmony_ci - rv32i 6062306a36Sopenharmony_ci - rv64i 6162306a36Sopenharmony_ci 6262306a36Sopenharmony_ci riscv,isa-extensions: 6362306a36Sopenharmony_ci $ref: /schemas/types.yaml#/definitions/string-array 6462306a36Sopenharmony_ci minItems: 1 6562306a36Sopenharmony_ci description: Extensions supported by the hart. 6662306a36Sopenharmony_ci items: 6762306a36Sopenharmony_ci anyOf: 6862306a36Sopenharmony_ci # single letter extensions, in canonical order 6962306a36Sopenharmony_ci - const: i 7062306a36Sopenharmony_ci description: | 7162306a36Sopenharmony_ci The base integer instruction set, as ratified in the 20191213 7262306a36Sopenharmony_ci version of the unprivileged ISA specification. 7362306a36Sopenharmony_ci 7462306a36Sopenharmony_ci This does not include Chapter 10, "Counters", which was moved into 7562306a36Sopenharmony_ci the Zicntr and Zihpm extensions after the ratification of the 7662306a36Sopenharmony_ci 20191213 version of the unprivileged specification. 7762306a36Sopenharmony_ci 7862306a36Sopenharmony_ci - const: m 7962306a36Sopenharmony_ci description: 8062306a36Sopenharmony_ci The standard M extension for integer multiplication and division, as 8162306a36Sopenharmony_ci ratified in the 20191213 version of the unprivileged ISA 8262306a36Sopenharmony_ci specification. 8362306a36Sopenharmony_ci 8462306a36Sopenharmony_ci - const: a 8562306a36Sopenharmony_ci description: 8662306a36Sopenharmony_ci The standard A extension for atomic instructions, as ratified in the 8762306a36Sopenharmony_ci 20191213 version of the unprivileged ISA specification. 8862306a36Sopenharmony_ci 8962306a36Sopenharmony_ci - const: f 9062306a36Sopenharmony_ci description: 9162306a36Sopenharmony_ci The standard F extension for single-precision floating point, as 9262306a36Sopenharmony_ci ratified in the 20191213 version of the unprivileged ISA 9362306a36Sopenharmony_ci specification. 9462306a36Sopenharmony_ci 9562306a36Sopenharmony_ci - const: d 9662306a36Sopenharmony_ci description: 9762306a36Sopenharmony_ci The standard D extension for double-precision floating-point, as 9862306a36Sopenharmony_ci ratified in the 20191213 version of the unprivileged ISA 9962306a36Sopenharmony_ci specification. 10062306a36Sopenharmony_ci 10162306a36Sopenharmony_ci - const: q 10262306a36Sopenharmony_ci description: 10362306a36Sopenharmony_ci The standard Q extension for quad-precision floating-point, as 10462306a36Sopenharmony_ci ratified in the 20191213 version of the unprivileged ISA 10562306a36Sopenharmony_ci specification. 10662306a36Sopenharmony_ci 10762306a36Sopenharmony_ci - const: c 10862306a36Sopenharmony_ci description: 10962306a36Sopenharmony_ci The standard C extension for compressed instructions, as ratified in 11062306a36Sopenharmony_ci the 20191213 version of the unprivileged ISA specification. 11162306a36Sopenharmony_ci 11262306a36Sopenharmony_ci - const: v 11362306a36Sopenharmony_ci description: 11462306a36Sopenharmony_ci The standard V extension for vector operations, as ratified 11562306a36Sopenharmony_ci in-and-around commit 7a6c8ae ("Fix text that describes vfmv.v.f 11662306a36Sopenharmony_ci encoding") of the riscv-v-spec. 11762306a36Sopenharmony_ci 11862306a36Sopenharmony_ci - const: h 11962306a36Sopenharmony_ci description: 12062306a36Sopenharmony_ci The standard H extension for hypervisors as ratified in the 20191213 12162306a36Sopenharmony_ci version of the privileged ISA specification. 12262306a36Sopenharmony_ci 12362306a36Sopenharmony_ci # multi-letter extensions, sorted alphanumerically 12462306a36Sopenharmony_ci - const: smaia 12562306a36Sopenharmony_ci description: | 12662306a36Sopenharmony_ci The standard Smaia supervisor-level extension for the advanced 12762306a36Sopenharmony_ci interrupt architecture for machine-mode-visible csr and behavioural 12862306a36Sopenharmony_ci changes to interrupts as frozen at commit ccbddab ("Merge pull 12962306a36Sopenharmony_ci request #42 from riscv/jhauser-2023-RC4") of riscv-aia. 13062306a36Sopenharmony_ci 13162306a36Sopenharmony_ci - const: ssaia 13262306a36Sopenharmony_ci description: | 13362306a36Sopenharmony_ci The standard Ssaia supervisor-level extension for the advanced 13462306a36Sopenharmony_ci interrupt architecture for supervisor-mode-visible csr and 13562306a36Sopenharmony_ci behavioural changes to interrupts as frozen at commit ccbddab 13662306a36Sopenharmony_ci ("Merge pull request #42 from riscv/jhauser-2023-RC4") of riscv-aia. 13762306a36Sopenharmony_ci 13862306a36Sopenharmony_ci - const: sscofpmf 13962306a36Sopenharmony_ci description: | 14062306a36Sopenharmony_ci The standard Sscofpmf supervisor-level extension for count overflow 14162306a36Sopenharmony_ci and mode-based filtering as ratified at commit 01d1df0 ("Add ability 14262306a36Sopenharmony_ci to manually trigger workflow. (#2)") of riscv-count-overflow. 14362306a36Sopenharmony_ci 14462306a36Sopenharmony_ci - const: sstc 14562306a36Sopenharmony_ci description: | 14662306a36Sopenharmony_ci The standard Sstc supervisor-level extension for time compare as 14762306a36Sopenharmony_ci ratified at commit 3f9ed34 ("Add ability to manually trigger 14862306a36Sopenharmony_ci workflow. (#2)") of riscv-time-compare. 14962306a36Sopenharmony_ci 15062306a36Sopenharmony_ci - const: svinval 15162306a36Sopenharmony_ci description: 15262306a36Sopenharmony_ci The standard Svinval supervisor-level extension for fine-grained 15362306a36Sopenharmony_ci address-translation cache invalidation as ratified in the 20191213 15462306a36Sopenharmony_ci version of the privileged ISA specification. 15562306a36Sopenharmony_ci 15662306a36Sopenharmony_ci - const: svnapot 15762306a36Sopenharmony_ci description: 15862306a36Sopenharmony_ci The standard Svnapot supervisor-level extensions for napot 15962306a36Sopenharmony_ci translation contiguity as ratified in the 20191213 version of the 16062306a36Sopenharmony_ci privileged ISA specification. 16162306a36Sopenharmony_ci 16262306a36Sopenharmony_ci - const: svpbmt 16362306a36Sopenharmony_ci description: 16462306a36Sopenharmony_ci The standard Svpbmt supervisor-level extensions for page-based 16562306a36Sopenharmony_ci memory types as ratified in the 20191213 version of the privileged 16662306a36Sopenharmony_ci ISA specification. 16762306a36Sopenharmony_ci 16862306a36Sopenharmony_ci - const: zba 16962306a36Sopenharmony_ci description: | 17062306a36Sopenharmony_ci The standard Zba bit-manipulation extension for address generation 17162306a36Sopenharmony_ci acceleration instructions as ratified at commit 6d33919 ("Merge pull 17262306a36Sopenharmony_ci request #158 from hirooih/clmul-fix-loop-end-condition") of 17362306a36Sopenharmony_ci riscv-bitmanip. 17462306a36Sopenharmony_ci 17562306a36Sopenharmony_ci - const: zbb 17662306a36Sopenharmony_ci description: | 17762306a36Sopenharmony_ci The standard Zbb bit-manipulation extension for basic bit-manipulation 17862306a36Sopenharmony_ci as ratified at commit 6d33919 ("Merge pull request #158 from 17962306a36Sopenharmony_ci hirooih/clmul-fix-loop-end-condition") of riscv-bitmanip. 18062306a36Sopenharmony_ci 18162306a36Sopenharmony_ci - const: zbc 18262306a36Sopenharmony_ci description: | 18362306a36Sopenharmony_ci The standard Zbc bit-manipulation extension for carry-less 18462306a36Sopenharmony_ci multiplication as ratified at commit 6d33919 ("Merge pull request 18562306a36Sopenharmony_ci #158 from hirooih/clmul-fix-loop-end-condition") of riscv-bitmanip. 18662306a36Sopenharmony_ci 18762306a36Sopenharmony_ci - const: zbs 18862306a36Sopenharmony_ci description: | 18962306a36Sopenharmony_ci The standard Zbs bit-manipulation extension for single-bit 19062306a36Sopenharmony_ci instructions as ratified at commit 6d33919 ("Merge pull request #158 19162306a36Sopenharmony_ci from hirooih/clmul-fix-loop-end-condition") of riscv-bitmanip. 19262306a36Sopenharmony_ci 19362306a36Sopenharmony_ci - const: zicbom 19462306a36Sopenharmony_ci description: 19562306a36Sopenharmony_ci The standard Zicbom extension for base cache management operations as 19662306a36Sopenharmony_ci ratified in commit 3dd606f ("Create cmobase-v1.0.pdf") of riscv-CMOs. 19762306a36Sopenharmony_ci 19862306a36Sopenharmony_ci - const: zicbop 19962306a36Sopenharmony_ci description: 20062306a36Sopenharmony_ci The standard Zicbop extension for cache-block prefetch instructions 20162306a36Sopenharmony_ci as ratified in commit 3dd606f ("Create cmobase-v1.0.pdf") of 20262306a36Sopenharmony_ci riscv-CMOs. 20362306a36Sopenharmony_ci 20462306a36Sopenharmony_ci - const: zicboz 20562306a36Sopenharmony_ci description: 20662306a36Sopenharmony_ci The standard Zicboz extension for cache-block zeroing as ratified 20762306a36Sopenharmony_ci in commit 3dd606f ("Create cmobase-v1.0.pdf") of riscv-CMOs. 20862306a36Sopenharmony_ci 20962306a36Sopenharmony_ci - const: zicntr 21062306a36Sopenharmony_ci description: 21162306a36Sopenharmony_ci The standard Zicntr extension for base counters and timers, as 21262306a36Sopenharmony_ci ratified in the 20191213 version of the unprivileged ISA 21362306a36Sopenharmony_ci specification. 21462306a36Sopenharmony_ci 21562306a36Sopenharmony_ci - const: zicsr 21662306a36Sopenharmony_ci description: | 21762306a36Sopenharmony_ci The standard Zicsr extension for control and status register 21862306a36Sopenharmony_ci instructions, as ratified in the 20191213 version of the 21962306a36Sopenharmony_ci unprivileged ISA specification. 22062306a36Sopenharmony_ci 22162306a36Sopenharmony_ci This does not include Chapter 10, "Counters", which documents 22262306a36Sopenharmony_ci special case read-only CSRs, that were moved into the Zicntr and 22362306a36Sopenharmony_ci Zihpm extensions after the ratification of the 20191213 version of 22462306a36Sopenharmony_ci the unprivileged specification. 22562306a36Sopenharmony_ci 22662306a36Sopenharmony_ci - const: zifencei 22762306a36Sopenharmony_ci description: 22862306a36Sopenharmony_ci The standard Zifencei extension for instruction-fetch fence, as 22962306a36Sopenharmony_ci ratified in the 20191213 version of the unprivileged ISA 23062306a36Sopenharmony_ci specification. 23162306a36Sopenharmony_ci 23262306a36Sopenharmony_ci - const: zihintpause 23362306a36Sopenharmony_ci description: 23462306a36Sopenharmony_ci The standard Zihintpause extension for pause hints, as ratified in 23562306a36Sopenharmony_ci commit d8ab5c7 ("Zihintpause is ratified") of the riscv-isa-manual. 23662306a36Sopenharmony_ci 23762306a36Sopenharmony_ci - const: zihpm 23862306a36Sopenharmony_ci description: 23962306a36Sopenharmony_ci The standard Zihpm extension for hardware performance counters, as 24062306a36Sopenharmony_ci ratified in the 20191213 version of the unprivileged ISA 24162306a36Sopenharmony_ci specification. 24262306a36Sopenharmony_ci 24362306a36Sopenharmony_ci - const: ztso 24462306a36Sopenharmony_ci description: 24562306a36Sopenharmony_ci The standard Ztso extension for total store ordering, as ratified 24662306a36Sopenharmony_ci in commit 2e5236 ("Ztso is now ratified.") of the 24762306a36Sopenharmony_ci riscv-isa-manual. 24862306a36Sopenharmony_ci 24962306a36Sopenharmony_ciadditionalProperties: true 25062306a36Sopenharmony_ci... 251