Skip to main content

word_uses_reserved_reg

Function word_uses_reserved_reg 

Source
pub fn word_uses_reserved_reg(w: u32) -> bool
Expand description

Reserved-register predicate on a raw 4-byte word, for the recompiler (which dispatches on raw words rather than building an Inst, and runs on the cold-compile hot path — so this must not re-decode).

True iff the word names x16..x31 (which do not exist in RV64E) in a real register field. For every word this equals Inst::uses_reserved_reg (pinned by word_predicate_matches_inst_predicate), so the interpreter and recompiler agree on which encodings are illegal and panic.