[][src]Struct cranelift_codegen::isa::StackRef

pub struct StackRef {
    pub base: StackBase,
    pub offset: StackOffset,
}

A method for referencing a stack slot in the current stack frame.

Stack slots are addressed with a constant offset from a base register. The base can be the stack pointer, the frame pointer, or (in the future) a zone register pointing to an inner zone of a large stack frame.

Fields

base: StackBase

The base register to use for addressing.

offset: StackOffset

Immediate offset from the base register to the first byte of the stack slot.

Methods

impl StackRef[src]

pub fn masked(
    ss: StackSlot,
    mask: StackBaseMask,
    frame: &StackSlots
) -> Option<Self>
[src]

Get a reference to the stack slot ss using one of the base pointers in mask.

pub fn sp(ss: StackSlot, frame: &StackSlots) -> Self[src]

Get a reference to ss using the stack pointer as a base.

Trait Implementations

impl Clone for StackRef[src]

impl Copy for StackRef[src]

impl Debug for StackRef[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.