pub struct DeoptInfo {
pub resume_ip: usize,
pub local_mapping: Vec<(u16, u16)>,
pub local_kinds: Vec<SlotKind>,
pub stack_depth: u16,
pub innermost_function_id: Option<u16>,
pub inline_frames: Vec<InlineFrameInfo>,
}Expand description
Metadata for deoptimization – maps JIT state back to interpreter state.
When a type guard or other speculative assumption fails inside JIT-compiled
code, the JIT returns the deopt sentinel (u64::MAX). The VM uses this
struct to reconstruct interpreter state from the JITContext locals and
resume execution in the bytecode interpreter.
Fields§
§resume_ip: usizeBytecode IP to resume at in the interpreter.
local_mapping: Vec<(u16, u16)>Map from JIT local index to bytecode local index.
Each pair is (jit_local_idx, bytecode_local_idx).
local_kinds: Vec<SlotKind>SlotKind for each mapped local (parallel to local_mapping, used for
unmarshaling JIT values back to interpreter ValueWord representation).
stack_depth: u16Stack depth at this deopt point (number of values on the operand stack).
innermost_function_id: Option<u16>Function ID of the innermost frame (where the guard fired). For single-frame deopt this equals the physical JIT function. For multi-frame deopt this is the inlined callee.
inline_frames: Vec<InlineFrameInfo>Caller frames for multi-frame deopt (outermost-first: [0] = outermost physical function). Empty for single-frame deopt (the common case).
Trait Implementations§
Source§impl<'de> Deserialize<'de> for DeoptInfo
impl<'de> Deserialize<'de> for DeoptInfo
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Auto Trait Implementations§
impl Freeze for DeoptInfo
impl RefUnwindSafe for DeoptInfo
impl Send for DeoptInfo
impl Sync for DeoptInfo
impl Unpin for DeoptInfo
impl UnsafeUnpin for DeoptInfo
impl UnwindSafe for DeoptInfo
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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>
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>
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