Skip to content

refactor(mlir): isolate corpus golden updates per program to reduce PR conflicts - #1575

Merged
godofecht merged 10 commits into
mainfrom
refactor/mlir-corpus-per-case-goldens-20261015
Nov 3, 2026
Merged

godofecht merged 10 commits into
mainfrom
refactor/mlir-corpus-per-case-goldens-20261015

Conversation

@godofecht

@godofecht godofecht commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

Why

The last 500 commits repeatedly touched compiler/fixtures/mlir/corpus.txt (26/50 ten-commit windows). Ten of the fifteen existing open PRs rewrite it, alongside compiler/src/mlirgen.flow and checked-in bootstrap outputs. This PR removes one mechanical collision source without changing Stage-A bootstrap safety.

Implementation

  • Keep the historical compiler/fixtures/mlir/corpus.txt as the baseline.
  • Support deterministic path-owned overrides at compiler/fixtures/mlir/corpus.d/<source-path>.sha256.
  • Add ./flow tool compiler/scripts/parity_mlir.flow --record-case <tracked-program.flow> to regenerate one normalized digest or add a new corpus program, instead of rewriting a globally shared corpus manifest.
  • Continue validating the entire corpus, using the scoped override if present; malformed overrides fail the parity gate.
  • Include a real existing corpus override for benchmarks/aosoa.flow to exercise the read path, plus migration guidance in the MLIR design documentation.

Migration progress

Per-program goldens have been staged without removing the original corpus entries on all ten open MLIR PR branches that modify corpus.txt: #1558, #1559, #1560, #1561, #1562, #1563, #1564, #1565, #1568 and #1569. This preserves each PR's existing checksums while the new verifier is being tested.

After this PR lands, each branch can be rebased, its committed corpus.txt replaced with the current mainline manifest, and parity validated using the scoped files. Only then can the central-manifest diff disappear. Do not overwrite compiler backend or bootstrap changes during that migration. Incompatible mlirgen.flow edits require a separate, ordered integration strategy, and the Stage-A fixed-point verification remains mandatory.

Validation

Verified at head 795b6aef9a9274d658c147d0f675753c4b6c0e88 (2026-11-02): full CI run 41545738372 completed green, including flowc self-host roundtrip, native tools, language tests, compiler corpus parity and flowc goldens and MLIR. Tier-1 run 41545738156 passed on both Ubuntu and macOS. No test gate was disabled. PR is ready for review with auto-merge enabled; GitHub's protected merge queue controls integration.

CI dependency

The earlier Native tools (no Python) failure came from the stale generated demo overview on previous main, not this MLIR parity change. #1578 has now merged and this branch was reconciled with updated main before the passing runs cited above. The hardened scoped-golden parser validates SHA-256 hex and requires all new entries to be eligible tracked programs.

Preserve the scoped SHA-256 recorder, its sample digest, and documentation;
carry forward current main unchanged outside the three feature files.

Copy link
Copy Markdown
Contributor Author

CI repair / conflict resolution (2026-11-02): merged current main (e11cd74f) into this PR at 7c654d21. Reconstructed the merge tree from current main plus exactly the three PR-owned files: compiler/scripts/parity_mlir.flow, docs/design/mlir-in-flow.md, and compiler/fixtures/mlir/corpus.d/benchmarks/aosoa.flow.sha256. Verified both modified text files apply cleanly and byte-for-byte to the PR head, with no overlapping main changes; verified the new scoped digest does not exist on main. Post-merge compare reports ahead 9, behind 0, exactly those three changed files. GitHub REST now reports mergeable=true, mergeable_state=blocked (draft/qualification), rather than a merge conflict. This is not a CI green claim: leave draft, wait for fresh full CI and Linux/macOS checks before review or merge. No test/golden gate was changed or bypassed.

Preserve per-case recorder and documentation while incorporating the
latest Sofia lattice-Boltzmann, generated docs and LSP transcript updates.
No test or CI gate changes.
@godofecht
godofecht marked this pull request as ready for review November 3, 2026 01:25
@godofecht
godofecht added this pull request to the merge queue Nov 3, 2026
Merged via the queue into main with commit 6f8544c Nov 3, 2026
30 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