pub struct SigmaKernelAssist { /* private fields */ }Expand description
σ-aware KernelAssist. Owns only ephemeral per-block kernel state.
Implementations§
Source§impl SigmaKernelAssist
impl SigmaKernelAssist
pub fn new() -> Self
Sourcepub fn reset_block_state(&mut self)
pub fn reset_block_state(&mut self)
Reset per-block ephemeral tables. Called at the start of each block apply.
Sourcepub fn seed_root_gas(&mut self, budget: u64)
pub fn seed_root_gas(&mut self, budget: u64)
Seed the root gas meter (meter_id 0) with the chain’s block-wide gas budget.
Sourcepub fn seed_root_quota(&mut self, budget: u64)
pub fn seed_root_quota(&mut self, budget: u64)
Seed the root storage quota (quota_id 0).
Trait Implementations§
Source§impl Default for SigmaKernelAssist
impl Default for SigmaKernelAssist
Source§impl KernelAssist for SigmaKernelAssist
impl KernelAssist for SigmaKernelAssist
Source§fn gas_meter_get(&self, meter_id: MeterId) -> u64
fn gas_meter_get(&self, meter_id: MeterId) -> u64
Read the remaining gas for
meter_id. Missing entry → 0.Source§fn gas_meter_set(&mut self, meter_id: MeterId, value: u64) -> u64
fn gas_meter_set(&mut self, meter_id: MeterId, value: u64) -> u64
Atomically
GasMeter[meter_id] := value; return previous value
(or 0 if no entry existed).fn storage_quota_get(&self, quota_id: QuotaId) -> u64
fn storage_quota_set(&mut self, quota_id: QuotaId, value: u64) -> u64
Source§fn yield_catcher_markers(&self, catcher_hash: CapHash) -> Vec<CapHash> ⓘ
fn yield_catcher_markers(&self, catcher_hash: CapHash) -> Vec<CapHash> ⓘ
Read the marker list for a YieldCatcher instance identified by
catcher_hash. Order matters: routing walks the list and takes
the first match.Source§fn yield_catcher_add(
&mut self,
catcher_hash: CapHash,
marker_instance_hash: CapHash,
)
fn yield_catcher_add( &mut self, catcher_hash: CapHash, marker_instance_hash: CapHash, )
Add a marker template to the catcher’s list.
Source§fn yield_catcher_remove(
&mut self,
catcher_hash: CapHash,
marker_instance_hash: CapHash,
)
fn yield_catcher_remove( &mut self, catcher_hash: CapHash, marker_instance_hash: CapHash, )
Remove a marker template. No-op if absent.
Source§fn yield_catcher_new(&mut self) -> CapHash
fn yield_catcher_new(&mut self) -> CapHash
Mint a fresh empty YieldCatcher. Returns its content hash
(which the caller stores as a Cap::Instance[YieldCatcher]).
Auto Trait Implementations§
impl Freeze for SigmaKernelAssist
impl RefUnwindSafe for SigmaKernelAssist
impl Send for SigmaKernelAssist
impl Sync for SigmaKernelAssist
impl Unpin for SigmaKernelAssist
impl UnsafeUnpin for SigmaKernelAssist
impl UnwindSafe for SigmaKernelAssist
Blanket Implementations§
§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
§type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
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
§impl<T> LayoutRaw for T
impl<T> LayoutRaw for T
§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Returns the layout of the type.