Expand description
KernelAssist trait: the integration point for kernel-assisted
Instances (GasMeter, StorageQuota, YieldCatcher).
Per the v3 spec (README §22 “Kernel-assisted Instances”), certain
Cap::Instance values are recognized by their image_hash_chain as
kernel-internal. The kernel short-circuits their state access — no
bytecode dispatch, no endpoint walk. From userspace, those caps
still look like ordinary Cap::Instance values; the
special-cased path is invisible.
After the move to the javm_cap::Cap<A> cache model, image / data
/ file lookups are cache operations rather than KernelAssist
hooks — the cache holds the content, the assist holds only the
per-block ephemeral kernel state (gas meters, storage quotas,
yield catchers, file id allocation).
Structs§
- InProcess
Kernel Assist - In-process, in-memory
KernelAssistimpl. State lives in plainHashMaps. Used by Stage 3’s tests and as a runnable default beforejar-kernel-v3lands its σ-backed implementation.
Enums§
- Kernel
Image - Identifies which kernel-assisted Image a given image_hash chain refers to. Recognized by the registry’s content-hash lookup.
Traits§
- Kernel
Assist - The integration point for kernel-assisted Instances.
Functions§
- kernel_
image_ hash - Compute the well-known image_hash for a kernel-assisted Image.
- recognize_
kernel_ image - Look up a known kernel-assisted Image by its image_hash chain.
Returns
Nonefor a hash that doesn’t match any kernel-known Image (the common case — user Images are not kernel-assisted).