The RISC-V instruction set architecture (ISA) is modular, allowing implementations to include various extensions alongside the base integer instruction set (RV32I, RV64I, RV128I). Below is a list of ratified and specified extensions to the RISC-V ISA as of the latest stable documentation (up to 2022). These extensions are officially standardized and approved by RISC-V International.
Core Extensions
These are the primary extensions that are widely adopted and form the basis for common RISC-V configurations (e.g., RV32G, RV64G).
-
M (Multiplication and Division)
- Adds integer multiplication and division operations (e.g.,
MUL, DIV, REM).
-
A (Atomic Instructions)
- Provides atomic memory operations for synchronization (e.g.,
LR.W, SC.W, AMOADD.W).
-
F (Single-Precision Floating-Point)
- Implements IEEE 754-2008 single-precision floating-point operations (e.g.,
FADD.S, FMUL.S).
-
D (Double-Precision Floating-Point)
- Extends F to support double-precision operations (e.g.,
FADD.D, FMUL.D). Requires F.
-
C (Compressed Instructions)
- Introduces 16-bit compressed instructions to reduce code size (e.g.,
C.ADDI, C.LW).
-
V (Vector Extension)
- Adds support for vector operations with scalable vector registers (e.g.,
VADD.VV, VMUL.VX). Ratified in late 2021.
-
Zifencei (Instruction-Fetch Fence)
- Adds the
FENCE.I instruction for synchronizing instruction fetches (e.g., after self-modifying code).
Other Ratified Extensions
These are less commonly used but still standardized extensions.
-
Zicsr (Control and Status Register Instructions)
- Includes instructions for accessing CSRs (e.g.,
CSRRW, CSRRS, CSRRC). Note: CSR instructions are part of the base ISA but are sometimes grouped under this pseudo-extension.
-
Zmmul (Multiply-Add Extension)
- Adds multiply-accumulate operations (e.g.,
MADD, NMADD). Ratified as part of the M extension.
Legacy or Obsolete Extensions
Some extensions were proposed but later deprecated or merged:
- Q (Quad-Precision Floating-Point)
- Proposed for quad-precision operations but merged into the F/D framework or deprecated.
- L (Decimal Floating-Point)
- Proposed for decimal floating-point support but not ratified.
Draft or In-Progress Extensions
These are under development and not yet ratified (as of 2022):
- B (Bit Manipulation Extension)
- Includes bit-level operations (e.g.,
CLZ, CTZ, BSET, BCLR).
- K (Cryptography Extension)
- Proposes cryptographic accelerators (e.g., AES, SHA-2, SM4).
- T (Transactional Memory)
- Supports hardware transactional memory (e.g.,
TXBEGIN, TXEND).
- N (User-Level Interrupts)
- Adds user-level interrupt handling.
- P (Packed SIMD Extension)
- Proposes packed SIMD operations for performance.
Summary
The ratified and specified extensions to the RISC-V ISA are:
M, A, F, D, C, V, Zifencei, Zicsr, Zmmul
Additional extensions like B, K, T, N, and P are in draft stages and may be ratified in the future.
For implementation-specific configurations, the G extension (General-Purpose) is a shorthand for I + M + A + F + D.