CSR Bit Fields

RISC-V vstimecmp CSR Register

Address 0x24DPrivilege Hypervisor direct / VS aliasAccess HRW / 64-bitHypervisor and virtualization CSRs

vstimecmp holds the VS timer compare value.

Bit Overview
bit 3 = only bit 3; bits 12..11 = bits 12 down to 11
MSBLSB
Field Map

Understand vstimecmp By Bit Fields

1 key fields
63:0

TIMECMP

RW

vstimecmp VS timer compare value.

TIMECMP (bits 63:0) — vstimecmp VS timer compare value.

What This Field Controls

  • - vstimecmp VS timer compare value.

Common Values

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

Open Official Manual
Official Basis & Search Notes

vstimecmp is a VS timer-compare CSR. The separate CSR address is for M/HS-side management; when V=1, guest access to the corresponding supervisor CSR is substituted with VS state unless an extension specifies otherwise.

vstimecmp address, access class, and width are checked against the official CSR tables: 0x24D, HRW, 64-bit.
Sstc adds the VS-level vstimecmp CSR, with availability controlled through state such as henvcfg.STCE.
This state is 64-bit; RV32 uses the corresponding high-half CSR for upper bits.
When writing, modify only officially defined fields; handle WARL, WLRL, WPRI, and reserved fields according to the official specification and implementation behavior.

What To Check First When Reading This CSR

  • - vstimecmp's separate CSR address is in the official HRW access class; a VS/VU guest normally reaches VS state through the corresponding supervisor CSR alias.
  • - Before reading it, confirm that the defining extension such as H, AIA, Sstc, Smstateen, or Smcsrind is implemented.

Risk Checks Before Writing

  • - When writing vstimecmp, modify only officially defined target fields and preserve WPRI, reserved, and unchanged fields.

Put It Back Into A Real Flow

1

Confirm that Sstc/H and relevant enable bits are implemented.

2

Treat it as 64-bit timer state; RV32 requires low/high access.

3

Do not confuse time offset with timer compare state.

FAQ

Is vstimecmp part of 64-bit timer state?

vstimecmp represents a 64-bit VS timer compare value; RV32 uses the matching high-half CSR.

How is vstimecmp related to time?

It is VS-level timer-compare state used for guest-supervisor timer interrupt comparison.