ISARef Multi-ISA & Silicon Reference
45,419 ISA items · 105,907 timings · 1,823 microarchs · 16,083 chips · 105 sources
Arch:
Tier:

mnret

T1 riscv alu insn
Machine mode resume from the RNMI or Double Trap handler
SourceRISC-V Official Unified Database (riscv-unified-db) (riscv_unified_db)
Reliability TierT1 — Official Specification
ISA / Silicon ScopeRV32/RV64 Smrnmi
RV32 / RV64 (Ratified & Standard Extensions)
License & VersionApache-2.0 / CC-BY-4.0
main
Upstreamhttps://github.com/riscv/riscv-unified-db
Privilegeuser
ExtensionsSmrnmi

Summary

MNRET is an M-mode-only instruction that uses the values in mnepc and mnstatus to return to the program counter, privilege mode, and virtualization mode of the interrupted context. This instruction also sets mnstatus.NMIE. If MNRET changes the privilege mode to a mode less privileged than M, it also sets mstatus.MPRV to 0. If the Zicfilp extension is implemented, then if the new privileged mode is y, MNRET sets ELP…

Syntax / Encoding

mnret | 01110000001000000000000001110011 (mask=0xffffffff match=0x70200073)

Binary Encodings (1)

WidthFormatBit PatternMask / Match
32RV011100000010000000000000011100110xffffffff / 0x70200073

Reference Notes

MNRET is an M-mode-only instruction that uses the values in mnepc and mnstatus to return to the
program counter, privilege mode, and virtualization mode of the interrupted context. This instruction
also sets mnstatus.NMIE. If MNRET changes the privilege mode to a mode less privileged than M, it
also sets mstatus.MPRV to 0. If the Zicfilp extension is implemented, then if the new privileged mode is
y, MNRET sets ELP to the logical AND of yLPE (see Section 22.1.1) and mnstatus.MNPELP.