Shared Deletion, Relocation, and Pre-Tick Stage Helpers for SuccinctWhpModelStep #
This internal helper module (imported privately by DeleteLast and DeleteReloc, so none of its
declarations enter the public export closure of SuccinctWhpModelStep) factors the shared
combinators for fastDelete:
SliceMapRelandBufMapRellast-slot deletion and swap-with-last relocation;- backyard pool release (
pool_release_last) and dictionary/quotient preservation (dict_map_after_delete); - epoch-buffer deletion/relocation (
buf_valid_after_delete),bufOld_validpreservation (bufOld_valid_after_delete), and Stages0, 1, 3ofValidEpochStagePreTick(preTick_after_delete_of_stage2).
Relocating loc_last into loc_del < loc_last across a full slice 0 .. loc_last
(loc_last + 1 → loc_last).
Relocating loc_last into loc_del < cur ≤ loc_last across a prefix 0 .. cur - 1, assuming
no collision between f loc_last and any remaining active item < cur \ {loc_del}.
Deleting loc_last when bktCnt b₀ = loc_last + 1 shrinks to loc_last.
Relocating (b₀, loc_last) into (b₀, loc_del) (loc_del < loc_last) in BufMapRel.
Releasing loc_last (fs.bktCount b = loc_last + 1) preserves all backyard-pool invariants.
Abstract dictionary-map and quotient-injectivity preservation under deleting (b, loc_del) and
relocating (b, loc_last) (when loc_del < loc_last).
Parametric epoch-buffer preservation across fastDelete (applicable to both curEp and
oldEp when rebStage ≤ 3).
Unified preservation of CoreFastInv.bufOld_valid across both loc_del = loc_last and
loc_del < loc_last deletion cases.
Discharges Stages 0, 1, 3 (and ≥ 4) of ValidEpochStagePreTick uniformly across both
fastDelete branches, leaving only Stage 2 for the caller.