pub enum ZkrInstruction<Hart>where
Hart: HartConfig,{
Csrrw {
rs1: Hart::Reg,
rd: Hart::Reg,
csr_index: u16,
/* private fields */
},
Csrrs {
rs1: Hart::Reg,
rd: Hart::Reg,
csr_index: u16,
/* private fields */
},
Csrrc {
rs1: Hart::Reg,
rd: Hart::Reg,
csr_index: u16,
/* private fields */
},
Csrrwi {
rd: Hart::Reg,
zimm: u8,
csr_index: u16,
/* private fields */
},
Csrrsi {
rd: Hart::Reg,
zimm: u8,
csr_index: u16,
/* private fields */
},
Csrrci {
rd: Hart::Reg,
zimm: u8,
csr_index: u16,
/* private fields */
},
}Expand description
RISC-V Zkr instruction.
Zkr (the entropy source extension) defines no instructions of its own: it only adds the
seed CSR (see SEED_CSR_INDEX), which is accessed through ordinary Zicsr instructions.
Variants§
Trait Implementations§
Source§impl<Hart> Clone for ZkrInstruction<Hart>
impl<Hart> Clone for ZkrInstruction<Hart>
Source§fn clone(&self) -> ZkrInstruction<Hart>
fn clone(&self) -> ZkrInstruction<Hart>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl<Hart> Copy for ZkrInstruction<Hart>
Source§impl<Hart> Debug for ZkrInstruction<Hart>
impl<Hart> Debug for ZkrInstruction<Hart>
§impl<Reg, Hart> Display for ZkrInstruction<Hart>
impl<Reg, Hart> Display for ZkrInstruction<Hart>
impl<Hart> Eq for ZkrInstruction<Hart>
§impl<Reg, Hart> Instruction for ZkrInstruction<Hart>where
Reg: Register,
Hart: HartConfig<Reg = Reg>,
impl<Reg, Hart> Instruction for ZkrInstruction<Hart>where
Reg: Register,
Hart: HartConfig<Reg = Reg>,
§const IMPLEMENTED_EXTENSIONS: &'static [ImplementedExtension]
const IMPLEMENTED_EXTENSIONS: &'static [ImplementedExtension]
All implemented extensions, including this instruction itself, with their ISA extensions. Read more
§const OWN_ISA_EXTENSIONS: &'static [IsaExtension]
const OWN_ISA_EXTENSIONS: &'static [IsaExtension]
ISA extensions defined by this instruction enum itself, without inherited ones. Read more
§fn try_decode(instruction: u32) -> Option<Self>
fn try_decode(instruction: u32) -> Option<Self>
Try to decode a single valid instruction
Source§const ISA_STRING: &'static str = _
const ISA_STRING: &'static str = _
ISA string as used in the
Tag_RISCV_arch attribute of ELF files, for example,
rv64i2p1_m2p0_zmmul1p0. Read moreSource§fn implements_extension<E>() -> boolwhere
E: Instruction<Hart = Self::Hart>,
fn implements_extension<E>() -> boolwhere
E: Instruction<Hart = Self::Hart>,
Checks whether this instruction implements the given extension, see
Self::IMPLEMENTED_EXTENSIONS for detailsSource§impl<Hart> PartialEq for ZkrInstruction<Hart>
impl<Hart> PartialEq for ZkrInstruction<Hart>
impl<Hart> StructuralPartialEq for ZkrInstruction<Hart>
Auto Trait Implementations§
impl<Hart> Freeze for ZkrInstruction<Hart>
impl<Hart> RefUnwindSafe for ZkrInstruction<Hart>
impl<Hart> Send for ZkrInstruction<Hart>
impl<Hart> Sync for ZkrInstruction<Hart>
impl<Hart> Unpin for ZkrInstruction<Hart>
impl<Hart> UnsafeUnpin for ZkrInstruction<Hart>
impl<Hart> UnwindSafe for ZkrInstruction<Hart>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more