Repository navigation
Exercise Proven’s repaired header boundary through actual RefC #27
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,35 @@ | ||
| // SPDX-License-Identifier: CC-BY-SA-4.0 | ||
| // Copyright (c) 2026 Jonathan D.A. Jewell <j.d.a.jewell@open.ac.uk> | ||
| = Proven header consumer diagnostic | ||
|
|
||
| Run `bash tests/consumer-boundary/proven-header-probe.sh /path/to/proven` with | ||
| Idris2 `b6cbc25d5cd2ef2a250556266fd7b68dfc360f8b` and Zig 0.15.2 on native | ||
| Linux x86_64 GNU. `IDRIS2`, `ZIG` and `EVIDENCE_DIR` may select explicit paths. | ||
|
|
||
| The diagnostic compiles the existing Idris String predicate independently, | ||
| builds Proven's actual RefC byte kernel and SDK bundle, then links the exported | ||
| C ABI into a Zig caller. The standalone unavailable-backend wrapper is not a | ||
| successful substitute. Missing build scripts, SDKs, symbols or nonzero statuses | ||
| are failures. | ||
|
|
||
| The five expected rows (Idris and Zig columns) are: | ||
|
|
||
| [source,text] | ||
| ---- | ||
| cr true true | ||
| lf true true | ||
| crlf true true | ||
| clean false false | ||
| embedded-cr true true | ||
| ---- | ||
|
|
||
| The earlier adjacent-pair implementation disagreed on three rows. The repaired | ||
| bridge agrees on all five. Logs bind source hashes, compiler versions and the | ||
| actual generated SDK. Proven's separate `scripts/test-header-bridge.sh` covers | ||
| all single bytes and byte pairs, NUL, non-UTF-8 and length boundaries, including | ||
| a broken-backend rejecting control. | ||
|
|
||
| This script is a differential executable diagnostic. It does not issue an | ||
| Atoma source-proof receipt. The current source frontend cannot represent the | ||
| loop, pointer span, foreign-call state transition or all compilation steps. | ||
| The corresponding source/refinement result therefore remains INCOMPLETE. |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -21,7 +21,8 @@ cp -R "$proven/src/Proven" "$work/src/Proven" | |
| git -C "$proven" rev-parse HEAD | ||
| "$idris" --version | ||
| "$zig" version | ||
| sha256sum "$proven/src/Proven/SafeHeader/Types.idr" "$proven/src/Proven/Core.idr" "$proven/ffi/zig/src/main.zig" | ||
| git -C "$proven" diff --stat | ||
| sha256sum "$proven/src/Proven/SafeHeader/Types.idr" "$proven/src/Proven/Core.idr" "$proven/src/Proven/SafeHeader/ByteKernel.idr" "$proven/ffi/zig/src/core.zig" "$proven/ffi/zig/src/header_refc.zig" "$proven/ffi/zig/src/main_refc.zig" | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
When a reader follows the design document’s reproduction instructions against its pinned Proven revision Useful? React with 👍 / 👎. |
||
| } > "$evidence/inputs.log" | ||
| cat > "$work/src/AtomaHeaderProbe.idr" <<'IDRIS' | ||
| module AtomaHeaderProbe | ||
|
|
@@ -47,8 +48,10 @@ pub fn main() !void { | |
| } | ||
| } | ||
| ZIG | ||
| "$zig" build-obj "$proven/ffi/zig/src/main.zig" -lc -femit-bin="$work/proven.o" > "$evidence/zig-build.log" 2>&1 | ||
| "$zig" build-exe "$work/probe.zig" "$work/proven.o" -lc -femit-bin="$work/probe" >> "$evidence/zig-build.log" 2>&1 | ||
| IDRIS2="$idris" bash "$proven/scripts/build-header-refc.sh" "$work/bundle" > "$evidence/header-build.log" 2>&1 | ||
| cp "$work/bundle/identity.log" "$evidence/header-identity.log" | ||
| (cd "$proven/ffi/zig"; "$zig" build --build-file build_standalone.zig -Dheader-refc="$work/bundle" --prefix "$work/install") > "$evidence/zig-build.log" 2>&1 | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
When Useful? React with 👍 / 👎. |
||
| "$zig" build-exe "$work/probe.zig" "$work/install/lib/libproven_ffi.a" "$work/bundle/libidris2_refc.a" "$work/bundle/libidris2_support.a" -lc -lgmp -lm -lpthread -femit-bin="$work/probe" >> "$evidence/zig-build.log" 2>&1 | ||
| "$work/probe" > "$evidence/zig-results.txt" 2>&1 | ||
| for result in idris-results.txt zig-results.txt; do | ||
| if [[ $(wc -l < "$evidence/$result") -ne 5 ]] || grep -Evq '^(true|false)$' "$evidence/$result"; then | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In the context of the preceding adapter claims, this link promises reproduction of the 256-tag/four-state RefC matrix, but its target documents only
proven-header-probe.sh, and the consumer-boundary directory contains no adapter runner or adapter revision. Readers therefore cannot reproduce or identify the evidence supporting those new claims; link the adapter’s actual pinned test instructions, or scope this sentence explicitly to the Proven diagnostic.Useful? React with 👍 / 👎.