Ticketed shadow owners for Aho's compressed scheduler #
The primary owner bank records productive events at block endpoints. A temporarily unaligned head cannot use that bank, since it need not end at an event. Before such a head is buried under another block, it is sealed into a disjoint shadow bank. Its ticket is the productive event at the start of the block.
For an input of length n, productive owners occupy [0, 2n - 1), their shadows occupy
[2n - 1, 4n - 2), and the last two slots are the temporary scratch and transient owners.
This file contains only the owner arithmetic and semantic ledgers. It does not perform any
machine move.
First physical slot of the bank of productive-event shadows.
Equations
- IndexedGrammar.Aho.shadowOwnerOffset input = 2 * input.length - 1
Instances For
The shadow of a canonical event owner. The shadow has the same root-relative productive ticket, translated into the disjoint second bank.
Equations
- window.shadowEventOwner d hd = ⟨IndexedGrammar.Aho.shadowOwnerOffset input + ↑(window.eventOwner d hd), ⋯⟩
Instances For
Shadowing preserves injectivity of productive event tickets.
Any equality of primary event owners lifts to the corresponding equality in the shadow bank. This is the generic bridge used by unary and binary parse transports.
Shadow owners commute with the one-position event shift of a pop.
Shadow owners commute with the canonical preimage of a push event.
Positive push events and their one-deeper child events have the same shadow owner.
Primary and shadow banks are physically disjoint.
A shadow owner is never the temporary scratch slot.
A shadow owner is never the temporary collision slot.
An owner does not use a shadow ticket belonging to the active productive window. Primary owners and the two temporary owners satisfy this automatically.
Equations
- One or more equations did not get rendered due to their size.
Instances For
A local shadow event lies strictly inside its shadow-ticket window.
Every primary productive owner lies before the shadow bank.
The temporary scratch slot lies after every shadow window.
The temporary collision slot lies after every shadow window.
Every reusable generic label lies beyond every shadow-owner window.
Equal-count transports preserve shadow-window exclusion.
Shadow tickets outside a binary parent window remain outside its left child.
Shadow tickets outside a binary parent window remain outside its right child.
The binary root ticket is already outside the left child's shadow window.
The binary root ticket is already outside the right child's shadow window.
Concrete start position of block i. Unlike blockEndpoint, this excludes block i
itself.
Equations
- IndexedGrammar.Aho.blockStart blocks i = (List.take (↑i) blocks).flatten.length
Instances For
Productive provenance for shadow-bank owners aligned with block starts. Non-shadow owners fall into the outside alternative automatically.
- owner_at (i : Fin blocks.length) : (∃ (hd : blockStart blocks i ∈ parse.eventDepths), blockOwnerAt owners ⋯ i = window.shadowEventOwner (blockStart blocks i) hd) ∨ OutsideShadowWindow window (blockOwnerAt owners ⋯ i)
Instances For
The empty block partition has the empty shadow ledger.
Equations
- ⋯ = ⋯
Instances For
A layout all of whose owners are outside the active shadow window.
Equations
- ⋯ = ⋯
Instances For
Generic parse/window transport. Local shadow tickets are transported explicitly; owners already outside the old window must remain outside the new one.
Equations
- ⋯ = ⋯
Instances For
Prepend one block, shifting every old block start by its length.
Equations
- ⋯ = ⋯
Instances For
Remove the first block, shifting every remaining start back by its length.
Equations
- ⋯ = ⋯
Instances For
Restrict a shadow-start layout to the left binary child. A ticket belonging to the binary root or the right subtree becomes outside the child's shadow window.
Equations
- ⋯ = ⋯
Instances For
Restrict a shadow-start layout to the right binary child. A ticket belonging to the binary root or the left subtree becomes outside the child's shadow window.
Equations
- ⋯ = ⋯
Instances For
Replace the owner of the first block while keeping all shadow-start classifications below it unchanged.
Equations
- ⋯ = ⋯
Instances For
A local shadow event absent from every represented block start is absent from all selected owners.
The shadow ticket at the start of the first block is fresh from every lower block owner. This is the active-layout fact used when a scratch head is sealed at a binary event.
Replacing a non-shadow head by its depth-zero shadow yields a physically fresh owner as soon as the old head is known distinct from that shadow.
When the second block is sealed at the end of a newly prepended first block, its shadow ticket is fresh from the new head and from every block below it.
Every open-frame owner has no ticket in the active shadow window. Primary owners satisfy this automatically. A local shadow-start owner can enter an open frame only after descent through the productive event at its start, at which point that ticket belongs to an ancestor window and is outside the active child window.
Equations
- IndexedGrammar.Aho.ShadowOwnedFrame parse window owner = IndexedGrammar.Aho.OutsideShadowWindow window owner
Instances For
Shadow-ticket provenance for every open frame.
- owner_at (owner : Fin (10 * input.length)) : owner ∈ owners → ShadowOwnedFrame parse window owner
Instances For
Equations
- ⋯ = ⋯
Instances For
Equations
- ⋯ = ⋯
Instances For
Equations
- ⋯ = ⋯
Instances For
Equal-count window transport preserves the outside-only frame invariant.
Equations
- ⋯ = ⋯
Instances For
Parent frame tickets remain outside the left binary child shadow window.
Equations
- ⋯ = ⋯
Instances For
Parent frame tickets remain outside the right binary child shadow window.
Equations
- ⋯ = ⋯
Instances For
Equations
- ⋯ = ⋯
Instances For
No local shadow event can be held by an open frame.
Cursor-level decomposition of shadow tickets. The active start layout is supplied by the runner because its block list is mode-specific.
- frames : ShadowOwnedFrames parse window cursor.frameOwners
- prefixLedger : PrefixFrameLedger cursor
Instances For
The canonical root cursor has an empty shadow ledger.
Equations
Instances For
Whole-cursor shadow freshness. Active right-side owners are excluded by their block starts, the common suffix is outside the shadow window, and prefix indices are reduced to the explicit frame-freshness premise.
Whole-cursor shadow freshness from an explicit active-list freshness fact. Prefix frames and the unselected right suffix are discharged entirely by the shadow ledger.
Generic cursor reassembly after transporting the active parse/window.
Equations
- One or more equations did not get rendered due to their size.