Immediate snapshot schedules, the Borowsky–Gafni characterization, and IIS views #
As a step toward #7504 (leaving the asynchronous read/write and atomic-snapshot to IIS
simulation open in #7504), this module formalizes one-shot Immediate Snapshot (IS) schedules and
R-round Iterated Immediate Snapshot (IIS) full-information executions over an active process set
U : Finset V, following [BG97] (§§3.4–3.6, PS pp. 5–6; see also [BG93b]
and [HS99], §5.2).
- One-shot
ISschedules (ISSchedule U): ordered partitions(B₁, …, Bₖ)of a finite participating process setU : Finset Vinto nonempty pairwise-disjoint blocks. All processes in blockBⱼconcurrently write their values and immediately scan the shared memory, observing the prefix unionB₁ ∪ ⋯ ∪ Bⱼ(ISSchedule.snapshot). We equipISSchedule Uwith a computableFintypeinstance enumerating all ordered partitions ofU. - Borowsky–Gafni immediate-snapshot characterization (
IsImmediateSnapshotOn,IsImmediateSnapshot): a set assignmentS : V → Finset Varises asπ.snapshotfor a (unique) ordered partitionπ : ISSchedule Uif and only if it satisfies self-inclusion (p ∈ S p), containment (S p ⊆ S q ∨ S q ⊆ S p), and immediacy (p ∈ S q → S p ⊆ S q) onU([BG97], §3.5, conditions 1–3, p. 5), packaged as explicit equivalencesISSchedule.equivImmediateSnapshotOnandISSchedule.equivImmediateSnapshot. R-roundIISfull-information views (IISView,iisRun): inductively, round-0views areInitView V Input(⟨p, inp p⟩) and round-(r + 1)views areStepView Vpairing process identitypwith theFinsetimage of round-rviews across(E (Fin.last r)).snapshot p([BG97], §3.5, p. 5). We track the participating process carrier (IISView.carrier) and observed input set (IISView.carrierInputs), prove view locality (iisRun_congr_carrier:p's view depends only oninprestricted to(iisRun inp E p).carrier), solo-execution singleton carriers (carrier_iisRun_eq_singleton_of_solo), and derive carrier-input validity from plain global input validity (IISProtocol.isCarrierValid_of_isValid, following the input-simplex extension step of [HS99], Proof of Theorem 3.3, p. 881).
Main definitions #
Cslib.Distributed.SetAgreement.unionBlocks,Cslib.Distributed.SetAgreement.blocksSnapshot: block-list union and prefix-union snapshot evaluation.Cslib.Distributed.SetAgreement.ISSchedule,Cslib.Distributed.SetAgreement.ISSchedule.snapshot: one-shot immediate-snapshot schedule (ordered partition ofU : Finset V) and its induced per-process snapshot map.Cslib.Distributed.SetAgreement.IsImmediateSnapshotOn,Cslib.Distributed.SetAgreement.IsImmediateSnapshot: Borowsky–Gafni immediate-snapshot axioms (self-inclusion, containment, immediacy) on a participating setUand onFinset.univ.Cslib.Distributed.SetAgreement.InitView,Cslib.Distributed.SetAgreement.StepView,Cslib.Distributed.SetAgreement.IISView: round-0, step, andR-roundIISviews.Cslib.Distributed.SetAgreement.IISView.proc,Cslib.Distributed.SetAgreement.IISView.carrier,Cslib.Distributed.SetAgreement.IISView.carrierInputs: owner process, participating process carrier, and observed input set of anIISview.Cslib.Distributed.SetAgreement.iisRun:R-round full-informationIISview execution.Cslib.Distributed.SetAgreement.IISProtocol,Cslib.Distributed.SetAgreement.IISProtocol.IsValid,Cslib.Distributed.SetAgreement.IISProtocol.IsCarrierValid:R-roundIISdecision protocols and global vs carrier-restricted input validity.
Main results #
Cslib.Distributed.SetAgreement.ISSchedule.isImmediateSnapshotOn,Cslib.Distributed.SetAgreement.ISSchedule.isImmediateSnapshot: everyISschedule satisfies self-inclusion, containment, and immediacy.Cslib.Distributed.SetAgreement.ISSchedule.equivImmediateSnapshotOn,Cslib.Distributed.SetAgreement.ISSchedule.equivImmediateSnapshot,Cslib.Distributed.SetAgreement.isImmediateSnapshot_iff_existsUnique_schedule: exact bijection and unique-existence characterization between ordered partitions and set assignments satisfying the Borowsky–Gafni axioms.Cslib.Distributed.SetAgreement.self_mem_carrier_iisRun,Cslib.Distributed.SetAgreement.carrier_iisRun_subset,Cslib.Distributed.SetAgreement.carrierInputs_iisRun: carrier bounds and input-image identity forR-roundIISviews.Cslib.Distributed.SetAgreement.iisRun_congr_carrier:p'sR-roundIISview depends only on inputs of processes in(iisRun inp E p).carrier.Cslib.Distributed.SetAgreement.carrier_iisRun_eq_singleton_of_solo: a process running first alone in every round observes carrier{p}and input set{inp p}.Cslib.Distributed.SetAgreement.IISProtocol.isCarrierValid_of_isValid: every globally input-validIISprotocol automatically satisfies carrier-input validity.
References #
Union of a list of process blocks B₁, …, Bₖ.
Prefix-union snapshot returned to process p by executing ordered concurrent blocks bs:
if p appears in block Bⱼ, p observes B₁ ∪ ⋯ ∪ Bⱼ; if p ∉ unionBlocks bs, ∅.
A one-shot Immediate Snapshot (IS) schedule over active processes U : Finset V: an ordered
partition (B₁, …, Bₖ) of U into nonempty pairwise-disjoint concurrent write-scan blocks
([BG97], §§3.4–3.5, p. 5).
Ordered list of concurrent write-then-snapshot blocks.
Every block in the schedule is nonempty.
Distinct blocks in the schedule are pairwise disjoint.
The union of all blocks equals the active process set
U.
Instances For
Auxiliary enumeration of ordered partitions of rem of length at most k.
Computable Finset of all one-shot IS schedules on U.
The unique one-shot IS schedule on the empty process set ∅.
Snapshot set observed by process p in one-shot IS schedule π : ISSchedule U.
Borowsky–Gafni immediate-snapshot characterization #
Borowsky–Gafni immediate-snapshot axioms for a set assignment S : V → Finset V over active
processes U : Finset V ([BG97], §3.5, conditions 1–3, p. 5): inactive processes
observe ∅, active snapshots lie in U, and active processes satisfy self-inclusion, containment,
and immediacy.
Non-participating processes have empty snapshot.
- subset (p : V) : p ∈ U → S p ⊆ U
Every active process's snapshot is a subset of
U. Self-inclusion: every active process observes itself (
p ∈ S p).Containment: any two active processes' snapshots are comparable under
⊆.Immediacy: if
qobservesp, thenqobserves everythingpobserved.
Global Borowsky–Gafni immediate-snapshot axioms on all processes V
([BG97], §3.5, conditions 1–3, p. 5).
Every one-shot IS schedule on U satisfies IsImmediateSnapshotOn U.
Every full-system one-shot IS schedule satisfies IsImmediateSnapshot.
Reconstruct the one-shot IS schedule on U corresponding to a set assignment S satisfying
IsImmediateSnapshotOn U S.
Two one-shot IS schedules on U with identical snapshot maps are equal.
One-shot immediate-snapshot characterization step for #7504 (after
Borowsky and Gafni, §3.5, conditions 1–3, p. 5): ordered partitions of U
into nonempty disjoint blocks correspond bijectively to set assignments satisfying
IsImmediateSnapshotOn U.
One-shot immediate-snapshot characterization step for #7504 (after Borowsky and Gafni, §3.5, conditions 1–3, p. 5): full-system ordered partitions correspond bijectively to set assignments satisfying self-inclusion, containment, and immediacy.
One-shot immediate-snapshot unique-schedule characterization step for #7504 (after
Borowsky and Gafni, §3.5, conditions 1–3, p. 5): a map S : V → Finset V
satisfies self-inclusion, containment, and immediacy if and only if there exists a unique one-shot
IS schedule π on V with π.snapshot = S.
R-round Iterated Immediate Snapshot (IIS) full-information views #
Explicit decidable equality on IISView V Input R.
Participating process carrier of an R-round IIS view: all processes whose initial inputs
causally contributed to the view.
Set of initial input values causally observed in an R-round IIS view.
Execute R rounds of the full-information Iterated Immediate Snapshot (IIS) protocol on
active process set U : Finset V from input assignment inp : V → Input along schedule sequence
E : Fin R → ISSchedule U ([BG97], §3.5, p. 5).
View locality of R-round IIS runs: process p's view depends only on the initial inputs of
processes in (iisRun inp₁ E p).carrier.
Solo-execution carrier property: if process p runs first alone ({p} :: tail) in every round
of E, then (iisRun inp E p).carrier = {p}.
Extend an IS schedule on U to all of Finset.univ by scheduling all remaining processes
univ \ U concurrently in a single trailing block (when (univ \ U).Nonempty).
IIS decision protocols and carrier-input validity #
An R-round deterministic decision protocol in the Iterated Immediate Snapshot (IIS) model:
each process p : V maps its R-round IIS view to an output decision in Val.
- decide : V → IISView V Val R → Val
Per-process decision rule applied after
Rrounds ofIIS.
Global input validity of an R-round IIS protocol: in every full-system execution, every
decided value is the initial input of some process in V.
Carrier-input validity of an R-round IIS protocol: in every full-system execution, every
process p decides an input belonging to a process in (iisRun inp E p).carrier (equivalently, in
(iisRun inp E p).carrierInputs).
Iterated immediate snapshot (IIS) carrier-validity step for #7504 (after the input-simplex
extension argument of Herlihy and Shavit, Proof of Theorem 3.3, p. 881):
because iisRun inp E p depends only on inp restricted to C = (iisRun inp E p).carrier,
replacing all inputs outside C with inp p leaves p's R-round view unchanged while
restricting all global inputs to C.image inp.