CSR Bit Fields

RISC-V vsireg4 CSR Register

Address 0x255Privilege Hypervisor direct / VS aliasAccess HRW / current XLEN, not VSXLENHypervisor and virtualization CSRs

vsireg4 is a VS indirect CSR data window selected by vsiselect.

Field Map

Understand vsireg4 By Bit Fields

1 key fields
XLEN-1:0

DATA

Selector-defined

VS indirect CSR alias window selected by vsiselect; for CTR select values 0x200..0x2FF it is read-only zero. If Sscsrind is also implemented, AIA select values 0x30..0x3F or 0x70..0xFF make accesses to vsireg2..6 raise exceptions under AIA rules.

DATA (bits XLEN-1:0) — VS indirect CSR alias window selected by vsiselect; for CTR select values 0x200..0x2FF it is read-only zero. If Sscsrind is also implemented, AIA select values 0x30..0x3F or 0x70..0xFF make accesses to vsireg2..6 raise exceptions under AIA rules.

What This Field Controls

  • - VS indirect CSR alias window selected by vsiselect; for CTR select values 0x200..0x2FF it is read-only zero. If Sscsrind is also implemented, AIA select values 0x30..0x3F or 0x70..0xFF make accesses to vsireg2..6 raise exceptions under AIA rules.

Common Values

This field is better understood together with surrounding context than as a fixed memorized enumeration.

Open Official Manual
Official Basis & Search Notes

vsireg4 is a VS indirect CSR alias window under the H extension, with current-XLEN width. Its meaning is entirely defined by the current vsiselect value and the owning extension; in the CTR 0x200..0x2FF range it is read-only zero.

vsireg4 address, access class, and width are checked against the official CSR tables: 0x255, HRW, current XLEN, not VSXLEN.
vsiselect supports at least selector range 0..0xFFF; custom selectors use the space with the most-significant bit set.
Direct VS/VU access to vsiselect/vsireg* raises a virtual-instruction exception; a guest uses the siselect/sireg* aliases for VS indirect state.
Smctr/Ssctr maps only vsireg, vsireg2, and vsireg3 to ctrsource, ctrtarget, and ctrdata for 0x200..0x2FF; vsireg4 is read-only zero.
If Sscsrind is also implemented, AIA makes accesses to vsireg2..6 under 0x30..0x3F or 0x70..0xFF raise an illegal-instruction or virtual-instruction exception depending on the access mode.

What To Check First When Reading This CSR

  • - The official table lists vsireg4's separate CSR address as HRW and current-XLEN width, not VSXLEN.
  • - VS/VU cannot directly access the separate vsiselect/vsireg* addresses; VS-mode uses the siselect/sireg* aliases for VS indirect state.
  • - When vsiselect is in the CTR range 0x200..0x2FF, vsireg4 is read-only zero; if Sscsrind is also implemented, AIA values 0x30..0x3F or 0x70..0xFF make accesses to vsireg2..6 raise exceptions.

Risk Checks Before Writing

  • - Before writing vsireg4, confirm the extension definition for the current vsiselect value; under CTR 0x200..0x2FF, writes to this alias window do not modify CTR entry state.

Put It Back Into A Real Flow

1

Write or confirm the vsiselect selector first.

2

Use the matching vsireg* data window for indirectly selected state defined by an official extension; behavior for an unimplemented HS-level selector is UNSPECIFIED.

3

CTR 0x200..0x2FF maps only vsireg/vsireg2/vsireg3 to ctrsource/ctrtarget/ctrdata; vsireg4 is read-only zero.

FAQ

What selector range does vsiselect support?

Smcsrind/Sscsrind requires vsiselect to support at least 0..0xFFF; the AIA window required 0..0x1FF, but the general Sscsrind rule extends the standard minimum range.

Can VS-mode directly access vsireg4?

Direct VS/VU access to vsiselect or vsireg* raises a virtual-instruction exception; a guest should use the siselect/sireg* aliases.