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/mk/dual_jspace_tap.mk # 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 / mk / dual_jspace_tap.mk` 80 lines ยท 4596 bytes Raw Blame History 1 # DUAL-3a: read-only observation tap at decision site "jspace.residency" 2 # (ADR 0031 section 7.3; src/runtime/rx_jspace.c js_forge_enforce). 3 # Not part of `all` or `test`. Host only; no GPU. 4 # 5 # test-dual-jspace-tap parity suite, plain + ASan/UBSan builds 6 # test-dual-jspace-tap-hostile negative control: a hostile observer mutates the 7 # space through its ctx; the parity suite must FAIL 8 # dual-jspace-tap-purity nm -u on rx_jspace.o: no aienos_cap_*, rx_gen_*, aegis 9 # dual-jspace-tap-hygiene the hostile seam exists in tests only (grep src/) 10 # bench-dual-jspace-tap observer NULL vs recording observer vs the base 11 # commit's rx_jspace.c (DJT_BASE_SHA), same workload 12 # test-dual-3a purity + hygiene + parity + hostile 13 ifndef DUAL_JSPACE_TAP_MK 14 DUAL_JSPACE_TAP_MK := 1 15 .PHONY: test-dual-jspace-tap test-dual-jspace-tap-hostile dual-jspace-tap-purity \ 16 dual-jspace-tap-hygiene bench-dual-jspace-tap test-dual-3a 17 DJT_CFLAGS = -std=gnu11 -Wall -Wextra -Werror -D_GNU_SOURCE -O2 -Isrc -pthread 18 DJT_ASAN = -O1 -g -fsanitize=address,undefined -fno-sanitize-recover=all 19 DJT_DIR = $(OUT_DIR)/tests-dual-jspace-tap 20 DJT_BASE_SHA ?= `cb7cc216147664549484fcca8e8ceadbd6f6cdbf` 21 DJT_JSPACE = src/runtime/rx_jspace.c src/runtime/rx_jspace.h src/runtime/aien_machine_id.h src/sha256.h 22 DJT_TEST = tests/runtime/rx_dual_jspace_tap.c 23 DJT_BENCH = tests/runtime/rx_dual_jspace_tap_bench.c 24 25 # The parity test includes rx_jspace.c (reference oracle needs its statics). 26 $(DJT_DIR)/rx_dual_jspace_tap: $(DJT_TEST) $(DJT_JSPACE) src/omega_om_units.c 27 @mkdir -p $(DJT_DIR) 28 $(CC) $(DJT_CFLAGS) -o $@ $(DJT_TEST) src/omega_om_units.c -lm 29 $(DJT_DIR)/rx_dual_jspace_tap_asan: $(DJT_TEST) $(DJT_JSPACE) src/omega_om_units.c 30 @mkdir -p $(DJT_DIR) 31 $(CC) $(DJT_CFLAGS) $(DJT_ASAN) -o $@ $(DJT_TEST) src/omega_om_units.c -lm 32 $(DJT_DIR)/rx_dual_jspace_tap_hostile: $(DJT_TEST) $(DJT_JSPACE) src/omega_om_units.c 33 @mkdir -p $(DJT_DIR) 34 $(CC) $(DJT_CFLAGS) -DDUAL_TAP_HOSTILE_TEST -o $@ $(DJT_TEST) src/omega_om_units.c -lm 35 36 test-dual-jspace-tap: $(DJT_DIR)/rx_dual_jspace_tap $(DJT_DIR)/rx_dual_jspace_tap_asan 37 ./$(DJT_DIR)/rx_dual_jspace_tap 38 ./$(DJT_DIR)/rx_dual_jspace_tap_asan 39 @echo "test-dual-jspace-tap: parity with and without the observer, plain and ASan/UBSan" 40 41 test-dual-jspace-tap-hostile: $(DJT_DIR)/rx_dual_jspace_tap_hostile 42 @if ./$(DJT_DIR)/rx_dual_jspace_tap_hostile; then \ 43 echo "test-dual-jspace-tap-hostile: a hostile observer changed decisions and went UNDETECTED"; exit 1; fi 44 @echo "test-dual-jspace-tap-hostile: hostile observer detected (parity suite failed as required)" 45 46 $(DJT_DIR)/rx_jspace.o: $(DJT_JSPACE) 47 @mkdir -p $(DJT_DIR) 48 $(CC) $(DJT_CFLAGS) -c -o $@ src/runtime/rx_jspace.c 49 dual-jspace-tap-purity: $(DJT_DIR)/rx_jspace.o 50 @if nm -u $< | grep -E 'aienos_cap_|rx_gen_|aegis'; then \ 51 echo "rx_jspace.o references an authority or promotion symbol"; exit 1; fi 52 @echo "dual-jspace-tap-purity: rx_jspace.o references no aienos_cap_*, rx_gen_* or aegis symbol" 53 54 dual-jspace-tap-hygiene: 55 @if grep -rn 'DUAL_TAP_HOSTILE' src/ ; then \ 56 echo "the hostile test seam leaked into src/"; exit 1; fi 57 @echo "dual-jspace-tap-hygiene: DUAL_TAP_HOSTILE appears nowhere under src/" 58 59 # Benchmark: the base commit's rx_jspace.c/.h are extracted next to each other 60 # so its own #include "rx_jspace.h" resolves to the old header. 61 DJT_BASE_DIR = $(DJT_DIR)/base-$(DJT_BASE_SHA) 62 $(DJT_BASE_DIR)/rx_jspace.c: 63 @mkdir -p $(DJT_BASE_DIR) 64 git show $(DJT_BASE_SHA):src/runtime/rx_jspace.c > $@ 65 git show $(DJT_BASE_SHA):src/runtime/rx_jspace.h > $(DJT_BASE_DIR)/rx_jspace.h 66 git show $(DJT_BASE_SHA):src/runtime/aien_machine_id.h > $(DJT_BASE_DIR)/aien_machine_id.h 67 $(DJT_DIR)/rx_dual_jspace_tap_bench_base: $(DJT_BENCH) $(DJT_BASE_DIR)/rx_jspace.c src/omega_om_units.c 68 @mkdir -p $(DJT_DIR) 69 $(CC) $(DJT_CFLAGS) -DDUAL_TAP_BENCH_BASE -I$(DJT_BASE_DIR) -o $@ $(DJT_BENCH) $(DJT_BASE_DIR)/rx_jspace.c src/omega_om_units.c -lm 70 $(DJT_DIR)/rx_dual_jspace_tap_bench: $(DJT_BENCH) $(DJT_JSPACE) src/omega_om_units.c 71 @mkdir -p $(DJT_DIR) 72 $(CC) $(DJT_CFLAGS) -o $@ $(DJT_BENCH) src/runtime/rx_jspace.c src/omega_om_units.c -lm 73 74 bench-dual-jspace-tap: $(DJT_DIR)/rx_dual_jspace_tap_bench_base $(DJT_DIR)/rx_dual_jspace_tap_bench 75 ./$(DJT_DIR)/rx_dual_jspace_tap_bench_base 76 ./$(DJT_DIR)/rx_dual_jspace_tap_bench 77 78 test-dual-3a: dual-jspace-tap-purity dual-jspace-tap-hygiene test-dual-jspace-tap test-dual-jspace-tap-hostile 79 @echo "test-dual-3a: DUAL-3a tap implemented; DUAL_ADVISORY_SCHEDULER not claimed" 80 endif