Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them. Page: /drakestapleton/benchmarks-mv/patches/9978f8bd420e111e # benchmarks-mv Measurement harnesses and evidence bundles for AIEN on the NVIDIA DGX Spark GB10. Speed is reported against the machine's physical limit and my own previous run. Attachment of AienOS. Brought by drakestapleton Sign in to star 0 stars 0 watching About Files History Releases Proposed changes Issues For developers ## GitHub aien-dev/benchmarks-mv#14 (code only) closed derived `9978f8bd420e111e` #14 Imported from GitHub aien-dev/benchmarks-mv#14 (code only) GitHub's metadata for this pull request is unavailable: its state is DERIVED from the commits (merged: the head is reachable from this project's main; open: GitHub kept a merge ref; else closed). Base `4ff1cb48773899f4830428ab7d3b0b2882d63d07` · Head `80234c15be23482bfd32a63118bbfc43cf2690f0` ### Apply it ``` git checkout -b patch-9978f8bd420e111e 4ff1cb48773899f4830428ab7d3b0b2882d63d07 curl -fsSL https://interplane.io/drakestapleton/benchmarks-mv/patches/9978f8bd420e111e.patch | git am ``` Raw patch (mbox) · Diff ### Provenance This proposal is imported from GitHub; it is not signed by its author. Its import statement and source record: ``` github-import 1 aien-dev/benchmarks-mv 14 80234c15be23482bfd32a63118bbfc43cf2690f0 ``` ``` {"kind":"github-import","owner":"aien-dev","repo":"benchmarks-mv","number":14,"url":"https://github.com/aien-dev/benchmarks-mv/pull/14","export_sha256":"967c79e26a893657b5cdaa45efd442be5dbd2ecfe68e25f9a8c1b5da4d60d452","imported_utc":"2026-11-18T16:40:20Z","metadata":"unavailable","state_derived":true} ``` ### Changes ``` diff --git a/README.md b/README.md index aef07f7..2864e53 100644 --- a/README.md +++ b/README.md @@ -221,3 +221,7 @@ Copyright (c) 2026 Drake Stapleton and AIEN Contributors. See [NOTICE](NOTICE) f - **Benchmark Code & Harness**: Standard [GNU AGPL-3.0-or-later](LICENSE) for universal execution, replication, and integration. - **Benchmark Data & Metrics**: Raw telemetry JSON, hardware timing records, and SVG comparison charts are dedicated to the public domain under [CC0-1.0](https://creativecommons.org/publicdomain/zero/1.0/). - **Upstream Development Charter**: [CONSTITUTION.md](CONSTITUTION.md) defines the internal architectural doctrine and stewardship standards for upstream development and does not bind downstream users. + +## Prime Drag Race + +The frozen contract and suite runner for the AIEN Prime Drag Race live in [prime-drag-race/](prime-drag-race/CONTRACT.md). The runner is a standalone Rust crate (`cargo build` inside that directory). diff --git a/prime-drag-race/CONTRACT.md b/prime-drag-race/CONTRACT.md new file mode 100644 index 0000000..82c0287 --- /dev/null +++ b/prime-drag-race/CONTRACT.md @@ -0,0 +1,121 @@ +# AIEN Prime Drag Race: benchmark contract (version 1) + +This contract is frozen. Any change to a rule below is a new contract version. +The runner in this directory enforces it. Contract version string: `1`. + +## What is measured + +Sieve all primes up to a limit (default 1,000,000), over and over, for at least a minimum time +(default 5 seconds), and count how many complete passes finish. The score is passes per second. +Higher is faster. + +## The canonical result + +For limit L, only odd numbers are stored. Bit k (word k/64, bit k%64, little-endian 64-bit words, +which is the same bytes as little-endian 32-bit words) is set exactly when 2k+1 is prime, for +0 <= k < (L+1)/2. All bits past that range are zero. The prime 2 is implicit when L >= 2. The count +of primes is the number of set bits plus 1 when L >= 2. For L = 1,000,000 the count is 78,498. + +The runner builds this result itself with an independent reference: deterministic Miller-Rabin on +every odd number up to L (bases 2, 3, 5, 7 below 3,215,031,751, otherwise the first 12 primes, with +128-bit multiplication). The reference is checked against trial division and the known prime counts +(10:4, 100:25, 1,000:168, 10,000:1,229, 100,000:9,592, 1,000,000:78,498, 10,000,000:664,579). + +## What one pass includes + +Everything needed to go from nothing to a complete result that the host can read: reset or allocate +the sieve state, compute the base primes up to sqrt(L) (for GPUs, on the host, written into a +device-visible buffer), launch the work, wait for confirmed completion, and have the result sitting +in host-readable memory. Excluded: process start, one-time setup (opening a GPU session, uploading +kernel code, allocating persistent buffers), and the final export and checking of the answer. +A CPU pass allocates a fresh zeroed sieve each time (faithful). A GPU pass that keeps persistent +buffers is marked not faithful. + +## Implementation interface + +` [--limit N] [--min-seconds S] [--bitmap-out PATH] [--report-out PATH] [--audit-passes K]` + +- Timed mode: loop passes against a monotonic clock until S seconds have passed. Elapsed is the + actual time spent. After the loop, outside the timing, export the last pass's canonical bitmap and + write the report. Print exactly one line on stdout, and only on success: + `