Skip to main content

ExitTag

Enum ExitTag 

Source
#[repr(u8)]
pub enum ExitTag { Untouched = 0, Int = 1, Float = 2, Table = 3, Closure = 4, Nil = 5, Str = 6, }
Expand description

What tag a register holds at the trace’s exit point (relative to its entry tag). Stored per register in CompiledTrace.exit_tags so the dispatcher knows how to re-pack the i64 payload back into a Value after the trace runs.

Variants§

§

Untouched = 0

Slot is untouched by the trace — restore the entry tag.

§

Int = 1

Trace writes an Int value to this slot (arith result, LoadI, Len, ForLoop step / count / visible-var).

§

Float = 2

Trace writes a Float bit-pattern to this slot (LoadF result, Float arith on two Float operands).

§

Table = 3

Trace writes a Table ptr to this slot (NewTable result).

§

Closure = 4

P12-S4-step2c — trace writes a Closure ptr to this slot. Today the only producer is Op::GetUpval whose result is inferred (via infer_upval_exit) to feed an Op::Call as the call target — the upval must be a closure for that dispatch to be sound.

§

Nil = 5

P12-S6-A1 — trace actively writes Nil to this slot (the only producer today is Op::LoadNil; raw payload is 0). The dispatcher restores Value::Nil regardless of the slot’s entry tag. Split out from Untouched so a LoadNil writer over an Int/Float/Table entry slot doesn’t get mis-packed back as the entry type.

§

Str = 6

P12-S12-C v2 — trace writes a Str ptr to this slot (LoadK of a Str constant, Move from a Str slot, or Concat result). Dispatcher repacks as Value::Str(Gc::from_ptr(raw)).

Trait Implementations§

Source§

impl Clone for ExitTag

Source§

fn clone(&self) -> ExitTag

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for ExitTag

Source§

impl Debug for ExitTag

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
Source§

impl Eq for ExitTag

Source§

impl PartialEq for ExitTag

Source§

fn eq(&self, other: &ExitTag) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl StructuralPartialEq for ExitTag

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.