Skip to content

Simplify bit primitive and barrier scenario benches - #288

Merged
zhoubot merged 1 commit into
mainfrom
codex/pipeline-scenarios
Oct 10, 2026
Merged

zhoubot merged 1 commit into
mainfrom
codex/pipeline-scenarios

Conversation

@zhoubot

@zhoubot zhoubot commented Oct 10, 2026 •

Copy link
Copy Markdown
Contributor

Replace expanded stimulus/control expressions in the bit-primitive and barrier system benches with immutable typed tables using the existing language. Bit primitive shrinks from 6,003 to 472 lines; barrier from 5,318 to 435 lines. No compiler, Runtime, public API, DUT, oracle, cycle or timeout changes.

The two counter contracts remain distinct. Bit primitive preserves the existing helper signature, advance/system bodies, 344-cycle history and hold-above-343 behavior. Its table has 344 active rows plus an all-zero fallback for known helper inputs 344–65535. Barrier keeps 347 rows, full-u64 clamp and wrap, explicit nominal tokens, and its four-one tail from phase 345. Assertions and registration order remain unchanged in both examples. Refresh the guides, verified module receipts and navigation.

Validation:

  • Independent bit-primitive proof covers 6,880 active values and all 1,310,720 field values over the complete known-u16 function domain; 10 mutations rejected. Barrier proof covers 4,164 values and 340 full-u64 intervals; 12 mutations rejected.
  • All six standalone tests pass: module, full system and four-state for each example. Bit primitive retains 42,153 known / 813 XZ Work rows and 7,568 system observations; barrier retains 699 known / 619 XZ rows and 4,164 system observations. Native workers 1/2, Verilator, genuine Icarus and original reset/discard/token-ledger probes remain required.
  • Twenty complete traces per example agree across original/candidate native/RTL executions. Cross-source comparison excludes only changed AST site/registration metadata; events, values, epochs, instances and ordering remain checked.
  • Source-import/transformed artifacts reproduce all published source units. Measured/public outputs share identical final IR and every generated file. Catalog tests 19/19, changed-file pre-commit and strict docs pass.

Same-machine LLVM 22 / -O0 measurements show bit-primitive bench compilation 5.58→3.25s, with native warm median 3.200→3.185s approximately unchanged; one candidate runtime outlier of 4.462 s is disclosed. Barrier compilation 5.37→2.21s and native warm median 2.362→1.853s improve, while RTL runtime is approximately unchanged. Runtime medians use three alternating paired warm runs; build/emission phases have one observation each. Both final IR and generated-output sizes decrease. Each README records the full table and limits.

Full catalog/nightly/platform matrices, arbitrary injected X/Z phase equivalence and actual u64 rollover execution are not claimed. Remaining migration and scaling work stays in #272/#265. Intermediate experiments, proof tools, reviews and candidate-bound raw evidence remain ignored under docs/gates/logs/pipeline-benches-20261010/; tests do not depend on those files.

@zhoubot
zhoubot requested a review from xiekunpeng as a code owner October 10, 2026 09:26
@zhoubot

zhoubot commented Oct 10, 2026

Copy link
Copy Markdown
Contributor Author

Final candidate 292e54434afaa6f72dae49ad6d55fd3d46135962: independent code review APPROVE, architecture CLEAR, both required GitHub checks passed. Authoring, independent preservation and review used separate instances.

Both full-domain source proofs, 22 rejected mutations, all six focused module/system/four-state gates, eight source-stage records and twenty matching traces per example are verified. The independent reviewer additionally checked 272 gate input hashes and execution receipts. Current generated module receipts, catalog links and README costs are bound to this candidate.

No API/compiler/Runtime/DUT/cycle/timeout changes. Bit native runtime is approximately unchanged with its outlier disclosed; barrier native warm median improves about 22%. Full nightly/platform validation, arbitrary injected X/Z phase equivalence and actual u64 rollover execution remain unclaimed. Raw evidence and independent reviews remain local ignored artifacts.

@zhoubot
zhoubot merged commit 306a52d into main Oct 10, 2026
2 checks passed
@zhoubot
zhoubot deleted the codex/pipeline-scenarios branch October 10, 2026 09:55
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