Skip to main content

Crate sim_lib_machine

Crate sim_lib_machine 

Source
Expand description

Policy contracts for neutral, bounded decoded-instruction machines.

Consumers supply every semantic choice through the traits below; the execution engine only owns bounded, iterative control transfer.

Structs§

AdmissionLimits
Hard bounds admitted for one machine description.
BranchTarget
A branch edge to validate and freeze into the target map.
CallTransfer
Guest-neutral call data: a code reference and width-accounted values.
CodeCursor
An instruction position minted only by validated LocatedCode.
ContinuationEvidence
Content-bound evidence for a suspended continuation and its receipt prefix.
CoverageMetadata
Stable metadata used to associate execution with a coverage counter.
Driver
Bounded iterative instruction driver.
Frame
One admitted activation, composed entirely from bounded machine state.
FrameStack
An explicit activation stack whose depth never consumes the host call stack.
LocatedCode
Immutable, fully validated located instructions and their control metadata.
LocatedFault
An instruction failure paired with its stable identity and source location.
LocatedInstruction
A decoded instruction and all immutable metadata required before execution.
MachineCheckpoint
Owned resumable machine state; construction requires an admitted permit.
MachineDescription
Immutable code plus the consumer-owned metadata needed to admit it.
MachinePermit
Proof that one exact immutable machine description passed admission.
ProtectedRegion
A validated protected region whose positions can only be valid cursors.
RegionSpec
A protected-region declaration using half-open instruction identities.
ReturnTransfer
Guest-neutral return data carrying width-accounted values to a continuation.
RootSnapshot
A complete, ordered view of roots visible at one machine safepoint.
ShufflePlan
A validated permutation and duplication of whole logical value groups.
SlotFile
Bounded indexed storage whose occupancy is measured in policy-defined units.
UnitStack
A bounded LIFO stack measured in policy-defined logical units.
WorkReceipt
Deterministic evidence for the exact instruction work performed by one drive.

Enums§

AdmissionError
A refusal produced before a permit can exist.
CodeError
Exact refusal evidence produced while freezing located code.
DriveError
A refusal produced by the iterative driver.
DriveOutcome
A completed or suspended iterative drive.
FrameStackError
Failure to admit another explicit frame.
MachineAbrupt
Abrupt terminal reasons carried through the control organ’s unwind vocabulary.
RootScanError
Deterministic refusal to materialize a complete root snapshot.
SafepointDriveError
A refusal from root publication or instruction execution during safepoint driving.
ShuffleError
Failure to construct or execute a logical stack shuffle.
SlotError
Exact failure evidence from indexed slot storage.
SourceLocation
Source units used to locate a decoded instruction.
StackError
Exact failure evidence from a unit-accounted operand stack.
StepKind
Stable classification recorded for each charged instruction.
StepOutcome
The explicit result of executing exactly one decoded instruction.
TargetLocation
An unresolved branch destination supplied by a code preparer.
Transfer
Explicit control transfer interpreted by a consumer-owned machine driver.
TransferError
Malformed value-width evidence in a transfer packet.

Traits§

AdmissionPolicy
Pure consumer checks and canonical encoding used during admission.
EffectPolicy
Classifies the effects an instruction may request from its driver.
FramePolicy
Describes bounded guest-frame metadata without owning frame storage.
HandlerPolicy
Selects protected regions and consumer-defined abrupt outcomes.
InstructionDriverPolicy
Consumer semantics invoked once per charged instruction.
InstructionPolicy
Supplies stable instruction identity and the consumer’s decoded form.
MachineFrame
The cursor access needed by the neutral driver.
ManagedRootSource
Projects live machine storage into the shared managed-object identity space.
ReceiptPolicy
Creates deterministic evidence for bounded machine work.
RootPolicy
Projects live machine state into the managed-root owner’s identity type.
SafepointPolicy
Declares semantic polling locations in prepared code.
ValueWidthPolicy
Accounts values in consumer-defined logical storage units.

Type Aliases§

DriveResult
Result type returned by one bounded drive operation.
MachineUnwind
Control-organ reason delivered exactly once to registered machine cleanups.
PolicyStep
Result type returned by one consumer instruction policy invocation.