pub enum Pseudo {
Show 14 variants
La {
rd: Register,
symbol: Label,
},
Li {
rd: Register,
imm: u64,
},
Mv {
rd: Register,
rs: Register,
},
Fmv {
data_size: DataSize,
rd: Register,
rs: Register,
},
Neg {
data_size: DataSize,
rd: Register,
rs: Register,
},
SextW {
rd: Register,
rs: Register,
},
Seqz {
rd: Register,
rs: Register,
},
Snez {
rd: Register,
rs: Register,
},
Fneg {
data_size: DataSize,
rd: Register,
rs: Register,
},
J {
offset: Label,
},
Jr {
rs: Register,
},
Jalr {
rs: Register,
},
Ret,
Call {
offset: Label,
},
}
Expand description
The assembler implements several convenience psuedo-instructions that are formed from multiple instructions in the base ISA, but have implicit arguments or reversed arguments that result in distinct semantics.
For more information: https://github.com/michaeljclark/michaeljclark.github.io/blob/master/asm.md#assembler-pseudo-instructions
Variants§
La
la rd, symbol
Li
li rd, immediate
Mv
mv rd, rs
Fmv
fmv.s rd, rs or fmv.d rd, rs
Neg
neg(w) rd, rs
SextW
sext.w rd, rs
Seqz
seqz rd, rs
Snez
snez rd, rs
Fneg
fneg.s rd, rs or fneg.d rd, rs
J
j offset
Jr
jr rs
Jalr
jalr rs
Ret
ret
Call
call offset
Implementations§
Trait Implementations§
impl Eq for Pseudo
impl StructuralPartialEq for Pseudo
Auto Trait Implementations§
impl Freeze for Pseudo
impl RefUnwindSafe for Pseudo
impl Send for Pseudo
impl Sync for Pseudo
impl Unpin for Pseudo
impl UnwindSafe for Pseudo
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more