pub enum Arch {
X86(Mode),
AArch64,
}Expand description
The architecture to decode for, with x86’s processor mode.
Variants§
Implementations§
Source§impl Arch
impl Arch
Sourcepub const fn max_length(self) -> usize
pub const fn max_length(self) -> usize
The longest instruction, in bytes: 15 on x86, 4 on AArch64 (whose instructions are all 4 bytes).
Sourcepub const fn invalid_step(self) -> usize
pub const fn invalid_step(self) -> usize
How far a Decoder moves past bytes that are no instruction: one
byte on x86, so that a sweep resynchronises; four on AArch64.
Trait Implementations§
impl Copy for Arch
impl Eq for Arch
impl StructuralPartialEq for Arch
Auto Trait Implementations§
impl Forget for Arch
impl Freeze for Arch
impl Move for Arch
impl RefUnwindSafe for Arch
impl Send for Arch
impl Sync for Arch
impl Unpin for Arch
impl UnsafeUnpin for Arch
impl UnwindSafe for Arch
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