Skip to content

Budget placement pressure and localize the linearize witness#45

Merged
fpedd merged 1 commit into
mainfrom
perf/budget-placement-pressure-local-witness
Jul 18, 2026
Merged

Budget placement pressure and localize the linearize witness#45
fpedd merged 1 commit into
mainfrom
perf/budget-placement-pressure-local-witness

Conversation

@fpedd

@fpedd fpedd commented Jul 18, 2026

Copy link
Copy Markdown
Owner

placement_pressure_per_allocation ran its internal linearize attempt
unbounded, so large non-interval-order vector-clock instances paid a
futile O(kmd) dominance pass before the fast output-sensitive
fallback sweep. Plumb work_budget through: Python defaults to
DEFAULT_WORK_BUDGET, and the budget bounds the linearize attempt
(silent fallback, as in omni_place) as well as the fallback conflict
sweep (RuntimeError past it, matching conflicts/conflict_degrees).

The 256-sample random incomparability witness in the linearizer missed
temporally local concurrency (global samples, local 2+2s), so genuinely
concurrent instances fell through to the full O(kmd) chain test. Add
a deterministic O(k*(log m + d)) local pass probing every
lexicographically adjacent start-row pair against the end-row windows
just below the component-0 boundary; every hit is a sound 2+2 and a
miss still reaches the exact chain test, so results are unchanged. The
budget check now runs before the witness so refused instances skip the
scan.

Measured: omni_place(linearize_budget=None) on 1M loosely coupled
vector allocations drops 162 s -> 1.3 s, and placement pressure on a
400k near-chain instance with one hidden 2+2 now answers in 0.2 s.
Differentially verified against brute-force references (conflict
relation, pinned antichains, placement peaks, interval-order decisions)
on over a thousand randomized instances with zero mismatches.

placement_pressure_per_allocation ran its internal linearize attempt
unbounded, so large non-interval-order vector-clock instances paid a
futile O(k*m*d) dominance pass before the fast output-sensitive
fallback sweep. Plumb work_budget through: Python defaults to
DEFAULT_WORK_BUDGET, and the budget bounds the linearize attempt
(silent fallback, as in omni_place) as well as the fallback conflict
sweep (RuntimeError past it, matching conflicts/conflict_degrees).

The 256-sample random incomparability witness in the linearizer missed
temporally local concurrency (global samples, local 2+2s), so genuinely
concurrent instances fell through to the full O(k*m*d) chain test. Add
a deterministic O(k*(log m + d)) local pass probing every
lexicographically adjacent start-row pair against the end-row windows
just below the component-0 boundary; every hit is a sound 2+2 and a
miss still reaches the exact chain test, so results are unchanged. The
budget check now runs before the witness so refused instances skip the
scan.

Measured: omni_place(linearize_budget=None) on 1M loosely coupled
vector allocations drops 162 s -> 1.3 s, and placement pressure on a
400k near-chain instance with one hidden 2+2 now answers in 0.2 s.
Differentially verified against brute-force references (conflict
relation, pinned antichains, placement peaks, interval-order decisions)
on over a thousand randomized instances with zero mismatches.
@fpedd
fpedd merged commit f41fa78 into main Jul 18, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant