Documentation

LeanPool.OrderMaintenance.Impl.PeakTop2

Theorem W, option (A), stage A2: the cut of a drain, its side list, and its end #

Nothing here is used by Theorems A and B.

theorem OrderMaintenance.Impl.gdD_K {K KH : ℕ} {κ : Caps} {s : Model.Core} {L : Loc} (hG : Gd K KH κ (ΓD K) s L) {x : Machine.Reg} (hx : ¬(x = "t" ∨ x = "b" ∨ x = "ws")) :
L x < 2 ^ K
theorem OrderMaintenance.Impl.wt_val {K KH W : ℕ} {κ : Caps} (hC : CapsW K κ) (hK : 8 ≤ K) (hW : 2 * K + 4 ≤ W) {S : Model.Core} {L' : Loc} (hG : Gd K KH κ (ΓD K) S L') {S2 : Model.Core} {L2 : Loc} {n : ℕ} (h : evalF κ wtS S L' = Res.ok S2 L2 n) :
L2 "w" < 2 ^ K

wtS: the weight of a child (1 at height 1).

theorem OrderMaintenance.Impl.sum_pk {K KH W : ℕ} {κ : Caps} {s : Model.Core} {L : Loc} (hC : CapsW K κ) (hK : 8 ≤ K) (hW : 2 * K + 4 ≤ W) (hcap : κ.lcap LK.children < 512) {N : ℕ} (hNc : N ≤ κ.lcap LK.children) (hG : Gd K KH κ (ΓD K) s L) (hn : L "n" = N) :
PK K KH κ (ΓD K) W sumS s L

The sum of the children's weights: t ≤ j·(2^K − 1) before iteration j.

theorem OrderMaintenance.Impl.cut_pk {K KH W : ℕ} {κ : Caps} {s : Model.Core} {L : Loc} (hC : CapsW K κ) (hK : 8 ≤ K) (hW : 2 * K + 4 ≤ W) {N : ℕ} (hNK : N < 2 ^ K) (hG : Gd K KH κ (ΓD K) s L) (hn : L "n" = N) :
PK K KH κ (ΓD K) W cutS s L

The cut: the count c stays at most the loop index.

theorem OrderMaintenance.Impl.shR_pk {K KH W : ℕ} {κ : Caps} {s : Model.Core} {L : Loc} (hC : CapsW K κ) (hK : 8 ≤ K) (hW : 2 * K + 4 ≤ W) {N : ℕ} (hNK : N < 2 ^ K) (hG : Gd K KH κ (ΓD K) s L) (hn : L "n" = N) :
PK K KH κ (ΓD K) W shRS s L

The shift to the right: k + 1 only when k < n.

theorem OrderMaintenance.Impl.drainCut_pk {K KH W : ℕ} {κ : Caps} {s : Model.Core} {L : Loc} (hC : CapsW K κ) (hK : 8 ≤ K) (hW : 2 * K + 4 ≤ W) (hcap : κ.lcap LK.children < 512) (hG : Gd K KH κ (ΓD K) s L) :
PK K KH κ (ΓD K) W drainCutS s L

The cut of a drain (drainCut), with at most 511 children.

theorem OrderMaintenance.Impl.drainSide_pk {K KH W : ℕ} {κ : Caps} {s : Model.Core} {L : Loc} (hC : CapsW K κ) (hK : 8 ≤ K) (hW : 2 * K + 4 ≤ W) (hG : Gd K KH κ (ΓD K) s L) :
PK K KH κ (ΓD K) W drainSideS s L
theorem OrderMaintenance.Impl.filterCall_pk {K KH W : ℕ} {κ : Caps} {s : Model.Core} {L : Loc} (hC : CapsW K κ) (hK : 8 ≤ K) (hW : 2 * K + 4 ≤ W) {Γ : Machine.Reg → ℕ} {k : LK} {args : List Exp} {ds : List Machine.Reg} (hG : Gd K KH κ Γ s L) (ha : ∀ e ∈ args, Exp.OK Γ K KH W e ∧ Exp.vw Γ K KH K e ≤ K) (hd : ∀ d ∈ ds, K ≤ Γ d) :
PK K KH κ Γ W ((filterP k).call args ds) s L
theorem OrderMaintenance.Impl.finishDrain_pk {K KH W : ℕ} {κ : Caps} {s : Model.Core} {L : Loc} (hC : CapsW K κ) (hK : 8 ≤ K) (hW : 2 * K + 4 ≤ W) (hG : Gd K KH κ (ΓK K) s L) :
PK K KH κ (ΓK K) W finishDrainS s L

The end of a drain (finishDrain).