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/omega-mv/blob/main/tests/arboris/host.sh # omega-mv Omega: a language for verified programs, semantic identity and machine realization. Seed-born work and existing implementations have distinct provenance. Brought by drakestapleton Sign in to star 1 stars 0 watching About Files History Releases Proposed changes Issues For developers branch `main` Branches Tags History `omega-mv / tests / arboris / host.sh` 134 lines ยท 8700 bytes Raw Blame History 1 #!/bin/sh 2 # SPDX-License-Identifier: AGPL-3.0-only 3 set -eu 4 out=${1:?supply the host build directory} 5 : "${OMC:?set OMC to the seeded compiler}" 6 dis=${NVDISASM:-/usr/local/cuda/bin/nvdisasm} 7 [ -x "$dis" ] || { echo "NOT_RUN: nvdisasm is required for SM121 parity"; exit 3; } 8 compile() { 9 dest=$1 10 shift 11 cat "$@" > "$out/unit.om" 12 sed 's/^export fn /fn /' "$out/unit.om" > "$out/program.om" 13 "$OMC" < "$out/program.om" > "$dest" 14 chmod +x "$dest" 15 } 16 printf 'om2\n' > "$out/signer-profile.om" 17 compile "$out/world-signer" "$out/signer-profile.om" om/tls/sha2.om \ 18 protocol/omnet/om/sha512/sha512.om protocol/omnet/om/`ed25519`/`ed25519`.om seed/authority/arboris-signer.om 19 sed '/^fn main to int/,$d' seed/authority/arboris-signer.om > "$out/signer-unit.om" 20 compile "$out/signer-ledger" "$out/signer-profile.om" om/tls/sha2.om \ 21 protocol/omnet/om/sha512/sha512.om protocol/omnet/om/`ed25519`/`ed25519`.om "$out/signer-unit.om" tests/arboris/signer-ledger.om 22 mkdir -p "$out/signer-ledger-fixture" 23 (cd "$out/signer-ledger-fixture" && ../signer-ledger) 24 grep -Fq "Arboris, Copyright 2026 Adam Pippert" NOTICE 25 compile "$out/arena" om/arboris_arena.om tests/arboris_arena_test.om 26 "$out/arena" 27 compile "$out/native-arena" om/arboris_arena.om gpu/nvidia/native/nvrm/context.om gpu/nvidia/native/share/share.om gpu/nvidia/native/arboris/arena.om tests/arboris/native-arena.om 28 "$out/native-arena" 29 sh tests/arboris/build-sparse-probe.sh "$out/sparse-packet" tests/arboris/sparse-packet.om 30 "$out/sparse-packet" 31 sh tests/arboris/build-sparse-probe.sh "$out/commit-packet" tests/arboris/commit-packet.om 32 "$out/commit-packet" 33 sh tests/arboris/build-sparse-probe.sh "$out/sparse-chip" 34 sh tests/arboris/build-sparse-probe.sh "$out/wave-chip" tests/arboris/sparse-silicon.om wave 35 sh tests/arboris/build-sparse-probe.sh "$out/small-chip" tests/arboris/sparse-silicon.om small 36 sh tests/arboris/build-sparse-probe.sh "$out/gated-chip" tests/arboris/gated-silicon.om 37 sh tests/arboris/build-sparse-probe.sh "$out/wide-chip" tests/arboris/gated-silicon.om wide 38 sh tests/arboris/build-sparse-probe.sh "$out/experimental-chip" tests/arboris/gated-silicon.om experimental 39 "$out/experimental-chip" reference > "$out/experimental-reference.log" 40 grep -qx "output_sha256=`c2437a10406d7aa8902c0a46eeca1b00413461689a8345cb0f62927d6b742fe5`" "$out/experimental-reference.log" 41 for model in persistent hubs even; do 42 sh tests/arboris/build-sparse-probe.sh "$out/$model-chip" tests/arboris/sparse-silicon.om "$model" 43 "$out/$model-chip" reference > "$out/$model-reference.log" 44 done 45 for model in small sparse wave; do 46 "$out/$model-chip" reference > "$out/$model-reference.log" 47 case "$model" in 48 small) expected=`33dfc6bc867a2bfbe09192038538c209c9b8bc89e16b6cedcaf0e7cf32b1a8f6` ;; 49 sparse) expected=`8ded4456ffe03d54cad43b7b7b8d07ff1997919c103dd1b49b61c6782d6e3d19` ;; 50 wave) expected=`b2d9f9458d97db2f5415078fbc43ad0256229175bbc28127eeaad941a708dc7a` ;; 51 esac 52 grep -qx "output_sha256=$expected" "$out/$model-reference.log" 53 done 54 "$out/gated-chip" reference > "$out/gated-reference.log" 55 "$out/wide-chip" reference > "$out/wide-reference.log" 56 grep -qx "output_sha256=`ca8052acb8c6306df043531ab6c116c5d8dd69a7e565974338088119f8355e34`" "$out/wide-reference.log" 57 compile "$out/spread" om/arboris_ontology.om om/tls/sha2.om om/arboris_records.om om/arboris_spread.om om/arboris_locality.om tests/arboris/locality.om tests/arboris_spread_test.om 58 "$out/spread" 59 compile "$out/gated" om/arboris_arena.om gpu/nvidia/om/numeric/numeric.om om/arboris_gated.om tests/arboris_gated_test.om 60 "$out/gated" 61 compile "$out/precision" om/arboris_arena.om gpu/nvidia/om/numeric/numeric.om om/arboris_gated.om om/arboris_gate_cubic.om om/arboris_q4.om tests/arboris/gate-precision.om 62 "$out/precision" > "$out/precision.metrics" 63 compile "$out/expert-hints" om/arboris_ontology.om om/tls/sha2.om om/arboris_records.om om/arboris_spread.om om/gpu/dsv41/arboris/prefetch.om tests/arboris/expert-hints.om 64 "$out/expert-hints" > "$out/expert-hints.bin" 65 compile "$out/hints-cli" "$out/signer-profile.om" om/gpu/dsv41/arboris/prefetch.om om/gpu/dsv41/arboris/hints-cli.om 66 # ARH1 frame with two votes for expert 12. Only one OP3 may be emitted. 67 printf 'ARH1\002\000\000\000\002\000\000\000\014\000\000\000\000\000\200\077\014\000\000\000\000\000\000\077' > "$out/frame" 68 printf '\003\000\000\000\014\000\000\000' > "$out/one-hint" 69 "$out/hints-cli" < "$out/frame" > "$out/frame-result" 70 cmp "$out/one-hint" "$out/frame-result" 71 printf 'x' >> "$out/frame" 72 if "$out/hints-cli" < "$out/frame" > "$out/frame-result"; then exit 1; fi 73 test ! -s "$out/frame-result" 74 compile "$out/online-core" "$out/signer-profile.om" om/arboris_online.om tests/arboris/online-core.om 75 "$out/online-core" 76 compile "$out/compute-lock" "$out/signer-profile.om" gpu/nvidia/native/arboris/compute-lock.om tests/arboris/compute-lock.om 77 "$out/compute-lock" 78 compile "$out/capq" om/runtime/rx_capq_core.om seed/authority/capq.om tests/arboris/capq.om 79 "$out/capq" 80 compile "$out/caproot-check" seed/authority/caproot.om tests/arboris/caproot-check.om 81 cc -O1 -c src/omega_om_units.c -o "$out/units.o" 82 cc -D_GNU_SOURCE -std=c11 -O2 -Wall -Wextra -Werror -Isrc tests/arboris/caproot_issuer.c src/runtime/rx_caproot.c "$out/units.o" -o "$out/caproot-issuer" 83 "$out/caproot-issuer" "$out/caproot-check" 84 compile "$out/wave-qmd" om/gpu/bw_qmd.om om/blackwell_arboris_qmd.om tests/arboris/wave-qmd.om 85 "$out/wave-qmd" 86 echo om2 > "$out/profile.om" 87 compile "$out/emit" "$out/profile.om" om/encoder/bw_enc_sm121.om om/blackwell_arboris_emit.om tests/arboris/emit-spread.om 88 compile "$out/emit-gated" "$out/profile.om" om/encoder/bw_enc_sm121.om om/blackwell_arboris_emit.om om/blackwell_arboris_gated_emit.om tests/arboris/emit-gated.om 89 "$out/emit-gated" > "$out/gated.sass" 90 echo "`66efbbc55e3e0434aa0e43416d25c22112c383a3f4c91da5337304d1fea85182` $out/gated.sass" | sha256sum -c - 91 grep -qx "output_sha256=`ad8a70b5e2935b7fca819ce4823afea8bef95c56135b6d86e7cf4ada6f16a089`" "$out/gated-reference.log" 92 "$dis" -b SM121 "$out/gated.sass" > "$out/gated.dis" 93 diff -u tests/arboris/gated-sm121.dis "$out/gated.dis" 94 "$out/emit" > "$out/wave.bin" 95 echo "`53058a3139706a7688ef68192a8bf8a679ef5dbad77cebc6c65b7081dfc7eb42` $out/wave.bin" | sha256sum -c - 96 "$dis" -b SM121 "$out/wave.bin" > "$out/wave.dis" 97 diff -u tests/arboris/spread-sm121.dis "$out/wave.dis" 98 "$out/emit" compound relax > "$out/relax.bin" 99 echo "`c9c1f2a6c5c7de7f8379d85d8bba1ad49e20479c76d0dde70b1fca1becfeba5b` $out/relax.bin" | sha256sum -c - 100 "$dis" -b SM121 "$out/relax.bin" > "$out/relax.dis" 101 diff -u tests/arboris/relax-sm121.dis "$out/relax.dis" 102 cc -std=c11 -O2 -Wall -Wextra -Werror -Isrc tests/arboris/scoreboard_oracle.c src/omega_bw_hazard.c "$out/units.o" -o "$out/check-wave" 103 "$out/check-wave" < "$out/wave.bin" 104 "$out/check-wave" < "$out/relax.bin" 105 "$out/check-wave" < "$out/gated.sass" 106 "$out/emit-gated" wide > "$out/wide.sass" 107 echo "`e1950992aaf3ba1a22562f68ddf2575d27dc39fc8e50f33e2683e0f2c6ed32af` $out/wide.sass" | sha256sum -c - 108 "$out/check-wave" < "$out/wide.sass" 109 for model in persistent hubs; do 110 compile "$out/emit-$model" om/arboris_arena.om om/encoder/bw_enc_sm121.om om/blackwell_arboris_emit.om om/blackwell_arboris_gated_emit.om "om/blackwell_arboris_$model.om" "tests/arboris/emit-$model.om" 111 "$out/emit-$model" > "$out/$model.bin" 112 "$dis" -b SM121 "$out/$model.bin" > "$out/$model.dis" 113 diff -u "tests/arboris/$model-sm121.dis" "$out/$model.dis" 114 "$out/check-wave" < "$out/$model.bin" 115 done 116 "$out/emit-persistent" even > "$out/even.bin" 117 "$out/check-wave" < "$out/even.bin" 118 grep -qx 'output_sha256=`48a04a4fc0bb0f8e14dca0855e21a1d239faec514a9e1d5c6696f273a798842d`' "$out/even-reference.log" 119 echo "`7b8e36a4edf2069a357419de0a61531387539c1a580d2726525568f073dcc489` $out/persistent.bin" | sha256sum -c - 120 echo "`62f2bd17c0c6d4f6460e2da38043642fe3a0d1023191c60ecdbcbd4cdcc435d3` $out/hubs.bin" | sha256sum -c - 121 "$out/emit-gated" wide experimental > "$out/experimental.sass" 122 echo "`1e263bde57f3dad20c9048c3b87b6097b4b681c9f727b22ffa100bc5470b306d` $out/experimental.sass" | sha256sum -c - 123 "$dis" -b SM121 "$out/experimental.sass" > "$out/experimental.dis" 124 diff -u tests/arboris/experimental-sm121.dis "$out/experimental.dis" 125 "$out/check-wave" < "$out/experimental.sass" 126 "$out/emit" compound relax small > "$out/small.bin" 127 "$out/check-wave" < "$out/small.bin" 128 "$out/emit" mutant > "$out/wave-mutant.bin" 129 if "$out/check-wave" < "$out/wave-mutant.bin" > "$out/negative.log"; then 130 echo "FAIL: scoreboard accepted a missing load wait" 131 exit 1 132 fi 133 grep -E 'reachable, [1-9][0-9]* hazards' "$out/negative.log" 134 echo "PASS Arboris CPU oracles, QMD packing, SM121 disassembly and OM/C scoreboards"