Skip to content
STIMSMITH

SOURCE ARCHIVE

SHA256: fb14957d0d53f72eb848e4dd9fe0dd870cb9384fcc1359e5f513aceaa900b21e
TYPE: text/html
SIZE: 53.0 KB
FETCHED: 8/27/2026, 10:09:56 PM
EXTRACTOR: http-html
CHARS: 2,717

EXTRACTED CONTENT

2,717 chars

Instructions can be grouped into a number of categories. Each category exercises different data and control paths in the core. For example the ADD and SUB instructions are in the same category as they are almost identical for the microarchitecture (both read two registers and write to one, both feed operands to the ALU and take their result from it, both have the same response to interrupts etc; the only difference is the ALU operation).

Instructions can be compressed or uncompressed but that isn’t factored into the instruction categories below (excepting for illegal instructions). The decompression occurs in the IF stage and is invisible to the ID/EX stage so isn’t relevant for instruction execution. A separate set of category-agnostic compressed instruction behaviour is considered instead.

An instruction category is sampled at the ID/EX stage (which is where all the varying behaviours actually occur). Some categories are just a single instruction, which is named without further description.

  • ALU - All of the reg/reg reg/imm instructions that use the ALU. This is any RISC-V instruction with an opcode of 7'b0010011 or 7'b0110011 (ibex_pkg::OPCODE_OP and ibex_pkg::OPCODE_OP_IMM) other than the MUL* and DIV* family of instructions (from RV32M).
  • Mul - Any MUL* instruction (from RV32M).
  • Div - Any DIV* instruction (from RV32M).
  • Branch - Any B* family branch instruction.
  • Jump - JAL/JALR
  • Load - Any L* family load instruction.
  • Store - Any S* family load instruction.
  • CSRAccess - Any instruction from Zicsr.
  • EBreakDbg/EBreakExc - An EBREAK instruction that either enters debug mode (Dbg) or causes an exception (Exc). Which occurs depends upon the setting of dcsr.ebreakm / dcsr.ebreaku combined with the privilege level of executed instruction.
  • ECall - ECALL is an environment call used for escalation of privilege.
  • MRet - MRET return out of M-mode
  • DRet - DRET ruturn from debug mode.
  • WFI - wait for interrupt.
  • Fence - FENCE memory fence on the data side.
  • FenceI - FENCE.I instruction fence instruction.
  • FetchError - Any instruction that saw a fetch error.
  • CompressedIllegal - Any compressed instruction with an illegal encoding.
  • UncompressedIllegal - Any uncompressed instruction with an illegal encoding.
  • CSRIllegal - Any instruction attempting a CSR access that is not allowed.
  • PrivIllegal - Illegal due to privilege level or being in/out of debug mode.
  • OtherIllegal - Any other instruction that raises an Illegal instruction exception that isn’t in the other categories.
  • None - No instruction in ID/EX stage.