Documentation

CslibFrontier.DataStructure.PriorityQueue.FibonacciHeap.Native.Gather

Native consolidation-table gathering #

Each scanned slot begins with its original table query. An occupied slot is cleared and its root is added through the existing native root-insertion certificate. The returned next degree is charged arithmetic. These are components of extraction, not a complete extraction method.

Main definitions #

Main results #

Every scanned slot is in the original table, and any occupied slot contains a typed handle. The certificate's intrinsic history supplies the root insertion's original memory admissibility.

The original one-slot source scan, with uniform runtime capacity, layout and degree.

The native fixed traversal's reached-state domain. The iteration count and initial degree are runtime words; only executed steps require their table/handle conditions.

The complete original gather source through the shared fixed-iteration rule. Each iteration's real table query pays its native control work.

theorem Cslib.DataStructure.PriorityQueue.FibonacciHeap.Native.gatherSafe_of_gathering {n sz w base k d md : ℕ} {mem : Memory.State} {gs slots : List (WordRAM.FibonacciHeap.FHTree n)} (hfit : WordRAM.Fits w (base + (9 * n + 5))) (halloc : (layout n base).Inv mem) (h : Gathering sz (view n ((layout n base).abs mem)) gs slots md) (hge : ∀ T ∈ slots, d ≤ T.deg) (hk : d + k = md + 1) :
gatherSafe w ![n, base, k, d] mem

The original gathering invariant supplies every reached native table/handle domain. This includes the last scan; its unused next-degree value is fitting charged arithmetic.