Branch-local compressed-index overlays #
A protected compressed block may be shared by a pending sibling and therefore cannot be updated in place. A branch which pushes above that shared suffix instead keeps a overlay, adjacent copy-on-write prefix. The head of this prefix is the mutable compressed accumulator; temporary event-boundary blocks may be consed above it and popped again without forgetting that the lower head is still overlay.
This file is deliberately ghost-only. An overlay index erases to the existing
WorkSym.index, so all operations are already certified by livePushFresh,
livePushCompress, the adjacent pop-and-erase moves, and eraseIndex. The only missing datum
in the runner is which adjacent lower indices remain branch-local.
Computed overlay words and ledgers #
Concrete flag blocks carried by the overlay overlay, nearest block first.
Equations
Instances For
The complete visible flag prefix after placing an overlay above a protected suffix.
Equations
- IndexedGrammar.Aho.ScheduleOverlay.flags overlay baseSuffix = (IndexedGrammar.Aho.ScheduleOverlay.blocks overlay).flatten ++ baseSuffix
Instances For
Persistent owners of the overlay followed by those of the protected suffix.
Equations
- IndexedGrammar.Aho.ScheduleOverlay.owners overlay baseSuffix = List.map IndexedGrammar.Aho.ScheduleIndex.owner overlay ++ baseSuffix
Instances For
Physical scheduler word with every overlay overlay block adjacent to the active task.
Equations
- IndexedGrammar.Aho.ScheduleOverlay.word overlay baseSuffix = List.map IndexedGrammar.Aho.ScheduleAtom.index overlay ++ baseSuffix
Instances For
Endpoint word after every overlay block and every protected block has been marked used.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Adjacent overlay certificate #
An adjacent overlay index prefix layered over an already certified protected layout.
The certificate is indexed only by the list of overlay ScheduleIndex records. All other
objects are computed by ScheduleOverlay, which makes consing a fresh block, replacing the
mutable head, and popping a temporary head exact operations rather than transports between
existential layouts.
- nil {T : Type} {g : IndexedGrammar T} [Fintype g.nt] {input : List T} {protectedFlags : List g.flag} {protectedBlocks : List (List g.flag)} {protectedOwners : List (Fin (10 * input.length))} {protectedWord protectedUsed : List (ScheduleAtom g input)} {base : ScheduleBlockLayout g input protectedFlags protectedBlocks protectedOwners protectedWord protectedUsed} : AdjacentOverlayLayout base []
- cons {T : Type} {g : IndexedGrammar T} [Fintype g.nt] {input : List T} {protectedFlags : List g.flag} {protectedBlocks : List (List g.flag)} {protectedOwners : List (Fin (10 * input.length))} {protectedWord protectedUsed : List (ScheduleAtom g input)} {base : ScheduleBlockLayout g input protectedFlags protectedBlocks protectedOwners protectedWord protectedUsed} {overlay : List (ScheduleIndex g input)} (idx : ScheduleIndex g input) (block_ne : idx.flags ≠ []) (later : ScheduleOverlay.flags overlay protectedFlags ≠ [] → idx.mark.later = true) (fresh : idx.owner ∉ ScheduleOverlay.owners overlay protectedOwners) (rest : AdjacentOverlayLayout base overlay) : AdjacentOverlayLayout base (idx :: overlay)
Instances For
The empty overlay prefix is the protected layout itself.
Equations
- ⋯ = ⋯
Instances For
Put one mutable overlay block above a protected suffix.
Equations
- ⋯ = ⋯
Instances For
Cons a new overlay event-boundary block above an existing overlay.
Equations
- ⋯ = ⋯
Instances For
Pop the adjacent overlay head while retaining the lower copy-on-write classification.
A nonempty overlay supplies the live-focus premise used by every overlay runner state.
Replace only the mutable head. This is the ghost counterpart of livePushCompress.
The lower overlay stack and the shared protected base are unchanged.
Forget copy-on-write status and seal every overlay block into the ordinary protected layout. This is used exactly when a binary fork starts sharing the overlay between its children.
All overlay and protected owners are duplicate-free.
Overlay owners are duplicate-free independently of the protected suffix.
No branch-local owner aliases an owner in the shared protected suffix.
Every block in the sealed overlay/protected layout is nonempty.
The complete visible prefix is exactly the flattening of the sealed block list.
Sealing preserves the exact block/owner alignment required by the protected runner.