minstreth

Machine Instructions Retired Counter

Upper half of 64-bit instructions retired counters.

See minstret for details.

Attributes

CSR Address

0xb02

Defining extension

  • Zicntr, version >= 0

Length

32-bit

Privilege Mode

M

Format

minstreth format
Figure 1. minstreth format

Field Summary

Name Location Type Reset Value

COUNT

31:0

RW-H

UNDEFINED_LEGAL

Fields

COUNT

Location

minstreth[31:0]

Description

Instructions retired counter

Upper half of minstret.

Type

RW-H

Read-Write with Hardware update

Field is writable by software. Any value that fits in the field is acceptable. Hardware also updates the field without an explicit software write.

Reset value

UNDEFINED_LEGAL

Software write

This field has special behavior when written by software (e.g., through csrrw).

When software tries to write csr_value, the field will be written with the return value of the function below.

CSR[mcycle].COUNT = {csr_value.COUNT[31:0], CSR[minstret].COUNT[31:0]};
return csr_value.COUNT;

Software read

This CSR may return a value that is different from what is stored in hardware.

  • Pruned

  • Original

return CSR[minstret].COUNT[63:32];
return CSR[minstret].COUNT[63:32];