ISARef Multi-ISA & Silicon Reference
45,419 ISA items · 105,907 timings · 913 microarchs · 15,555 chips · 105 sources
Arch:
Tier:

c.ebreak

T1 riscv alu insn
Breakpoint exception
SourceRISC-V Official Unified Database (riscv-unified-db) (riscv_unified_db)
Reliability TierT1 — Official Specification
ISA / Silicon ScopeRV32/RV64 Zca
RV32 / RV64 (Ratified & Standard Extensions)
License & VersionApache-2.0 / CC-BY-4.0
main
Upstreamhttps://github.com/riscv/riscv-unified-db
Privilegeuser
ExtensionsZca

Summary

The C.EBREAK instruction is used by debuggers to cause control to be transferred back to a debugging environment. Unless overridden by an external debug environment, C.EBREAK raises a breakpoint exception and performs no other operation.

Syntax / Encoding

c.ebreak | 1001000000000010 (mask=0xffff match=0x9002)

Binary Encodings (1)

WidthFormatBit PatternMask / Match
16RV10010000000000100xffff / 0x9002

Reference Notes

The C.EBREAK instruction is used by debuggers to cause control to be transferred back to
a debugging environment. Unless overridden by an external debug environment,
C.EBREAK raises a breakpoint exception and performs no other operation.

[NOTE]
As described in the `C` Standard Extension for Compressed Instructions, the `c.ebreak`
instruction performs the same operation as the EBREAK instruction.

EBREAK causes the receiving privilege mode's epc register to be set to the address of
the EBREAK instruction itself, not the address of the following instruction.
As EBREAK causes a synchronous exception, it is not considered to retire,
and should not increment the `minstret` CSR.