Skip to content

test: guard inspection commands on shared-dependency graphs - #874

Merged
kvlonge merged 2 commits into
mainfrom
test/chi-431-inspection-perf-guards
Sep 28, 2026
Merged

kvlonge merged 2 commits into
mainfrom
test/chi-431-inspection-perf-guards

Conversation

@kvlonge

@kvlonge kvlonge commented Sep 28, 2026

Copy link
Copy Markdown
Contributor

Why

A sqb lineage rendering bug (CHI-430) was exponential on shared dependencies and ran past 20 GB on a real project, while every CI performance guard stayed green: the guards only measured sqb compile, and the generated benchmark had no diamond-shaped dependencies.

Changes

  • Structural diamond-project tests for sqb lineage (relation and column, all directions), sqb dag and the sqb plan tree: each node expanded at most once, output bounded linearly.
  • Opt-in diamond lattice in the benchmark generator (off for the existing compile guards; fingerprints unchanged).
  • New inspection-command guard in the existing 3000-model cold-compile performance job: lineage from a high-fan-out and a high-fan-in model (text and json), dag --json and scope --json, each with wall-time, peak-RSS and output-line ceilings (~42 s added).
  • Performance jobs also trigger on lineage, plan, scope, dag and CLI output changes.

Verification

  • Reverting CHI-430 fails both the structural test and the guard (786,427 lines / 703 MB vs 3,130 lines / 128 MiB).
  • make test-e2e-cold-compile-performance SQLBUILD_BENCHMARK_MODELS=3000 passes under a 4 GiB limit; make test, make check-ci and the hygiene scan pass; one independent review.

Add deterministic layered-diamond E2E coverage for lineage (relation and
column, both directions), dag and plan output, asserting each node is
expanded once and output stays linear in project size.

Add fresh-process wall-time, peak-RSS and output-size guards for lineage,
dag, scope and plan on the 3,000-model semantic benchmark extended with an
opt-in shared-dependency lattice, run in the existing 3,000-model
fresh-process compile job. The compile guard fixtures are unchanged.

Refs: CHI-431
Their current cost would set the budget and add minutes to the 3,000-model job. The follow-up fixes add their own guards with tight ceilings. Refs: CHI-431
@kvlonge
kvlonge enabled auto-merge (squash) September 28, 2026 21:16
@kvlonge
kvlonge merged commit 6da7c51 into main Sep 28, 2026
29 checks passed
@kvlonge
kvlonge deleted the test/chi-431-inspection-perf-guards branch September 28, 2026 21:35
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