MOP.RR.0

RISC-V MOP.RR.0 Instruction Details

Instruction ManualR-type

MOP.RR.0 writes zero to rd under its default Zimop definition; a redefining extension may use rs1 and rs2.

Instruction Syntax

mop.rr.0 rd, rs1, rs2
Operand Breakdown
rd: the default semantics write 0 to x[rd]; with rd=x0 the architectural write is discarded and x0 remains 0.
rs1 and rs2: explicit register fields in the recommended assembly syntax; the default Zimop definition reads neither and carries no syntactic dependency from either source to rd.
Bits 31..25 are a fixed MOP.RR.n selector; only a future redefining extension may specify reads of rs1, rs2, or both.
ZimopSystem & Privileged

Extension condition: RV32/RV64 requires Zimop 1.0; this page describes the base behavior unless another extension redefines it.

Instruction Encoding

31..25
fixed n selector
24..20
rs2
19..15
rs1
14..12
funct3
11..7
rd
6..0
opcode

MOP.RR.0 uses opcode 1110011 (0x73), funct3 100, fixed n selector 1000001. MOP.RR.n uses SYSTEM fields: bits 31..25 are the fixed n selector, rs2, rs1, and rd are explicit register fields, funct3=100, and opcode=SYSTEM. The default definition writes only 0 to x[rd]; neither rs1 nor rs2 is a default read source.

Format: Zimop MOP.RR SYSTEM fields (n=0)
opcode: 1110011 (0x73)
funct3: 100 (0x4)
fixed n selector: 1000001 (0x41)

Instruction Behavior

MOP.RR.0 is a Zimop may-be-operation with recommended syntax mop.rr.0 rd, rs1, rs2. If no other extension redefines the encoding, the official default behavior writes 0 to x[rd]. The encoding space allows future extensions to define it as reading x[rs1] and x[rs2] and writing x[rd]. Standard software should not execute a MOP unless deliberately targeting an extension that redefines it. rd may be x0, in which case x0 remains zero; register overlap does not turn the base behavior into a copy or computation.

Quick Understanding & Search Notes

MOP.RR.0 is a three-register Zimop MOP encoding; when not redefined, it writes zero to rd.

The official extension defines 8 MOP.RR.n instructions numbered 0 through 7.
MOP.RR.n allows a future extension to read rs1/rs2 and write rd, but by default it reads no source registers and creates no source-to-destination syntactic dependency.
Bits 31..25 are fixed to 1000001, not an assembly immediate; funct3=100 and opcode=1110011 (SYSTEM).

Common Usage Scenarios

System & Privileged

Assume RV32/RV64 Zimop 1.0 is implemented and this MOP is not redefined: mop.rr.0 t0, t1, t2 sets t0 (x5) to zero regardless of the old t1 (x6) and t2 (x7) values; other registers are unchanged. Overlapping rd with a source field still writes zero; rd=x0 leaves x0 zero. Standard software should execute it only when deliberately targeting an extension that redefines this MOP.

Extension Compatibility

Assume RV32/RV64 Zimop 1.0 is implemented and this MOP is not redefined: mop.rr.0 t0, t1, t2 sets t0 (x5) to zero regardless of the old t1 (x6) and t2 (x7) values; other registers are unchanged. Overlapping rd with a source field still writes zero; rd=x0 leaves x0 zero. Standard software should execute it only when deliberately targeting an extension that redefines this MOP.

Pre-Use Checklist

Syntax Check
  • Confirm the assembly syntax has only rd, rs1, and rs2; bits 31..25 are the fixed MOP.RR.n selector, not an ordinary R-type funct7 operation.
  • Confirm any x-register is valid for all three fields; the default definition reads neither rs1 nor rs2 and carries no syntactic dependency from either source to rd.
Semantic Check
  • Confirm that, unless another extension has redefined it, the instruction only writes 0 to x[rd]; with rd=x0, x0 remains 0.
  • Do not assume a specific future redefining operation; standard software should execute this MOP only when deliberately targeting that redefining extension.

Pitfalls / Common Confusions

The default behavior writes zero to rd rather than generally leaving registers unchanged; with rd=x0, x0 remains zero.
Default Zimop MOPs carry no syntactic dependency from rs1/rs2 to rd; a redefining extension may specify otherwise.
Zimop defines only MOP.RR.0 through MOP.RR.7.

FAQ

Does MOP.RR.0 write rd by default?

Under the default Zimop definition described here, it writes zero to rd; if rd=x0, x0 remains zero. For redefined behavior, consult the corresponding extension.

How is MOP.RR.0 different from MOP.R.0?

MOP.RR is reserved for future extensions that may read two source registers; MOP.R is reserved for future extensions that may read one source register.