From 3a0ca608bb6b47d0153331a1a2db94b1afe484d2 Mon Sep 17 00:00:00 2001 From: Drake Stapleton Date: Thu, 1 Oct 2026 06:32:54 -0500 Subject: [PATCH 1/8] OSC-3 item 1: split test-compiler into quick and full; OSC-3 receipt script (Lane 30) test-compiler-full = the old test-compiler (alias kept), full counts, used by receipts and by CI when src/compiler or src/aarch64_* changes. test-compiler-quick (< 60 s single core target) runs every golden/negative program and determinism at smoke counts on every compiler-path change. OSC-3 slice; not a general Omega compiler; no self-hosting. Co-Authored-By: Drake Stapleton Co-Authored-By: Claude Fable 5.1 --- .github/workflows/host-suites.yml | 21 +++-- docs/osc/OSC-3-DESIGN.md | 40 ++++++++ mk/compiler.mk | 46 ++++++++- tests/compiler/osc3_receipt.sh | 149 ++++++++++++++++++++++++++++++ 4 files changed, 249 insertions(+), 7 deletions(-) create mode 100644 docs/osc/OSC-3-DESIGN.md create mode 100755 tests/compiler/osc3_receipt.sh diff --git a/.github/workflows/host-suites.yml b/.github/workflows/host-suites.yml index c29c346da..9efbe3f70 100644 --- a/.github/workflows/host-suites.yml +++ b/.github/workflows/host-suites.yml @@ -137,13 +137,22 @@ jobs: - name: Changed-path guard (compiler files only) id: guard run: | - if [ "${{ github.event_name }}" != "pull_request" ]; then echo "run=true" >> "$GITHUB_OUTPUT"; exit 0; fi - if git diff --name-only HEAD^1 HEAD \ - | grep -Eq '^(src/compiler/|tests/compiler/|mk/compiler\.mk$|src/sha256\.|src/aarch64_|\.github/workflows/host-suites\.yml$)'; then + if [ "${{ github.event_name }}" != "pull_request" ]; then echo "run=true" >> "$GITHUB_OUTPUT"; echo "full=true" >> "$GITHUB_OUTPUT"; exit 0; fi + CHANGED=$(git diff --name-only HEAD^1 HEAD) + if echo "$CHANGED" | grep -Eq '^(src/compiler/|tests/compiler/|mk/compiler\.mk$|src/sha256\.|src/aarch64_|\.github/workflows/host-suites\.yml$)'; then echo "run=true" >> "$GITHUB_OUTPUT" else - echo "run=false" >> "$GITHUB_OUTPUT"; echo "no OSC-1 compiler files changed; skipping" + echo "run=false" >> "$GITHUB_OUTPUT"; echo "no OSC compiler files changed; skipping" fi - - name: OSC-0B model sweep, OSC-1 back end, compiler golden/negative/model agreement, determinism (plain + ASan/UBSan) + # OSC-3 item 1: the full suite runs when the compiler or the legacy writer itself changes + if echo "$CHANGED" | grep -Eq '^(src/compiler/|src/aarch64_)'; then + echo "full=true" >> "$GITHUB_OUTPUT" + else + echo "full=false" >> "$GITHUB_OUTPUT" + fi + - name: OSC compiler quick suite (every compiler-path change; smoke counts, < 60 s) if: steps.guard.outputs.run == 'true' - run: make PHYSICS_DIR=/nonexistent PHYSICS_LOCK_CHECK=0 test-compiler + run: make PHYSICS_DIR=/nonexistent PHYSICS_LOCK_CHECK=0 test-compiler-quick + - name: OSC-0B model sweep, back end, compiler golden/negative/model agreement, determinism, legacy writer (full, plain + ASan/UBSan) + if: steps.guard.outputs.run == 'true' && steps.guard.outputs.full == 'true' + run: make PHYSICS_DIR=/nonexistent PHYSICS_LOCK_CHECK=0 test-compiler-full diff --git a/docs/osc/OSC-3-DESIGN.md b/docs/osc/OSC-3-DESIGN.md new file mode 100644 index 000000000..001b61be4 --- /dev/null +++ b/docs/osc/OSC-3-DESIGN.md @@ -0,0 +1,40 @@ +# OSC-3 design: the third Omega Systems Core compiler slice + +OSC-3 slice; not a general Omega compiler; no self-hosting. + +OSC-3 builds on OSC-2 (docs/osc/OSC-2-DESIGN.md; omega #148..#151) under +ADR OMEGA-SYSTEMS-CORE-0000. Each item is its own pull request, merged before +the next, with a content-addressed receipt in `evidence/OSC-3/receipts/` +written by `make osc3-receipt ITEM= PHYSICS_DIR=`. + +Every OSC-3 receipt records: `make test-compiler-full` PASS (plain and +ASan/UBSan), contract/struct/arena fuzz with 0 mismatches, runtime model replay +with 0 rejected runs, the full legacy writer differential, golden and negative +counts, the golden corpus digests compared program by program with the OSC-2 +encoder receipt (identical unless the item says why), cross-process +determinism, and the M6/M9/M14 gate logs compared by sha256 with the OSC-2 +encoder receipt. Item-specific evidence lines start with `osc3 :`. + +## Item 0: owed external review of OSC-2 + +See the item 0 section below once the review has run (Codex was at its usage +limit at 2026-10-01T11:31Z; retried before each later PR). + +## Item 1: quick and full compiler suites + +`make test-compiler` had grown to 1m32..2m23 single core, mostly the legacy +writer's exhaustive differential and the full fuzz counts, against a 3-minute +budget. It is split: + +- `make test-compiler-full`: everything, at the full counts. This is the old + `test-compiler` (kept as an alias with the same meaning). Receipts use it. + CI runs it when `src/compiler/` or `src/aarch64_*` changes. +- `make test-compiler-quick`: the same binaries, every golden and negative + program, determinism, the legacy caller allowlist; smaller sweeps (model + 10^5 sequences, compiler fuzz 120 per entry plain and 24 under ASan/UBSan, + legacy writer differential in its sampled mode). Target under 60 s single + core. CI runs it on every change to the compiler paths. It is a smoke run + and is never receipt evidence. + +The quick wall time is measured inside every OSC-3 receipt +(`test_compiler_quick.wall_seconds`, binaries already built). diff --git a/mk/compiler.mk b/mk/compiler.mk index 8163bac58..365f50ecb 100644 --- a/mk/compiler.mk +++ b/mk/compiler.mk @@ -5,6 +5,8 @@ # the OSC-2 item 4 test also links the legacy writer src/aarch64_encoder.c + decoder. # OSC-1 slice; not a general Omega compiler; no self-hosting. # +# test-compiler-quick smoke (< 60 s single core): same programs, small sweeps; CI on every change +# test-compiler-full = test-compiler (receipts and src/compiler CI use it) # test-compiler model sweep (10^6) + back end + compiler golden/negative/model # agreement + cross-process determinism, plain and ASan/UBSan # + legacy AArch64 writer differential/refusal + frozen-caller check @@ -13,7 +15,7 @@ # osc2-receipt ITEM=contracts|structs|arenas|encoder (default contracts): receipt under evidence/OSC-2/receipts (clean tree only) ifndef COMPILER_MK COMPILER_MK := 1 -.PHONY: test-compiler oscc compiler-receipt osc0b-model-receipt osc2-receipt +.PHONY: test-compiler test-compiler-full test-compiler-quick oscc compiler-receipt osc0b-model-receipt osc2-receipt osc3-receipt OSC_DIR = $(OUT_DIR)/compiler OSC_CFLAGS = -std=gnu11 -Wall -Wextra -Werror -D_GNU_SOURCE -O2 -Isrc -Isrc/compiler -Isrc/compiler/model OSC_ASAN = -O1 -g -fsanitize=address,undefined -fno-sanitize-recover=all @@ -102,6 +104,44 @@ test-compiler: $(OSC_DIR)/test_osc_model $(OSC_DIR)/test_osc_model_asan \ @tail -1 $(OSC_DIR)/legacy_callers.out; grep -q '^OSC2_LEGACY_CALLERS_PASS ' $(OSC_DIR)/legacy_callers.out @echo "test-compiler: PASS (OSC-1 slice + OSC-2 contracts + structs + arenas + legacy AArch64 writer; OSC-2 slice; not a general Omega compiler; no self-hosting.)" + +# OSC-3 item 1: the split. test-compiler-full is everything (the targets above, +# full counts; receipts use it). test-compiler is kept as an alias of full so old +# commands and scripts keep their meaning. test-compiler-quick (< 60 s single +# core) is the every-change CI leg: same binaries, same golden and negative +# programs, same determinism check, smaller sweeps and fuzz counts (stated in +# each output). Quick is a smoke run, never receipt evidence. +OSC_QDIR = $(OSC_DIR)/quick +OSC_QUICK_MODEL_SEQ ?= 100000 +OSC_QUICK_FUZZ ?= 120 +OSC_QUICK_ASAN_FUZZ ?= 24 +test-compiler-full: test-compiler + +test-compiler-quick: $(OSC_DIR)/test_osc_model $(OSC_DIR)/test_osc_backend $(OSC_DIR)/test_osc_backend_asan \ + $(OSC_DIR)/test_osc_compiler $(OSC_DIR)/test_osc_compiler_asan $(OSC_DIR)/oscc \ + $(OSC_DIR)/test_legacy_a64 $(OSC_DIR)/test_legacy_a64_asan + @mkdir -p $(OSC_QDIR) + $(abspath $(OSC_DIR)/test_osc_model) 05c0b5eed0010001 $(OSC_QUICK_MODEL_SEQ) > $(OSC_QDIR)/model.out + @tail -1 $(OSC_QDIR)/model.out; grep -Eq '^OSC0B_MODEL_(SMOKE_)?PASS$$' $(OSC_QDIR)/model.out + $(abspath $(OSC_DIR)/test_osc_backend) > $(OSC_QDIR)/backend.out + @tail -1 $(OSC_QDIR)/backend.out; grep -q '^OSC1_BACKEND_PASS$$' $(OSC_QDIR)/backend.out + $(abspath $(OSC_DIR)/test_osc_backend_asan) > $(OSC_QDIR)/backend_asan.out + @tail -1 $(OSC_QDIR)/backend_asan.out; grep -q '^OSC1_BACKEND_PASS$$' $(OSC_QDIR)/backend_asan.out + $(abspath $(OSC_DIR)/test_osc_compiler) $(OSC_QUICK_FUZZ) > $(OSC_QDIR)/compiler.out + @tail -1 $(OSC_QDIR)/compiler.out; grep -Eq '^OSC1_COMPILER_PASS( |$$)' $(OSC_QDIR)/compiler.out + $(abspath $(OSC_DIR)/test_osc_compiler_asan) $(OSC_QUICK_ASAN_FUZZ) > $(OSC_QDIR)/compiler_asan.out + @tail -1 $(OSC_QDIR)/compiler_asan.out; grep -Eq '^OSC1_COMPILER_PASS( |$$)' $(OSC_QDIR)/compiler_asan.out + sh tests/compiler/determinism.sh $(abspath $(OSC_DIR)/oscc) > $(OSC_QDIR)/determinism.out + @tail -1 $(OSC_QDIR)/determinism.out; grep -q '^OSC1_DETERMINISM_PASS$$' $(OSC_QDIR)/determinism.out + @grep "^struct fuzz: .* mismatches=0$$" $(OSC_QDIR)/compiler.out + @grep "^arena fuzz: .* mismatches=0$$" $(OSC_QDIR)/compiler.out + @grep "^runtime model replay: .* rejected=0$$" $(OSC_QDIR)/compiler.out + $(abspath $(OSC_DIR)/test_legacy_a64) quick > $(OSC_QDIR)/legacy_a64.out + @tail -1 $(OSC_QDIR)/legacy_a64.out; grep -q '^OSC2_LEGACY_A64_PASS$$' $(OSC_QDIR)/legacy_a64.out + sh tests/compiler/legacy_a64_callers.sh --selftest > $(OSC_QDIR)/legacy_callers.out + @tail -1 $(OSC_QDIR)/legacy_callers.out; grep -q '^OSC2_LEGACY_CALLERS_PASS ' $(OSC_QDIR)/legacy_callers.out + @echo "test-compiler-quick: PASS (smoke counts; not receipt evidence; full = make test-compiler-full. OSC-3 slice; not a general Omega compiler; no self-hosting.)" + osc0b-model-receipt: sh tests/compiler/osc0b_model_receipt.sh @@ -111,4 +151,8 @@ compiler-receipt: osc2-receipt: ITEM ?= contracts osc2-receipt: sh tests/compiler/osc2_receipt.sh $(ITEM) + +# OSC-3: ITEM=review|split|handles|dropflags|effects|identity|module; needs PHYSICS_DIR (M6/M9/M14) +osc3-receipt: + sh tests/compiler/osc3_receipt.sh $(ITEM) endif diff --git a/tests/compiler/osc3_receipt.sh b/tests/compiler/osc3_receipt.sh new file mode 100755 index 000000000..e78073e91 --- /dev/null +++ b/tests/compiler/osc3_receipt.sh @@ -0,0 +1,149 @@ +#!/bin/sh +# OSC-3 compiler slice receipt, one per item (docs/osc/OSC-3-DESIGN.md). +# OSC-3 slice; not a general Omega compiler; no self-hosting. +# Usage: tests/compiler/osc3_receipt.sh ITEM +# ITEM: review | split | handles | dropflags | effects | identity | module +# 1. refuses a dirty tree: receipts record an exact commit +# 2. runs `make test-compiler-full` (everything, full counts) into a temporary OUT_DIR, +# and `make test-compiler-quick` (wall time recorded; quick is never the evidence) +# 3. compiles every golden program with oscc; records IR and code digests and compares +# every program that the OSC-2 baseline receipt lists (tests/compiler/osc3_baseline.json +# names it) against its OSC-2 digests: identical unless OSC3_CODE_CHANGE_OK=1 and the +# item states why (the receipt then lists the programs that changed) +# 4. runs the M6/M9/M14 gates (PHYSICS_DIR must point at the pinned physics checkout) +# and compares each normalised gate log sha256 with the OSC-2 encoder receipt values +# 5. records every "^" line the test binaries print for this item +# (lines starting with "osc3 :"), plain and ASan +# 6. writes evidence/OSC-3/receipts/osc3--.json; never overwrites evidence +set -eu +ITEM=${1:-} +case "$ITEM" in review|split|handles|dropflags|effects|identity|module) ;; *) echo "osc3-receipt: REFUSED: unknown ITEM '$ITEM'" >&2; exit 2 ;; esac +ROOT=$(cd "$(dirname "$0")/../.." && pwd -P) +cd "$ROOT" +EVD=evidence/OSC-3/receipts +BASEREC=$(ls evidence/OSC-2/receipts/osc2-encoder-*.json | head -1) +die() { echo "osc3-receipt: REFUSED: $*" >&2; exit 2; } +[ -n "${PHYSICS_DIR:-}" ] && [ -d "$PHYSICS_DIR" ] || die "PHYSICS_DIR must point at the pinned physics checkout (M6/M9/M14 gates are part of every OSC-3 receipt)" +[ -z "$(git status --porcelain --untracked-files=all)" ] || die "dirty tree; commit first (receipts record an exact commit)" +COMMIT=$(git rev-parse HEAD) +BASE=$(git merge-base HEAD origin/main) || die "no merge base with origin/main" + +T=$(mktemp -d) +trap 'rm -rf "$T"' EXIT +O="$T/build/compiler" +nice make --no-print-directory OUT_DIR="$T/build" PHYSICS_DIR=/nonexistent PHYSICS_LOCK_CHECK=0 test-compiler-full \ + >"$T/make.log" 2>&1 || { tail -30 "$T/make.log"; die "make test-compiler-full failed"; } +grep -q '^test-compiler: PASS' "$T/make.log" || die "no test-compiler (full) PASS line" +q0=$(date +%s) +nice make --no-print-directory OUT_DIR="$T/build" PHYSICS_DIR=/nonexistent PHYSICS_LOCK_CHECK=0 test-compiler-quick \ + >"$T/quick.log" 2>&1 || { tail -30 "$T/quick.log"; die "make test-compiler-quick failed"; } +q1=$(date +%s) +grep -q '^test-compiler-quick: PASS' "$T/quick.log" || die "no test-compiler-quick PASS line" +QSECS=$((q1 - q0)) + +MSUM=$(grep '^OSC0B_MODEL_SEED=' "$O/model.out" | tail -1) +CLINE=$(grep '^golden=' "$O/compiler.out" | tail -1 | sed 's/ time=.*//') +CLINE_ASAN=$(grep '^golden=' "$O/compiler_asan.out" | tail -1 | sed 's/ time=.*//') +DLINE=$(grep '^programs=' "$O/determinism.out" | tail -1) +for v in "$MSUM" "$CLINE" "$CLINE_ASAN" "$DLINE"; do [ -n "$v" ] || die "cannot parse test output"; done +fz() { grep "^$1 fuzz:" "$2" | tail -1; } +for k in contract struct arena; do + for f in "$O/compiler.out" "$O/compiler_asan.out"; do + l=$(fz $k "$f"); [ -n "$l" ] || die "no $k fuzz line in $f" + case "$k:$l" in contract:*) ;; *" mismatches=0") ;; *) die "$k fuzz mismatches in $f" ;; esac + done +done +for f in "$O/compiler.out" "$O/compiler_asan.out"; do + case "$(grep '^runtime model replay:' "$f" | tail -1)" in *" rejected=0") ;; *) die "runtime model replay rejected runs ($f)" ;; esac +done +case "$(grep '^legacy a64 differential:' "$O/legacy_a64.out" | tail -1)" in *" mode=full "*" mismatches=0") ;; *) die "legacy a64 full differential" ;; esac + +# golden corpus vs the OSC-2 baseline receipt +: >"$T/corpus.txt"; : >"$T/changed.txt" +NSAME=0; NBASE=0 +for f in tests/compiler/progs/*.osc; do + out=$("$O/oscc" "$f") || die "oscc refused golden program $f" + ir=$(echo "$out" | sed -n 's/^ir_sha256=//p'); code=$(echo "$out" | sed -n 's/^code_sha256=//p') + printf '%s %s %s %s\n' "$f" "$(sha256sum "$f" | cut -d' ' -f1)" "$ir" "$code" >>"$T/corpus.txt" + b=$(grep "\"program\": \"$f\"" "$BASEREC" || true) + if [ -n "$b" ]; then + NBASE=$((NBASE + 1)) + case "$b" in *"\"ir_sha256\": \"$ir\", \"code_sha256\": \"$code\""*) NSAME=$((NSAME + 1)) ;; *) echo "$f" >>"$T/changed.txt" ;; esac + fi +done +NCHG=$(wc -l <"$T/changed.txt" | tr -d ' ') +[ "$NCHG" = 0 ] || [ "${OSC3_CODE_CHANGE_OK:-0}" = 1 ] || { cat "$T/changed.txt"; die "$NCHG OSC-2 golden programs compile differently (set OSC3_CODE_CHANGE_OK=1 only if the item states why)"; } +CORPUS_SHA=$(sha256sum "$T/corpus.txt" | cut -d' ' -f1) +NPROG=$(wc -l <"$T/corpus.txt" | tr -d ' ') +NNEG=$(ls tests/compiler/neg/*.osc | wc -l | tr -d ' ') + +# M6/M9/M14 gates, normalised log hash vs the OSC-2 encoder receipt +G="" +rm -rf build/osc3-receipt-gates; mkdir -p build/osc3-receipt-gates +for m in m6 m9 m14; do + nice make --no-print-directory OUT_DIR=build/osc3-receipt-gates PHYSICS_DIR="$PHYSICS_DIR" "test-$m" >"$T/$m.log" 2>&1 \ + || { tail -20 "$T/$m.log"; die "test-$m failed"; } + tot=$(grep 'TOTAL GATES' "$T/$m.log" | head -1 | sed 's/.*TOTAL GATES: \([0-9]*\) | PASSED: \([0-9]*\) | FAILED: \([0-9]*\).*/{"total": \1, "passed": \2, "failed": \3}/') + case "$tot" in "{\"total\": "*", \"failed\": 0}") ;; *) die "test-$m: no gate total line with failed=0" ;; esac + sed -n "/omegatool --run/,\$p" "$T/$m.log" | sed 's|\./build/[^/ ]*/omegatool|./OUT/omegatool|g' >"$T/$m.norm" + gsha=$(sha256sum "$T/$m.norm" | cut -d' ' -f1) + grep -q "\"$m\": {[^}]*\"gate_log_sha256\": \"$gsha\"" "$BASEREC" || die "test-$m gate log differs from the OSC-2 baseline ($gsha)" + G="$G\"$m\": ${tot%\}}, \"gate_log_sha256\": \"$gsha\", \"identical_to_osc2_baseline\": true}, " +done +GATES="{${G%, }}" + +esc() { sed 's/\\/\\\\/g; s/"/\\"/g'; } +R="$T/receipt.json" +{ + printf '{\n' + printf ' "schema": "omega.osc3.compiler.receipt.v1",\n' + printf ' "verdict": "PASS",\n' + printf ' "item": "%s",\n' "$ITEM" + printf ' "statement": "OSC-3 slice; not a general Omega compiler; no self-hosting.",\n' + printf ' "design": "docs/osc/OSC-3-DESIGN.md",\n' + printf ' "repo_commit": "%s",\n' "$COMMIT" + printf ' "base_commit": "%s",\n' "$BASE" + printf ' "tree_clean": true,\n' + printf ' "host_arch": "%s",\n' "$(uname -m)" + printf ' "c_compiler": "%s",\n' "$(${CC:-cc} --version 2>/dev/null | head -1 | esc)" + printf ' "test_compiler_full": "PASS",\n' + printf ' "test_compiler_quick": {"result": "PASS", "wall_seconds": %s, "budget_seconds": 60, "note": "nice, one make job; smoke counts, not evidence"},\n' "$QSECS" + printf ' "osc0b_model": "%s",\n' "$(echo "$MSUM" | esc)" + printf ' "compiler": "%s",\n' "$(echo "$CLINE" | esc)" + printf ' "compiler_asan": "%s",\n' "$(echo "$CLINE_ASAN" | esc)" + for k in contract struct arena; do + printf ' "%s_fuzz": "%s",\n' "$k" "$(fz $k "$O/compiler.out" | esc)" + printf ' "%s_fuzz_asan": "%s",\n' "$k" "$(fz $k "$O/compiler_asan.out" | esc)" + done + printf ' "runtime_model_replay": "%s",\n' "$(grep '^runtime model replay:' "$O/compiler.out" | tail -1 | esc)" + printf ' "runtime_model_replay_asan": "%s",\n' "$(grep '^runtime model replay:' "$O/compiler_asan.out" | tail -1 | esc)" + printf ' "legacy_a64_differential": "%s",\n' "$(grep '^legacy a64 differential:' "$O/legacy_a64.out" | tail -1 | esc)" + printf ' "item_evidence": [\n' + { grep -h "^osc3 $ITEM:" "$O/compiler.out" | sed 's/^/plain: /'; grep -h "^osc3 $ITEM:" "$O/compiler_asan.out" | sed 's/^/asan: /'; } | esc | sed 's/.*/ "&",/' >"$T/ev.txt" || true + sed '$ s/,$//' "$T/ev.txt" + printf ' ],\n' + printf ' "determinism": "%s",\n' "$(echo "$DLINE" | esc)" + printf ' "golden_programs": %s,\n' "$NPROG" + printf ' "negative_programs": %s,\n' "$NNEG" + printf ' "osc2_baseline_receipt": "%s",\n' "$BASEREC" + printf ' "osc2_programs_identical": "%s of %s",\n' "$NSAME" "$NBASE" + printf ' "osc2_programs_changed": [%s],\n' "$(sed 's/.*/"&"/' "$T/changed.txt" | paste -sd, -)" + printf ' "golden_corpus_sha256": "%s",\n' "$CORPUS_SHA" + printf ' "golden_corpus": [\n' + n=0 + while read -r f src ir code; do + n=$((n + 1)); sep=,; [ "$n" = "$NPROG" ] && sep= + printf ' {"program": "%s", "source_sha256": "%s", "ir_sha256": "%s", "code_sha256": "%s"}%s\n' "$f" "$src" "$ir" "$code" "$sep" + done <"$T/corpus.txt" + printf ' ],\n' + printf ' "m6_m9_m14_gates": %s,\n' "$GATES" + printf ' "self_host": "no: the OSC-3 compiler slice cannot compile any part of itself (docs/osc/OSC-1-SELF-HOST-STATEMENT.md)",\n' + printf ' "timing_measured": "quick wall time only"\n' + printf '}\n' +} >"$R" +mkdir -p "$EVD" +RSHA=$(sha256sum "$R" | cut -d' ' -f1) +OUT="$EVD/osc3-$ITEM-$RSHA.json" +[ -e "$OUT" ] && { echo "osc3-receipt: identical receipt already present: $OUT"; exit 0; } +cp "$R" "$OUT" +echo "osc3-receipt: PASS receipt=$OUT" From 7f6dc16820458bdc171e780d6ae9ca0f2cd82087 Mon Sep 17 00:00:00 2001 From: Drake Stapleton Date: Thu, 1 Oct 2026 07:07:28 -0500 Subject: [PATCH 2/8] OSC-3 item 0: record the owed Codex review of OSC-2 (NO FINDINGS) Co-Authored-By: Drake Stapleton Co-Authored-By: Claude Fable 5.1 --- docs/osc/OSC-3-DESIGN.md | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/docs/osc/OSC-3-DESIGN.md b/docs/osc/OSC-3-DESIGN.md index 001b61be4..35e6baa4c 100644 --- a/docs/osc/OSC-3-DESIGN.md +++ b/docs/osc/OSC-3-DESIGN.md @@ -17,8 +17,16 @@ encoder receipt. Item-specific evidence lines start with `osc3 :`. ## Item 0: owed external review of OSC-2 -See the item 0 section below once the review has run (Codex was at its usage -limit at 2026-10-01T11:31Z; retried before each later PR). +OSC-2 (#148..#151) was reviewed only by the Gemini fallback because Codex was +at its usage limit. The owed Codex review ran on 2026-10-01: first attempt +11:30Z refused (usage limit, reset 12:03Z); second attempt 12:04Z, +`codex exec -s read-only -c model="gpt-6-astra"` over +`git diff 0abdb08^..7e713e3 -- src/compiler src/language tests/compiler mk/compiler.mk src/aarch64_encoder.c`, +asked for correctness bugs only (miscompilation, interpreter/native +disagreement, missed contract traps, unsound ownership/borrow/arena checks, +compiler memory safety, layout, encoder ranges) with concrete failing inputs. +Result: **NO FINDINGS**. No item 0 fix PR was needed; the result is recorded +here and in the item 1 pull request. ## Item 1: quick and full compiler suites From 78d11e4ec10bdcfb39599fb44efae2e8c8262b4e Mon Sep 17 00:00:00 2001 From: Drake Stapleton Date: Thu, 1 Oct 2026 07:15:39 -0500 Subject: [PATCH 3/8] OSC-3 item 1: quick ASan fuzz 120 per entry (24 missed coverage checks) Co-Authored-By: Drake Stapleton Co-Authored-By: Claude Fable 5.1 --- docs/osc/OSC-3-DESIGN.md | 2 +- mk/compiler.mk | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/osc/OSC-3-DESIGN.md b/docs/osc/OSC-3-DESIGN.md index 35e6baa4c..42e6cc6a4 100644 --- a/docs/osc/OSC-3-DESIGN.md +++ b/docs/osc/OSC-3-DESIGN.md @@ -39,7 +39,7 @@ budget. It is split: CI runs it when `src/compiler/` or `src/aarch64_*` changes. - `make test-compiler-quick`: the same binaries, every golden and negative program, determinism, the legacy caller allowlist; smaller sweeps (model - 10^5 sequences, compiler fuzz 120 per entry plain and 24 under ASan/UBSan, + 10^5 sequences, compiler fuzz 120 per entry, plain and under ASan/UBSan (smaller counts miss coverage checks), legacy writer differential in its sampled mode). Target under 60 s single core. CI runs it on every change to the compiler paths. It is a smoke run and is never receipt evidence. diff --git a/mk/compiler.mk b/mk/compiler.mk index 365f50ecb..8b3ae55d6 100644 --- a/mk/compiler.mk +++ b/mk/compiler.mk @@ -114,7 +114,7 @@ test-compiler: $(OSC_DIR)/test_osc_model $(OSC_DIR)/test_osc_model_asan \ OSC_QDIR = $(OSC_DIR)/quick OSC_QUICK_MODEL_SEQ ?= 100000 OSC_QUICK_FUZZ ?= 120 -OSC_QUICK_ASAN_FUZZ ?= 24 +OSC_QUICK_ASAN_FUZZ ?= 120 test-compiler-full: test-compiler test-compiler-quick: $(OSC_DIR)/test_osc_model $(OSC_DIR)/test_osc_backend $(OSC_DIR)/test_osc_backend_asan \ From 076193b2e198af0fabbd3609a733a5ece8a25bf7 Mon Sep 17 00:00:00 2001 From: Drake Stapleton Date: Thu, 1 Oct 2026 07:40:26 -0500 Subject: [PATCH 4/8] OSC-3: run compiler suites on push to main; list remaining u32 generation sites with a fix plan Co-Authored-By: Drake Stapleton Co-Authored-By: Claude Fable 5.1 --- .github/workflows/compiler-main.yml | 26 ++++++++++++++++++++ docs/osc/OSC-3-DESIGN.md | 38 +++++++++++++++++++++++++++++ 2 files changed, 64 insertions(+) create mode 100644 .github/workflows/compiler-main.yml diff --git a/.github/workflows/compiler-main.yml b/.github/workflows/compiler-main.yml new file mode 100644 index 000000000..9b72a0612 --- /dev/null +++ b/.github/workflows/compiler-main.yml @@ -0,0 +1,26 @@ +name: Compiler on main +# OSC-3 (Lane 30): the `compiler` job in host-suites.yml runs on pull requests +# only. This workflow re-runs the OSC compiler suites after every merge to main +# that touches the compiler paths, so main has its own post-merge result. +# OSC-3 slice; not a general Omega compiler; no self-hosting. +on: + workflow_dispatch: + push: + branches: [main] + paths: + - 'src/compiler/**' + - 'tests/compiler/**' + - 'mk/compiler.mk' + - 'src/sha256.*' + - 'src/aarch64_*' + - '.github/workflows/compiler-main.yml' +jobs: + compiler-main: + runs-on: ubuntu-24.04-arm + timeout-minutes: 20 + steps: + - uses: actions/checkout@v4 + - name: OSC compiler quick suite + run: make PHYSICS_DIR=/nonexistent PHYSICS_LOCK_CHECK=0 test-compiler-quick + - name: OSC compiler full suite (plain + ASan/UBSan, legacy writer full differential) + run: make PHYSICS_DIR=/nonexistent PHYSICS_LOCK_CHECK=0 test-compiler-full diff --git a/docs/osc/OSC-3-DESIGN.md b/docs/osc/OSC-3-DESIGN.md index 42e6cc6a4..f08627aa7 100644 --- a/docs/osc/OSC-3-DESIGN.md +++ b/docs/osc/OSC-3-DESIGN.md @@ -46,3 +46,41 @@ budget. It is split: The quick wall time is measured inside every OSC-3 receipt (`test_compiler_quick.wall_seconds`, binaries already built). + +CI: the `compiler` job in `.github/workflows/host-suites.yml` runs on pull +requests (quick always on compiler paths, full when `src/compiler/` or +`src/aarch64_*` changes). `.github/workflows/compiler-main.yml` re-runs quick +and full on every push to main that touches the compiler paths (the 2026-10-01 +audit found the compiler suites never ran after merge). + +## Generation width: remaining 32-bit sites and fix plan + +ADR OMEGA-SYSTEMS-CORE-0000 decision 1 fixes capability and object generations +at u64 end to end, a slot retired at the maximum, never wrapped. The 2026-10-01 +audit (track 2, s.F.3) found these sites still 32-bit; checked against main +07004a8. A u64 generation stored into any of them is silently truncated, and a +truncated generation can make a stale handle look live again. + +| Site (main 07004a8) | Today | Owner | Fix plan | +|---|---|---|---| +| `src/runtime/rx_world.h:177` `RxObjRef{uint32_t id; uint32_t generation}` | u32 | runtime lane (src/runtime) | widen `generation` to u64; retire the object id at UINT64_MAX; versioned like omega#71 | +| `src/runtime/rx_world.h:305` object `generation` | u32 | runtime lane | same change, same PR as :177 | +| `src/runtime/rx_world.h:328` `RxSub{reaction; generation; mask}` | u32 | runtime lane | widen with :177 (subscriptions compare against object generations) | +| `src/runtime/rx_world.h:599` `seat_generation` | u32 | runtime lane | widen; retire the seat at max | +| `src/runtime/rx_graph.c:517, :529` crumb/graph hash writes object generations with `put32` | u32 on the wire | runtime lane | `put64` together with a crumb/graph record version bump (old records refused, not reinterpreted), in the identity-break sequence (item 5) | +| `src/runtime/rx_jspace.c:1406, :1413, :1414` J-Space body writes branch/slot generations with `put32` | u32 on the wire | runtime lane | `put64` with a J-Space record version bump, same rule | +| `src/omega_accelerator.h:67, :87` `uint32_t capability_generation` | u32 | accelerator owner (not OSC) | widen to u64, retire at max; ADR decision 1 names this file | +| `src/compiler/osc_rt.h:69-70` `slot_serial[]`, `next_serial` (`++next_serial`, no overflow check) | u32 | OSC (this lane) | item 2: handle generations are u64 with retire-at-max; the region serial is widened or traps on wrap (stated in the item 2 section) | +| AIENOS ADR 0013 (`index u32; generation u32`, retire at u32::MAX) | u32 | aienos lane | request only, see item 5 (`docs/osc/OSC-3-ADR0013-REQUEST.md`); not edited from this repository | + +Only the `osc_rt` row is inside this lane's files. The others are listed so the +owning lanes can schedule them; each is a versioned change with old records +refused, never reinterpreted. None is applied by OSC-3. + +## Slice order after item 4 + +Per the audit (III.7 and the 2026-10-01 review), the first real migration is +crumbline (`src/crumbline`-family C) once effects and capabilities exist: +item 4 (effects/capabilities), then item 5 (identity break + ADR 0013 +request), then item 6 (crumbline as the first production C module under +contracts; proposal in docs/osc first). From 388f674c0bfef3568e75116afb4b4d6d81b5b53e Mon Sep 17 00:00:00 2001 From: Drake Stapleton Date: Thu, 1 Oct 2026 07:40:39 -0500 Subject: [PATCH 5/8] OSC-3 design: crumbline path Co-Authored-By: Drake Stapleton Co-Authored-By: Claude Fable 5.1 --- docs/osc/OSC-3-DESIGN.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/osc/OSC-3-DESIGN.md b/docs/osc/OSC-3-DESIGN.md index f08627aa7..19d62c24d 100644 --- a/docs/osc/OSC-3-DESIGN.md +++ b/docs/osc/OSC-3-DESIGN.md @@ -80,7 +80,7 @@ refused, never reinterpreted. None is applied by OSC-3. ## Slice order after item 4 Per the audit (III.7 and the 2026-10-01 review), the first real migration is -crumbline (`src/crumbline`-family C) once effects and capabilities exist: +crumbline (`src/crumbline/`) once effects and capabilities exist: item 4 (effects/capabilities), then item 5 (identity break + ADR 0013 request), then item 6 (crumbline as the first production C module under contracts; proposal in docs/osc first). From a845ccc8770f13b70fe73114b5f1b4cec016969d Mon Sep 17 00:00:00 2001 From: Drake Stapleton Date: Thu, 1 Oct 2026 07:42:02 -0500 Subject: [PATCH 6/8] OSC-3 receipt: refuse when an OSC-2 baseline golden program is missing (Codex review finding) Co-Authored-By: Drake Stapleton Co-Authored-By: Claude Fable 5.1 --- tests/compiler/osc3_receipt.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/compiler/osc3_receipt.sh b/tests/compiler/osc3_receipt.sh index e78073e91..855a5ce5d 100755 --- a/tests/compiler/osc3_receipt.sh +++ b/tests/compiler/osc3_receipt.sh @@ -59,6 +59,11 @@ done case "$(grep '^legacy a64 differential:' "$O/legacy_a64.out" | tail -1)" in *" mode=full "*" mismatches=0") ;; *) die "legacy a64 full differential" ;; esac # golden corpus vs the OSC-2 baseline receipt +# every program the OSC-2 baseline receipt lists must still exist (a deleted or renamed +# golden program must not silently drop out of the comparison) +for bp in $(grep -o '"program": "[^"]*"' "$BASEREC" | sed 's/"program": "//; s/"$//'); do + [ -f "$bp" ] || die "OSC-2 baseline golden program $bp is missing (renamed or deleted)" +done : >"$T/corpus.txt"; : >"$T/changed.txt" NSAME=0; NBASE=0 for f in tests/compiler/progs/*.osc; do @@ -72,6 +77,7 @@ for f in tests/compiler/progs/*.osc; do fi done NCHG=$(wc -l <"$T/changed.txt" | tr -d ' ') +NBL=$(grep -c "\"program\": " "$BASEREC"); [ "$NBASE" = "$NBL" ] || die "compared $NBASE of $NBL OSC-2 baseline programs" [ "$NCHG" = 0 ] || [ "${OSC3_CODE_CHANGE_OK:-0}" = 1 ] || { cat "$T/changed.txt"; die "$NCHG OSC-2 golden programs compile differently (set OSC3_CODE_CHANGE_OK=1 only if the item states why)"; } CORPUS_SHA=$(sha256sum "$T/corpus.txt" | cut -d' ' -f1) NPROG=$(wc -l <"$T/corpus.txt" | tr -d ' ') From 5aa9f7283c82136d9b20fb7fc44d1ca60cc1e709 Mon Sep 17 00:00:00 2001 From: Drake Stapleton Date: Thu, 1 Oct 2026 07:46:02 -0500 Subject: [PATCH 7/8] OSC-3 item 1 receipt (split) Co-Authored-By: Drake Stapleton Co-Authored-By: Claude Fable 5.1 --- ...20adc4f3634f906dbf79519c4bf81081dbfca.json | 77 +++++++++++++++++++ 1 file changed, 77 insertions(+) create mode 100644 evidence/OSC-3/receipts/osc3-split-55566dd13a376d8a3654a09798520adc4f3634f906dbf79519c4bf81081dbfca.json diff --git a/evidence/OSC-3/receipts/osc3-split-55566dd13a376d8a3654a09798520adc4f3634f906dbf79519c4bf81081dbfca.json b/evidence/OSC-3/receipts/osc3-split-55566dd13a376d8a3654a09798520adc4f3634f906dbf79519c4bf81081dbfca.json new file mode 100644 index 000000000..2e5c38a9a --- /dev/null +++ b/evidence/OSC-3/receipts/osc3-split-55566dd13a376d8a3654a09798520adc4f3634f906dbf79519c4bf81081dbfca.json @@ -0,0 +1,77 @@ +{ + "schema": "omega.osc3.compiler.receipt.v1", + "verdict": "PASS", + "item": "split", + "statement": "OSC-3 slice; not a general Omega compiler; no self-hosting.", + "design": "docs/osc/OSC-3-DESIGN.md", + "repo_commit": "7efd8b3e7df93c68541e3ee29e4f2af8403196c9", + "base_commit": "7e713e301a6733a679f82f6892beda57b313908c", + "tree_clean": true, + "host_arch": "aarch64", + "c_compiler": "cc (Ubuntu 13.3.0-6ubuntu2~24.04.1) 13.3.0", + "test_compiler_full": "PASS", + "test_compiler_quick": {"result": "PASS", "wall_seconds": 30, "budget_seconds": 60, "note": "nice, one make job; smoke counts, not evidence"}, + "osc0b_model": "OSC0B_MODEL_SEED=05c0b5eed0010001 SEQUENCES=1000000 STEPS=21905422 FALSE_ACCEPTS=0 WRONG_NAME=0 FALSE_REJECTS=0", + "compiler": "golden=37/37 funcs=129 entries=92 expect_runs=100 diff_runs=115136 trace_replays=89 rt_replays=70929 rt_events=351214 neg=96/96 neg_traced=18 checks=319518 failed=0", + "compiler_asan": "golden=37/37 funcs=129 entries=92 expect_runs=100 diff_runs=115136 trace_replays=89 rt_replays=70929 rt_events=351214 neg=96/96 neg_traced=18 checks=319518 failed=0", + "contract_fuzz": "contract fuzz: units=200 compiled=174 static_refused=26 runs=11136 ok=882 requires=5435 ensures=4384 overflow=435 other_traps=0 mismatches=0", + "contract_fuzz_asan": "contract fuzz: units=200 compiled=174 static_refused=26 runs=11136 ok=882 requires=5435 ensures=4384 overflow=435 other_traps=0 mismatches=0", + "struct_fuzz": "struct fuzz: units=125 runs=6000 ok=3805 bounds=1087 requires=155 overflow=224 cast=729 mismatches=0", + "struct_fuzz_asan": "struct fuzz: units=125 runs=6000 ok=3805 bounds=1087 requires=155 overflow=224 cast=729 mismatches=0", + "arena_fuzz": "arena fuzz: units=125 allocs=557 runs=6000 ok=2542 arena_full=2606 bounds=639 overflow=213 mismatches=0", + "arena_fuzz_asan": "arena fuzz: units=125 allocs=557 runs=6000 ok=2542 arena_full=2606 bounds=639 overflow=213 mismatches=0", + "runtime_model_replay": "runtime model replay: runs=115238 events=351214 accepted=115238 rejected=0", + "runtime_model_replay_asan": "runtime model replay: runs=115238 events=351214 accepted=115238 rejected=0", + "legacy_a64_differential": "legacy a64 differential: emitters=25 mode=full words=71266833 decoded=71266817 mismatches=0", + "item_evidence": [ + ], + "determinism": "programs=37 identical=37", + "golden_programs": 37, + "negative_programs": 96, + "osc2_baseline_receipt": "evidence/OSC-2/receipts/osc2-encoder-cb452b9889ad972086f304448645168791c52ec7a33eff284a306da237eca1c9.json", + "osc2_programs_identical": "37 of 37", + "osc2_programs_changed": [], + "golden_corpus_sha256": "f8a4be89ebf700e778aa154001148651491fc9b07384d031560f2a63130710eb", + "golden_corpus": [ + {"program": "tests/compiler/progs/arena_basic.osc", "source_sha256": "4d7572fef4094024a1f8e84aa54f29e95c6d34c65bce9bfe9d171a0c6015236d", "ir_sha256": "c1cbf604876cbc775f118dd68b867836197a9fd82ea133aacbea3672b8016f3e", "code_sha256": "3fb18af64f18ec3f52d1c5bc600d13af869282a2e56160a9972a6d7a54e54623"}, + {"program": "tests/compiler/progs/arena_borrows.osc", "source_sha256": "a90474fb7d52cf9d24db60c5752aba7db3dbbb2d1527b51a81410522e05bd96c", "ir_sha256": "b2b2737fd79346c4881c63053eeb7c8a493ece93c733b254986f1b88ac39c4b3", "code_sha256": "69209e13ee4f303a9177c8ff8560291da04c6613e0a6bbb7ff25167270cc2ce8"}, + {"program": "tests/compiler/progs/arena_dtor.osc", "source_sha256": "59bb1cc1a7a3d94852581a8465e290f7fc806f82c0ed0e5d5614f724cd47a2db", "ir_sha256": "0853cf1d750b7aa7f89bedce30bab8abed21b7c03688b3ec1d149ed6a4ff1ecc", "code_sha256": "39e09aa8abe6d0527d1bcdf4769099f5e4fb35783949f436b20b25ff29e33a59"}, + {"program": "tests/compiler/progs/arena_full.osc", "source_sha256": "048b757f8e0997ec6eacc1be7065f10a9621eb8147c3a638faff6883b50db7d6", "ir_sha256": "2095deb65522e3782d66abeb601a02fd4f16d76d05bfec32345931f970c0f3bc", "code_sha256": "c58d9cf04f27ea71370cc0fdfe903113ef4449db1d1e8c265adf4a5f5488f902"}, + {"program": "tests/compiler/progs/arena_nested.osc", "source_sha256": "6fbcb009abcd1e47188ccac0adadf4c2a110e060f44028ef5194e637f6b59659", "ir_sha256": "0d910fe9717796b0f1a3afe70e3ad8af94bb9d43675bbc3568635b0f175ec81d", "code_sha256": "6a45e3becc6c0179bab0eeffb4864795a5cf1d12163ac738272ec10d2e3a008e"}, + {"program": "tests/compiler/progs/arena_structs.osc", "source_sha256": "2ccd4e8a6d4eab0e15f1018545ba4604e54dd2f85b21aed38711c3d34a0cf1a4", "ir_sha256": "f9029fbc626e4a06b12f928b60ec3739c935c0d6afbafe0df9daba7580312bfc", "code_sha256": "c1d5a138f01a4625b2eafc626f3d35f4476189f89fd38d9e777345aa0dee65d1"}, + {"program": "tests/compiler/progs/arrays.osc", "source_sha256": "0d41e301111e2c132ceba7d7272eb42ae0d1b1cb0341c4f76d3fec2ce38a6ee8", "ir_sha256": "3c3b6e50085dd82cde7ec97d2feb580d38b714f8cb4f60db35b9a4f36530df0d", "code_sha256": "e6b45cce88509c39fa0503302691906d79e4189de57244a9bc1036ba15c91ac5"}, + {"program": "tests/compiler/progs/bitrev.osc", "source_sha256": "7a831a9f47434a76b65bdf837fecaf96f4a85d2c31c4682b280301b8aa588d1c", "ir_sha256": "e3aa5e5e5c58fbc686025370e8c87eceb5c4805b2a9d21d55bfbf7bfdba6cc36", "code_sha256": "94674978c5ca8c96ccc0fed847668ab4b73c0dd1f3f7527a613b26cd307c2362"}, + {"program": "tests/compiler/progs/bounds.osc", "source_sha256": "0519478f54c98ca06f3414ff9ac5dc4193ed5b2b43a7a89b2333ef3bb54b3094", "ir_sha256": "7e7bb041550f9a5a4445c0e028650f6e0cf9afcea61819a95e29b92eca13d966", "code_sha256": "07bb15370990980cd1b27be4ee87612133a58463e305e067870b6668ebc9a2d9"}, + {"program": "tests/compiler/progs/calls.osc", "source_sha256": "add5b82ec5ea73b322e9b1620220f9ff73ba9f76aeff031e0654980e2f36bcbc", "ir_sha256": "9d50bea67d3928a457201dfe35541b912b9acfbdaf97e901e7ea2e0f3185524d", "code_sha256": "a6434af2275da292a0a573b355cab439bfb26f85be6b0b0dcdc709edc66d7a94"}, + {"program": "tests/compiler/progs/casts.osc", "source_sha256": "a5093b32ee0d204d20920e5fd8f8c39c8e10b92c89aabb41fb703e7e28637fb3", "ir_sha256": "cc35e86f43ba0ebe29ea6906c0af5e01fa30964c75b0a69b05370c4100ae80b3", "code_sha256": "fdff78f367ea211da5e5058ffe715ea7fb14a1bee2727e69aefd9fda2b27bece"}, + {"program": "tests/compiler/progs/collatz.osc", "source_sha256": "912412fa1ffd990786a055d2b43a35f9fd629fa59299b1181463f3b314cd741f", "ir_sha256": "fdf94380724fa0994a074cbed2cf789c3ed4dfeb14450e648b9144ada4e57edd", "code_sha256": "9b06e959179f262f45ef72015ee1001a026262754804c107b640813131e014bf"}, + {"program": "tests/compiler/progs/contracts_basic.osc", "source_sha256": "8a1370cec47deb9671ef6e4a55a66a94b97d3f34754fa7c64ae741853134bb99", "ir_sha256": "94f2e0f6c9c8c15630725d5105007a7ecdb26212c898219b4d99be340d027ede", "code_sha256": "b7d9a360486ca56847ee83a0dc7731026305a20a9dfd250d2d6bc3197b74a0fc"}, + {"program": "tests/compiler/progs/contracts_ensures.osc", "source_sha256": "4bade10adc6078e9a8cb77b12fd529f0cb733bcf24629018a95402528a0bc3f0", "ir_sha256": "c2a7c5cca6ffd933c90d89d20e0b8dcb5c56fbf831fd9b882ad729de1efefa9f", "code_sha256": "de5746dd6d6c22049987e7bd5bdde6a238fe24785e4c654a852e383a0e657f6a"}, + {"program": "tests/compiler/progs/contracts_requires.osc", "source_sha256": "83f5842fba1f7f027cb655fcff243f1650761afedecb1cd168992a08b7924224", "ir_sha256": "16bc4b6267ee1d4a75cc60d35514baf10cc3f326b3a3e47222ca271587c9dac3", "code_sha256": "599922ff8eff90977309cf593da6cac4f951eb182bdf8a8b156c36ca6c7917ff"}, + {"program": "tests/compiler/progs/factorial.osc", "source_sha256": "3e410e9214a30628b199f7bfe8f99d7e9f439e73af2d279719fa7b523bc74e21", "ir_sha256": "cc36ae8edf9a203d4f82bd1b351b92f2df818427d26239ae8c6542e175674700", "code_sha256": "a3fc5f8c4a5ae8ce6381a0db02a03e391df791a0ce2d6f778face3a30532ecd3"}, + {"program": "tests/compiler/progs/fib.osc", "source_sha256": "9490114a0c756edab0ee7af37252b5883cc7c11b69e54ba5481530b2dcb8e03c", "ir_sha256": "bfe54f4d1502277153becb83faa0fd2975496a1875837fa8e8aa72431aa0ad00", "code_sha256": "d2e25ea89ebd59e49e29303696b7b2bff4ff39d45f62bd5566db609830d153a8"}, + {"program": "tests/compiler/progs/gcd.osc", "source_sha256": "0fad11202f1f6ce6e845b266f24df86cbc0e6160a4772c043a15b60fa54a720f", "ir_sha256": "5d649066a565d7e7ab680ea6b2827306701714da7b23755836814da7cccfa328", "code_sha256": "eb4cbe78da3176853323b2d11b970444c51fb61a33dbc770ec355cc10b94d45d"}, + {"program": "tests/compiler/progs/ifchain.osc", "source_sha256": "89fd46fc610516121dbd38cca232a98abccb55abf1593409ca575ab7e293699e", "ir_sha256": "2323f2753d8e2eb269d65db1b8e9a6006b0e09ed98e0f3f74268143cf870342d", "code_sha256": "f7c3aa9e0ae96c5d1a1c0fbcb44b7504843aac8ed5035b2400d50819cc999e03"}, + {"program": "tests/compiler/progs/isort.osc", "source_sha256": "7dceeaf139addf172152b8861602d02d654e5d2f9fab451d2c38d823ddd1b7db", "ir_sha256": "fe5d0090baeb54d9afd33a9745b7a60136e513aaca0c03f5275d5efab4de3091", "code_sha256": "b99188f630088cd1c48b4e57d48431982eb3671c50fbe5ea42e17db680baf100"}, + {"program": "tests/compiler/progs/loopbound.osc", "source_sha256": "71def740b4af102745e954e5d06582cf28b5e90e633a254a3f248bd1ed8c10c3", "ir_sha256": "d5994fccb2c93ba53d8e3a73222aa54f28f2159509f992167c8e77e779734db2", "code_sha256": "e8b5a7ca1240adbcfc66c6e1e117b01ad692c4faed32381742e0ba9a7313bd83"}, + {"program": "tests/compiler/progs/minmax.osc", "source_sha256": "95c17e1cb5ffc836ef2bcf16ab39246b5c0bbb8acb1c05a6e08b838a12b60b7e", "ir_sha256": "a5ee50c4f631cfda3282c6a6a42842f20986ae4129fa4e22656ea836c8a01543", "code_sha256": "387756318095cc219eec337923bf12440927b254cac189872b17ea617f17ae41"}, + {"program": "tests/compiler/progs/nested.osc", "source_sha256": "8e9aaf037c142ea43dcc4e9013013688eb19f03f24a9e8511058623ced32dc35", "ir_sha256": "94e13f928a06a8d2ddff59030bb412cfcb5e4888570f9b7fc44786c135415c04", "code_sha256": "0eb5b788611a907d360730c08b78c6b0cfbf3a454323b42808f77f8aed300e71"}, + {"program": "tests/compiler/progs/oom.osc", "source_sha256": "1d82ff5262c21e4760b2404dc8fc649863a35ac4a164e4ae6684adcd7cecfc7e", "ir_sha256": "6ce4fcbb5b507668183dd67678a93dad7fe11d7b3f02c2466815712fb300116c", "code_sha256": "5c788e2eef2be25b04013f7bd8378d715756293c36f9509c14e9d5d465e5552a"}, + {"program": "tests/compiler/progs/ops.osc", "source_sha256": "2f68f1cf7d7d4569c90d79e4afc2bbdb9cf1bc2fc39cc8f8e23555c90cdd0223", "ir_sha256": "9742eb592d1cfcd72c622d2ab28fe1dd1fa921f14cd3418662f303be851e1162", "code_sha256": "0c038096a7f33e702937c2979eba15d6fc5a25dd66ba12c5b746df8529e7a959"}, + {"program": "tests/compiler/progs/popcount.osc", "source_sha256": "eab7407d3cfc923d15f52e04e00d96a9e7331b0e2496552b8258e7f88bc65236", "ir_sha256": "15aa9536feb7cbbe9cd03efcf2517321964bb479c0331f45610225c64af186ac", "code_sha256": "04510e1bf63889d5dd0bb7b85eeffb7b016ad87a65a7e0e2209df082f1a9d1db"}, + {"program": "tests/compiler/progs/prefix.osc", "source_sha256": "a4852da0953c8e11e5a9e51d00be81a6cc9e1f9e938cbd9d186f34ccb53cc524", "ir_sha256": "6feaa9af48e493a02a3de461aeae3b88b1c813c9011a462537e88c661704ee63", "code_sha256": "f4c78d8644d86ce7f1edd36ebd6958d5250a34dedde3435587e34dfb2d474362"}, + {"program": "tests/compiler/progs/reborrow.osc", "source_sha256": "caf5e895fcd0660d6ca7c6360228901cb4eee5a7afe128b59334aec904e63feb", "ir_sha256": "34086f590aeaec09669b9656cfca7db57beffb67a59d7e1ba22548336de146b2", "code_sha256": "a6a0a251ed5ddcbc431e38ed73602ee9202fd2d601bd7085ae70ccb5974daf62"}, + {"program": "tests/compiler/progs/scopes.osc", "source_sha256": "9904f63cb89734f2411f04b098640cb0ebe8069a49ae7b1a40c728d434770070", "ir_sha256": "81e996a3c8c6515d57375609aba9ae7c6c5822626b1a8da9cd0943b70db4a1ed", "code_sha256": "e3faba53225b4f3a9398b5d39f6a224b24df08cf9b6a67ca5652a439f0717127"}, + {"program": "tests/compiler/progs/shifts.osc", "source_sha256": "dd33980fb0f3b8d61477b6c197508e3c46d894c0ebc0f99244c01b5e86ee8780", "ir_sha256": "7d2e542f2241ccfacbd6a812c1671733dda94410ede4e3847b43c0955a6f69b3", "code_sha256": "c07f4547cac6e250b1c76021f0955fd530844fcc593a33192592ee0f917ecf59"}, + {"program": "tests/compiler/progs/shortcircuit.osc", "source_sha256": "c3f272b3f6b6d27c9cde9887197e73dd622ea30ff802fb87c250a5e2f704e1d0", "ir_sha256": "863365c4653fb44aac42316b1cde491107ad739d58b7af5b4b55e3a2774c5d41", "code_sha256": "bbd44412068130fdf65d66f718f74c6e0e7e36ee19282f19e5c2f3bbcf66ba2e"}, + {"program": "tests/compiler/progs/sixparams.osc", "source_sha256": "535fead297b7c4b7946c25b0b1f716634b4342701c3ff486dbd8189ed8bc3770", "ir_sha256": "176dee2ab6b66ff28dc04f095964c51f59dcda5518a9696a95a9c588dd78083e", "code_sha256": "c1e8cf802ef21c2b08b08dd266303c715e64ab7323cb5267fe2492de1e54cee8"}, + {"program": "tests/compiler/progs/structs_contracts.osc", "source_sha256": "06573d57946360c9e65090b61696a005ffe3fd3f3c1ca117765d9a3028a6f43a", "ir_sha256": "06b233f9e16e229fc606c8bda44b24e43473a2cd376053341e6ee644e124fe99", "code_sha256": "d52177fe222b3e548cc1df3bb294d524b41bcb093b64e8fc41f153094eacebf0"}, + {"program": "tests/compiler/progs/structs_dtor.osc", "source_sha256": "71f951fae6f1471dc52c5edb43abfa7b7692835e0d9fe8c63ae18a2e44e97ad5", "ir_sha256": "c7b4d22c623f0b1c4d004474c532ca74cbf23911cdcd299ad81843f4ef9a27df", "code_sha256": "3d73cda95a76bd70f7a5e4aa7673a360b2c40423381db88cabadd3bbfe363b0d"}, + {"program": "tests/compiler/progs/structs_fields.osc", "source_sha256": "4da454a3b5633ddec4f39f35c67236b26b87dde922d829ff5eb39df2195b5f2e", "ir_sha256": "865a9a09510cf16363e38345c47544ac1c9b48f7eddec67729f7e1ca40d03461", "code_sha256": "69be8bd0763aec308f5a002820ae496bc86dd1ac93111e532790dab27dd10586"}, + {"program": "tests/compiler/progs/structs_owner.osc", "source_sha256": "babf04cbcfbece1e1c4c4d23c59b97fb7644f639f77d987d6732c613313170cc", "ir_sha256": "11dd47aca0387de3b7fc3f546272b165c9f2d2675626dda03a255a4dd4942807", "code_sha256": "3e1df27680d16d47f1c2568d9e7f3f066ef29eb13e0faa89a16e12c182ec3da7"}, + {"program": "tests/compiler/progs/types.osc", "source_sha256": "ca4d49a4aca05b04e9935dd7cc560a023c4e4cffa36ff84c7755883a90c2b0d5", "ir_sha256": "f623556285814fbd02241fe4f24025bf93811581655beab6073e8d867b42b3a5", "code_sha256": "45c042eeb15cebf30615b7ad341b58a41bd805d83a08c358304b4284785eee35"} + ], + "m6_m9_m14_gates": {"m6": {"total": 10, "passed": 10, "failed": 0, "gate_log_sha256": "7fcc69abb701878b6a400b9ebdceb83bcb98496c8b884b01a2b7587d5bd8b178", "identical_to_osc2_baseline": true}, "m9": {"total": 10, "passed": 10, "failed": 0, "gate_log_sha256": "4d8a42eab694e06c2ee49accf9e7325a59912f80d74358bdabbfd57f2301f184", "identical_to_osc2_baseline": true}, "m14": {"total": 10, "passed": 10, "failed": 0, "gate_log_sha256": "5e96e93e2d5b381917fb145f1f6d4757f0fd311361d39bc6f24bb82ec8d17e35", "identical_to_osc2_baseline": true}}, + "self_host": "no: the OSC-3 compiler slice cannot compile any part of itself (docs/osc/OSC-1-SELF-HOST-STATEMENT.md)", + "timing_measured": "quick wall time only" +} From fcde19da8863213fbcd5650a64c467042574a9d3 Mon Sep 17 00:00:00 2001 From: Drake Stapleton Date: Thu, 1 Oct 2026 08:01:42 -0500 Subject: [PATCH 8/8] OSC-3 item 1: rebase on #154; compiler job runs quick+full on push to main via host-suites (drop redundant compiler-main.yml) Co-Authored-By: Drake Stapleton Co-Authored-By: Claude Fable 5.1 --- .github/workflows/compiler-main.yml | 26 -------------------------- docs/osc/OSC-3-DESIGN.md | 12 +++++++----- 2 files changed, 7 insertions(+), 31 deletions(-) delete mode 100644 .github/workflows/compiler-main.yml diff --git a/.github/workflows/compiler-main.yml b/.github/workflows/compiler-main.yml deleted file mode 100644 index 9b72a0612..000000000 --- a/.github/workflows/compiler-main.yml +++ /dev/null @@ -1,26 +0,0 @@ -name: Compiler on main -# OSC-3 (Lane 30): the `compiler` job in host-suites.yml runs on pull requests -# only. This workflow re-runs the OSC compiler suites after every merge to main -# that touches the compiler paths, so main has its own post-merge result. -# OSC-3 slice; not a general Omega compiler; no self-hosting. -on: - workflow_dispatch: - push: - branches: [main] - paths: - - 'src/compiler/**' - - 'tests/compiler/**' - - 'mk/compiler.mk' - - 'src/sha256.*' - - 'src/aarch64_*' - - '.github/workflows/compiler-main.yml' -jobs: - compiler-main: - runs-on: ubuntu-24.04-arm - timeout-minutes: 20 - steps: - - uses: actions/checkout@v4 - - name: OSC compiler quick suite - run: make PHYSICS_DIR=/nonexistent PHYSICS_LOCK_CHECK=0 test-compiler-quick - - name: OSC compiler full suite (plain + ASan/UBSan, legacy writer full differential) - run: make PHYSICS_DIR=/nonexistent PHYSICS_LOCK_CHECK=0 test-compiler-full diff --git a/docs/osc/OSC-3-DESIGN.md b/docs/osc/OSC-3-DESIGN.md index 19d62c24d..b8f194562 100644 --- a/docs/osc/OSC-3-DESIGN.md +++ b/docs/osc/OSC-3-DESIGN.md @@ -47,11 +47,13 @@ budget. It is split: The quick wall time is measured inside every OSC-3 receipt (`test_compiler_quick.wall_seconds`, binaries already built). -CI: the `compiler` job in `.github/workflows/host-suites.yml` runs on pull -requests (quick always on compiler paths, full when `src/compiler/` or -`src/aarch64_*` changes). `.github/workflows/compiler-main.yml` re-runs quick -and full on every push to main that touches the compiler paths (the 2026-10-01 -audit found the compiler suites never ran after merge). +CI: the `compiler` job in `.github/workflows/host-suites.yml` runs quick on +every pull request touching the compiler paths and full when `src/compiler/` +or `src/aarch64_*` changes. Since omega #154 (Lane 34) the workflow also runs +on every push to main, and the compiler job then runs quick and full, so main +has its own post-merge result (the 2026-10-01 audit found the compiler suites +never ran after merge). An earlier draft of this item added a separate +`compiler-main.yml` for this; it was dropped as redundant after #154. ## Generation width: remaining 32-bit sites and fix plan