[−][src]Struct cranelift_codegen_meta::cdsl::recipes::EncodingRecipe
A recipe for encoding instructions with a given format.
Many different instructions can be encoded by the same recipe, but they must all have the same instruction format.
The operands_in and operands_out arguments are tuples specifying the register
allocation constraints for the value operands and results respectively. The
possible constraints for an operand are:
- A
RegClassspecifying the set of allowed registers. - A
Registerspecifying a fixed-register operand. - An integer indicating that this result is tied to a value operand, so they must use the same register.
- A
Stackspecifying a value in a stack slot.
The branch_range argument must be provided for recipes that can encode
branch instructions. It is an (origin, bits) tuple describing the exact
range that can be encoded in a branch instruction.
Fields
name: StringShort mnemonic name for this recipe.
format: Rc<InstructionFormat>Associated instruction format.
base_size: u64Base number of bytes in the binary encoded instruction.
operands_in: Vec<OperandConstraint>Tuple of register constraints for value operands.
operands_out: Vec<OperandConstraint>Tuple of register constraints for results.
compute_size: &'static strFunction name to use when computing actual size.
branch_range: Option<BranchRange>(origin, bits) range for branches.
clobbers_flags: boolThis instruction clobbers iflags and fflags; true by default.
inst_predicate: Option<InstructionPredicate>Instruction predicate.
isa_predicate: Option<u8>ISA predicate.
emit: Option<String>Rust code for binary emission.
Trait Implementations
impl Clone for EncodingRecipe[src]
fn clone(&self) -> EncodingRecipe[src]
fn clone_from(&mut self, source: &Self)1.0.0[src]
impl Eq for EncodingRecipe[src]
impl PartialEq<EncodingRecipe> for EncodingRecipe[src]
Auto Trait Implementations
impl !RefUnwindSafe for EncodingRecipe
impl !Send for EncodingRecipe
impl !Sync for EncodingRecipe
impl Unpin for EncodingRecipe
impl !UnwindSafe for EncodingRecipe
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T[src]
impl<T> From<T> for T[src]
impl<T, U> Into<U> for T where
U: From<T>, [src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone, [src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T[src]
fn clone_into(&self, target: &mut T)[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,