- Exceptions
-
CHERI fault exceptions occur when the authorizing capability fails one of the checks listed below; in this case, CHERI data fault is reported in the [mtval2] or [stval2] TYPE field and the corresponding code is written to CAUSE.
CAUSE Reason Tag violation
Authority capability tag set to 0, or has any reserved bits set
Seal violation
Authority capability is sealed
Permission violation
Authority capability does not grant [w_perm], or the AP field could not have been produced by [ACPERM]
Invalid address violation
The effective address is invalid according to [section_invalid_addr_conv]
Bounds violation
At least one byte accessed is outside the authority capability bounds, or the capability has malformed bounds
If {cheri_pte_ext_name} is implemented, and virtual memory is enabled, then the state of PTE.CW and PTE.CRG from the current virtual memory page may cause a CHERI PTE page fault exception in addition to a normal RISC-V page fault. See [mtval2-page-fault] for the exception reporting in this case.