interplane.Get Omega
Read in your language

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

Comparing 43fd09c24a05e9970d0872ee69d21696812a810c ... 5a01c95e751c3896039e561038c4069a877f54a1

Showing the newest 250 commits.

2786 files changed, +863672 -2105

.gitattributes+2-0
.gitignore+3-0
AGENTS.md+5-1
CONTRIBUTORS.md+29-0
ENGINEERING-NOTES.md+1-1
FOLDERS.md+52-1
Makefile+64-21
README.md+19-2
aienux/NOT-YET-OMEGA-EXTRAS.tsv+67-0
aienux/NOT-YET-OMEGA.tsv+1900-0
aienux/README.md+50-0
aienux/UNITS.md+45-0
aienux/aegis/aegis.om+970-0
aienux/aegis/aegis_test.om+416-0
aienux/allen/application.om+241-0
aienux/allen/base.om+102-0
aienux/allen/code.om+264-0
aienux/allen/context.om+237-0
aienux/allen/courier.om+261-0
aienux/allen/demo.om+166-0
aienux/allen/efi-main.om+481-0
aienux/allen/font-data.om+4-0
aienux/allen/font.om+326-0
aienux/allen/github.om+1250-0
aienux/allen/http.om+495-0
aienux/allen/intent.om+292-0
aienux/allen/local-model.om+278-0
aienux/allen/look-chat.om+142-0
aienux/allen/look-home.om+1018-0
aienux/allen/look-install.om+158-0
aienux/allen/look-mind.om+1088-0
aienux/allen/look-night.om+965-0
aienux/allen/look-paint.om+755-0
aienux/allen/look-show.om+592-0
aienux/allen/look-sky.om+360-0
aienux/allen/look-skydata.om+124-0
aienux/allen/look-stat.om+215-0
aienux/allen/main.om+146-0
aienux/allen/memory.om+451-0
aienux/allen/net.om+1845-0
aienux/allen/paint.om+100-0
aienux/allen/platform.om+11-0
aienux/allen/presentation.om+156-0
aienux/allen/provider-core.om+256-0
aienux/allen/provider.om+70-0
aienux/allen/reply.om+175-0
aienux/allen/repository-screen.om+543-0
aienux/allen/runtime.om+145-0
aienux/allen/scene-input.om+319-0
aienux/allen/scene.om+340-0
aienux/allen/scheduler.om+229-0
aienux/allen/session.om+187-0
aienux/allen/surface.om+185-0
aienux/allen/target-x86efi.om+1-0
aienux/allen/tests/application.om+346-0
aienux/allen/tests/build-probe.om+3-0
aienux/allen/tests/check.om+17-0
aienux/allen/tests/code.om+58-0
aienux/allen/tests/context.om+359-0
aienux/allen/tests/courier.om+63-0
aienux/allen/tests/edges.om+157-0
aienux/allen/tests/fixture.om+67-0
aienux/allen/tests/font-mutants.om+101-0
aienux/allen/tests/font-output.om+83-0
aienux/allen/tests/font-render.om+79-0
aienux/allen/tests/font.om+114-0
aienux/allen/tests/github-fixtures.om+8-0
aienux/allen/tests/github.om+413-0
aienux/allen/tests/golden.om+16-0
aienux/allen/tests/http.om+105-0
aienux/allen/tests/https-live.om+186-0
aienux/allen/tests/intent.om+41-0
aienux/allen/tests/look-chat.om+313-0
aienux/allen/tests/look-home-dirty.om+151-0
aienux/allen/tests/look-home-stubs.om+14-0
aienux/allen/tests/look-home.om+197-0
aienux/allen/tests/look-mind.om+156-0
aienux/allen/tests/look-night.om+104-0
aienux/allen/tests/look-paint.om+243-0
aienux/allen/tests/look-sky.om+121-0
aienux/allen/tests/look-submit.om+108-0
aienux/allen/tests/memory.om+146-0
aienux/allen/tests/net.om+722-0
aienux/allen/tests/paint.om+16-0
aienux/allen/tests/presentation-mutants.om+101-0
aienux/allen/tests/presentation.om+238-0
aienux/allen/tests/probe.om+8-0
aienux/allen/tests/provider-core.om+306-0
aienux/allen/tests/provider-display-mutants.om+119-0
aienux/allen/tests/provider-input.om+144-0
aienux/allen/tests/provider-mutants.om+101-0
aienux/allen/tests/provider-output.om+104-0
aienux/allen/tests/provider-process.om+100-0
aienux/allen/tests/render.om+12-0
aienux/allen/tests/reply.om+47-0
aienux/allen/tests/runtime.om+57-0
aienux/allen/tests/scene-input.om+213-0
aienux/allen/tests/scene.om+23-0
aienux/allen/tests/scheduler.om+258-0
aienux/allen/tests/stdio-overflow.om+30-0
aienux/allen/tests/surface-mutants.om+101-0
aienux/allen/tests/surface-render.om+128-0
aienux/allen/tests/surface.om+309-0
aienux/allen/tests/tls-cert-ecdsa.om+363-0
aienux/allen/tests/tls-cert.om+338-0
aienux/allen/tests/tls-crypto-aead.om+179-0
aienux/allen/tests/tls-crypto-fixture.om+82-0
aienux/allen/tests/tls-crypto-poly.om+133-0
aienux/allen/tests/tls-crypto-sha.om+158-0
aienux/allen/tests/tls-crypto-x25519-iter.om+24-0
aienux/allen/tests/tls-crypto-x25519.om+106-0
aienux/allen/tests/tls-session-records.om+256-0
aienux/allen/tests/tls-session-schedule.om+128-0
aienux/allen/tests/view.om+25-0
aienux/allen/tls-cert.om+1299-0
aienux/allen/tls-crypto.om+628-0
aienux/allen/tls-p384.om+471-0
aienux/allen/tls.om+1303-0
aienux/allen/vendor/cert-p256.om+447-0
aienux/allen/vendor/cert-root.om+9-0
aienux/allen/vendor/cert-sha384.om+333-0
aienux/allen/vendor/sha256-core.om+179-0
aienux/allen/vendor/sha256.om+213-0
aienux/allen/view.om+98-0
aienux/argus/contain.om+574-0
aienux/argus/event.om+579-0
aienux/argus/ring.om+202-0
aienux/argus/test.om+884-0
aienux/atlas/lib.om+617-0
aienux/atlas/main.om+471-0
aienux/atlas/test.om+464-0
aienux/capability/lib.om+934-0
aienux/capability/test.om+863-0
aienux/connector/gates/celldrv.om+41-0
aienux/connector/gates/hostile/env.om+20-0
aienux/connector/gates/hostile/exit125.om+6-0
aienux/connector/gates/hostile/fork.om+24-0
aienux/connector/gates/hostile/gpu.om+13-0
aienux/connector/gates/hostile/hello.om+6-0
aienux/connector/gates/hostile/memhog.om+97-0
aienux/connector/gates/hostile/net.om+44-0
aienux/connector/gates/hostile/passwd.om+16-0
aienux/connector/gates/hostile/spin.om+8-0
aienux/connector/gates/hostile/writer.om+24-0
aienux/connector/gates/signer.om+104-0
aienux/connector/runner/00base.om+479-0
aienux/connector/runner/10key.om+162-0
aienux/connector/runner/20net.om+384-0
aienux/connector/runner/30cell.om+369-0
aienux/connector/runner/40job.om+333-0
aienux/connector/runner/50cmd.om+754-0
aienux/connector/runner/joingen.om+63-0
aienux/debugger/lib.om+1153-0
aienux/debugger/main.om+225-0
aienux/debugger/test.om+436-0
aienux/disk/ext4_ro.om+697-0
aienux/disk/gpt_ro.om+376-0
aienux/disk/nvme_bare_a64efi.om+72-0
aienux/disk/nvme_ro_bare.om+459-0
aienux/disk/omega_nvme.om+345-0
aienux/disk/omega_nvme_main.om+28-0
aienux/disk/omega_nvme_transport.om+118-0
aienux/disk/pack_bundle.om+191-0
aienux/disk/sha256_bare.om+216-0
aienux/disk/tests/omega_nvme_adminwrap.om+26-0
aienux/disk/tests/omega_nvme_failstop.om+23-0
aienux/disk/tests/omega_nvme_probe.om+17-0
aienux/disk/tests/run_slice_d.sh+353-0
aienux/disk/tests/test_gpt_ext4_ro.om+269-0
aienux/disk/tests/test_nvme_ro_bare.om+415-0
aienux/import/rtl8127-omega/README.md+11-0
aienux/import/rtl8127-omega/commit-map+6-0
aienux/import/rtl8127-omega/filter-repo-command.txt+1-0
aienux/import/rtl8127-omega/filter-repo.version+1-0
aienux/import/rtl8127-omega/paths.txt+2-0
aienux/import/rtl8127-omega/ref-map+2-0
aienux/import/spark-connector/README.md+11-0
aienux/import/spark-connector/commit-map+21-0
aienux/import/spark-connector/filter-repo-command.txt+1-0
aienux/import/spark-connector/filter-repo.version+1-0
aienux/import/spark-connector/paths.txt+2-0
aienux/import/spark-connector/ref-map+2-0
aienux/import/spark-supervisor/README.md+11-0
aienux/import/spark-supervisor/commit-map+24-0
aienux/import/spark-supervisor/filter-repo-command.txt+1-0
aienux/import/spark-supervisor/filter-repo.version+1-0
aienux/import/spark-supervisor/paths.txt+2-0
aienux/import/spark-supervisor/ref-map+2-0
aienux/import/step1-om/README.md+24-0
aienux/import/step1-om/commit-map+702-0
aienux/import/step1-om/filter-repo-command.txt+1-0
aienux/import/step1-om/filter-repo.version+1-0
aienux/import/step1-om/paths.txt+16-0
aienux/import/step1-om/ref-map+4-0
aienux/kernel/arm64/acpi.om+263-0
aienux/kernel/arm64/efi_boot.om+223-0
aienux/kernel/arm64/frames.om+284-0
aienux/kernel/arm64/fwops.om+280-0
aienux/kernel/arm64/gicv3.om+450-0
aienux/kernel/arm64/host_test.om+269-0
aienux/kernel/arm64/mmu.om+492-0
aienux/kernel/arm64/smp.om+154-0
aienux/kernel/arm64/uart.om+124-0
aienux/kernel/core/ipc.om+269-0
aienux/kernel/core/pagetable.om+397-0
aienux/kernel/core/scheduler.om+389-0
aienux/kernel/core/test.om+677-0
aienux/kernel/hal/bar0_mmio.om+380-0
aienux/kernel/hal/hal_test.om+747-0
aienux/kernel/hal/iort.om+732-0
aienux/kernel/hal/nvme_store_gate.om+530-0
aienux/kernel/hal/pcie.om+542-0
aienux/kernel/hal/pcie_smmu_test.om+739-0
aienux/kernel/hal/run_smmu_qemu.sh+54-0
aienux/kernel/hal/smmu_qemu_test.om+529-0
aienux/kernel/hal/smmuv3.om+1158-0
aienux/kernel/x86/model/llama.om+355-0
aienux/kernel/x86/tools/arithmetic.om+31-0
aienux/kernel/x86/tools/system.om+11-0
aienux/kernel/x86/tools/text.om+29-0
aienux/lm1b/lm1b.in.om+1429-0
aienux/lm1b/lm1b.om+2872-0
aienux/lm1b/sha256.om+159-0
aienux/net/rtl8127/cmd/rtl8127d/probe.om+103-0
aienux/net/rtl8127/om/rtl8127/bare_a64efi.om+134-0
aienux/net/rtl8127/om/rtl8127/hw.om+35-0
aienux/net/rtl8127/om/rtl8127/model.om+381-0
aienux/net/rtl8127/om/rtl8127/rtl8127.om+703-0
aienux/net/rtl8127/om/rtl8127/tcp_glue.om+69-0
aienux/net/rtl8127/om/rtl8127/test/driver.om+339-0
aienux/net/rtl8127/om/rtl8127/test/test_rtl8127_nc_dma.om+168-0
aienux/net/rtl8127/om/rtl8127/test/test_tcp_glue.om+212-0
aienux/net/tcp/corpus.om+665-0
aienux/net/tcp/link.om+505-0
aienux/net/tcp/peer.om+299-0
aienux/net/tcp/tcp.om+1364-0
aienux/net/tcp/tcpd.om+472-0
aienux/net/wire/omtk.om+273-0
aienux/net/wire/test_loopback.om+932-0
aienux/net/wire/wire_loop.om+800-0
aienux/pi-register/lib.om+1464-0
aienux/pi-register/main.om+247-0
aienux/pi-register/test.om+304-0
aienux/platform/readback.om+110-0
aienux/platform/unit.om+88-0
aienux/spark/build_spark_efi.sh+165-0
aienux/spark/mk_qemu_disk.py+87-0
aienux/spark/plat_gb10.om+32-0
aienux/spark/plat_qemu.om+38-0
aienux/spark/run_phase3_gate.sh+216-0
aienux/spark/run_spark_qemu_e2e.sh+76-0
aienux/spark/spark_main.om+1536-0
aienux/spark/test_spark_e2e.om+1044-0
aienux/supervisor/om/contract.om+64-0
aienux/supervisor/om/lib.om+854-0
aienux/supervisor/om/limited.om+459-0
aienux/supervisor/om/limits.om+264-0
aienux/supervisor/om/root.om+2519-0
aienux/supervisor/om/services.om+404-0
aienux/supervisor/om/supervise.om+1935-0
aienux/supervisor/om/syscalls.om+7-0
aienux/supervisor/om/watch.om+284-0
aienux/supervisor/tests/load.om+77-0
aienux/tools/hwgates/hwgates.om+707-0
aienux/tools/imac-image/imac-image.om+605-0
aienux/tools/spark-image/spark-image.om+613-0
aienux/units-gate.om+1054-0
aienux/units-run.tsv+12-0
aienux/units.tsv+92-0
apps/NOT-YET-OMEGA.tsv+1979-0
apps/README.md+37-0
apps/UNITS.md+15-0
apps/aienos-site/om/agora-page/agora-js.om+51-0
apps/aienos-site/om/agora-page/agora.om+21-0
apps/aienos-site/om/agora-page/aienet.om+45-0
apps/aienos-site/om/agora-page/contract.om+71-0
apps/aienos-site/om/agora/agora-edge.om+772-0
apps/aienos-site/om/agora/agora-sync.om+1388-0
apps/aienos-site/om/agora/agora.om+4419-0
apps/aienos-site/om/agora/aien-agora.om+980-0
apps/aienos-site/om/agora/client.om+561-0
apps/aienos-site/om/agora/fake-upstream.om+125-0
apps/aienos-site/om/agora/http.om+2463-0
apps/aienos-site/om/agora/json.om+1247-0
apps/aienos-site/om/agora/jsonw.om+671-0
apps/aienos-site/om/agora/observer-check.om+776-0
apps/aienos-site/om/agora/policy-check.om+215-0
apps/aienos-site/om/agora/policy.om+152-0
apps/aienos-site/om/agora/reload-check.om+646-0
apps/aienos-site/om/agora/sha256.om+343-0
apps/aienos-site/om/agora/sha2h.om+8-0
apps/aienos-site/om/agora/startup-check.om+139-0
apps/aienos-site/om/agora/test/fake-peer.om+112-0
apps/aienos-site/om/agora/test/https-probe.om+82-0
apps/aienos-site/om/agora/test/pow.om+102-0
apps/aienos-site/om/agora/tls/aesgcm.om+761-0
apps/aienos-site/om/agora/tls/chacha.om+443-0
apps/aienos-site/om/agora/tls/ec.om+685-0
apps/aienos-site/om/agora/tls/hkdf.om+170-0
apps/aienos-site/om/agora/tls/rsa.om+642-0
apps/aienos-site/om/agora/tls/sha2.om+592-0
apps/aienos-site/om/agora/tls/tls.om+2261-0
apps/aienos-site/om/agora/tls/x25519.om+332-0
apps/aienos-site/om/agora/tls/x509.om+2077-0
apps/aienos-site/om/aien-universe/universe.om+125-0
apps/aienos-site/om/allen-audio/asset.om+31-0
apps/aienos-site/om/allen-audio/chirp.om+272-0
apps/aienos-site/om/allen-audio/native.om+22-0
apps/aienos-site/om/allen-page/allen-js.om+690-0
apps/aienos-site/om/allen-page/allen.om+124-0
apps/aienos-site/om/allen-page/contract.om+86-0
apps/aienos-site/om/allen-page/speed-js.om+226-0
apps/aienos-site/om/allen-panes/contract.om+54-0
apps/aienos-site/om/allen-panes/panes.om+326-0
apps/aienos-site/om/allen-scene/scene.om+1116-0
apps/aienos-site/om/alpha-page/client.om+13-0
apps/aienos-site/om/alpha-page/page.om+147-0
apps/aienos-site/om/hive-page/contract.om+70-0
apps/aienos-site/om/hive-page/fresh.om+18-0
apps/aienos-site/om/hive-page/freshness-js.om+7-0
apps/aienos-site/om/hive-page/hive-js.om+71-0
apps/aienos-site/om/hive-page/hive.om+789-0
apps/aienos-site/om/hive-page/turing-look.om+57-0
apps/aienos-site/om/hive-render/render.om+1962-0
apps/aienos-site/om/lab-page/axpy.om+15-0
apps/aienos-site/om/lab-page/client.om+31-0
apps/aienos-site/om/lab-page/harness.om+67-0
apps/aienos-site/om/lab-page/lab.om+159-0
apps/aienos-site/om/omega-reference/page.om+887-0
apps/aienos-site/om/omega-reference/vendor/examples/arrays.om+55-0
apps/aienos-site/om/omega-reference/vendor/examples/checked_conv.om+51-0
apps/aienos-site/om/omega-reference/vendor/examples/consts.om+58-0
apps/aienos-site/om/omega-reference/vendor/examples/contract_ensures.om+13-0
apps/aienos-site/om/omega-reference/vendor/examples/contract_invariant.om+12-0
apps/aienos-site/om/omega-reference/vendor/examples/contract_release.om+9-0
apps/aienos-site/om/omega-reference/vendor/examples/contract_requires.om+12-0
apps/aienos-site/om/omega-reference/vendor/examples/contracts_ok.om+15-0
apps/aienos-site/om/omega-reference/vendor/examples/defect_keyword_prefix.om+9-0
apps/aienos-site/om/omega-reference/vendor/examples/echo_args.om+72-0
apps/aienos-site/om/omega-reference/vendor/examples/empty_text_part.om+19-0
apps/aienos-site/om/omega-reference/vendor/examples/env_read.om+67-0
apps/aienos-site/om/omega-reference/vendor/examples/err01_input.om+4-0
apps/aienos-site/om/omega-reference/vendor/examples/err02_output.om+4-0
apps/aienos-site/om/omega-reference/vendor/examples/err03_unknown_name.om+4-0
apps/aienos-site/om/omega-reference/vendor/examples/err04_line_ends.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/err05_extra_words.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/err06_bad_number.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/err07_type_mismatch.om+6-0
apps/aienos-site/om/omega-reference/vendor/examples/err08_out_of_range.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/err09_disallowed.om+7-0
apps/aienos-site/om/omega-reference/vendor/examples/err10_duplicate.om+7-0
apps/aienos-site/om/omega-reference/vendor/examples/err11_ambiguous.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/err12_registers.om+21-0
apps/aienos-site/om/omega-reference/vendor/examples/err13_long_name.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/err14_capacity.om+101-0
apps/aienos-site/om/omega-reference/vendor/examples/err15_missing_end.om+3-0
apps/aienos-site/om/omega-reference/vendor/examples/err16_syntax.om+4-0
apps/aienos-site/om/omega-reference/vendor/examples/err17_after_path.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/err18_missing_ret.om+9-0
apps/aienos-site/om/omega-reference/vendor/examples/err19_global_arg.om+9-0
apps/aienos-site/om/omega-reference/vendor/examples/err20_readonly.om+6-0
apps/aienos-site/om/omega-reference/vendor/examples/err21_const_index.om+6-0
apps/aienos-site/om/omega-reference/vendor/examples/err22_text_escape.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/err23_size.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/err27_fresh.om+9-0
apps/aienos-site/om/omega-reference/vendor/examples/err28_seal.om+8-0
apps/aienos-site/om/omega-reference/vendor/examples/err29_layout.om+8-0
apps/aienos-site/om/omega-reference/vendor/examples/err30_contract.om+12-0
apps/aienos-site/om/omega-reference/vendor/examples/exit_status.om+4-0
apps/aienos-site/om/omega-reference/vendor/examples/float_arith.om+63-0
apps/aienos-site/om/omega-reference/vendor/examples/float_to_int.om+51-0
apps/aienos-site/om/omega-reference/vendor/examples/functions.om+66-0
apps/aienos-site/om/omega-reference/vendor/examples/globals.om+63-0
apps/aienos-site/om/omega-reference/vendor/examples/hello.om+9-0
apps/aienos-site/om/omega-reference/vendor/examples/int_arith.om+53-0
apps/aienos-site/om/omega-reference/vendor/examples/int_bits_and.om+10-0
apps/aienos-site/om/omega-reference/vendor/examples/loops.om+70-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_bound_range.om+8-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_c_call.om+7-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_char_literal.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_compare_operator.om+8-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_else_if.om+10-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_for_bound.om+9-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_free.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_infix.om+6-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_main_args.om+4-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_neg_name.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_new_var_len.om+6-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_om1_rotr.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_om2_int_hex.om+6-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_om2_param_slots.om+9-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_om2_part_global.om+9-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_om2_part_sized.om+9-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_om2_part_statement.om+7-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_om2_upper_hex.om+6-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_param_length.om+8-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_reserved_name.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_return.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_semicolon.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_seven_params.om+7-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_short_circuit.om+10-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_slash_comment.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_struct_after_fn.om+5-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_trap_range.om+4-0
apps/aienos-site/om/omega-reference/vendor/examples/mistake_value_stmt.om+8-0
apps/aienos-site/om/omega-reference/vendor/examples/om2_hex_rotr.om+40-0
apps/aienos-site/om/omega-reference/vendor/examples/om2_param_slots.om+24-0
apps/aienos-site/om/omega-reference/vendor/examples/om2_part_trap.om+17-0
apps/aienos-site/om/omega-reference/vendor/examples/om2_tour.om+43-0
apps/aienos-site/om/omega-reference/vendor/examples/om2_views.om+53-0
apps/aienos-site/om/omega-reference/vendor/examples/print_decimal.om+50-0
apps/aienos-site/om/omega-reference/vendor/examples/stdin_count.om+71-0
apps/aienos-site/om/omega-reference/vendor/examples/structs.om+59-0
apps/aienos-site/om/omega-reference/vendor/examples/text.om+48-0
apps/aienos-site/om/omega-reference/vendor/examples/tmp_files.om+81-0
apps/aienos-site/om/omega-reference/vendor/examples/trap1_overflow.om+8-0
apps/aienos-site/om/omega-reference/vendor/examples/trap2_div0.om+8-0
apps/aienos-site/om/omega-reference/vendor/examples/trap3_bounds.om+9-0
apps/aienos-site/om/omega-reference/vendor/examples/trap4_loop.om+10-0
apps/aienos-site/om/omega-reference/vendor/examples/trap5_conv.om+8-0
apps/aienos-site/om/omega-reference/vendor/examples/trap6_stack.om+13-0
apps/aienos-site/om/omega-reference/vendor/examples/trap7_shift.om+8-0
apps/aienos-site/om/omega-reference/vendor/examples/trap_code.om+6-0
apps/aienos-site/om/omega-reference/vendor/examples/unsigned_wrap.om+56-0
apps/aienos-site/om/omega-reference/vendor/examples/wire_le.om+68-0
apps/aienos-site/om/omega-reference/vendor/skills/omega-encoding/examples/fnv1a32.om+55-0
apps/aienos-site/om/omega-reference/vendor/skills/omega-encoding/examples/trap_narrow.om+9-0
apps/aienos-site/om/site/agora-pages.om+49-0
apps/aienos-site/om/site/build.om+212-0
apps/aienos-site/om/site/chrome.om+327-0
apps/aienos-site/om/site/client.om+12-0
apps/aienos-site/om/site/copy.om+181-0
apps/aienos-site/om/site/csp.om+264-0
apps/aienos-site/om/site/css.om+81-0
apps/aienos-site/om/site/discovery.om+1351-0
apps/aienos-site/om/site/door.om+11-0
apps/aienos-site/om/site/engineer.om+385-0
apps/aienos-site/om/site/floor.om+48-0
apps/aienos-site/om/site/forge.om+16-0
apps/aienos-site/om/site/freshness.om+60-0
apps/aienos-site/om/site/inventory.om+237-0
apps/aienos-site/om/site/json.om+698-0
apps/aienos-site/om/site/learn.om+20-0
apps/aienos-site/om/site/ledger.om+6248-0
apps/aienos-site/om/site/legacy-assets.om+85-0
apps/aienos-site/om/site/links.om+242-0
apps/aienos-site/om/site/machine.om+1741-0
apps/aienos-site/om/site/markdown.om+590-0
apps/aienos-site/om/site/people.om+463-0
apps/aienos-site/om/site/registry.om+125-0
apps/aienos-site/om/site/repos.om+552-0
apps/aienos-site/om/site/route-assets.om+134-0
apps/aienos-site/om/site/runtime.om+510-0
apps/aienos-site/om/site/seo-graph.om+245-0
apps/aienos-site/om/site/seo.om+419-0
apps/aienos-site/om/site/site-names.om+174-0
apps/aienos-site/om/site/site.om+445-0
apps/aienos-site/om/site/verify-core.om+1007-0
apps/aienos-site/om/site/verify-data.om+1474-0
apps/aienos-site/om/site/verify-data2.om+1450-0
apps/aienos-site/om/site/verify-seo.om+2103-0
apps/aienos-site/om/site/verify-site.om+947-0
apps/aienos-site/om/site/verify-text.om+636-0
apps/aienos-site/om/site/verify-unicode.om+13-0
apps/aienos-site/om/site/verify.om+68-0
apps/aienos-site/om/still-building-page/still.om+44-0
apps/aienos-site/om/support-page/support.om+20-0
apps/aienos-site/public/allen/scene.om+1116-0
apps/aienos-site/public/alpha/wizard.om+4894-0
apps/aienos-site/scripts/allen/contacts/allen_contacts_ingest.om+1738-0
apps/aienos-site/scripts/allen/science/math-admit.om+234-0
apps/aienos-site/scripts/allen/science/pane-contract.om+54-0
apps/core/site_forge.om+297-0
apps/core/test.om+223-0
apps/edge/lib.om+964-0
apps/edge/main.om+43-0
apps/edge/test.om+364-0
apps/hop/Linux/apps.om+949-0
apps/hop/Linux/build.om+608-0
apps/hop/Linux/chat.om+843-0
apps/hop/Linux/core.om+197-0
apps/hop/Linux/files.om+1714-0
apps/hop/Linux/install.om+949-0
apps/hop/Linux/main.om+205-0
apps/hop/Linux/window.om+948-0
apps/hop/Omega/hopcore.om+5040-0
apps/hop/Omega/hopfact.om+485-0
apps/hop/Omega/hopfuse.om+645-0
apps/hop/Omega/tests/mutant-fuse/mut.om+645-0
apps/hop/Omega/tests/mutant/hopcore-addr.om+5040-0
apps/hop/Omega/tests/mutant/hopcore-asm.om+5040-0
apps/hop/Omega/tests/mutant/hopcore-board.om+5040-0
apps/hop/Omega/tests/mutant/hopcore-gcm.om+5040-0
apps/hop/Omega/tests/mutant/hopcore-lifts.om+5040-0
apps/hop/Omega/tests/mutant/hopcore-names.om+5040-0
apps/hop/Omega/tests/mutant/hopcore-paths.om+5040-0
apps/hop/Omega/tests/mutant/hopcore-rank.om+5040-0
apps/hop/Omega/tests/mutant/hopcore-spans.om+5040-0
apps/hop/Omega/tests/mutant/hopcore-status.om+5040-0
apps/hop/Omega/tests/mutant/hopcore-suggest.om+5040-0
apps/hop/Omega/tests/mutant/hopcore-text.om+5040-0
apps/hop/Omega/tests/mutant/hopcore-words.om+5040-0
apps/hop/Omega/tests/mutant/hoppanel-deaf.om+13093-0
apps/hop/Omega/tests/mutant/mut.om+485-0
apps/hop/Omega/ui/hoppanel.om+8126-0
apps/import/aienos.com/README.md+11-0
apps/import/aienos.com/commit-map+677-0
apps/import/aienos.com/filter-repo-command.txt+1-0
apps/import/aienos.com/filter-repo.version+1-0
apps/import/aienos.com/paths.txt+2-0
apps/import/aienos.com/ref-map+3-0
apps/import/hop/README.md+11-0
apps/import/hop/commit-map+145-0
apps/import/hop/filter-repo-command.txt+1-0
apps/import/hop/filter-repo.version+1-0
apps/import/hop/paths.txt+2-0
apps/import/hop/ref-map+9-0
apps/import/interplane-forge/README.md+11-0
apps/import/interplane-forge/commit-map+414-0
apps/import/interplane-forge/filter-repo-command.txt+1-0
apps/import/interplane-forge/filter-repo.version+1-0
apps/import/interplane-forge/paths.txt+2-0
apps/import/interplane-forge/ref-map+4-0
apps/import/interplane.io/README.md+11-0
apps/import/interplane.io/commit-map+154-0
apps/import/interplane.io/filter-repo-command.txt+1-0
apps/import/interplane.io/filter-repo.version+1-0
apps/import/interplane.io/paths.txt+2-0
apps/import/interplane.io/ref-map+2-0
apps/import/omtex/README.md+11-0
apps/import/omtex/commit-map+6-0
apps/import/omtex/filter-repo-command.txt+1-0
apps/import/omtex/filter-repo.version+1-0
apps/import/omtex/paths.txt+2-0
apps/import/omtex/ref-map+2-0
apps/interplane-forge/browse/a_core.om+625-0
apps/interplane-forge/browse/b_md.om+2110-0
apps/interplane-forge/browse/c1_page.om+1234-0
apps/interplane-forge/browse/c2_hist.om+1210-0
apps/interplane-forge/browse/c3_blame.om+396-0
apps/interplane-forge/browse/d_route.om+147-0
apps/interplane-forge/browse/e1_json.om+916-0
apps/interplane-forge/browse/e2_json.om+970-0
apps/interplane-forge/browse/tests/mdmain.om+34-0
apps/interplane-forge/browse/tests/stubutil.om+640-0
apps/interplane-forge/browse/tests/title.om+73-0
apps/interplane-forge/chain/chain.om+1289-0
apps/interplane-forge/collab/co0form.om+205-0
apps/interplane-forge/collab/co1json.om+350-0
apps/interplane-forge/collab/co2cob.om+1956-0
apps/interplane-forge/collab/co3view.om+544-0
apps/interplane-forge/collab/co4pat.om+874-0
apps/interplane-forge/collab/co5iss.om+369-0
apps/interplane-forge/collab/co6route.om+180-0
apps/interplane-forge/collab/co7md.om+40-0
apps/interplane-forge/collab/co8cache.om+195-0
apps/interplane-forge/collab/co9comp.om+138-0
apps/interplane-forge/collab/co9form.om+493-0
apps/interplane-forge/collab/co9page.om+225-0
apps/interplane-forge/collab/coJjson.om+755-0
apps/interplane-forge/collab/native/helpers.om+256-0
apps/interplane-forge/collab/native/issue.om+878-0
apps/interplane-forge/collab/native/json.om+447-0
apps/interplane-forge/collab/native/route.om+84-0
apps/interplane-forge/collab/native/write.om+841-0
apps/interplane-forge/community/00core.om+588-0
apps/interplane-forge/community/10msg.om+697-0
apps/interplane-forge/community/20api.om+380-0
apps/interplane-forge/community/30page.om+773-0
apps/interplane-forge/community/40route.om+226-0
apps/interplane-forge/community/tests/seed.om+160-0
apps/interplane-forge/contrib/forge-contribute.om+808-0
apps/interplane-forge/dl/dl.om+2127-0
apps/interplane-forge/dl/dlclone.om+31-0
apps/interplane-forge/dl/dljson.om+331-0
apps/interplane-forge/dl/tests/fstub.om+490-0
apps/interplane-forge/dl/tests/tmain.om+352-0
apps/interplane-forge/door/ev1decl.om+497-0
apps/interplane-forge/door/ev2log.om+416-0
apps/interplane-forge/door/ev3col.om+1029-0
apps/interplane-forge/door/ev4json.om+565-0
apps/interplane-forge/door/ev5feed.om+298-0
apps/interplane-forge/galaxy/cli.om+42-0
apps/interplane-forge/galaxy/live.om+636-0
apps/interplane-forge/galaxy/page.om+713-0
apps/interplane-forge/galaxy/stars.om+557-0
apps/interplane-forge/growth/g1prep.om+781-0
apps/interplane-forge/growth/g2page.om+1266-0
apps/interplane-forge/infra/spark/forged-listen.om+105-0
apps/interplane-forge/infra/spark/forged-seccomp.om+140-0
apps/interplane-forge/infra/spark/public-read.om+120-0
apps/interplane-forge/infra/test/envprobe.om+168-0
apps/interplane-forge/infra/test/hog.om+116-0
apps/interplane-forge/infra/test/netprobe.om+186-0
apps/interplane-forge/ipl/om/landrec.om+466-0
apps/interplane-forge/nodes/head.om+81-0
apps/interplane-forge/nodes/snap.om+626-0
apps/interplane-forge/nodes/srch.om+123-0
apps/interplane-forge/nodes/stat.om+406-0
apps/interplane-forge/open/intake.om+4780-0
apps/interplane-forge/open/route.om+2639-0
apps/interplane-forge/patch/p1decl.om+482-0
apps/interplane-forge/patch/p2base.om+522-0
apps/interplane-forge/patch/p2utf8.om+79-0
apps/interplane-forge/patch/p3gate.om+401-0
apps/interplane-forge/patch/p4take.om+1179-0
apps/interplane-forge/patch/p5imp.om+1281-0
apps/interplane-forge/patch/p5page.om+614-0
apps/interplane-forge/patch/p6json.om+637-0
apps/interplane-forge/patch/p7route.om+133-0
apps/interplane-forge/quiet/qn1dig.om+428-0
apps/interplane-forge/quiet/qn2bind.om+393-0
apps/interplane-forge/quiet/qn3http.om+701-0
apps/interplane-forge/research/agent.om+1326-0
apps/interplane-forge/research/build.om+2476-0
apps/interplane-forge/research/intake-route.om+292-0
apps/interplane-forge/research/lib/jflat.om+606-0
apps/interplane-forge/research/noadd.om+4-0
apps/interplane-forge/research/route.om+508-0
apps/interplane-forge/research/sync.om+3656-0
apps/interplane-forge/salvage/00core.om+700-0
apps/interplane-forge/salvage/10verify.om+669-0
apps/interplane-forge/salvage/15bundle.om+89-0
apps/interplane-forge/salvage/20web.om+964-0
apps/interplane-forge/salvage/collector.om+98-0
apps/interplane-forge/salvage/replay.om+99-0
apps/interplane-forge/salvage/tests/journey.om+200-0
apps/interplane-forge/salvage/tests/limits.om+72-0
apps/interplane-forge/salvage/tests/store.om+86-0
apps/interplane-forge/salvage/tests/verify.om+82-0
apps/interplane-forge/server/agents.om+195-0
apps/interplane-forge/server/chromegen.om+561-0
apps/interplane-forge/server/count-snapshot.om+343-0
apps/interplane-forge/server/counts.om+1043-0
apps/interplane-forge/server/json.om+642-0
apps/interplane-forge/server/jsonp.om+339-0
apps/interplane-forge/server/main.om+1013-0
apps/interplane-forge/server/nobrowse.om+4-0
apps/interplane-forge/server/nocollab.om+4-0
apps/interplane-forge/server/nocommunity.om+9-0
apps/interplane-forge/server/nodl.om+11-0
apps/interplane-forge/server/nodoor.om+22-0
apps/interplane-forge/server/nogrowth.om+7-0
apps/interplane-forge/server/noissuewrite.om+17-0
apps/interplane-forge/server/noopen.om+17-0
apps/interplane-forge/server/nopatch.om+12-0
apps/interplane-forge/server/noquiet.om+12-0
apps/interplane-forge/server/noresearch.om+9-0
apps/interplane-forge/server/nosalvage.om+11-0
apps/interplane-forge/server/nosocial.om+39-0
apps/interplane-forge/server/nostat.om+14-0
apps/interplane-forge/server/pages.om+955-0
apps/interplane-forge/server/radsrc.om+300-0
apps/interplane-forge/server/repos.om+369-0
apps/interplane-forge/server/route.om+725-0
apps/interplane-forge/server/state.om+629-0
apps/interplane-forge/server/tests/ratelim.om+68-0
apps/interplane-forge/server/tr.om+1022-0
apps/interplane-forge/server/util.om+1219-0
apps/interplane-forge/social/05decl.om+275-0
apps/interplane-forge/social/10base.om+115-0
apps/interplane-forge/social/20crypt.om+289-0
apps/interplane-forge/social/30store.om+929-0
apps/interplane-forge/social/40auth.om+857-0
apps/interplane-forge/social/50route.om+65-0
apps/interplane-forge/social/55pages.om+784-0
apps/interplane-forge/social/60json.om+223-0
apps/interplane-forge/store/clone.om+40-0
apps/interplane-forge/store/evcol.om+863-0
apps/interplane-forge/store/head.om+25-0
apps/interplane-forge/store/moving.om+42-0
apps/interplane-forge/store/mvcommunity.om+13-0
apps/interplane-forge/store/mvgrowth.om+15-0
apps/interplane-forge/store/mvopen.om+27-0
apps/interplane-forge/store/mvsalvage.om+14-0
apps/interplane-forge/store/repos.om+1112-0
apps/interplane-forge/store/tests/mutant-scan.om+55-0
apps/interplane-forge/tools/bring/installer.om+220-0
apps/interplane-forge/tools/bring/src/10base.om+298-0
apps/interplane-forge/tools/bring/src/20walk.om+463-0
apps/interplane-forge/tools/bring/src/30tar.om+338-0
apps/interplane-forge/tools/bring/src/35enc.om+217-0
apps/interplane-forge/tools/bring/src/40net.om+1366-0
apps/interplane-forge/tools/bring/src/50patch.om+760-0
apps/interplane-forge/tools/bring/src/90main.om+177-0
apps/interplane-forge/tools/bring/src/arch-a64.om+25-0
apps/interplane-forge/tools/bring/src/arch-x86.om+26-0
apps/interplane-forge/tools/bring/src/plat-linux.om+132-0
apps/interplane-forge/tools/bring/src/plat-macos.om+376-0
apps/interplane-forge/tools/bring/tests/standin.om+753-0
apps/interplane-forge/tools/doi/doi.om+2111-0
apps/interplane-forge/visits/owner.om+156-0
apps/interplane-forge/visits/visits.om+964-0
apps/interplane-site/content/omega/examples/sum.om+7-0
apps/interplane-site/native/lib/sha2.om+592-0
apps/interplane-site/native/site.om+6639-0
apps/interplane-site/native/translate.om+780-0
apps/omega-projects/lib.om+880-0
apps/omega-projects/main.om+165-0
apps/omega-projects/test.om+306-0
apps/omtex/examples/hello/hello.om+21-0
apps/omtex/examples/listings/paper.om+121-0
apps/omtex/examples/omega-language/paper.om+197-0
apps/omtex/examples/turing-brief/paper.om+133-0
apps/omtex/lib/omtex.om+1176-0
apps/readings-window/lib.om+690-0
apps/readings-window/main.om+125-0
apps/readings-window/test.om+333-0
apps/site_builder/html_feed.om+214-0
apps/site_builder/radicle_index.om+299-0
apps/site_builder/script_policy.om+172-0
apps/site_builder/test.om+300-0
apps/translate/lib.om+2175-0
apps/translate/main.om+84-0
apps/translate/test.om+517-0
apps/units-gate.om+1054-0
apps/units-run.tsv+10-0
apps/units.tsv+134-0
argus.lock+0-4
bridge/NOT-YET-OMEGA.tsv+319-0
bridge/README.md+32-0
bridge/UNITS.md+17-0
bridge/babel/src/00-core.om+250-0
bridge/babel/src/10-io.om+522-0
bridge/babel/src/20-split.om+697-0
bridge/babel/src/30-pipe.om+613-0
bridge/babel/src/40-gen.om+595-0
bridge/babel/src/50-diff.om+886-0
bridge/babel/src/60-report.om+961-0
bridge/babel/src/65-exclude.om+365-0
bridge/babel/src/70-complete.om+715-0
bridge/babel/src/90-main.om+865-0
bridge/core/abi_ggml.om+256-0
bridge/core/test.om+218-0
bridge/ggml/kernels/bfs.om+11-0
bridge/ggml/kernels/bin.om+20-0
bridge/ggml/kernels/cpy.om+6-0
bridge/ggml/kernels/cpyh.om+6-0
bridge/ggml/kernels/df32.om+11-0
bridge/ggml/kernels/dh16.om+11-0
bridge/ggml/kernels/dq8.om+28-0
bridge/ggml/kernels/dq8r.om+11-0
bridge/ggml/kernels/f2hv.om+6-0
bridge/ggml/kernels/gbmm.om+125-0
bridge/ggml/kernels/h2fv.om+6-0
bridge/ggml/kernels/math.om+157-0
bridge/ggml/kernels/rcp.om+4-0
bridge/ggml/kernels/rmsc.om+7-0
bridge/ggml/kernels/rope.om+31-0
bridge/ggml/kernels/rtsc.om+6-0
bridge/ggml/kernels/scl.om+12-0
bridge/ggml/kernels/sexp.om+11-0
bridge/ggml/kernels/silu.om+8-0
bridge/ggml/kernels/smw.om+7-0
bridge/ggml/kernels/smwh.om+7-0
bridge/ggml/kernels/sq.om+9-0
bridge/ggml/kernels/swi.om+8-0
bridge/ggml/kernels/vmax.om+11-0
bridge/import/babel/README.md+11-0
bridge/import/babel/commit-map+9-0
bridge/import/babel/filter-repo-command.txt+1-0
bridge/import/babel/filter-repo.version+1-0
bridge/import/babel/paths.txt+2-0
bridge/import/babel/ref-map+2-0
bridge/import/ggml-omega/README.md+11-0
bridge/import/ggml-omega/commit-map+7-0
bridge/import/ggml-omega/filter-repo-command.txt+1-0
bridge/import/ggml-omega/filter-repo.version+1-0
bridge/import/ggml-omega/paths.txt+2-0
bridge/import/ggml-omega/ref-map+2-0
bridge/import/omega-bridge-kit/README.md+11-0
bridge/import/omega-bridge-kit/commit-map+11-0
bridge/import/omega-bridge-kit/filter-repo-command.txt+1-0
bridge/import/omega-bridge-kit/filter-repo.version+1-0
bridge/import/omega-bridge-kit/paths.txt+2-0
bridge/import/omega-bridge-kit/ref-map+2-0
bridge/import/omega-bridge/README.md+11-0
bridge/import/omega-bridge/commit-map+219-0
bridge/import/omega-bridge/filter-repo-command.txt+1-0
bridge/import/omega-bridge/filter-repo.version+1-0
bridge/import/omega-bridge/paths.txt+2-0
bridge/import/omega-bridge/ref-map+4-0
bridge/kit/samples/gcd.om+11-0
bridge/kit/samples/power.om+9-0
bridge/omega-bridge/examples/attachment.om+23-0
bridge/omega-bridge/examples/deepinfer/flops_pairs.om+41-0
bridge/omega-bridge/max-cpu/omatmul.om+51-0
bridge/omega-bridge/pytorch/kernels/addmm.om+21-0
bridge/omega-bridge/pytorch/kernels/eadd.om+7-0
bridge/omega-bridge/pytorch/kernels/linear.om+21-0
bridge/omega-bridge/pytorch/kernels/mm.om+20-0
bridge/omega-bridge/pytorch/kernels/relu.om+12-0
bridge/omega-bridge/pytorch/kernels/softmax.om+72-0
bridge/omega-bridge/pytorch/kernels/tr.om+9-0
bridge/omega-bridge/src/freest.om+1216-0
bridge/omega-bridge/src/gpu_adapter.om+756-0
bridge/omega-bridge/src/kernel_leaf.om+121-0
bridge/omega-bridge/src/native.om+3695-0
bridge/omega-bridge/src/toc.om+7288-0
bridge/omega-bridge/tests/cabi/ext.om+14-0
bridge/omega-bridge/tests/cabi/fixture.om+343-0
bridge/omega-bridge/tests/cabi/gate.om+946-0
bridge/omega-bridge/tests/cabi/proc.om+531-0
bridge/omega-bridge/tests/device-window/race.om+574-0
bridge/omega-bridge/tests/fixtures/bytecopy.om+23-0
bridge/omega-bridge/tests/fixtures/echo.om+16-0
bridge/omega-bridge/tests/fixtures/fib.om+29-0
bridge/omega-bridge/tests/fixtures/for_expr_once.om+9-0
bridge/omega-bridge/tests/fixtures/for_varchange.om+9-0
bridge/omega-bridge/tests/fixtures/io_errno.om+5-0
bridge/omega-bridge/tests/fixtures/local_array.om+5-0
bridge/omega-bridge/tests/fixtures/num_bool.om+8-0
bridge/omega-bridge/tests/fixtures/num_byte_add.om+5-0
bridge/omega-bridge/tests/fixtures/num_byte_cast.om+5-0
bridge/omega-bridge/tests/fixtures/num_byte_div.om+5-0
bridge/omega-bridge/tests/fixtures/num_byte_mul.om+5-0
bridge/omega-bridge/tests/fixtures/num_byte_neg.om+5-0
bridge/omega-bridge/tests/fixtures/num_byte_rem.om+5-0
bridge/omega-bridge/tests/fixtures/num_byte_shiftlimit.om+6-0
bridge/omega-bridge/tests/fixtures/num_byte_shl.om+5-0
bridge/omega-bridge/tests/fixtures/num_byte_shr.om+5-0
bridge/omega-bridge/tests/fixtures/num_byte_sub.om+5-0
bridge/omega-bridge/tests/fixtures/num_div_negative.om+5-0
bridge/omega-bridge/tests/fixtures/num_int_add.om+5-0
bridge/omega-bridge/tests/fixtures/num_int_cast.om+5-0
bridge/omega-bridge/tests/fixtures/num_int_div.om+5-0
bridge/omega-bridge/tests/fixtures/num_int_mul.om+5-0
bridge/omega-bridge/tests/fixtures/num_int_neg.om+5-0
bridge/omega-bridge/tests/fixtures/num_int_rem.om+5-0
bridge/omega-bridge/tests/fixtures/num_int_shiftlimit.om+6-0
bridge/omega-bridge/tests/fixtures/num_int_shl.om+5-0
bridge/omega-bridge/tests/fixtures/num_int_shr.om+5-0
bridge/omega-bridge/tests/fixtures/num_int_sub.om+5-0
bridge/omega-bridge/tests/fixtures/num_intmin_literal.om+4-0
bridge/omega-bridge/tests/fixtures/num_long_add.om+5-0
bridge/omega-bridge/tests/fixtures/num_long_cast.om+5-0
bridge/omega-bridge/tests/fixtures/num_long_div.om+5-0
bridge/omega-bridge/tests/fixtures/num_long_mul.om+5-0
bridge/omega-bridge/tests/fixtures/num_long_neg.om+5-0
bridge/omega-bridge/tests/fixtures/num_long_rem.om+5-0
bridge/omega-bridge/tests/fixtures/num_long_shiftlimit.om+6-0
bridge/omega-bridge/tests/fixtures/num_long_shl.om+5-0
bridge/omega-bridge/tests/fixtures/num_long_shr.om+5-0
bridge/omega-bridge/tests/fixtures/num_long_sub.om+5-0
bridge/omega-bridge/tests/fixtures/num_not.om+5-0
bridge/omega-bridge/tests/fixtures/num_rem_negative.om+5-0
bridge/omega-bridge/tests/fixtures/num_short_add.om+5-0
bridge/omega-bridge/tests/fixtures/num_short_cast.om+5-0
bridge/omega-bridge/tests/fixtures/num_short_div.om+5-0
bridge/omega-bridge/tests/fixtures/num_short_mul.om+5-0
bridge/omega-bridge/tests/fixtures/num_short_neg.om+5-0
bridge/omega-bridge/tests/fixtures/num_short_rem.om+5-0
bridge/omega-bridge/tests/fixtures/num_short_shiftlimit.om+6-0
bridge/omega-bridge/tests/fixtures/num_short_shl.om+5-0
bridge/omega-bridge/tests/fixtures/num_short_shr.om+5-0
bridge/omega-bridge/tests/fixtures/num_short_sub.om+5-0
bridge/omega-bridge/tests/fixtures/num_uchar_add.om+5-0
bridge/omega-bridge/tests/fixtures/num_uchar_cast.om+5-0
bridge/omega-bridge/tests/fixtures/num_uchar_div.om+5-0
bridge/omega-bridge/tests/fixtures/num_uchar_mul.om+5-0
bridge/omega-bridge/tests/fixtures/num_uchar_neg.om+5-0
bridge/omega-bridge/tests/fixtures/num_uchar_rem.om+5-0
bridge/omega-bridge/tests/fixtures/num_uchar_shiftlimit.om+6-0
bridge/omega-bridge/tests/fixtures/num_uchar_shl.om+5-0
bridge/omega-bridge/tests/fixtures/num_uchar_shr.om+5-0
bridge/omega-bridge/tests/fixtures/num_uchar_sub.om+5-0
bridge/omega-bridge/tests/fixtures/num_uint_add.om+5-0
bridge/omega-bridge/tests/fixtures/num_uint_cast.om+5-0
bridge/omega-bridge/tests/fixtures/num_uint_div.om+5-0
bridge/omega-bridge/tests/fixtures/num_uint_mul.om+5-0
bridge/omega-bridge/tests/fixtures/num_uint_neg.om+5-0
bridge/omega-bridge/tests/fixtures/num_uint_rem.om+5-0
bridge/omega-bridge/tests/fixtures/num_uint_shiftlimit.om+6-0
bridge/omega-bridge/tests/fixtures/num_uint_shl.om+5-0
bridge/omega-bridge/tests/fixtures/num_uint_shr.om+5-0
bridge/omega-bridge/tests/fixtures/num_uint_sub.om+5-0
bridge/omega-bridge/tests/fixtures/num_ulong_add.om+5-0
bridge/omega-bridge/tests/fixtures/num_ulong_cast.om+5-0
bridge/omega-bridge/tests/fixtures/num_ulong_div.om+5-0
bridge/omega-bridge/tests/fixtures/num_ulong_mul.om+5-0
bridge/omega-bridge/tests/fixtures/num_ulong_neg.om+5-0
bridge/omega-bridge/tests/fixtures/num_ulong_rem.om+5-0
bridge/omega-bridge/tests/fixtures/num_ulong_shiftlimit.om+6-0
bridge/omega-bridge/tests/fixtures/num_ulong_shl.om+5-0
bridge/omega-bridge/tests/fixtures/num_ulong_shr.om+5-0
bridge/omega-bridge/tests/fixtures/num_ulong_sub.om+5-0
bridge/omega-bridge/tests/fixtures/num_ushort_add.om+5-0
bridge/omega-bridge/tests/fixtures/num_ushort_cast.om+5-0
bridge/omega-bridge/tests/fixtures/num_ushort_div.om+5-0
bridge/omega-bridge/tests/fixtures/num_ushort_mul.om+5-0
bridge/omega-bridge/tests/fixtures/num_ushort_neg.om+5-0
bridge/omega-bridge/tests/fixtures/num_ushort_rem.om+5-0
bridge/omega-bridge/tests/fixtures/num_ushort_shiftlimit.om+6-0
bridge/omega-bridge/tests/fixtures/num_ushort_shl.om+5-0
bridge/omega-bridge/tests/fixtures/num_ushort_shr.om+5-0
bridge/omega-bridge/tests/fixtures/num_ushort_sub.om+5-0
bridge/omega-bridge/tests/fixtures/order_calls.om+14-0
bridge/omega-bridge/tests/fixtures/order_put.om+14-0
bridge/omega-bridge/tests/fixtures/order_trap.om+17-0
bridge/omega-bridge/tests/fixtures/r5b_assign.om+7-0
bridge/omega-bridge/tests/fixtures/r5b_cycle.om+6-0
bridge/omega-bridge/tests/fixtures/r5b_fwd.om+6-0
bridge/omega-bridge/tests/fixtures/r5b_fwd_fm.om+9-0
bridge/omega-bridge/tests/fixtures/r5b_mut.om+19-0
bridge/omega-bridge/tests/fixtures/sort.om+63-0
bridge/omega-bridge/tests/fixtures/t_bounds.om+5-0
bridge/omega-bridge/tests/fixtures/t_cmp_unsigned.om+9-0
bridge/omega-bridge/tests/fixtures/t_conv.om+4-0
bridge/omega-bridge/tests/fixtures/t_conv_sign.om+6-0
bridge/omega-bridge/tests/fixtures/t_div0.om+4-0
bridge/omega-bridge/tests/fixtures/t_exit.om+3-0
bridge/omega-bridge/tests/fixtures/t_loop.om+7-0
bridge/omega-bridge/tests/fixtures/t_ovf.om+5-0
bridge/omega-bridge/tests/fixtures/t_rw.om+5-0
bridge/omega-bridge/tests/fixtures/t_stack.om+7-0
bridge/omega-bridge/tests/fixtures/t_u63.om+6-0
bridge/omega-bridge/tests/fixtures/t_u64max.om+5-0
bridge/omega-bridge/tests/fixtures/t_void.om+8-0
bridge/omega-bridge/tests/fixtures/t_write_wrap.om+6-0
bridge/omega-bridge/tests/fixtures/text_program.om+8-0
bridge/omega-bridge/tests/fixtures/two_loops.om+10-0
bridge/omega-bridge/tests/freest-fixtures/attn_args.om+21-0
bridge/omega-bridge/tests/freest-fixtures/attn_buf.om+27-0
bridge/omega-bridge/tests/freest-fixtures/attn_fill.om+26-0
bridge/omega-bridge/tests/freest-fixtures/attn_set.om+26-0
bridge/omega-bridge/tests/freest-fixtures/epoch.om+8-0
bridge/omega-bridge/tests/freest-fixtures/revision.om+8-0
bridge/omega-bridge/tests/freest-fixtures/scalar.om+23-0
bridge/omega-bridge/tests/native/big.om+9-0
bridge/omega-bridge/tests/native/fill.om+10-0
bridge/omega-bridge/tests/native/freestanding/f32.om+50-0
bridge/omega-bridge/tests/native/freestanding/f64.om+20-0
bridge/omega-bridge/tests/native/freestanding/pathlen.om+15-0
bridge/omega-bridge/tests/native/fsum.om+18-0
bridge/omega-bridge/tests/native/g1/calc.lowered.om+12-0
bridge/omega-bridge/tests/native/g1/calc.om+9-0
bridge/omega-bridge/tests/native/halve.om+7-0
bridge/omega-bridge/tests/native/hsum.om+20-0
bridge/omega-bridge/tests/native/macos/hostw.om+7-0
bridge/omega-bridge/tests/native/madd.om+5-0
bridge/omega-bridge/tests/native/mix.om+7-0
bridge/omega-bridge/tests/native/smadd.om+5-0
bridge/omega-bridge/tests/native/spin.om+8-0
bridge/omega-bridge/tests/native/v2/dev/ctxget.om+8-0
bridge/omega-bridge/tests/native/v2/dev/ctxnew.om+5-0
bridge/omega-bridge/tests/native/v2/dev/ctxput.om+5-0
bridge/omega-bridge/tests/native/v2/dev/hdev.om+93-0
bridge/omega-bridge/tests/native/v2/dev/onehost.om+8-0
bridge/omega-bridge/tests/native/v2/fsout.om+10-0
bridge/omega-bridge/tests/native/v2/hoist.om+47-0
bridge/omega-bridge/tests/native/v2/host/hfile.om+51-0
bridge/omega-bridge/tests/native/v2/lay.om+45-0
bridge/omega-bridge/tests/native/v2/om3/fnmap.om+40-0
bridge/omega-bridge/tests/native/v2/one.om+8-0
bridge/omega-bridge/tests/native/v2/oneedit.om+5-0
bridge/omega-bridge/tests/native/v2/sha256-om2.om+344-0
bridge/omega-bridge/tests/native/v2/v1use/bsum.om+5-0
bridge/omega-bridge/tests/native/v2/vec.om+58-0
bridge/omega-bridge/tests/native/x86/check_physical_receipt.om+2233-0
bridge/omega-bridge/tests/native/x86/check_receipt_test.om+964-0
bridge/omega-bridge/tests/native/x86/follow.om+4-0
bridge/omega-bridge/tests/native/x86/outtrap.om+12-0
bridge/omega-bridge/tests/native/x86/trapcall.om+13-0
bridge/omega-bridge/tests/unsupported/five_params.om+6-0
bridge/omega-bridge/tools/run-device-window.om+2380-0
bridge/units-gate.om+1054-0
bridge/units-run.tsv+6-0
bridge/units.tsv+179-0
core/NOT-YET-OMEGA.tsv+6996-0
core/README.md+40-0
core/UNITS.md+15-0
core/aegis/dag.om+490-0
core/aegis/gateway.om+902-0
core/aegis/heartbeat.om+429-0
core/aegis/journal.om+459-0
core/aegis/main.om+654-0
core/aegis/policy.om+485-0
core/aegis/test.om+869-0
core/aien/src/bots/bots.om+755-0
core/aien/src/goal_microjobs/canon.om+540-0
core/aien/src/goal_microjobs/kernel.om+902-0
core/aien/src/goal_microjobs/recovery.om+157-0
core/aien/src/goal_microjobs/shadow.om+419-0
core/aien/tests/goal_microjobs/shadow-oracle.om+30-0
core/cortex/om/api.om+577-0
core/cortex/om/api2.om+583-0
core/cortex/om/api3.om+407-0
core/cortex/om/brain.om+2596-0
core/cortex/om/crc32c.om+101-0
core/cortex/om/de.om+1369-0
core/cortex/om/enc.om+482-0
core/cortex/om/f64.om+689-0
core/cortex/om/flog.om+398-0
core/cortex/om/fts.om+3557-0
core/cortex/om/http.om+793-0
core/cortex/om/import_main.om+533-0
core/cortex/om/json.om+1983-0
core/cortex/om/like.om+277-0
core/cortex/om/log.om+805-0
core/cortex/om/main.om+394-0
core/cortex/om/qs.om+329-0
core/cortex/om/sqlite.om+766-0
core/cortex/om/srv.om+560-0
core/cortex/om/store.om+637-0
core/cortex/om/uni_fts.om+376-0
core/cortex/om/uni_rust.om+404-0
core/cortex/tests/brain/mkimp.om+163-0
core/cortex/tests/conc/slow.om+209-0
core/cortex/tests/fts/t_flog.om+101-0
core/cortex/tests/fts/t_like.om+176-0
core/cortex/tests/fts/t_query.om+336-0
core/cortex/tests/fts/t_tok.om+72-0
core/cortex/tests/fts/tdump.om+62-0
core/cortex/tests/fts/tlib.om+126-0
core/cortex/tests/import/crctest.om+52-0
core/cortex/tests/import/logdump.om+292-0
core/cortex/tests/json/t_api.om+92-0
core/cortex/tests/json/t_f64.om+62-0
core/cortex/tests/json/t_io.om+132-0
core/cortex/tests/json/t_json.om+72-0
core/cortex/tests/json/t_perf.om+112-0
core/cortex/tests/json/t_time.om+38-0
core/cortex/tests/json/t_uni.om+76-0
core/cortex/tests/pageunit/gen.om+332-0
core/cortex/tests/parity/gen.om+749-0
core/cortex/tests/parity/pcmp.om+913-0
core/cortex/tests/parity/pdrive.om+529-0
core/cortex/tools/pageunit/enc.om+155-0
core/cortex/tools/pincheck.om+379-0
core/dream/lib.om+1198-0
core/dream/main.om+68-0
core/dream/test.om+424-0
core/hive-not-swarm/lib.om+662-0
core/hive-not-swarm/main.om+87-0
core/hive-not-swarm/test.om+397-0
core/hive-view/src/main.om+408-0
core/hive-view/src/page.om+2749-0
core/hive-view/src/poll.om+1661-0
core/hive-view/src/route.om+426-0
core/hive-view/src/run.om+273-0
core/hive-view/src/util.om+197-0
core/hive-view/src/web.om+700-0
core/hive-view/tests/gate.om+1239-0
core/hive/lib.om+936-0
core/hive/main.om+645-0
core/hive/test.om+557-0
core/import/aien-sovereign-core-mv/README.md+11-0
core/import/aien-sovereign-core-mv/commit-map+1357-0
core/import/aien-sovereign-core-mv/filter-repo-command.txt+1-0
core/import/aien-sovereign-core-mv/filter-repo.version+1-0
core/import/aien-sovereign-core-mv/paths.txt+2-0
core/import/aien-sovereign-core-mv/ref-map+13-0
core/import/aien/README.md+11-0
core/import/aien/commit-map+26-0
core/import/aien/filter-repo-command.txt+1-0
core/import/aien/filter-repo.version+1-0
core/import/aien/paths.txt+2-0
core/import/aien/ref-map+2-0
core/import/cortex/README.md+11-0
core/import/cortex/commit-map+22-0
core/import/cortex/filter-repo-command.txt+1-0
core/import/cortex/filter-repo.version+1-0
core/import/cortex/paths.txt+2-0
core/import/cortex/ref-map+2-0
core/import/hive-view/README.md+11-0
core/import/hive-view/commit-map+14-0
core/import/hive-view/filter-repo-command.txt+1-0
core/import/hive-view/filter-repo.version+1-0
core/import/hive-view/paths.txt+2-0
core/import/hive-view/ref-map+2-0
core/import/omega-mission/README.md+11-0
core/import/omega-mission/commit-map+15-0
core/import/omega-mission/filter-repo-command.txt+1-0
core/import/omega-mission/filter-repo.version+1-0
core/import/omega-mission/paths.txt+2-0
core/import/omega-mission/ref-map+2-0
core/import/spark-rsi-mv/README.md+11-0
core/import/spark-rsi-mv/commit-map+143-0
core/import/spark-rsi-mv/filter-repo-command.txt+1-0
core/import/spark-rsi-mv/filter-repo.version+1-0
core/import/spark-rsi-mv/paths.txt+2-0
core/import/spark-rsi-mv/ref-map+2-0
core/mission/journal.om+990-0
core/mission/mission.om+825-0
core/mission/sha.om+216-0
core/mobhub/lib.om+1236-0
core/mobhub/main.om+456-0
core/mobhub/test.om+704-0
core/openclaw/lib.om+1352-0
core/openclaw/main.om+194-0
core/openclaw/test.om+407-0
core/rsi/om/eval/canary.om+170-0
core/rsi/om/eval/eval_test.om+316-0
core/rsi/om/eval/evaluator.om+157-0
core/rsi/om/eval/rollback.om+313-0
core/rsi/om/governance/ledger.om+314-0
core/rsi/om/governance/promotion_gate.om+163-0
core/rsi/om/governance/test.om+232-0
core/rsi/om/p256/p256.om+682-0
core/rsi/om/p256/sha256.om+1527-0
core/rsi/om/p256/tests/run.om+436-0
core/rsi/om/reuse-eval/gen.om+1503-0
core/rsi/om/reuse-eval/judge.om+3560-0
core/rsi/om/reuse-eval/main.om+19-0
core/rsi/om/reuse-eval/receipt.om+413-0
core/rsi/om/reuse-eval/ref.om+643-0
core/rsi/om/reuse-eval/sha256.om+1527-0
core/rsi/om/reuse-eval/stats.om+2204-0
core/rsi/om/reuse-eval/turing.om+905-0
core/rsi/tests/reuse-eval/gen-det.om+371-0
core/rsi/tests/reuse-eval/gen-final.om+937-0
core/rsi/tests/reuse-eval/gen-train.om+759-0
core/rsi/tests/reuse-eval/judge-arm.om+156-0
core/rsi/tests/reuse-eval/judge-build.om+76-0
core/rsi/tests/reuse-eval/judge-calib.om+87-0
core/rsi/tests/reuse-eval/judge-cli.om+222-0
core/rsi/tests/reuse-eval/judge-controls.om+141-0
core/rsi/tests/reuse-eval/judge-drive.om+29-0
core/rsi/tests/reuse-eval/judge-end.om+103-0
core/rsi/tests/reuse-eval/judge-protocol.om+175-0
core/rsi/tests/reuse-eval/receipt-fields.om+464-0
core/rsi/tests/reuse-eval/ref-hand.om+482-0
core/rsi/tests/reuse-eval/ref-kat.om+264-0
core/rsi/tests/reuse-eval/run.om+685-0
core/rsi/tests/reuse-eval/stats-decide.om+287-0
core/rsi/tests/reuse-eval/stats-e2e.om+886-0
core/rsi/tests/reuse-eval/stats-payback.om+82-0
core/rsi/tests/reuse-eval/stats-rank.om+145-0
core/rsi/tests/reuse-eval/turing-tps.om+479-0
core/sovereign-core/crates/aien-omega-q38/om/plan.om+38-0
core/sovereign-core/om/crumb-coverage/crumb-coverage.om+767-0
core/sovereign-core/om/effects/world.om+438-0
core/sovereign-core/om/expert-bytes/expert-bytes.om+883-0
core/sovereign-core/om/flint/manifest.om+1776-0
core/sovereign-core/om/flint/ops.om+1836-0
core/sovereign-core/om/golden/fake.om+329-0
core/sovereign-core/om/golden/golden.om+1460-0
core/sovereign-core/om/golden/ollm/drive.om+3426-0
core/sovereign-core/om/golden/ollm/gate.om+954-0
core/sovereign-core/om/golden/ollm/gdec.om+330-0
core/sovereign-core/om/hive-task/drive.om+3209-0
core/sovereign-core/om/hive-task/task.om+472-0
core/sovereign-core/om/inquisitor-exit/check.om+687-0
core/sovereign-core/om/q38-head/select.om+117-0
core/sovereign-core/om/qwen-native/blocks/attention.om+202-0
core/sovereign-core/om/qwen-native/blocks/gdn.om+182-0
core/sovereign-core/om/qwen-native/blocks/math.om+99-0
core/sovereign-core/om/qwen-native/blocks/tests/probe.om+132-0
core/sovereign-core/om/qwen-native/flash/attest.om+161-0
core/sovereign-core/om/qwen-native/flash/checkpoint-pins.om+71-0
core/sovereign-core/om/qwen-native/flash/common.om+89-0
core/sovereign-core/om/qwen-native/flash/diskcheck.om+41-0
core/sovereign-core/om/qwen-native/flash/graph.om+566-0
core/sovereign-core/om/qwen-native/flash/main.om+138-0
core/sovereign-core/om/qwen-native/flash/profile.om+311-0
core/sovereign-core/om/qwen-native/flash/project.om+333-0
core/sovereign-core/om/qwen-native/flash/serve.om+600-0
core/sovereign-core/om/qwen-native/flash/session.om+86-0
core/sovereign-core/om/qwen-native/flash/weights.om+375-0
core/sovereign-core/om/qwen-native/linear/linear.om+257-0
core/sovereign-core/om/qwen-native/linear/spans-test.om+107-0
core/sovereign-core/om/qwen-native/linear/standalone.om+197-0
core/sovereign-core/om/qwen-native/model/attest.om+153-0
core/sovereign-core/om/qwen-native/model/checkpoint-pins.om+72-0
core/sovereign-core/om/qwen-native/model/diskcheck.om+46-0
core/sovereign-core/om/qwen-native/model/generate.om+143-0
core/sovereign-core/om/qwen-native/model/graph.om+215-0
core/sovereign-core/om/qwen-native/model/probe.om+32-0
core/sovereign-core/om/qwen-native/model/profile.om+239-0
core/sovereign-core/om/qwen-native/model/project.om+160-0
core/sovereign-core/om/qwen-native/model/session.om+94-0
core/sovereign-core/om/qwen-native/model/weights.om+400-0
core/sovereign-core/om/qwen-native/tokenizer/cli.om+29-0
core/sovereign-core/om/qwen-native/tokenizer/model.om+287-0
core/sovereign-core/om/qwen-native/tokenizer/tables.om+235-0
core/sovereign-core/om/qwen-native/tokenizer/tokenizer.om+406-0
core/sovereign-core/om/qwen-native/tokenizer/tokio.om+44-0
core/sovereign-core/om/qwen-native/tokenizer/unicode-data.om+8765-0
core/sovereign-core/om/qwen-native/tokenizer/unicode.om+107-0
core/sovereign-core/om/residency/residency.om+565-0
core/sovereign-core/om/ribbon/pipeline.om+339-0
core/sovereign-core/om/ribbon/test_driver.om+56-0
core/sovereign-core/om/runtime/inference_abi.om+241-0
core/sovereign-core/om/runtime/membrane.om+375-0
core/sovereign-core/om/runtime/test.om+307-0
core/sovereign-core/om/scheduler/kv_cache.om+653-0
core/sovereign-core/om/scheduler/scheduler.om+837-0
core/sovereign-core/om/scheduler/test.om+533-0
core/sovereign-core/om/serve/cli.om+234-0
core/sovereign-core/om/serve/http_auth.om+457-0
core/sovereign-core/om/serve/router.om+370-0
core/sovereign-core/om/serve/test.om+465-0
core/sovereign-core/om/store/closure.om+322-0
core/sovereign-core/om/store/closure_test.om+312-0
core/sovereign-core/om/store/kv_store.om+512-0
core/sovereign-core/om/store/kv_store_test.om+387-0
core/sovereign-core/om/tur-ledger/tur-ledger.om+1625-0
core/sovereign-core/om/vendor/ec.om+685-0
core/sovereign-core/om/vendor/json.om+1247-0
core/sovereign-core/om/vendor/sha256.om+162-0
core/sovereign-core/tests/turing-network/tur_r0_oracle.om+123-0
core/units-gate.om+1054-0
core/units-run.tsv+17-0
core/units.tsv+54-0
docs/A64-EFI.md+6-2
docs/PIPELINE.md+5-0
docs/ROADMAP-1.0.md+3-2
docs/UXL.md+25-0
docs/X86-EFI.md+2-0
docs/baremetal/SPARK-LIVE-BOOT.md+245-0
docs/gpu/GSP_RPC_REGISTRY_REFERENCE.md+446-0
docs/gpu/PI_DRIVE_27B_SPARK.md+125-0
docs/gpu/Q38_27B_GB10_STRESS_20261119.md+131-0
docs/migration/C-TO-OM-INVENTORY.md+2-0
docs/one_layer/OMEGESE.md+1-1
docs/one_layer/OM_COMPLETION.md+4-1
docs/osc/audit/omega-runtime.md+1-1
docs/r15-handoff.md+6-4
docs/r16-production-entry-point.md+3-2
gpu/EXTRA-NOT-YET-OMEGA.tsv+287-0
gpu/README.md+16-5
gpu/UNITS.md+2-0
gpu/adapters/lib.om+922-0
gpu/adapters/main.om+63-0
gpu/adapters/test.om+340-0
gpu/algebra/pack.om+251-0
gpu/algebra/quant.om+134-0
gpu/algebra/test.om+659-0
gpu/algebra/trit.om+553-0
gpu/algebra/z3.om+190-0
gpu/checker2/lrat.om+634-0
gpu/checker2/test.om+211-0
gpu/cuda-crack/check/reencode.om+357-0
gpu/cuda-crack/gen/bw_enc_sm121.om+551-0
gpu/cuda-crack/gen/isa.om+401-0
gpu/driver/chan/chan.om+365-0
gpu/driver/chan/complete.om+379-0
gpu/driver/chan/dma.om+44-0
gpu/driver/chan/gmmu.om+790-0
gpu/driver/chan/gmmu_bm.om+565-0
gpu/driver/chan/mem.om+264-0
gpu/driver/chan/params.om+332-0
gpu/driver/chan/rmchan.om+741-0
gpu/driver/chan/sim.om+537-0
gpu/driver/fwprep.om+613-0
gpu/driver/gsp/arena.om+550-0
gpu/driver/gsp/arena_bm.om+353-0
gpu/driver/gsp/bindata.om+1526-0
gpu/driver/gsp/bm_hal.om+334-0
gpu/driver/gsp/boot.om+467-0
gpu/driver/gsp/bootfs.om+388-0
gpu/driver/gsp/compute.om+758-0
gpu/driver/gsp/connect.om+17-0
gpu/driver/gsp/dispatch.om+203-0
gpu/driver/gsp/fw.om+778-0
gpu/driver/gsp/fw_bm.om+278-0
gpu/driver/gsp/inflate.om+562-0
gpu/driver/gsp/irq.om+160-0
gpu/driver/gsp/irqbm.om+144-0
gpu/driver/gsp/irqcc.om+131-0
gpu/driver/gsp/irqcmd.om+58-0
gpu/driver/gsp/irqctl.om+109-0
gpu/driver/gsp/irqlease.om+209-0
gpu/driver/gsp/irqprovider.om+316-0
gpu/driver/gsp/irqqueue.om+110-0
gpu/driver/gsp/irqsim.om+82-0
gpu/driver/gsp/irqtypes.om+19-0
gpu/driver/gsp/irqvfio.om+269-0
gpu/driver/gsp/logdec.om+1059-0
gpu/driver/gsp/mmio.om+304-0
gpu/driver/gsp/mmio_bm.om+195-0
gpu/driver/gsp/notify.om+6-0
gpu/driver/gsp/ogdmodel.om+130-0
gpu/driver/gsp/ogdvars.om+9-0
gpu/driver/gsp/owned.om+81-0
gpu/driver/gsp/profile.om+28-0
gpu/driver/gsp/q38_run.om+1189-0
gpu/driver/gsp/replay.om+14-0
gpu/driver/gsp/rpc.om+336-0
gpu/driver/gsp/sec2.om+174-0
gpu/driver/gsp/sec2sim.om+89-0
gpu/driver/gsp/seq.om+200-0
gpu/driver/gsp/seqcore.om+178-0
gpu/driver/gsp/service.om+50-0
gpu/driver/gsp/sha2.om+518-0
gpu/driver/gsp/sim.om+332-0
gpu/driver/gsp/sysinfo.om+709-0
gpu/driver/gsp/transport.om+328-0
gpu/driver/gsp/transport_bm.om+195-0
gpu/driver/ogd.om+129-0
gpu/driver/rm/dispatch.om+263-0
gpu/driver/rm/endpoint.om+471-0
gpu/driver/rm/handles.om+142-0
gpu/driver/rm/import.om+194-0
gpu/driver/rm/ioctl.om+111-0
gpu/driver/rm/memory.om+264-0
gpu/driver/rm/model.om+150-0
gpu/driver/rm/uvmclient.om+224-0
gpu/driver/tests/arena_large.om+202-0
gpu/driver/tests/arena_trace.om+280-0
gpu/driver/tests/boot_dma.om+43-0
gpu/driver/tests/bootfs_trace.om+278-0
gpu/driver/tests/chan_trace.om+264-0
gpu/driver/tests/complete_trace.om+172-0
gpu/driver/tests/compute_trace.om+423-0
gpu/driver/tests/dispatch_trace.om+329-0
gpu/driver/tests/dma_badfd.om+26-0
gpu/driver/tests/dma_check.om+314-0
gpu/driver/tests/dma_replay.om+18-0
gpu/driver/tests/irq_trace.om+63-0
gpu/driver/tests/irqcc_trace.om+343-0
gpu/driver/tests/irqcmd_trace.om+75-0
gpu/driver/tests/irqlease_trace.om+151-0
gpu/driver/tests/irqqueue_trace.om+116-0
gpu/driver/tests/irqvfio_trace.om+112-0
gpu/driver/tests/logdec_trace.om+572-0
gpu/driver/tests/mmio_trace.om+325-0
gpu/driver/tests/params_dump.om+234-0
gpu/driver/tests/pm_gate.om+82-0
gpu/driver/tests/q38_run_shim.om+109-0
gpu/driver/tests/q38_run_test.om+378-0
gpu/driver/tests/q38_sass_emit.om+65-0
gpu/driver/tests/q38_sass_encode.om+81-0
gpu/driver/tests/q38_sass_parity.sh+92-0
gpu/driver/tests/rmchan_trace.om+286-0
gpu/driver/tests/rme_trace.om+30-0
gpu/driver/tests/rpc_trace.om+316-0
gpu/driver/tests/sec2_trace.om+175-0
gpu/driver/tests/seq_trace.om+301-0
gpu/driver/tests/slice_c_gate.om+851-0
gpu/driver/tests/sysinfo_cli.om+409-0
gpu/driver/tests/transport_trace.om+375-0
gpu/driver/tests/uvm_trace.om+307-0
gpu/driver/tests/uvme_notify.om+108-0
gpu/driver/tests/uvms_trace.om+191-0
gpu/driver/uvm/endpoint.om+583-0
gpu/driver/uvm/fault.om+124-0
gpu/driver/uvm/fmt.om+176-0
gpu/driver/uvm/ioctl.om+257-0
gpu/driver/uvm/notify.om+75-0
gpu/driver/uvm/pt.om+483-0
gpu/driver/uvm/range.om+226-0
gpu/driver/uvm/resident.om+100-0
gpu/driver/uvm/ring.om+97-0
gpu/driver/uvm/service.om+146-0
gpu/driver/w0.om+554-0
gpu/extra-units-gate.om+1054-0
gpu/extra-units-run.tsv+12-0
gpu/extra-units.tsv+30-0
gpu/forge/envelope.om+521-0
gpu/forge/hardware.om+854-0
gpu/forge/main.om+464-0
gpu/forge/provider.om+453-0
gpu/forge/realize.om+880-0
gpu/forge/test.om+610-0
gpu/head-to-head/lib.om+849-0
gpu/head-to-head/main.om+294-0
gpu/head-to-head/test.om+428-0
gpu/import/cuda-crack/README.md+11-0
gpu/import/cuda-crack/commit-map+19-0
gpu/import/cuda-crack/filter-repo-command.txt+1-0
gpu/import/cuda-crack/filter-repo.version+1-0
gpu/import/cuda-crack/paths.txt+2-0
gpu/import/cuda-crack/ref-map+2-0
gpu/import/omega-gpu-driver/README.md+11-0
gpu/import/omega-gpu-driver/commit-map+32-0
gpu/import/omega-gpu-driver/filter-repo-command.txt+1-0
gpu/import/omega-gpu-driver/filter-repo.version+1-0
gpu/import/omega-gpu-driver/paths.txt+2-0
gpu/import/omega-gpu-driver/ref-map+2-0
gpu/nvidia/om/graph/{aux.om => aux_nodes.om}+0-0
gpu/physics0/rng.om+84-0
gpu/physics0/test.om+363-0
gpu/physics0/types.om+248-0
gpu/physics0/wire.om+385-0
gpu/physics0/world.om+429-0
gpu/runtime/INVENTORY.tsv+1-1
gpu/runtime/omega-base.sha256.txt+9-7
gpu/runtime/pathmap.tsv+1-0
gpu/rx/regulate.om+189-0
gpu/rx/skillroute.om+331-0
gpu/rx/test.om+331-0
gpu/spirv/check.sh+27-0
gpu/spirv/conform.om+104-7
gpu/spirv/emit.om+213-16
gpu/spirv/intel-rmsnorm.tsv+4-0
gpu/spirv/intel_rmsnorm.py+896-0
gpu/turing/energy.om+103-0
gpu/turing/select.om+666-0
gpu/turing/test.om+360-0
gpu/turing/types.om+111-0
gpu/units-gate.om+262-5
gpu/units-run.tsv+4-0
gpu/units.tsv+1-1
mk/allen.mk+1-1
mk/visor-authority.mk+1-1
om/gpu/bw_qmd.om+172-0
om/gpu/bw_sched.om+267-0
om/gpu/cg_bf16.om+794-0
om/gpu/cg_gemm.om+1016-0
om/gpu/cg_moe.om+1093-0
om/gpu/cg_moe2.om+790-0
om/gpu/cg_pf.om+178-0
om/gpu/cg_pfhost.om+631-0
om/gpu/cg_qmma.om+434-0
om/gpu/q38_plan.om+186-0
om/gpu/test_gpu_om.om+217-0
om/units.sh+4-4
protocol/NOT-YET-OMEGA.tsv+5821-0
protocol/README.md+39-0
protocol/UNITS.md+17-0
protocol/aien-protocols/core/action_event.om+184-0
protocol/aien-protocols/core/main.om+233-0
protocol/aien-protocols/core/provenance.om+183-0
protocol/aien-protocols/core/test.om+484-0
protocol/aien-protocols/core/types.om+399-0
protocol/aien-protocols/ext/discovery_capsule.om+156-0
protocol/aien-protocols/ext/evaluation.om+110-0
protocol/aien-protocols/ext/microjob.om+144-0
protocol/aien-protocols/ext/probe.om+108-0
protocol/aien-protocols/ext/test.om+485-0
protocol/aien-protocols/specs/aienet/jobpath/matmul_u32_recompute.om+145-0
protocol/aien-protocols/specs/latent-payload/driver.om+45-0
protocol/aien-protocols/specs/latent-payload/validator.om+268-0
protocol/import/aien-protocols-mv/README.md+11-0
protocol/import/aien-protocols-mv/commit-map+98-0
protocol/import/aien-protocols-mv/filter-repo-command.txt+1-0
protocol/import/aien-protocols-mv/filter-repo.version+1-0
protocol/import/aien-protocols-mv/paths.txt+2-0
protocol/import/aien-protocols-mv/ref-map+7-0
protocol/import/interplane-mv/README.md+11-0
protocol/import/interplane-mv/commit-map+182-0
protocol/import/interplane-mv/filter-repo-command.txt+1-0
protocol/import/interplane-mv/filter-repo.version+1-0
protocol/import/interplane-mv/paths.txt+2-0
protocol/import/interplane-mv/ref-map+3-0
protocol/import/omnet/README.md+11-0
protocol/import/omnet/commit-map+34-0
protocol/import/omnet/filter-repo-command.txt+1-0
protocol/import/omnet/filter-repo.version+1-0
protocol/import/omnet/paths.txt+2-0
protocol/import/omnet/ref-map+2-0
protocol/import/synapse-board/README.md+11-0
protocol/import/synapse-board/commit-map+6-0
protocol/import/synapse-board/filter-repo-command.txt+1-0
protocol/import/synapse-board/filter-repo.version+1-0
protocol/import/synapse-board/paths.txt+2-0
protocol/import/synapse-board/ref-map+2-0
protocol/import/synapse-claims/README.md+11-0
protocol/import/synapse-claims/commit-map+8-0
protocol/import/synapse-claims/filter-repo-command.txt+1-0
protocol/import/synapse-claims/filter-repo.version+1-0
protocol/import/synapse-claims/paths.txt+2-0
protocol/import/synapse-claims/ref-map+2-0
protocol/import/synapse-map/README.md+11-0
protocol/import/synapse-map/commit-map+5-0
protocol/import/synapse-map/filter-repo-command.txt+1-0
protocol/import/synapse-map/filter-repo.version+1-0
protocol/import/synapse-map/paths.txt+2-0
protocol/import/synapse-map/ref-map+2-0
protocol/import/synapse-mcp/README.md+11-0
protocol/import/synapse-mcp/commit-map+4-0
protocol/import/synapse-mcp/filter-repo-command.txt+1-0
protocol/import/synapse-mcp/filter-repo.version+1-0
protocol/import/synapse-mcp/paths.txt+2-0
protocol/import/synapse-mcp/ref-map+2-0
protocol/import/synapse-pulse/README.md+11-0
protocol/import/synapse-pulse/commit-map+11-0
protocol/import/synapse-pulse/filter-repo-command.txt+1-0
protocol/import/synapse-pulse/filter-repo.version+1-0
protocol/import/synapse-pulse/paths.txt+2-0
protocol/import/synapse-pulse/ref-map+2-0
protocol/interplane/core/envelope.om+493-0
protocol/interplane/core/main.om+244-0
protocol/interplane/core/policy.om+186-0
protocol/interplane/core/test.om+346-0
protocol/interplane/forge/forge.om+2807-0
protocol/interplane/forge/tests/joinpg.om+13-0
protocol/interplane/omega/hardware/map.om+322-0
protocol/omnet/cmd/tkad/adapter.om+301-0
protocol/omnet/cmd/tkad/helpers.om+294-0
protocol/omnet/cmd/tkad/main.om+154-0
protocol/omnet/cmd/tkad/rpc.om+498-0
protocol/omnet/cmd/tkad/socket.om+134-0
protocol/omnet/cmd/tkad/state.om+424-0
protocol/omnet/om/argon2/argon2.om+317-0
protocol/omnet/om/argon2/argon2pool.om+196-0
protocol/omnet/om/argon2/test/driver.om+203-0
protocol/omnet/om/argon2/test/trap.om+33-0
protocol/omnet/om/blake2b/blake2b.om+202-0
protocol/omnet/om/blake2b/test/driver.om+337-0
protocol/omnet/om/blake2s/blake2s.om+201-0
protocol/omnet/om/blake2s/test/driver.om+336-0
protocol/omnet/om/cbor/cbor.om+626-0
protocol/omnet/om/cbor/test/driver.om+215-0
protocol/omnet/om/codec/codec.om+494-0
protocol/omnet/om/codec/test/driver.om+257-0
protocol/omnet/om/ed25519/ed25519.om+637-0
protocol/omnet/om/ed25519/test/driver.om+216-0
protocol/omnet/om/json/json.om+800-0
protocol/omnet/om/json/test/driver.om+250-0
protocol/omnet/om/quantity/demo.om+94-0
protocol/omnet/om/quantity/fixtures/crypto-wrap.om+12-0
protocol/omnet/om/quantity/fixtures/mixed-object.om+7-0
protocol/omnet/om/quantity/fixtures/mixed-quantity.om+8-0
protocol/omnet/om/quantity/fixtures/mixed-scalar.om+7-0
protocol/omnet/om/quantity/fixtures/mixed-slice.om+7-0
protocol/omnet/om/quantity/mutate.om+95-0
protocol/omnet/om/quantity/oracle-export.om+55-0
protocol/omnet/om/quantity/quantity.om+142-0
protocol/omnet/om/quantity/test/driver.om+214-0
protocol/omnet/om/quantity/tests.om+358-0
protocol/omnet/om/sha512/sha512.om+332-0
protocol/omnet/om/sha512/test/driver.om+389-0
protocol/omnet/om/sha512/test/trap.om+9-0
protocol/omnet/om/store/store.om+217-0
protocol/omnet/om/store/storepool.om+582-0
protocol/omnet/om/store/test/driver.om+199-0
protocol/omnet/om/store/test/resume.om+91-0
protocol/omnet/om/tka/test/driver.om+207-0
protocol/omnet/om/tka/test/revocation.om+90-0
protocol/omnet/om/tka/tka.om+651-0
protocol/omnet/om/tka/tkapool.om+459-0
protocol/omnet/om/tka/tkastate.om+335-0
protocol/omnet/om/tkasig/test/driver.om+129-0
protocol/omnet/om/tkasig/tkasig.om+432-0
protocol/open-humanity/lib.om+1416-0
protocol/open-humanity/main.om+404-0
protocol/open-humanity/test.om+409-0
protocol/rad-id-sync/lib.om+1313-0
protocol/rad-id-sync/main.om+323-0
protocol/rad-id-sync/test.om+559-0
protocol/synapse/board/src/00-util.om+344-0
protocol/synapse/board/src/10-scan.om+501-0
protocol/synapse/board/src/20-emit.om+529-0
protocol/synapse/board/src/30-serve.om+263-0
protocol/synapse/board/src/90-main.om+386-0
protocol/synapse/board/tests/run.om+1515-0
protocol/synapse/board/tools/build.om+952-0
protocol/synapse/claims/src/10_base.om+395-0
protocol/synapse/claims/src/20_time_io.om+329-0
protocol/synapse/claims/src/30_parse.om+410-0
protocol/synapse/claims/src/40_state.om+630-0
protocol/synapse/claims/src/50_event.om+322-0
protocol/synapse/claims/src/70_cmds.om+849-0
protocol/synapse/claims/src/90_main.om+296-0
protocol/synapse/core/changeset.om+966-0
protocol/synapse/core/graph.om+356-0
protocol/synapse/core/lease.om+372-0
protocol/synapse/core/ledger.om+307-0
protocol/synapse/core/main.om+687-0
protocol/synapse/core/review.om+307-0
protocol/synapse/core/test.om+450-0
protocol/synapse/map/src/00-base.om+770-0
protocol/synapse/map/src/10-json.om+619-0
protocol/synapse/map/src/20-infer.om+363-0
protocol/synapse/map/src/30-tok.om+282-0
protocol/synapse/map/src/40-xerj.om+302-0
protocol/synapse/map/src/50-cmds.om+578-0
protocol/synapse/map/src/60-route.om+597-0
protocol/synapse/map/src/70-new.om+460-0
protocol/synapse/map/src/75-publish.om+395-0
protocol/synapse/map/src/99-main.om+99-0
protocol/synapse/mcp/src/00base.om+443-0
protocol/synapse/mcp/src/10mcp.om+1214-0
protocol/synapse/pulse/src/00base.om+509-0
protocol/synapse/pulse/src/10pulse.om+1926-0
protocol/synapse/pulse/src/20main.om+272-0
protocol/units-gate.om+1054-0
protocol/units-run.tsv+10-0
protocol/units.tsv+34-0
seed/omc/diagnostics-v2.py+1-1
seed/omc/omc.om+728-17
seed/omc/qualify-x86.py+1-1
seed/omc/sitecov.floor+1-1
seed/omc/sites/fexp-nodigits.om+4-0
seed/omc/sites/fexp-overflow.om+4-0
seed/omc/sites/fsufx-bad.om+4-0
seed/omc/sites/tok-ctrl.om+4-0
seed/omc/size-history.tsv+2-0
seed/omc/tests/pools/enlarge-users.txt+22-0
seed/out/omcbinary
seed/out/omc.sha256+1-1
seed/qualification/om2/current/qualify.py+4-3
si/NOT-YET-OMEGA.tsv+7225-0
si/README.md+57-0
si/STACK.tsv+93-0
si/UNITS.md+17-0
si/agent-archive/lib.om+1056-0
si/agent-archive/main.om+191-0
si/agent-archive/test.om+288-0
si/aien-harness/harness.om+919-0
si/aien-harness/test.om+965-0
si/architecture/tests/ecosystem303/catalogue-test.om+159-0
si/architecture/tests/ecosystem303/mutate.om+98-0
si/architecture/tools/candidate/check_candidate.om+1838-0
si/architecture/tools/candidate/check_pins.om+1655-0
si/architecture/tools/capreg/capreg.om+1210-0
si/architecture/tools/capreg/gate.om+559-0
si/architecture/tools/doctrine/doctrine.om+1827-0
si/architecture/tools/doctrine/gate.om+361-0
si/architecture/tools/ecosystem303/catalogue.om+159-0
si/architecture/tools/ecosystem303/cli.om+104-0
si/architecture/tools/name-check/gate.om+458-0
si/architecture/tools/name-check/namecheck.om+779-0
si/architecture/tools/zero-legacy/closure.om+1063-0
si/architecture/tools/zero-legacy/elfclose.om+1301-0
si/architecture/tools/zero-legacy/expect.om+175-0
si/architecture/tools/zero-legacy/fixtures/clean/src/ok.om+3-0
si/architecture/tools/zero-legacy/fixtures/elfgen.om+328-0
si/architecture/tools/zero-legacy/fixtures/io-build.om+134-0
si/architecture/tools/zero-legacy/fixtures/io-errors.om+55-0
si/architecture/tools/zero-legacy/fixtures/loader-sentinel.om+11-0
si/architecture/tools/zero-legacy/fixtures/tree/src/hello.om+4-0
si/architecture/tools/zero-legacy/fixtures/tree/src/launch.om+7-0
si/architecture/tools/zero-legacy/fixtures/tree/src/launch2.om+6-0
si/architecture/tools/zero-legacy/fixtures/tree/src/link.om+1-0
si/architecture/tools/zero-legacy/fixtures/tree/src/sh.om+2-0
si/architecture/tools/zero-legacy/gate.om+590-0
si/architecture/tools/zero-legacy/sha256.om+271-0
si/architecture/verify/authority.om+275-0
si/architecture/verify/test.om+235-0
si/benchmarks/native/neuralese/fixtures/nl7-fixture.om+203-0
si/benchmarks/native/neuralese/learn-cli.om+3-0
si/benchmarks/native/neuralese/learncase.om+54-0
si/benchmarks/native/neuralese/learnscore.om+328-0
si/benchmarks/native/neuralese/nl1r/arithmetic.om+235-0
si/benchmarks/native/neuralese/nl1r/boundary-oracle.om+200-0
si/benchmarks/native/neuralese/nl1r/checkpoint.om+162-0
si/benchmarks/native/neuralese/nl1r/evidence/boundary-independent-source.om+1379-0
si/benchmarks/native/neuralese/nl1r/evidence/boundary-oracle-source.om+896-0
si/benchmarks/native/neuralese/nl1r/evidence/boundary-replay/mutant-execute-before-all-verified.om+1377-0
si/benchmarks/native/neuralese/nl1r/evidence/boundary-replay/mutant-no-envelope-validation.om+1379-0
si/benchmarks/native/neuralese/nl1r/evidence/boundary-replay/mutant-no-receiver-match.om+1379-0
si/benchmarks/native/neuralese/nl1r/evidence/boundary-replay/mutant-wrong-chunk-expectation.om+1379-0
si/benchmarks/native/neuralese/nl1r/evidence/confirm-20261107/out/boundary-oracle.om+896-0
si/benchmarks/native/neuralese/nl1r/evidence/confirm-20261107/out/boundary.om+1379-0
si/benchmarks/native/neuralese/nl1r/evidence/confirm-20261107/out/capacity.om+852-0
si/benchmarks/native/neuralese/nl1r/evidence/confirm-20261107/out/checkpoint.om+302-0
si/benchmarks/native/neuralese/nl1r/evidence/confirm-20261107/out/judge.om+732-0
si/benchmarks/native/neuralese/nl1r/evidence/confirm-20261107/out/task.om+887-0
si/benchmarks/native/neuralese/nl1r/evidence/fixture-source.om+541-0
si/benchmarks/native/neuralese/nl1r/evidence/judge-source.om+734-0
si/benchmarks/native/neuralese/nl1r/fixture.om+173-0
si/benchmarks/native/neuralese/nl1r/io.om+140-0
si/benchmarks/native/neuralese/nl1r/judge.om+357-0
si/benchmarks/native/neuralese/nl1r/mutate.om+101-0
si/benchmarks/native/neuralese/nl7-score.om+526-0
si/benchmarks/native/neuralese/nl7-wire.om+439-0
si/benchmarks/native/neuralese/score.om+360-0
si/benchmarks/native/queueflow/flow.om+907-0
si/benchmarks/native/queueflow/kflow.om+824-0
si/benchmarks/tests/gates/provenance-check.om+1591-0
si/benchmarks/verify/bundle.om+272-0
si/benchmarks/verify/test.om+225-0
si/directives/om2.om+1-0
si/directives/target-a64efi.om+1-0
si/directives/target-x86efi.om+1-0
si/directives/target-x86linux.om+1-0
si/editors/tree-sitter/test/highlight/basics.om+36-0
si/editors/tree-sitter/test/highlight/om1-names.om+9-0
si/editors/tree-sitter/test/negative/malformed.om+5-0
si/editors/vscode/test/fixtures/field-call.om+17-0
si/editors/vscode/test/fixtures/layout.om+9-0
si/editors/vscode/test/fixtures/notes.om+11-0
si/front-door/compiler/gate.om+2113-0
si/front-door/compiler/links.om+558-0
si/front-door/compiler/rebuild.om+1445-0
si/front-door/compiler/si.om+1164-0
si/front-door/tests/ledger/alpha/main.om+4-0
si/front-door/tests/omc/examples/count_err03_om1.om+6-0
si/front-door/tests/omc/examples/count_err04_short.om+7-0
si/front-door/tests/omc/examples/count_err07_element.om+7-0
si/front-door/tests/omc/examples/count_err07_offset.om+7-0
si/front-door/tests/omc/examples/count_err07_scalar.om+7-0
si/front-door/tests/omc/examples/count_err07_struct.om+11-0
si/front-door/tests/omc/examples/count_err07_value.om+7-0
si/front-door/tests/omc/examples/count_err08_value.om+7-0
si/front-door/tests/omc/examples/count_err09_part.om+7-0
si/front-door/tests/omc/examples/count_err16_name.om+6-0
si/front-door/tests/omc/examples/count_err16_statement.om+7-0
si/front-door/tests/omc/examples/count_err27_fresh.om+10-0
si/front-door/tests/omc/examples/count_err30_contract.om+11-0
si/front-door/tests/omc/examples/count_trap3.om+11-0
si/front-door/tests/omc/examples/count_trap3_wrap.om+11-0
si/front-door/tests/omc/examples/count_word.om+201-0
si/front-door/tests/regress/fma_second_ambig.om+6-0
si/front-door/tests/regress/fma_third_int.om+7-0
si/front-door/tests/regress/fma_width_mix.om+6-0
si/front-door/tools/adapter/half.om+17-0
si/front-door/tools/forkpush.om+585-0
si/front-door/tools/ledger.om+484-0
si/harness/coder/eval/cat.om+23-0
si/harness/coder/eval/selftest/src-control/st1-pass.om+6-0
si/harness/coder/eval/selftest/src/sc-big.om+8-0
si/harness/coder/eval/selftest/src/sc-e127.om+4-0
si/harness/coder/eval/selftest/src/sc-rightout.om+6-0
si/harness/coder/eval/selftest/src/st1-pass.om+6-0
si/harness/coder/eval/selftest/src/st2-wrong.om+6-0
si/harness/coder/eval/selftest/src/st3-exit.om+6-0
si/harness/coder/eval/selftest/src/st4-badcompile.om+3-0
si/harness/coder/eval/selftest/src/st6-stdin.om+32-0
si/harness/coder/eval/selftest/src/st7-cheat.om+17-0
si/harness/coder/observed/between_fns.om+9-0
si/harness/coder/observed/elif_is_assignment.om+14-0
si/harness/coder/observed/else_nested.om+11-0
si/harness/coder/observed/struct_after_fn.om+7-0
si/harness/examples/a64efi_efi_needs_efirt.om+6-0
si/harness/examples/a64efi_host_word.om+5-0
si/harness/examples/a64efi_read.om+6-0
si/harness/examples/a64efi_reserved_name.om+7-0
si/harness/examples/arrays.om+55-0
si/harness/examples/block_frees_registers.om+26-0
si/harness/examples/bound_input_guard.om+26-0
si/harness/examples/checked_conv.om+51-0
si/harness/examples/consts.om+58-0
si/harness/examples/contract_ensures.om+13-0
si/harness/examples/contract_invariant.om+12-0
si/harness/examples/contract_release.om+9-0
si/harness/examples/contract_requires.om+12-0
si/harness/examples/contracts_ok.om+15-0
si/harness/examples/decl_order.om+10-0
si/harness/examples/defect_keyword_prefix.om+9-0
si/harness/examples/echo_args.om+72-0
si/harness/examples/empty_text_part.om+19-0
si/harness/examples/env_read.om+67-0
si/harness/examples/err01_input.om+4-0
si/harness/examples/err02_output.om+4-0
si/harness/examples/err03_unknown_name.om+4-0
si/harness/examples/err04_line_ends.om+5-0
si/harness/examples/err05_extra_words.om+5-0
si/harness/examples/err06_bad_number.om+5-0
si/harness/examples/err07_type_mismatch.om+6-0
si/harness/examples/err08_out_of_range.om+5-0
si/harness/examples/err09_disallowed.om+7-0
si/harness/examples/err10_duplicate.om+7-0
si/harness/examples/err11_ambiguous.om+5-0
si/harness/examples/err12_registers.om+21-0
si/harness/examples/err13_long_name.om+5-0
si/harness/examples/err14_capacity.om+101-0
si/harness/examples/err15_missing_end.om+3-0
si/harness/examples/err16_syntax.om+4-0
si/harness/examples/err17_after_path.om+5-0
si/harness/examples/err18_missing_ret.om+9-0
si/harness/examples/err19_global_arg.om+9-0
si/harness/examples/err20_pread_text.om+8-0
si/harness/examples/err20_readonly.om+6-0
si/harness/examples/err21_const_index.om+6-0
si/harness/examples/err22_text_escape.om+5-0
si/harness/examples/err23_size.om+5-0
si/harness/examples/err25_target.om+5-0
si/harness/examples/err27_fresh.om+9-0
si/harness/examples/err28_seal.om+8-0
si/harness/examples/err29_layout.om+8-0
si/harness/examples/err30_contract.om+12-0
si/harness/examples/execenv.om+79-0
si/harness/examples/exit_status.om+4-0
si/harness/examples/float_arith.om+63-0
si/harness/examples/float_to_int.om+51-0
si/harness/examples/for_bound.om+10-0
si/harness/examples/functions.om+66-0
si/harness/examples/globals.om+63-0
si/harness/examples/hello.om+9-0
si/harness/examples/int_arith.om+53-0
si/harness/examples/int_bits_and.om+10-0
si/harness/examples/layout_word_plain.om+5-0
si/harness/examples/local_arrays_per_fn.om+9-0
si/harness/examples/loops.om+70-0
si/harness/examples/mistake_bound_input.om+24-0
si/harness/examples/mistake_bound_range.om+8-0
si/harness/examples/mistake_c_call.om+7-0
si/harness/examples/mistake_char_literal.om+5-0
si/harness/examples/mistake_compare_operator.om+8-0
si/harness/examples/mistake_decl_order.om+6-0
si/harness/examples/mistake_deep_nest.om+5-0
si/harness/examples/mistake_else_if.om+10-0
si/harness/examples/mistake_free.om+5-0
si/harness/examples/mistake_infix.om+6-0
si/harness/examples/mistake_ir_bound.om+9-0
si/harness/examples/mistake_local_arrays.om+6-0
si/harness/examples/mistake_main_args.om+4-0
si/harness/examples/mistake_neg_name.om+5-0
si/harness/examples/mistake_new_var_len.om+6-0
si/harness/examples/mistake_om1_rotr.om+5-0
si/harness/examples/mistake_om2_int_hex.om+6-0
si/harness/examples/mistake_om2_layout_late.om+8-0
si/harness/examples/mistake_om2_layout_zero_count.om+8-0
si/harness/examples/mistake_om2_param_slots.om+9-0
si/harness/examples/mistake_om2_part_global.om+9-0
si/harness/examples/mistake_om2_part_sized.om+9-0
si/harness/examples/mistake_om2_part_statement.om+7-0
si/harness/examples/mistake_om2_upper_hex.om+6-0
si/harness/examples/mistake_om2_word_layout.om+6-0
si/harness/examples/mistake_om2_word_name.om+6-0
si/harness/examples/mistake_om2_word_open.om+6-0
si/harness/examples/mistake_om2_word_out.om+6-0
si/harness/examples/mistake_om2_word_seal.om+6-0
si/harness/examples/mistake_param_length.om+8-0
si/harness/examples/mistake_reserved_name.om+5-0
si/harness/examples/mistake_return.om+5-0
si/harness/examples/mistake_semicolon.om+5-0
si/harness/examples/mistake_seven_params.om+7-0
si/harness/examples/mistake_short_circuit.om+10-0
si/harness/examples/mistake_slash_comment.om+5-0
si/harness/examples/mistake_struct_after_fn.om+5-0
si/harness/examples/mistake_trap_range.om+4-0
si/harness/examples/mistake_value_stmt.om+8-0
si/harness/examples/mistake_word_edit.om+5-0
si/harness/examples/mistake_word_view.om+5-0
si/harness/examples/om2_hex_rotr.om+40-0
si/harness/examples/om2_param_slots.om+24-0
si/harness/examples/om2_part_trap.om+17-0
si/harness/examples/om2_tour.om+43-0
si/harness/examples/om2_views.om+53-0
si/harness/examples/om2_word_plain.om+5-0
si/harness/examples/p10_profile.om+39-0
si/harness/examples/print_decimal.om+50-0
si/harness/examples/pwrite_text.om+29-0
si/harness/examples/stdin_count.om+71-0
si/harness/examples/structs.om+59-0
si/harness/examples/text.om+48-0
si/harness/examples/tmp_files.om+81-0
si/harness/examples/trap1_divmin.om+12-0
si/harness/examples/trap1_overflow.om+8-0
si/harness/examples/trap2_div0.om+8-0
si/harness/examples/trap3_bounds.om+9-0
si/harness/examples/trap4_for_bound.om+11-0
si/harness/examples/trap4_loop.om+10-0
si/harness/examples/trap5_conv.om+8-0
si/harness/examples/trap6_stack.om+13-0
si/harness/examples/trap7_shift.om+8-0
si/harness/examples/trap_code.om+6-0
si/harness/examples/unsigned_wrap.om+56-0
si/harness/examples/wire_le.om+68-0
si/harness/skills/omega-encoding/examples/fnv1a32.om+55-0
si/harness/skills/omega-encoding/examples/pitfall_elif.om+14-0
si/harness/skills/omega-encoding/examples/pitfall_or_global.om+9-0
si/harness/skills/omega-encoding/examples/pitfall_shared_name.om+14-0
si/harness/skills/omega-encoding/examples/trap_narrow.om+9-0
si/harness/tools/guides.om+2085-0
si/harness/tools/jflat.om+533-0
si/harness/tools/rules.om+1152-0
si/harvester/harvester.om+1011-0
si/harvester/test.om+1150-0
si/import/aien-architecture-mv/README.md+11-0
si/import/aien-architecture-mv/commit-map+480-0
si/import/aien-architecture-mv/filter-repo-command.txt+1-0
si/import/aien-architecture-mv/filter-repo.version+1-0
si/import/aien-architecture-mv/paths.txt+2-0
si/import/aien-architecture-mv/ref-map+2-0
si/import/aien-receipts/README.md+11-0
si/import/aien-receipts/commit-map+555-0
si/import/aien-receipts/filter-repo-command.txt+1-0
si/import/aien-receipts/filter-repo.version+1-0
si/import/aien-receipts/paths.txt+2-0
si/import/aien-receipts/ref-map+4-0
si/import/benchmarks-mv/README.md+11-0
si/import/benchmarks-mv/commit-map+131-0
si/import/benchmarks-mv/filter-repo-command.txt+1-0
si/import/benchmarks-mv/filter-repo.version+1-0
si/import/benchmarks-mv/paths.txt+2-0
si/import/benchmarks-mv/ref-map+4-0
si/import/omega-harness/README.md+11-0
si/import/omega-harness/commit-map+334-0
si/import/omega-harness/filter-repo-command.txt+1-0
si/import/omega-harness/filter-repo.version+1-0
si/import/omega-harness/paths.txt+2-0
si/import/omega-harness/ref-map+3-0
si/import/omega-mcp/README.md+11-0
si/import/omega-mcp/commit-map+48-0
si/import/omega-mcp/filter-repo-command.txt+1-0
si/import/omega-mcp/filter-repo.version+1-0
si/import/omega-mcp/paths.txt+2-0
si/import/omega-mcp/ref-map+3-0
si/import/omega-packages/README.md+11-0
si/import/omega-packages/commit-map+13-0
si/import/omega-packages/filter-repo-command.txt+1-0
si/import/omega-packages/filter-repo.version+1-0
si/import/omega-packages/paths.txt+2-0
si/import/omega-packages/ref-map+2-0
si/import/omega-rosetta/README.md+11-0
si/import/omega-rosetta/commit-map+5-0
si/import/omega-rosetta/filter-repo-command.txt+1-0
si/import/omega-rosetta/filter-repo.version+1-0
si/import/omega-rosetta/paths.txt+2-0
si/import/omega-rosetta/ref-map+2-0
si/import/sovereign-intelligence/README.md+13-0
si/import/sovereign-intelligence/commit-map+75-0
si/import/sovereign-intelligence/filter-repo-command.txt+1-0
si/import/sovereign-intelligence/filter-repo.version+1-0
si/import/sovereign-intelligence/paths.txt+6-0
si/import/sovereign-intelligence/ref-map+5-0
si/import/tree-sitter-omega/README.md+11-0
si/import/tree-sitter-omega/commit-map+8-0
si/import/tree-sitter-omega/filter-repo-command.txt+1-0
si/import/tree-sitter-omega/filter-repo.version+1-0
si/import/tree-sitter-omega/paths.txt+2-0
si/import/tree-sitter-omega/ref-map+2-0
si/import/vscode-omega/README.md+11-0
si/import/vscode-omega/commit-map+11-0
si/import/vscode-omega/filter-repo-command.txt+1-0
si/import/vscode-omega/filter-repo.version+1-0
si/import/vscode-omega/paths.txt+2-0
si/import/vscode-omega/ref-map+3-0
si/inquisitor/lib.om+2361-0
si/inquisitor/main.om+106-0
si/inquisitor/test.om+550-0
si/mcp/data/examples/argsenv.om+10-0
si/mcp/data/examples/argtrap.om+6-0
si/mcp/data/examples/arith.om+39-0
si/mcp/data/examples/arrays.om+20-0
si/mcp/data/examples/calls.om+17-0
si/mcp/data/examples/clock.om+17-0
si/mcp/data/examples/consts.om+11-0
si/mcp/data/examples/contract_fail.om+9-0
si/mcp/data/examples/contracts.om+16-0
si/mcp/data/examples/control.om+29-0
si/mcp/data/examples/cpu_order.om+6-0
si/mcp/data/examples/dirs.om+42-0
si/mcp/data/examples/e03.om+3-0
si/mcp/data/examples/e04.om+4-0
si/mcp/data/examples/e05.om+3-0
si/mcp/data/examples/e06.om+4-0
si/mcp/data/examples/e07.om+4-0
si/mcp/data/examples/e08.om+4-0
si/mcp/data/examples/e09.om+4-0
si/mcp/data/examples/e10.om+6-0
si/mcp/data/examples/e11.om+4-0
si/mcp/data/examples/e12.om+20-0
si/mcp/data/examples/e13.om+4-0
si/mcp/data/examples/e14.om+4-0
si/mcp/data/examples/e15.om+2-0
si/mcp/data/examples/e16.om+1-0
si/mcp/data/examples/e17.om+4-0
si/mcp/data/examples/e18.om+5-0
si/mcp/data/examples/e19.om+7-0
si/mcp/data/examples/e20.om+5-0
si/mcp/data/examples/e21.om+5-0
si/mcp/data/examples/e22.om+4-0
si/mcp/data/examples/e23.om+4-0
si/mcp/data/examples/e25.om+4-0
si/mcp/data/examples/e27.om+8-0
si/mcp/data/examples/e28.om+6-0
si/mcp/data/examples/e29.om+7-0
si/mcp/data/examples/e30.om+8-0
si/mcp/data/examples/exit.om+4-0
si/mcp/data/examples/files.om+39-0
si/mcp/data/examples/floats.om+12-0
si/mcp/data/examples/fma.om+15-0
si/mcp/data/examples/for_guard.om+12-0
si/mcp/data/examples/free_refused.om+5-0
si/mcp/data/examples/hello.om+6-0
si/mcp/data/examples/ints.om+20-0
si/mcp/data/examples/kfd.om+15-0
si/mcp/data/examples/kfdmap_trap.om+7-0
si/mcp/data/examples/limits.om+28-0
si/mcp/data/examples/mapping.om+37-0
si/mcp/data/examples/om2_abstract.om+21-0
si/mcp/data/examples/om2_export.om+5-0
si/mcp/data/examples/om2_fresh.om+12-0
si/mcp/data/examples/om2_layout.om+15-0
si/mcp/data/examples/om2_out.om+12-0
si/mcp/data/examples/om2_part.om+9-0
si/mcp/data/examples/om2_rotate.om+8-0
si/mcp/data/examples/om2_unroll.om+12-0
si/mcp/data/examples/own_refused.om+5-0
si/mcp/data/examples/peername.om+5-0
si/mcp/data/examples/pools.om+16-0
si/mcp/data/examples/procs.om+33-0
si/mcp/data/examples/qty.om+6-0
si/mcp/data/examples/sched.om+16-0
si/mcp/data/examples/secrets.om+8-0
si/mcp/data/examples/sockets.om+37-0
si/mcp/data/examples/structs.om+9-0
si/mcp/data/examples/t01.om+5-0
si/mcp/data/examples/t02.om+4-0
si/mcp/data/examples/t03.om+5-0
si/mcp/data/examples/t04.om+7-0
si/mcp/data/examples/t05.om+5-0
si/mcp/data/examples/t06.om+6-0
si/mcp/data/examples/t07.om+5-0
si/mcp/data/examples/t08.om+4-0
si/mcp/data/examples/t10.om+8-0
si/mcp/data/examples/t11.om+4-0
si/mcp/data/examples/t12.om+4-0
si/mcp/data/examples/t13.om+4-0
si/mcp/data/examples/t14.om+4-0
si/mcp/data/examples/trapword.om+4-0
si/mcp/data/examples/vfio.om+23-0
si/mcp/data/examples/vfioirq_trap.om+6-0
si/mcp/gates/pincheck.om+421-0
si/mcp/maintenance/rpc.om+633-0
si/mcp/maintenance/state.om+111-0
si/mcp/maintenance/store.om+1524-0
si/mcp/maintenance/validate.om+326-0
si/mcp/qa/rpc.om+691-0
si/mcp/qa/store.om+1101-0
si/mcp/src/boot.om+152-0
si/mcp/src/rpc.om+652-0
si/mcp/src/sandbox.om+669-0
si/mcp/src/state.om+134-0
si/mcp/src/tools.om+1102-0
si/mcp/src/util.om+394-0
si/packages/examples/hello.om+19-0
si/packages/homebrew/formula.om+811-0
si/packages/homebrew/test.om+814-0
si/receipts/audit/tls/omega-mv/bench/drivers/bench.om+239-0
si/rosetta/bench/solutions/HumanEval_0.om+12-0
si/rosetta/bench/solutions/HumanEval_13.om+9-0
si/rosetta/bench/solutions/HumanEval_16.om+14-0
si/rosetta/bench/solutions/HumanEval_2.om+3-0
si/rosetta/bench/solutions/HumanEval_27.om+15-0
si/rosetta/bench/solutions/HumanEval_3.om+9-0
si/rosetta/bench/solutions/HumanEval_30.om+10-0
si/rosetta/bench/solutions/HumanEval_48.om+9-0
si/rosetta/bench/solutions/HumanEval_53.om+2-0
si/rosetta/bench/solutions/HumanEval_9.om+12-0
si/rosetta/exercises/acronym/.meta/example.om+28-0
si/rosetta/exercises/acronym/acronym.om+10-0
si/rosetta/exercises/acronym/test.om+153-0
si/rosetta/exercises/all-your-base/.meta/example.om+37-0
si/rosetta/exercises/all-your-base/all-your-base.om+11-0
si/rosetta/exercises/all-your-base/test.om+370-0
si/rosetta/exercises/allergies/.meta/example.om+106-0
si/rosetta/exercises/allergies/allergies.om+16-0
si/rosetta/exercises/allergies/test.om+432-0
si/rosetta/exercises/armstrong-numbers/.meta/example.om+28-0
si/rosetta/exercises/armstrong-numbers/armstrong-numbers.om+9-0
si/rosetta/exercises/armstrong-numbers/test.om+66-0
si/rosetta/exercises/atbash-cipher/.meta/example.om+55-0
si/rosetta/exercises/atbash-cipher/atbash-cipher.om+15-0
si/rosetta/exercises/atbash-cipher/test.om+203-0
si/rosetta/exercises/binary-search/.meta/example.om+23-0
si/rosetta/exercises/binary-search/binary-search.om+10-0
si/rosetta/exercises/binary-search/test.om+199-0
si/rosetta/exercises/bob/.meta/example.om+60-0
si/rosetta/exercises/bob/bob.om+12-0
si/rosetta/exercises/bob/test.om+327-0
si/rosetta/exercises/change/.meta/example.om+64-0
si/rosetta/exercises/change/change.om+11-0
si/rosetta/exercises/change/test.om+307-0
si/rosetta/exercises/collatz-conjecture/.meta/example.om+18-0
si/rosetta/exercises/collatz-conjecture/collatz-conjecture.om+9-0
si/rosetta/exercises/collatz-conjecture/test.om+58-0
si/rosetta/exercises/darts/.meta/example.om+19-0
si/rosetta/exercises/darts/darts.om+10-0
si/rosetta/exercises/darts/test.om+130-0
si/rosetta/exercises/difference-of-squares/.meta/example.om+16-0
si/rosetta/exercises/difference-of-squares/difference-of-squares.om+18-0
si/rosetta/exercises/difference-of-squares/test.om+66-0
si/rosetta/exercises/eliuds-eggs/.meta/example.om+14-0
si/rosetta/exercises/eliuds-eggs/eliuds-eggs.om+9-0
si/rosetta/exercises/eliuds-eggs/test.om+76-0
si/rosetta/exercises/grains/.meta/example.om+12-0
si/rosetta/exercises/grains/grains.om+14-0
si/rosetta/exercises/grains/test.om+64-0
si/rosetta/exercises/hamming/.meta/example.om+18-0
si/rosetta/exercises/hamming/hamming.om+10-0
si/rosetta/exercises/hamming/test.om+124-0
si/rosetta/exercises/hello-world/.meta/example.om+12-0
si/rosetta/exercises/hello-world/hello-world.om+9-0
si/rosetta/exercises/hello-world/test.om+72-0
si/rosetta/exercises/isbn-verifier/.meta/example.om+32-0
si/rosetta/exercises/isbn-verifier/isbn-verifier.om+10-0
si/rosetta/exercises/isbn-verifier/test.om+199-0
si/rosetta/exercises/isogram/.meta/example.om+22-0
si/rosetta/exercises/isogram/isogram.om+9-0
si/rosetta/exercises/isogram/test.om+150-0
si/rosetta/exercises/knapsack/.meta/example.om+29-0
si/rosetta/exercises/knapsack/knapsack.om+10-0
si/rosetta/exercises/knapsack/test.om+184-0
si/rosetta/exercises/largest-series-product/.meta/example.om+43-0
si/rosetta/exercises/largest-series-product/largest-series-product.om+10-0
si/rosetta/exercises/largest-series-product/test.om+157-0
si/rosetta/exercises/leap/.meta/example.om+15-0
si/rosetta/exercises/leap/leap.om+10-0
si/rosetta/exercises/leap/test.om+66-0
si/rosetta/exercises/luhn/.meta/example.om+29-0
si/rosetta/exercises/luhn/luhn.om+10-0
si/rosetta/exercises/luhn/test.om+206-0
si/rosetta/exercises/nth-prime/.meta/example.om+29-0
si/rosetta/exercises/nth-prime/nth-prime.om+9-0
si/rosetta/exercises/nth-prime/test.om+82-0
si/rosetta/exercises/nucleotide-count/.meta/example.om+32-0
si/rosetta/exercises/nucleotide-count/nucleotide-count.om+10-0
si/rosetta/exercises/nucleotide-count/test.om+139-0
si/rosetta/exercises/pangram/.meta/example.om+23-0
si/rosetta/exercises/pangram/pangram.om+9-0
si/rosetta/exercises/pangram/test.om+122-0
si/rosetta/exercises/pascals-triangle/.meta/example.om+20-0
si/rosetta/exercises/pascals-triangle/pascals-triangle.om+10-0
si/rosetta/exercises/pascals-triangle/test.om+245-0
si/rosetta/exercises/perfect-numbers/.meta/example.om+32-0
si/rosetta/exercises/perfect-numbers/perfect-numbers.om+10-0
si/rosetta/exercises/perfect-numbers/test.om+136-0
si/rosetta/exercises/prime-factors/.meta/example.om+25-0
si/rosetta/exercises/prime-factors/prime-factors.om+10-0
si/rosetta/exercises/prime-factors/test.om+198-0
si/rosetta/exercises/protein-translation/.meta/example.om+105-0
si/rosetta/exercises/protein-translation/protein-translation.om+12-0
si/rosetta/exercises/protein-translation/test.om+438-0
si/rosetta/exercises/queen-attack/.meta/example.om+33-0
si/rosetta/exercises/queen-attack/queen-attack.om+15-0
si/rosetta/exercises/queen-attack/test.om+130-0
si/rosetta/exercises/raindrops/.meta/example.om+47-0
si/rosetta/exercises/raindrops/raindrops.om+10-0
si/rosetta/exercises/raindrops/test.om+225-0
si/rosetta/exercises/resistor-color-duo/.meta/example.om+82-0
si/rosetta/exercises/resistor-color-duo/resistor-color-duo.om+11-0
si/rosetta/exercises/resistor-color-duo/test.om+101-0
si/rosetta/exercises/resistor-color-trio/.meta/example.om+130-0
si/rosetta/exercises/resistor-color-trio/resistor-color-trio.om+13-0
si/rosetta/exercises/resistor-color-trio/test.om+163-0
si/rosetta/exercises/resistor-color/.meta/example.om+91-0
si/rosetta/exercises/resistor-color/resistor-color.om+15-0
si/rosetta/exercises/resistor-color/test.om+93-0
si/rosetta/exercises/reverse-string/.meta/example.om+12-0
si/rosetta/exercises/reverse-string/reverse-string.om+9-0
si/rosetta/exercises/reverse-string/test.om+122-0
si/rosetta/exercises/rna-transcription/.meta/example.om+26-0
si/rosetta/exercises/rna-transcription/rna-transcription.om+10-0
si/rosetta/exercises/rna-transcription/test.om+122-0
si/rosetta/exercises/rotational-cipher/.meta/example.om+21-0
si/rosetta/exercises/rotational-cipher/rotational-cipher.om+10-0
si/rosetta/exercises/rotational-cipher/test.om+163-0
si/rosetta/exercises/run-length-encoding/.meta/example.om+71-0
si/rosetta/exercises/run-length-encoding/run-length-encoding.om+15-0
si/rosetta/exercises/run-length-encoding/test.om+193-0
si/rosetta/exercises/saddle-points/.meta/example.om+38-0
si/rosetta/exercises/saddle-points/saddle-points.om+11-0
si/rosetta/exercises/saddle-points/test.om+238-0
si/rosetta/exercises/scrabble-score/.meta/example.om+21-0
si/rosetta/exercises/scrabble-score/scrabble-score.om+10-0
si/rosetta/exercises/scrabble-score/test.om+129-0
si/rosetta/exercises/secret-handshake/.meta/example.om+49-0
si/rosetta/exercises/secret-handshake/secret-handshake.om+11-0
si/rosetta/exercises/secret-handshake/test.om+160-0
si/rosetta/exercises/series/.meta/example.om+35-0
si/rosetta/exercises/series/series.om+11-0
si/rosetta/exercises/series/test.om+181-0
si/rosetta/exercises/sieve/.meta/example.om+25-0
si/rosetta/exercises/sieve/sieve.om+10-0
si/rosetta/exercises/sieve/test.om+286-0
si/rosetta/exercises/space-age/.meta/example.om+61-0
si/rosetta/exercises/space-age/space-age.om+12-0
si/rosetta/exercises/space-age/test.om+123-0
si/rosetta/exercises/square-root/.meta/example.om+18-0
si/rosetta/exercises/square-root/square-root.om+9-0
si/rosetta/exercises/square-root/test.om+88-0
si/rosetta/exercises/sum-of-multiples/.meta/example.om+24-0
si/rosetta/exercises/sum-of-multiples/sum-of-multiples.om+10-0
si/rosetta/exercises/sum-of-multiples/test.om+196-0
si/rosetta/exercises/triangle/.meta/example.om+22-0
si/rosetta/exercises/triangle/test.om+178-0
si/rosetta/exercises/triangle/triangle.om+19-0
si/rosetta/exercises/two-fer/.meta/example.om+27-0
si/rosetta/exercises/two-fer/test.om+93-0
si/rosetta/exercises/two-fer/two-fer.om+10-0
si/rosetta/tasks/100-doors/100-doors.om+55-0
si/rosetta/tasks/99-bottles-of-beer/99-bottles-of-beer.om+64-0
si/rosetta/tasks/abc-problem/abc-problem.om+79-0
si/rosetta/tasks/abelian-sandpile-model/abelian-sandpile-model.om+97-0
si/rosetta/tasks/abundant-deficient-and-perfect-number-classifications/abundant-deficient-and-perfect-number-classifications.om+77-0
si/rosetta/tasks/ackermann-function/ackermann-function.om+57-0
si/rosetta/tasks/additive-primes/additive-primes.om+92-0
si/rosetta/tasks/almost-prime/almost-prime.om+72-0
si/rosetta/tasks/amicable-pairs/amicable-pairs.om+60-0
si/rosetta/tasks/anagrams/anagrams.om+121-0
si/rosetta/tasks/anti-primes/anti-primes.om+66-0
si/rosetta/tasks/array-concatenation/array-concatenation.om+61-0
si/rosetta/tasks/attractive-numbers/attractive-numbers.om+85-0
si/rosetta/tasks/bacon-cipher/bacon-cipher.om+85-0
si/rosetta/tasks/base64-encode-data/base64-encode-data.om+60-0
si/rosetta/tasks/bead-sort/bead-sort.om+121-0
si/rosetta/tasks/bell-numbers/bell-numbers.om+113-0
si/rosetta/tasks/binary-digits/binary-digits.om+38-0
si/rosetta/tasks/binary-search/binary-search.om+98-0
si/rosetta/tasks/bogosort/bogosort.om+132-0
si/rosetta/tasks/bubble-sort/bubble-sort.om+83-0
si/rosetta/tasks/caesar-cipher/caesar-cipher.om+43-0
si/rosetta/tasks/camel-case-and-snake-case/camel-case-and-snake-case.om+115-0
si/rosetta/tasks/catalan-numbers/catalan-numbers.om+60-0
si/rosetta/tasks/character-codes/character-codes.om+50-0
si/rosetta/tasks/cocktail-sort-with-shifting-bounds/cocktail-sort-with-shifting-bounds.om+125-0
si/rosetta/tasks/cocktail-sort/cocktail-sort.om+125-0
si/rosetta/tasks/comb-sort/comb-sort.om+113-0
si/rosetta/tasks/combinations-with-repetitions/combinations-with-repetitions.om+90-0
si/rosetta/tasks/combinations/combinations.om+77-0
si/rosetta/tasks/comma-quibbling/comma-quibbling.om+65-0
si/rosetta/tasks/conways-game-of-life/conways-game-of-life.om+126-0
si/rosetta/tasks/copy-a-string/copy-a-string.om+38-0
si/rosetta/tasks/count-how-many-vowels-and-consonants-occur-in-a-string/count-how-many-vowels-and-consonants-occur-in-a-string.om+82-0
si/rosetta/tasks/count-in-factors/count-in-factors.om+76-0
si/rosetta/tasks/count-occurrences-of-a-substring/count-occurrences-of-a-substring.om+61-0
si/rosetta/tasks/count-the-coins/count-the-coins.om+71-0
si/rosetta/tasks/counting-sort/counting-sort.om+117-0
si/rosetta/tasks/crc-32/crc-32.om+51-0
si/rosetta/tasks/cuban-primes/cuban-primes.om+137-0
si/rosetta/tasks/cycle-sort/cycle-sort.om+136-0
si/rosetta/tasks/determinant-and-permanent/determinant-and-permanent.om+207-0
si/rosetta/tasks/determine-if-a-string-has-all-the-same-characters/determine-if-a-string-has-all-the-same-characters.om+77-0
si/rosetta/tasks/determine-if-a-string-has-all-unique-characters/determine-if-a-string-has-all-unique-characters.om+80-0
si/rosetta/tasks/determine-if-a-string-is-collapsible/determine-if-a-string-is-collapsible.om+72-0
si/rosetta/tasks/determine-if-a-string-is-numeric/determine-if-a-string-is-numeric.om+112-0
si/rosetta/tasks/determine-if-a-string-is-squeezable/determine-if-a-string-is-squeezable.om+84-0
si/rosetta/tasks/digital-root/digital-root.om+68-0
si/rosetta/tasks/dijkstras-algorithm/dijkstras-algorithm.om+143-0
si/rosetta/tasks/dutch-national-flag-problem/dutch-national-flag-problem.om+131-0
si/rosetta/tasks/elementary-cellular-automaton/elementary-cellular-automaton.om+81-0
si/rosetta/tasks/emirp-primes/emirp-primes.om+110-0
si/rosetta/tasks/empty-string/empty-string.om+45-0
si/rosetta/tasks/equilibrium-index/equilibrium-index.om+122-0
si/rosetta/tasks/ethiopian-multiplication/ethiopian-multiplication.om+75-0
si/rosetta/tasks/evaluate-binomial-coefficients/evaluate-binomial-coefficients.om+72-0
si/rosetta/tasks/extensible-prime-generator/extensible-prime-generator.om+104-0
si/rosetta/tasks/factorial/factorial.om+47-0
si/rosetta/tasks/factors-of-an-integer/factors-of-an-integer.om+72-0
si/rosetta/tasks/fibonacci-n-step-number-sequences/fibonacci-n-step-number-sequences.om+88-0
si/rosetta/tasks/fibonacci-sequence/fibonacci-sequence.om+49-0
si/rosetta/tasks/fizzbuzz/fizzbuzz.om+53-0
si/rosetta/tasks/floyd-warshall-algorithm/floyd-warshall-algorithm.om+134-0
si/rosetta/tasks/floyds-triangle/floyds-triangle.om+81-0
si/rosetta/tasks/fusc-sequence/fusc-sequence.om+79-0
si/rosetta/tasks/generate-lower-case-ascii-alphabet/generate-lower-case-ascii-alphabet.om+24-0
si/rosetta/tasks/gnome-sort/gnome-sort.om+112-0
si/rosetta/tasks/gray-code/gray-code.om+94-0
si/rosetta/tasks/greatest-common-divisor/greatest-common-divisor.om+62-0
si/rosetta/tasks/greatest-subsequential-sum/greatest-subsequential-sum.om+137-0
si/rosetta/tasks/hailstone-sequence/hailstone-sequence.om+87-0
si/rosetta/tasks/hamming-numbers/hamming-numbers.om+84-0
si/rosetta/tasks/happy-numbers/happy-numbers.om+68-0
si/rosetta/tasks/harshad-or-niven-series/harshad-or-niven-series.om+66-0
si/rosetta/tasks/heapsort/heapsort.om+127-0
si/rosetta/tasks/hello-world-newline-omission/hello-world-newline-omission.om+19-0
si/rosetta/tasks/hello-world/hello-world.om+19-0
si/rosetta/tasks/hofstadter-figure-figure-sequences/hofstadter-figure-figure-sequences.om+102-0
si/rosetta/tasks/hofstadter-q-sequence/hofstadter-q-sequence.om+66-0
si/rosetta/tasks/identity-matrix/identity-matrix.om+56-0
si/rosetta/tasks/insertion-sort/insertion-sort.om+82-0
si/rosetta/tasks/isbn13-check-digit/isbn13-check-digit.om+53-0
si/rosetta/tasks/isqrt-integer-square-root-of-x/isqrt-integer-square-root-of-x.om+75-0
si/rosetta/tasks/jewels-and-stones/jewels-and-stones.om+61-0
si/rosetta/tasks/josephus-problem/josephus-problem.om+67-0
si/rosetta/tasks/kaprekar-numbers/kaprekar-numbers.om+71-0
si/rosetta/tasks/knapsack-problem-0-1/knapsack-problem-0-1.om+142-0
si/rosetta/tasks/knapsack-problem-unbounded/knapsack-problem-unbounded.om+88-0
si/rosetta/tasks/knights-tour/knights-tour.om+134-0
si/rosetta/tasks/kronecker-product/kronecker-product.om+148-0
si/rosetta/tasks/langtons-ant/langtons-ant.om+140-0
si/rosetta/tasks/leap-year/leap-year.om+58-0
si/rosetta/tasks/least-common-multiple/least-common-multiple.om+85-0
si/rosetta/tasks/letter-frequency/letter-frequency.om+58-0
si/rosetta/tasks/levenshtein-distance/levenshtein-distance.om+81-0
si/rosetta/tasks/longest-common-prefix/longest-common-prefix.om+86-0
si/rosetta/tasks/longest-common-subsequence/longest-common-subsequence.om+80-0
si/rosetta/tasks/longest-increasing-subsequence/longest-increasing-subsequence.om+150-0
si/rosetta/tasks/look-and-say-sequence/look-and-say-sequence.om+70-0
si/rosetta/tasks/loops-break/loops-break.om+49-0
si/rosetta/tasks/loops-continue/loops-continue.om+44-0
si/rosetta/tasks/loops-do-while/loops-do-while.om+43-0
si/rosetta/tasks/loops-downward-for/loops-downward-for.om+38-0
si/rosetta/tasks/loops-for-with-a-specified-step/loops-for-with-a-specified-step.om+43-0
si/rosetta/tasks/loops-for/loops-for.om+26-0
si/rosetta/tasks/loops-foreach/loops-foreach.om+28-0
si/rosetta/tasks/loops-n-plus-one-half/loops-n-plus-one-half.om+45-0
si/rosetta/tasks/loops-while/loops-while.om+40-0
si/rosetta/tasks/lucas-lehmer-test/lucas-lehmer-test.om+111-0
si/rosetta/tasks/ludic-numbers/ludic-numbers.om+106-0
si/rosetta/tasks/luhn-test-of-credit-card-numbers/luhn-test-of-credit-card-numbers.om+52-0
si/rosetta/tasks/magic-squares-of-odd-order/magic-squares-of-odd-order.om+94-0
si/rosetta/tasks/mandelbrot-set/mandelbrot-set.om+51-0
si/rosetta/tasks/matrix-multiplication/matrix-multiplication.om+112-0
si/rosetta/tasks/matrix-transposition/matrix-transposition.om+91-0
si/rosetta/tasks/matrix-with-two-diagonals/matrix-with-two-diagonals.om+54-0
si/rosetta/tasks/maximum-triangle-path-sum/maximum-triangle-path-sum.om+111-0
si/rosetta/tasks/maze-generation/maze-generation.om+162-0
si/rosetta/tasks/maze-solving/maze-solving.om+225-0
si/rosetta/tasks/md5/md5.om+158-0
si/rosetta/tasks/merge-sort/merge-sort.om+129-0
si/rosetta/tasks/mersenne-primes/mersenne-primes.om+135-0
si/rosetta/tasks/miller-rabin-primality-test/miller-rabin-primality-test.om+152-0
si/rosetta/tasks/mobius-function/mobius-function.om+65-0
si/rosetta/tasks/modular-exponentiation/modular-exponentiation.om+123-0
si/rosetta/tasks/modular-inverse/modular-inverse.om+93-0
si/rosetta/tasks/n-queens-problem/n-queens-problem.om+70-0
si/rosetta/tasks/narcissistic-decimal-number/narcissistic-decimal-number.om+73-0
si/rosetta/tasks/number-names/number-names.om+127-0
si/rosetta/tasks/one-dimensional-cellular-automata/one-dimensional-cellular-automata.om+96-0
si/rosetta/tasks/ordered-partitions/ordered-partitions.om+115-0
si/rosetta/tasks/ordered-words/ordered-words.om+57-0
si/rosetta/tasks/palindrome-detection/palindrome-detection.om+75-0
si/rosetta/tasks/pancake-sort/pancake-sort.om+127-0
si/rosetta/tasks/pangram-checker/pangram-checker.om+54-0
si/rosetta/tasks/pascals-triangle/pascals-triangle.om+59-0
si/rosetta/tasks/patience-sort/patience-sort.om+138-0
si/rosetta/tasks/perfect-numbers/perfect-numbers.om+57-0
si/rosetta/tasks/perfect-totient-numbers/perfect-totient-numbers.om+75-0
si/rosetta/tasks/permutation-sort/permutation-sort.om+156-0
si/rosetta/tasks/permutations-by-swapping/permutations-by-swapping.om+111-0
si/rosetta/tasks/permutations-derangements/permutations-derangements.om+153-0
si/rosetta/tasks/permutations/permutations.om+90-0
si/rosetta/tasks/pernicious-numbers/pernicious-numbers.om+80-0
si/rosetta/tasks/phrase-reversals/phrase-reversals.om+72-0
si/rosetta/tasks/population-count/population-count.om+73-0
si/rosetta/tasks/power-set/power-set.om+62-0
si/rosetta/tasks/primality-by-trial-division/primality-by-trial-division.om+80-0
si/rosetta/tasks/prime-decomposition/prime-decomposition.om+69-0
si/rosetta/tasks/priority-queue/priority-queue.om+123-0
si/rosetta/tasks/proper-divisors/proper-divisors.om+76-0
si/rosetta/tasks/pythagorean-triples/pythagorean-triples.om+85-0
si/rosetta/tasks/queue-definition/queue-definition.om+107-0
si/rosetta/tasks/queue-usage/queue-usage.om+103-0
si/rosetta/tasks/quicksort/quicksort.om+115-0
si/rosetta/tasks/radix-sort/radix-sort.om+144-0
si/rosetta/tasks/recamans-sequence/recamans-sequence.om+83-0
si/rosetta/tasks/remove-duplicate-elements/remove-duplicate-elements.om+112-0
si/rosetta/tasks/remove-vowels-from-a-string/remove-vowels-from-a-string.om+43-0
si/rosetta/tasks/repeat-a-string/repeat-a-string.om+35-0
si/rosetta/tasks/reverse-a-string/reverse-a-string.om+32-0
si/rosetta/tasks/reverse-words-in-a-string/reverse-words-in-a-string.om+59-0
si/rosetta/tasks/roman-numerals-encode/roman-numerals-encode.om+76-0
si/rosetta/tasks/rot-13/rot-13.om+38-0
si/rosetta/tasks/run-length-encoding/run-length-encoding.om+85-0
si/rosetta/tasks/selection-sort/selection-sort.om+107-0
si/rosetta/tasks/semiprime/semiprime.om+84-0
si/rosetta/tasks/sha-1/sha-1.om+142-0
si/rosetta/tasks/sha-256/sha-256.om+215-0
si/rosetta/tasks/shell-sort/shell-sort.om+113-0
si/rosetta/tasks/sieve-of-eratosthenes/sieve-of-eratosthenes.om+53-0
si/rosetta/tasks/smith-numbers/smith-numbers.om+95-0
si/rosetta/tasks/sort-an-integer-array/sort-an-integer-array.om+115-0
si/rosetta/tasks/sort-disjoint-sublist/sort-disjoint-sublist.om+134-0
si/rosetta/tasks/sort-three-variables/sort-three-variables.om+172-0
si/rosetta/tasks/soundex/soundex.om+79-0
si/rosetta/tasks/spiral-matrix/spiral-matrix.om+99-0
si/rosetta/tasks/square-free-integers/square-free-integers.om+105-0
si/rosetta/tasks/stack/stack.om+109-0
si/rosetta/tasks/stern-brocot-sequence/stern-brocot-sequence.om+105-0
si/rosetta/tasks/stooge-sort/stooge-sort.om+107-0
si/rosetta/tasks/strand-sort/strand-sort.om+167-0
si/rosetta/tasks/string-append/string-append.om+33-0
si/rosetta/tasks/string-case/string-case.om+42-0
si/rosetta/tasks/string-comparison/string-comparison.om+87-0
si/rosetta/tasks/string-concatenation/string-concatenation.om+34-0
si/rosetta/tasks/string-length/string-length.om+56-0
si/rosetta/tasks/string-matching/string-matching.om+74-0
si/rosetta/tasks/string-prepend/string-prepend.om+42-0
si/rosetta/tasks/strip-a-set-of-characters-from-a-string/strip-a-set-of-characters-from-a-string.om+43-0
si/rosetta/tasks/strip-comments-from-a-string/strip-comments-from-a-string.om+55-0
si/rosetta/tasks/strip-whitespace-from-a-string/strip-whitespace-from-a-string.om+53-0
si/rosetta/tasks/substitution-cipher/substitution-cipher.om+56-0
si/rosetta/tasks/substring/substring.om+48-0
si/rosetta/tasks/sudoku/sudoku.om+110-0
si/rosetta/tasks/sum-and-product-of-an-array/sum-and-product-of-an-array.om+51-0
si/rosetta/tasks/sum-digits-of-an-integer/sum-digits-of-an-integer.om+82-0
si/rosetta/tasks/sum-multiples-of-3-and-5/sum-multiples-of-3-and-5.om+60-0
si/rosetta/tasks/temperature-conversion/temperature-conversion.om+78-0
si/rosetta/tasks/the-twelve-days-of-christmas/the-twelve-days-of-christmas.om+60-0
si/rosetta/tasks/thue-morse/thue-morse.om+38-0
si/rosetta/tasks/tokenize-a-string/tokenize-a-string.om+40-0
si/rosetta/tasks/topological-sort/topological-sort.om+161-0
si/rosetta/tasks/topswops/topswops.om+131-0
si/rosetta/tasks/totient-function/totient-function.om+87-0
si/rosetta/tasks/towers-of-hanoi/towers-of-hanoi.om+51-0
si/rosetta/tasks/tree-traversal/tree-traversal.om+118-0
si/rosetta/tasks/twin-primes/twin-primes.om+88-0
si/rosetta/tasks/url-decoding/url-decoding.om+56-0
si/rosetta/tasks/url-encoding/url-encoding.om+56-0
si/rosetta/tasks/van-eck-sequence/van-eck-sequence.om+60-0
si/rosetta/tasks/vigenere-cipher/vigenere-cipher.om+60-0
si/rosetta/tasks/water-collected-between-towers/water-collected-between-towers.om+156-0
si/rosetta/tasks/wireworld/wireworld.om+103-0
si/rosetta/tasks/word-wrap/word-wrap.om+57-0
si/rosetta/tasks/zig-zag-matrix/zig-zag-matrix.om+84-0
si/seed-challenge/challenge.om+1171-0
si/seed-challenge/test.om+1077-0
si/units-gate.om+1054-0
si/units-run.tsv+16-0
si/units.tsv+505-0
spec/r15-performance-proof.md+51-3
spec/r16-orchestrator-retirement.md+17-5
src/omega_api_decl.h+50-0
src/omega_blackwell_codegen_bf16.c+30-277
src/omega_blackwell_codegen_dec.c+9-6
src/omega_blackwell_codegen_gemm.c+43-352
src/omega_blackwell_codegen_gemm.h+1-1
src/omega_blackwell_codegen_moe.c+46-460
src/omega_blackwell_codegen_moe2.c+29-304
src/omega_blackwell_codegen_pf.c+9-16
src/omega_blackwell_codegen_pfhost.c+30-128
src/omega_blackwell_codegen_qmma.c+21-58
src/omega_blackwell_qmd.c+13-125
src/omega_blackwell_qmd.h+4-6
src/omega_bw_om_ir.h+102-0
src/omega_gpu_bf16_gemv_api.c+11-0
src/omega_gpu_decode_attn256_api.c+14-5
src/omega_gpu_fp8_api.c+1-1
src/omega_gpu_q38_graph.c+538-67
src/omega_gpu_q38_graph.h+36-2
src/omega_native.h+71-1
src/omega_om_units.c+804-1
src/omega_om_units.ident+13-3
src/omega_om_units_fs.c+92-1
src/physics0/pd0_chan.c+4-1
src/physics0/pd0_wire.c+6-3
src/physics0/pd0_wire.h+2-1
src/runtime/rx_generation.c+166-19
src/runtime/rx_generation.h+35-10
tests/a64efi/boot_el1_smp.sh+56-0
tests/aienos_lock_source/run.sh+51-1
tests/amd-kfd-launch/check.py+216-0
tests/argus_lock_validation.sh+63-0
tests/gates/omega-aienux-units.gate+27-0
tests/gates/omega-apps-units.gate+27-0
tests/gates/omega-bridge-units.gate+26-0
tests/gates/omega-core-units.gate+28-0
tests/gates/omega-gpu-extra-units.gate+26-0
tests/gates/omega-protocol-units.gate+29-0
tests/gates/omega-si-units.gate+26-0
tests/gates/omega-train-units.gate+27-0
tests/gates/run.sh+55-31
tests/gpu_bf16_gemv_test.c+6-2
tests/gpu_exact_head_test.c+33-9
tests/gpu_fp8_api_test.c+1-1
tests/gpu_q38_stroke_exact_test.c+259-0
tests/kfd/check.py+21-3
tests/physics0/test_pd0_world.c+47-0
tests/r15_receipt_test.sh+95-4
tests/runtime/rx_gen_work_auth.c+287-0
tests/runtime/rx_r16_negative.c+99-11
tests/runtime/rx_r9_barrier.c+10-5
tests/test_bw_om_codegen_bounds.c+403-0
tests/test_omega_gpu_q38_graph_host.c+136-0
tests/universal/semantics.py+1-1
tests/universal/translation/validate_compose.py+2-2
tests/universal/translation/validate_compose_v2.py+2-2
tests/universal/translation/validate_g1.py+1-1
tests/visor/test_visor_authority.c+2-1
tools/adapters/build-c-export.py+1-1
tools/adapters/build-c-import.py+1-1
tools/adapters/build-lower.py+1-1
tools/adapters/build-python-export.py+1-1
tools/adapters/build-python-import.py+1-1
tools/adapters/build-retarget.py+2-2
tools/pi-drive-27b/omguard.om+752-0
tools/pi-drive-27b/omguard_trace.om+571-0
tools/pi-drive-27b/pi_drive.om+173-0
tools/pi-drive-27b/pi_drive_omtk.om+418-0
tools/pi-drive-27b/run-spark-27b.sh+66-0
tools/pi-drive-27b/specdraft.om+175-0
tools/pi-drive-27b/specdraft_trace.om+470-0
tools/pi-drive-27b/tree20.om+159-0
tools/pinned_checkout.sh+217-0
tools/r15_qualify.sh+235-23
tools/r15_receipt.sh+185-21
tools/r15_reruns_validate.om+128-0
tools/require_physics_pin.sh+7-8
tools/spark-boot/preflight.sh+489-0
tools/spark-boot/stage_bootnext.sh+489-0
tools/spark-boot/tests/test_stage_bootnext.sh+148-0
tools/test_pinned_checkout.sh+80-0
tools/trit/test-daily.py+1-1
tools/uxl/level1/README.md+42-0
tools/uxl/level1/SHA256.json+67-0
tools/uxl/level1/calculate.py+24-0
tools/uxl/level1/calculations.json+20-0
tools/uxl/level1/coding24/coding24-check.stderr+0-0
tools/uxl/level1/coding24/coding24-check.stdout+1-0
tools/uxl/level1/coding24/coding24-control.stderr+0-0
tools/uxl/level1/coding24/coding24-control.stdout+289-0
tools/uxl/level1/coding24/coding24.json+98-0
tools/uxl/level1/coding24/coding24.stderr+0-0
tools/uxl/level1/coding24/coding24.stdout+289-0
tools/uxl/level1/host/qualification.json+17-0
tools/uxl/level1/host/source-binding.json+22-0
tools/uxl/level1/native/DELIVERY_SHA256.json+56-0
tools/uxl/level1/native/MANIFEST.json+31-0
tools/uxl/level1/native/amdserve-real2.txt+1-0
tools/uxl/level1/native/amdserve-real2.txt.mark+1-0
tools/uxl/level1/native/benchmark.stderr+0-0
tools/uxl/level1/native/benchmark.stdout+16-0
tools/uxl/level1/native/candidate.json+7-0
tools/uxl/level1/native/control.json+294-0
tools/uxl/level1/native/control.stderr+0-0
tools/uxl/level1/native/control.stdout+527-0
tools/uxl/level1/native/environment.json+18-0
tools/uxl/level1/native/independent-hip-graph.json+1-0
tools/uxl/level1/native/job-state.json+3-0
tools/uxl/level1/native/lighthouse256.json+297-0
tools/uxl/level1/native/real2-controls.plan.json+1179-0
tools/uxl/level1/native/real2.plan.json+212-0
tools/uxl/level1/native/runner.stderr+0-0
tools/uxl/level1/native/runner.stdout+6-0
tools/uxl/level1/native/sample1.json+294-0
tools/uxl/level1/native/sample1.stderr+0-0
tools/uxl/level1/native/sample1.stdout+527-0
tools/uxl/level1/native/sample2.json+294-0
tools/uxl/level1/native/sample2.stderr+0-0
tools/uxl/level1/native/sample2.stdout+527-0
tools/uxl/level1/native/sample3.json+294-0
tools/uxl/level1/native/sample3.stderr+0-0
tools/uxl/level1/native/sample3.stdout+527-0
tools/uxl/level1/native/sample4.json+294-0
tools/uxl/level1/native/sample4.stderr+0-0
tools/uxl/level1/native/sample4.stdout+527-0
tools/uxl/level1/native/sample5.json+294-0
tools/uxl/level1/native/sample5.stderr+0-0
tools/uxl/level1/native/sample5.stdout+527-0
tools/uxl/level1/native/state.json+2367-0
tools/uxl/level1/native/vadd-lds.hsaco.stderr+0-0
tools/uxl/level1/native/vadd-lds.hsaco.stdout+165-0
tools/uxl/level1/native/vadd.hsaco.stderr+0-0
tools/uxl/level1/native/vadd.hsaco.stdout+165-0
tools/uxl/level1/native/warmup.json+294-0
tools/uxl/level1/native/warmup.stderr+0-0
tools/uxl/level1/native/warmup.stdout+527-0
tools/uxl/level1/numerical/graph.json+1-0
tools/uxl/level1/oracle/ORIGINAL_SCRIPTS.json+18-0
tools/uxl/level1/oracle/benchmark-qualified.py+87-0
tools/uxl/level1/oracle/coding24-check.py+20-0
tools/uxl/level1/oracle/driver-real2.py+346-0
tools/uxl/level1/oracle/lighthouse256.json+297-0
tools/uxl/level1/oracle/run-all.py+51-0
tools/uxl/level1/spark-baseline/decode1.request.json+1-0
tools/uxl/level1/spark-baseline/decode1.request.u32lebinary
tools/uxl/level1/spark-baseline/decode1.response.json+1-0
tools/uxl/level1/spark-baseline/qualification.json+20-0
tools/uxl/level1/verify.py+47-0
tools/uxl/run_all.py+770-0
tools/uxl/windows_paths.py+97-0
train/NOT-YET-OMEGA.tsv+1733-0
train/README.md+34-0
train/UNITS.md+17-0
train/aien-train/native/adtrain/mlp.om+409-0
train/aien-train/native/alignment/check.om+269-0
train/aien-train/native/alignment/project.om+385-0
train/aien-train/native/btwave/gate.om+1283-0
train/aien-train/native/btwave/ledger.om+290-0
train/aien-train/native/btwave/main.om+545-0
train/aien-train/native/btwave/trit.om+546-0
train/aien-train/native/btwave/wave_ipc.om+370-0
train/aien-train/native/collective/admit/a1emit-main.om+72-0
train/aien-train/native/collective/admit/cli-main.om+100-0
train/aien-train/native/collective/admit_p0.om+598-0
train/aien-train/native/collective/shared_bank_p0.om+224-0
train/aien-train/native/distributed7/admission.om+304-0
train/aien-train/native/ecosystem5/pack.om+180-0
train/aien-train/native/ecosystem6/affine.om+165-0
train/aien-train/native/neuralese/affine.om+179-0
train/aien-train/native/neuralese/check.om+157-0
train/aien-train/native/neuralese/gradientcheck.om+77-0
train/aien-train/native/neuralese/hadamard.om+58-0
train/aien-train/native/neuralese/io.om+27-0
train/aien-train/native/neuralese/learn.om+328-0
train/aien-train/native/neuralese/mutants/gradient-index.om+179-0
train/aien-train/native/neuralese/mutants/gradient-sign.om+179-0
train/aien-train/native/neuralese/mutants/update-sign.om+179-0
train/aien-train/native/neuralese/nl1r-task/boundary.om+162-0
train/aien-train/native/neuralese/nl1r-task/controls.om+255-0
train/aien-train/native/neuralese/nl1r-task/evidence/boundary-attempt1.om+1356-0
train/aien-train/native/neuralese/nl1r-task/evidence/boundary-attempt2.om+1367-0
train/aien-train/native/neuralese/nl1r-task/evidence/boundary-attempt3.om+1366-0
train/aien-train/native/neuralese/nl1r-task/evidence/boundary-attempt4.om+1368-0
train/aien-train/native/neuralese/nl1r-task/evidence/boundary-attempt5.om+1376-0
train/aien-train/native/neuralese/nl1r-task/evidence/boundary-attempt6.om+1379-0
train/aien-train/native/neuralese/nl1r-task/evidence/controls-attempt2.om+1211-0
train/aien-train/native/neuralese/nl1r-task/evidence/controls-attempt3.om+1211-0
train/aien-train/native/neuralese/nl1r-task/evidence/controls.om+1202-0
train/aien-train/native/neuralese/nl1r-task/evidence/mutant-dense-index.om+1211-0
train/aien-train/native/neuralese/nl1r-task/evidence/mutant-effect-request.om+1211-0
train/aien-train/native/neuralese/nl1r-task/evidence/mutant-ignored-payload.om+1211-0
train/aien-train/native/neuralese/nl1r-task/evidence/mutant-inactive-loss.om+1211-0
train/aien-train/native/neuralese/nl1r-task/evidence/mutant-stale-schema.om+1211-0
train/aien-train/native/neuralese/nl1r-task/evidence/mutant-wrong-width.om+1209-0
train/aien-train/native/neuralese/nl1r-task/evidence/task-attempt2.om+887-0
train/aien-train/native/neuralese/nl1r-task/evidence/task-attempt3.om+887-0
train/aien-train/native/neuralese/nl1r-task/evidence/task-source-freeze.om+887-0
train/aien-train/native/neuralese/nl1r-task/evidence/task.om+878-0
train/aien-train/native/neuralese/nl1r-task/main.om+140-0
train/aien-train/native/neuralese/nl1r-task/task.om+244-0
train/aien-train/native/neuralese/nl1r/capacity.om+227-0
train/aien-train/native/neuralese/nl1r/checkpointcheck.om+24-0
train/aien-train/native/neuralese/nl1r/controls.om+208-0
train/aien-train/native/neuralese/nl1r/evidence/compile-attempt1.om+854-0
train/aien-train/native/neuralese/nl1r/evidence/mutant-checkpoint-partial-attempt2.om+525-0
train/aien-train/native/neuralese/nl1r/evidence/mutant-checkpoint-partial.om+525-0
train/aien-train/native/neuralese/nl1r/evidence/mutant-direct-sidechannel.om+849-0
train/aien-train/native/neuralese/nl1r/evidence/mutant-gradient-index.om+849-0
train/aien-train/native/neuralese/nl1r/evidence/mutant-gradient-sign.om+849-0
train/aien-train/native/neuralese/nl1r/evidence/mutant-partial-commit.om+850-0
train/aien-train/native/neuralese/nl1r/evidence/mutant-quant-ties.om+559-0
train/aien-train/native/neuralese/nl1r/evidence/mutant-stale-schema.om+849-0
train/aien-train/native/neuralese/nl1r/evidence/mutant-update-sign.om+849-0
train/aien-train/native/neuralese/nl1r/main.om+141-0
train/aien-train/native/neuralese/nl1r/quantcheck.om+59-0
train/aien-train/native/neuralese/nl1r/wire.om+273-0
train/aien-train/native/neuralese/nl7-guards.om+5-0
train/aien-train/native/neuralese/nl7-learn-main.om+4-0
train/aien-train/native/neuralese/nl7-learn.om+594-0
train/aien-train/native/neuralese/nl7-structure.om+408-0
train/aien-train/native/omegalora/lora.om+503-0
train/aien-train/native/omegese45/core/ckpt.om+318-0
train/aien-train/native/omegese45/core/cli.om+440-0
train/aien-train/native/omegese45/core/model.om+279-0
train/aien-train/native/omegese45/core/run.om+311-0
train/aien-train/native/omegese45/data/gen.om+384-0
train/aien-train/native/omegese45/hive/hive.om+1380-0
train/aien-train/native/omegese45/mjr1.om+174-0
train/aien-train/native/omegese45/msg.om+409-0
train/aien-train/native/omegese45/translate/en2goal.om+446-0
train/aien-train/native/omegese45/translate/goal2en.om+60-0
train/aien-train/native/omegese45/translate/main-en2goal.om+22-0
train/aien-train/native/omegese45/translate/main-goal2en.om+22-0
train/aien-train/native/omegese45/translate/main-rep2en.om+26-0
train/aien-train/native/omegese45/translate/otfrag.om+23-0
train/aien-train/native/omegese45/translate/otio.om+85-0
train/aien-train/native/omegese45/translate/otmsg.om+42-0
train/aien-train/native/omegese45/translate/rep2en.om+625-0
train/aien-train/native/omegese45/vocab.om+318-0
train/aien-train/native/si19/fixture.om+103-0
train/aien-train/native/si19/main.om+278-0
train/aien-train/native/si19/omexp.om+797-0
train/aien-train/native/si19/omexpfix.om+217-0
train/aien-train/native/si19/omexpmain.om+447-0
train/aien-train/native/si19/select.om+809-0
train/aien-train/native/si19/selmain.om+622-0
train/aien-train/native/si19/world.om+704-0
train/aien-train/tests/adtrain/main.om+269-0
train/aien-train/tests/adtrain/mutate.om+118-0
train/aien-train/tests/adtrain/replay/ckforge.om+141-0
train/aien-train/tests/adtrain/replay/padprobe.om+32-0
train/aien-train/tests/adtrain/replay/subst.om+100-0
train/aien-train/tests/distributed7/admission.om+300-0
train/aien-train/tests/distributed7/mutate.om+158-0
train/aien-train/tests/ecosystem5/mutate.om+103-0
train/aien-train/tests/ecosystem5/pack-test.om+356-0
train/aien-train/tests/ecosystem6/mutate.om+117-0
train/aien-train/tests/ecosystem6/step-test.om+345-0
train/aien-train/tests/omegese45/contract/main.om+361-0
train/aien-train/tests/omegese45/core/main.om+546-0
train/aien-train/tests/omegese45/core/mutate.om+103-0
train/aien-train/tests/si19/omexp-test.om+511-0
train/aien-train/tests/si19/select-test.om+723-0
train/aien-train/tests/si19/world-test.om+572-0
train/aien-train/tools/verified_examples/examples.om+1056-0
train/aien-train/tools/verified_examples/gate.om+689-0
train/aien-train/tools/verified_examples/sources.om+316-0
train/blas/om/blas.om+596-0
train/dnn/om/dnn.om+881-0
train/import/aien-train/README.md+28-0
train/import/aien-train/commit-map+437-0
train/import/aien-train/docs-omegallm/README.md+12-0
train/import/aien-train/docs-omegallm/commit-map+437-0
train/import/aien-train/docs-omegallm/filter-repo-command.txt+1-0
train/import/aien-train/docs-omegallm/filter-repo.version+1-0
train/import/aien-train/docs-omegallm/paths.txt+2-0
train/import/aien-train/docs-omegallm/ref-map+3-0
train/import/aien-train/filter-repo-command.txt+1-0
train/import/aien-train/filter-repo.version+1-0
train/import/aien-train/not-yet-omega-command.txt+22-0
train/import/aien-train/paths.txt+2-0
train/import/aien-train/ref-map+3-0
train/import/omega-blas/README.md+11-0
train/import/omega-blas/commit-map+14-0
train/import/omega-blas/filter-repo-command.txt+1-0
train/import/omega-blas/filter-repo.version+1-0
train/import/omega-blas/paths.txt+2-0
train/import/omega-blas/ref-map+2-0
train/import/omega-dnn/README.md+11-0
train/import/omega-dnn/commit-map+5-0
train/import/omega-dnn/filter-repo-command.txt+1-0
train/import/omega-dnn/filter-repo.version+1-0
train/import/omega-dnn/paths.txt+2-0
train/import/omega-dnn/ref-map+2-0
train/import/omega-kernel-template/README.md+11-0
train/import/omega-kernel-template/commit-map+8-0
train/import/omega-kernel-template/filter-repo-command.txt+1-0
train/import/omega-kernel-template/filter-repo.version+1-0
train/import/omega-kernel-template/paths.txt+2-0
train/import/omega-kernel-template/ref-map+3-0
train/import/openaccel-lab/README.md+11-0
train/import/openaccel-lab/commit-map+4-0
train/import/openaccel-lab/filter-repo-command.txt+1-0
train/import/openaccel-lab/filter-repo.version+1-0
train/import/openaccel-lab/paths.txt+2-0
train/import/openaccel-lab/ref-map+2-0
train/kernel-template/kernel.om+32-0
train/omega-llm/README.md+34-0
train/omega-llm/docs/CONTRACT-BF16.md+255-0
train/omega-llm/docs/CONTRACT-V1.md+216-0
train/omega-llm/docs/CONTRACT-V2.md+61-0
train/omega-llm/docs/CONTRACT-V3.md+87-0
train/omega-llm/docs/CONTRACT.md+263-0
train/omega-llm/docs/GROW.md+82-0
train/omega-llm/docs/MACBOOK.md+91-0
train/omega-llm/docs/OM-BUNDLES.md+225-0
train/omega-llm/docs/README.md+569-0
train/omega-llm/docs/SPECIALISTS.md+101-0
train/omega-llm/docs/WEIGHT-EDIT.md+104-0
train/omega-llm/docs/WSP-CONTROLLER.md+314-0
train/omega-llm/docs/WSP-METHOD.md+309-0
train/omega-llm/docs/WSP-OPERATOR.md+142-0
train/omega-llm/docs/WSP-PATCH.md+222-0
train/omega-llm/native/adam.om+331-0
train/omega-llm/native/bpe.om+997-0
train/omega-llm/native/ckpt.om+274-0
train/omega-llm/native/cli.om+1057-0
train/omega-llm/native/data.om+405-0
train/omega-llm/native/eio.om+1001-0
train/omega-llm/native/epool.om+10-0
train/omega-llm/native/gpu/batch.om+181-0
train/omega-llm/native/gpu/context.om+1104-0
train/omega-llm/native/gpu/gb.om+1005-0
train/omega-llm/native/gpu/gg.om+2706-0
train/omega-llm/native/gpu/gk.om+1754-0
train/omega-llm/native/gpu/gr.om+657-0
train/omega-llm/native/gpu/launch.om+288-0
train/omega-llm/native/gpu/vector.om+49-0
train/omega-llm/native/lio.om+497-0
train/omega-llm/native/lpool.om+13-0
train/omega-llm/native/math.om+186-0
train/omega-llm/native/mio.om+351-0
train/omega-llm/native/model.om+1358-0
train/omega-llm/native/net/http.om+2463-0
train/omega-llm/native/net/json.om+1247-0
train/omega-llm/native/net/jsonw.om+671-0
train/omega-llm/native/nogpu.om+15-0
train/omega-llm/native/noserve.om+6-0
train/omega-llm/native/serve.om+2788-0
train/omega-llm/native/spec.om+2194-0
train/omega-llm/native/tok/tkcli.om+386-0
train/omega-llm/native/tok/tkcore.om+387-0
train/omega-llm/native/tok/tkfit.om+432-0
train/omega-llm/native/tok/tkio.om+233-0
train/omega-llm/tests/gpu-dump.om+25-0
train/omega-llm/tests/weight-edit.om+101-0
train/omega-llm/tools/ctlsamp/ctlsamp.om+1432-0
train/omega-llm/tools/wdrive/om2.om+1-0
train/omega-llm/tools/wdrive/wbuild.om+1418-0
train/omega-llm/tools/wdrive/wcheck.om+506-0
train/omega-llm/tools/wdrive/wpolicy.om+315-0
train/omega-llm/tools/wdrive/wrun.om+440-0
train/omega-llm/tools/wgate/wgate.om+4597-0
train/omega-llm/tools/wpatch/wpatch.om+1372-0
train/omega-llm/tools/wpatch/wpbuild.om+800-0
train/omega-llm/tools/wpatch/wpcheck.om+2176-0
train/omega-llm/tools/wprobe/wprobe.om+1896-0
train/omega-llm/tools/wscore/wscore.om+1834-0
train/omega-llm/tools/wsplit/wsplit.om+1409-0
train/openaccel-lab/controls/attention_nomax/omega.om+69-0
train/openaccel-lab/controls/dequant_int4_nosign/omega.om+49-0
train/openaccel-lab/controls/gemm_offbyone/omega.om+38-0
train/openaccel-lab/controls/reduce_drop_last/omega.om+26-0
train/openaccel-lab/controls/scan_exclusive/omega.om+26-0
train/openaccel-lab/controls/softmax_unstable/omega.om+38-0
train/openaccel-lab/lib/omega/oal.om+339-0
train/openaccel-lab/workloads/argmax/omega.om+30-0
train/openaccel-lab/workloads/attention/omega.om+69-0
train/openaccel-lab/workloads/attn_scores/omega.om+43-0
train/openaccel-lab/workloads/batched_gemm/omega.om+50-0
train/openaccel-lab/workloads/dequant_int4/omega.om+52-0
train/openaccel-lab/workloads/dequant_int8/omega.om+34-0
train/openaccel-lab/workloads/dot/omega.om+26-0
train/openaccel-lab/workloads/gemm_bias_relu/omega.om+45-0
train/openaccel-lab/workloads/gemm_nn/omega.om+43-0
train/openaccel-lab/workloads/gemm_nt/omega.om+43-0
train/openaccel-lab/workloads/gemv/omega.om+38-0
train/openaccel-lab/workloads/layernorm/omega.om+55-0
train/openaccel-lab/workloads/quant_int8/omega.om+68-0
train/openaccel-lab/workloads/reduce_max/omega.om+25-0
train/openaccel-lab/workloads/reduce_sum/omega.om+25-0
train/openaccel-lab/workloads/rmsnorm/omega.om+41-0
train/openaccel-lab/workloads/rope/omega.om+48-0
train/openaccel-lab/workloads/saxpy/omega.om+27-0
train/openaccel-lab/workloads/scan_i32/omega.om+25-0
train/openaccel-lab/workloads/silu/omega.om+26-0
train/openaccel-lab/workloads/softmax/omega.om+42-0
train/openaccel-lab/workloads/tmatmul16/omega.om+38-0
train/openaccel-lab/workloads/transpose/omega.om+29-0
train/openaccel-lab/workloads/tsoftmax16/omega.om+37-0
train/openaccel-lab/workloads/vecadd/omega.om+24-0
train/units-gate.om+1078-0
train/units-run.tsv+4-0
train/units.tsv+81-0
uxl-run.ps1+16-0
uxl-run.sh+4-0

.gitattributes

@@ -1 +1,3 @@
1+# Checkout stays byte-exact: core.autocrlf must not rewrite hashed inputs.
2+* -text
13 tools/codebook/vectors/*.tsv whitespace=-trailing-space

.gitignore

@@ -8,3 +8,6 @@ tests/test_omega_numeric
88 build-pr/
99 build-enc-c/
1010 build-enc-diff/
11+__pycache__/
12+*.pyc
13+uxl-run-*.log

AGENTS.md

@@ -8,9 +8,10 @@ Shared rules: read https://www.aienos.com/agents/RULES.md first. This file adds
88
99 - Applies to the whole repository.
1010 - `seed/`: the seeded compiler chain (rungs 0 to 4, `seed/omc/omc.om`, host checks in `seed/host/`). The language is specified in `docs/one_layer/OMEGESE.md`.
11+- `gpu/`, `aienux/`, `apps/`, `bridge/`, `core/`, `protocol/`, `si/`, `train/`: pure-Omega Sovereign Intelligence layers built by `seed/out/omc`, each with its `README.md`, `UNITS.md`, `units.tsv` and `units-gate.om` (master ledger: `si/STACK.tsv`).
1112 - `om/`: Omega implementations behind C entry points (`om/sha256`, `om/blake3`), bound into the C build through the generated `src/omega_om_units.inc`.
1213 - `src/`: existing core and the C compiler awaiting replacement (`src/compiler/`), the reaction runtime (`src/runtime/`), the host-only fabric interface (`src/fabric/`), the Physics Zero apparatus (`src/physics0/`).
13-- `spec/`, `docs/`: specifications. `tests/`: gate suites; `tests/gates/*.gate` are the manifests the DGX Spark judge runs. `tools/`: harnesses. `mk/`: make fragments included by the `Makefile`.
14+- `spec/`, `docs/`: specifications. `tests/`: gate suites; `tests/gates/*.gate` are the manifests the DGX Spark judge runs. `tools/`: harnesses (including `tools/trit/`, `tools/codebook/`, `tools/uxl/`, invoked via `./uxl-run.sh` or `.\uxl-run.ps1`). `mk/`: make fragments included by the `Makefile`.
1415 - `bench/prime_race/`, `calibration/`, `research/`, `doctrine/`: benchmark, Turing calibration, experiments, the Milestone 4 doctrine.
1516 - `evidence/`: content-addressed receipts, additions only.
1617 - `docs/migration/C-TO-OM-INVENTORY.md` lists the C that remains to be replaced.
@@ -84,5 +85,8 @@ Gates whose manifest lists `gb10` under `requires:` (for example the `*-silicon`
8485 - `docs/ROADMAP-1.0.md`: the Omega 1.0 readiness audit, milestones RM1..RM11 and their acceptance gates (live status stays with aien-architecture).
8586 - `docs/migration/C-TO-OM-INVENTORY.md`: remaining C to replace.
8687 - `docs/PIPELINE.md`: how a pull request is tested on the Spark.
88+- `docs/UXL.md`: one-command UXL verification (`./uxl-run.sh`, `.\uxl-run.ps1`).
89+- `docs/A64-EFI.md`, `docs/SPIRV.md`, `docs/baremetal/SPARK-LIVE-BOOT.md`: AArch64 UEFI backend, SPIR-V OpenCL kernel emitter, and bare-metal Spark boot runbook.
90+- `si/STACK.tsv`: master ledger of Sovereign Intelligence pure-Omega layers in this repository.
8791 - `CONTRIBUTORS.md`: who built what.
8892 - The kernel Omega is meant to run on, Aienux: https://interplane.io/drakestapleton/aienux

CONTRIBUTORS.md

@@ -7,6 +7,23 @@ The current development method is [Human-Directed Agentic Engineering (HDAE)](RE
77
88 | Model | What it did |
99 |---|---|
10+| Gemini 4 Neon (via Antigravity) | Closed remaining OM-2 Blackwell IR boundary gaps: `omega_bw_ir_from_om` (`src/omega_bw_om_ir.h`) now clears `prog` via `omega_bw_ir_init` on every error path (preventing partial-program residue), all remaining OM-2 codegen wrappers (`bf16`, `moe2`, `pf`, `pfhost`, `qmma`) zero-initialize `ins`/`meta` and init `prog`, and `tests/test_bw_om_codegen_bounds.c` adds partial-residue checks, `qmma`/`pfhost` invalid-spec sweeps, and max-size legal input headroom checks (173/173 PASS on Spark AArch64; zero calls to aborting `apic` GPU/codegen wrappers in `src/`). Completed live GB10 silicon validation (`spark-window 20261119T233031Z-d8ecb9`, exclusive, quiet machine): `gpu_qmma_probe_test` PASS (262,144/262,144 exact, 238.47 TFLOPS peak, 1,048,576/1,048,576 F2E4 exact), `gpu_pfhost_test --chip` PASS (router `rl` 0/262,144 diffs 0.314 ms, combine `mc` 0/4,194,304 diffs 0.818 ms, mutants 1..2 caught), `gpu_fp8gemm_test` 36/36 PASS (bit-identical, 1.90–2.78× vs GEMV), `gpu_moe_window_test --small` 101/101 PASS. |
11+| Gemini 4 Neon (via Antigravity) | Hardened the pure-OM-2 Blackwell IR boundary (`src/omega_bw_om_ir.h` validates `meta[5]`, instruction/vreg/uvreg/loop bounds, vreg/uvreg widths, opcode range, register/subregister/barrier/flag bounds; `*_patch` in `cg_{bf16,gemm,moe,moe2}.om` guards `pos < 1024`; `gemm`/`moe` wrappers zero-init buffers and reset `prog` on any failure) and added host boundary + kernel-metrics test `tests/test_bw_om_codegen_bounds.c` (76/76 PASS; 10/10 compiled kernels byte-for-byte identical SM121 SASS SHA-256, GPRs, occupancy, and avg stalls vs C parent `3d0cb3500`). Re-verified on live GB10 silicon (`spark-window 20261119T231305Z-1a8c84`, exclusive): `gpu_q38_graph_test` 22/22 PASS, `gpu_q38_stroke_exact_test` 71/71 PASS, 4-layer 27B `q38_stress_bench` PASS (`N=8` batched `plain bf16` 33.919 ms / 4.16×, `64x8` sustained `bat_exact` mean 41.826 ms / 191.27 tok/s). |
12+| Gemini 4 Neon (via Antigravity) | Migrated Blackwell QMMA probe/peak + F2E4 probe (`om/gpu/cg_qmma.om`) and prefill router logits + MoE weighted combine (`om/gpu/cg_pfhost.om`) codegen emitters from C into pure seeded OM-2, bound via `om/units.sh` (`--check` PASS) and wired into `src/omega_blackwell_codegen_{qmma,pfhost}.c`. Verified HOST_TESTED + Blackwell warp-simulator PASS on Spark AArch64 (`gpu_pfhost_test --sim` PASS with 0 diffs across router/combine/mutants, `gpu_qmma_probe_test --host-only` PASS, `bw_hazard_test` 268/268 with `qmma_peak` 20/20, `qmma_probe` 3/3, `f2e4_probe` 1/1, `rl` 6/6, `mc` 6/6 clean). |
13+| Gemini 4 Neon (via Antigravity) | Migrated Blackwell FP8 e4m3 block-scaled GEMV v1 (`om/gpu/cg_moe.om`, including `deep`, `sched=1` pipelined byte decode, `coal` coalesced output, `wfirst`, `k=17408`, and mutants 1..5) and v2 row-pipelined (`om/gpu/cg_moe2.om`, SB_B pipelining and mutants 1..3) codegen emitters from C into pure seeded OM-2, bound via `om/units.sh` (`--check` PASS) and wired into `src/omega_blackwell_codegen_{moe,moe2}.c` (with `sched=1` feeding `om/gpu/bw_sched.om` directly). Verified HOST_TESTED + Blackwell warp-simulator PASS on Spark AArch64 (`gpu_fp8_api_test` 4997+214 with 54/54 A/B bit-identical, `bw_hazard_test` 268/268 with `fp8_gemv` 559/559 clean and `fp8_gemv2` 58/58 clean). |
14+| Gemini 4 Neon (via Antigravity) | Migrated Blackwell FP8 e4m3 block-scaled grouped GEMM codegen (`om/gpu/cg_gemm.om`, including `rowmap`, double-buffered scoreboard 3/4 prefetch, 4-way interleaved decode, `i`-outer/`q`-inner FFMA, empty-segment guard, and mutants 1..4) from C into pure seeded OM-2, bound via `om/units.sh` (`--check` PASS) and wired directly into `om/gpu/bw_sched.om` in `src/omega_blackwell_codegen_gemm.c`. Verified HOST_TESTED + Blackwell warp-simulator PASS on Spark AArch64 (`gpu_fp8gemm_test` 59+21 bit-identical, `bw_hazard_test` 268/268 with `fp8gemm` 104/104 clean). |
15+| Gemini 4 Neon (via Antigravity) | Migrated Blackwell prefill copy (`om/gpu/cg_pf.om`) and BF16 streaming GEMV / `lm_head` (`om/gpu/cg_bf16.om`, including `XBATCH`, `MASK`, and mutants 1..4) codegen emitters from C into pure seeded OM-2 with a shared IR unpacker (`src/omega_bw_om_ir.h`), bound via `om/units.sh` (`--check` PASS), replacing C emitters in `src/omega_blackwell_codegen_{pf,bf16}.c`. Verified HOST_TESTED + Blackwell warp-simulator PASS on Spark AArch64 (`gpu_bf16_gemv_test` 192+23 = 359,562 warp issues bit-identical, `gpu_exact_head_test --sim` 13/13, `bw_hazard_test` 268/268 with `bf16_gemv` 174/174 clean and `pf_copy` 1/1 clean). |
16+| Gemini 4 Neon (via Antigravity) | Rewrote Blackwell QMD packing/verification (`om/gpu/bw_qmd.om`, dynamic 32/64/96 KiB word 36 SMEM config), dependency-driven IR stall scheduling (`om/gpu/bw_sched.om`), and Qwen3.8 multi-head batching/overlap/exact-head/attn256 L2-cache planning (`om/gpu/q38_plan.om`) in pure OM-2 (`om/gpu/test_gpu_om.om` PASS), bound via `om/units.sh` (`--check` PASS, freestanding GPU link PASS), replacing C QMD/scheduler/planner logic and adding 4-way interleaved FP8 GEMM decode + `i`-outer/`q`-inner FFMA, batched `exact_head` + `XB = 4` `bf16` `lm_head`, `K = 17408` `down_proj` deep staging, disjoint-head `mark_independent` overlap, and L2-cached `attn256` partials/rope/norms. Verified HOST_TESTED + Blackwell warp-simulator PASS on Spark AArch64 (`gpu_fp8_api_test` 4997+214, `gpu_fp8gemm_test` 59+21, `gpu_bf16_gemv_test` 192+23, `gpu_exact_head_test` 13, `gpu_decode_attn256_test` 61+14, `gpu_q38_graph_test` 9, `test_omega_gpu_q38_graph_host` 49, freestanding 50+7); live GB10 silicon timing NOT_RUN yet. |
17+| Grok 4.7 (via Cursor Agent) | Kept the strict rerun JSON check when sealing R15 binaries, and made `verify_commit` archive the tree id stored in the commit object (`tools/r15_qualify.sh`) so a commit-graph cannot substitute another tree. |
18+| OpenAI Codex | Bound R15 qualification to fresh candidate/dependency archives, sealed executables, per-execution digest checks, final tree state and receipt-enforced build provenance. |
19+| Grok 4.7 (via Cursor Agent) | Ran the R15 rerun validator under qemu-user on this x86 host: the seeded compiler is AArch64, so `tools/r15_receipt.sh` uses `qemu-aarch64` only when `uname -m` is not aarch64. Added refusal cases for a second trailing JSON value and for a `\u0050ASS` value, which must still count as PASS. |
20+| Codex | Replaced R15 rerun substring acceptance with strict seeded-Omega JSON and exact-schema validation, including duplicate, nested, malformed, extra-key and non-string regression controls. |
21+| Grok 4.7 (via Cursor Agent) | Closed the pinned-checkout copy so a sibling `uploadpack.packObjectsHook` or fsmonitor does not run, took the root tree from the commit object, and refused a physics.lock that is not one 40-hex commit before any recipe echoes it. `tools/test_pinned_checkout.sh`: 15 checks PASS. |
22+| Codex | Isolated every gate dependency pin in a fresh read-only checkout copied from the locked object graph; disabled replacements and grafts; added raw commit, tree, blob, path and mode verification; strengthened Physics pin checks and added hostile-source regression controls. Static verification only. |
23+| Grok 4.7 (via Cursor Agent) | Kept the ARGUS pin note in the Makefile when `argus.lock` lost its comments, and checked that `make ARGUS_COMMIT=...` cannot override the parsed lock. |
24+| OpenAI Codex | Made `argus.lock` a strict single-commit file, validated it as data before GNU make derives ARGUS paths or recipes, and added static regression coverage for malformed and shell-bearing lock content. |
25+| Grok 4.7 (via Cursor Agent) | Reviewed the generation-work ownership fix: length-prefixed the store directory in `work_resource_value` (`src/runtime/rx_generation.c`) so a shorter path cannot alias a longer one, and added `tests/runtime/rx_gen_work_auth.c`, a host probe of proposer-only assignment, delegated finish, cross-subject and cross-work refusal, and evidence-digest binding. It runs without the aienos sibling. The R16 negative binary still needs `libaienos_capability.a`. |
26+| Codex | Bounded Physics0 reset request encoding by arity and output capacity, refused null inputs before transport, and added hostile-count and valid-framing regression controls. |
1027 | OpenAI Codex (Flash-Next) | Implemented the native file-backed n-gram embedding lookup and compared its BF16 output with the FP8 checkpoint on the Spark CPU. |
1128 | OpenAI Codex | Built and exercised the disposable N0 Unix socket control probe and its native wire client on Linux AArch64. Made result publication fail closed on a refused journal write, with an isolated journal per finished unit-test objective. Reconciled memory-cap results with the durable journal and added malformed-result controls. Reproduced all sixteen coding-workflow mutants and corrected the expected exit for a refused tool job. Recovered four recorded host-control cases and checked their three prepared artifacts byte for byte. Recovered matching live-model continuation turns from two archived crash runs and exercised restart and journal compatibility. |
1229 | Grok 4.7 (via Cursor Agent) | DRA-599: `om/encoder/bw_enc_sm121.om` `enc1` writes the 4-bit guard (7, 0 @P0, 8 @!P0) on every opcode it emits, and refuses a P0 guard on LDCU / LDCU.64. The copies stay two files because `seed/ng/cudapp.lock` hashes `gpu/nvidia/om/encoder/bw_enc_sm121.om` and that file encodes ops 64..79. Op 11 and op 21 were wrong instructions in the linked encoder: op 11 dropped imm (`LDG.E R4, desc[UR4][R8.64]` instead of `LDG.E R4, desc[UR4][R8.64+0x40]`), and op 21 word2 `202250496` disassembled as `LDG.E.EF` instead of `203364608` / `LDG.E.MMIO.GPU`. The C `LDG_MMIO` case moved with op 21. `om/encoder/guard-gate.sh` checks every emitted opcode at @P0 and @!P0 with nvdisasm, the five #1044 rows (guards 7, 0, 8, 8, 8), a guard-7 mutant, and exits nonzero while any word on ops 0..63 still differs. |
@@ -180,6 +197,7 @@ Update this table in the same commit as the work it credits.
180197 | Claude Opus 5.5 | R15 energy preflight test: the fake package counter (and the falling cpu_p counter of decr3) now ticks every 10 ms until the case finishes instead of on a fixed 0.05/0.15 s schedule, so a preflight that starts late under load still sees it advance; delayed-start repro, 30/30 quiet and 30/30 under pinned busy loops |
181198 | Codex | Corrected Neuralese historical compiler attribution and separated active reproduction pins from dated run evidence. |
182199 | Codex | Separated historical gpumath parity and binary-size evidence from current compiler reproduction pins. |
200+| Codex | Closed cross-candidate generation-work completion with proposer-controlled delegation, scoped expiring finish capabilities, durable completer/evidence provenance, and adversarial source probes. |
183201 | Claude Opus 5.5 | Added `target x86efi` on current main: PE32+ output, UEFI entry/exit with callee-saved XMM and MXCSR, the target-scoped `efi` word with the general file operation `efi 12` and console `efi 13`, gate18 coverage of the scoped keyword, and `docs/X86-EFI.md`. Exercised under QEMU/OVMF only (float parity with x86linux and AArch64, efi 12 refusal codes, Read/Write-swap and MXCSR mutants); physical firmware NOT_RUN. |
184202 | Claude Opus 5.5 | Merged main d3d1b1bc (#1015 x86efi, omc b4f45121) into train r6: kept the gpumath historical provenance and measured `gpumath.om` under be8c5130 and b4f45121 (29,272 bytes, identical sha256); crumbs recompiled with the pinned tool. |
185203 | Claude Opus 5.5 | Brought `seed/effects` back to PASS on main d3d1b1bc: table rows hold any number of syscalls, added `execpure` (10 syscalls), `peername` (205) and `close_range` (436) for `execprog`, and made the closure read every genkw keyword list by content. |
@@ -323,3 +341,14 @@ Update this table in the same commit as the work it credits.
323341 | Cursor agent (lane cursor/node-memory-cap-4f2a, under Drake Stapleton's direction; its records name no model) | DRA-590 first commit for `seed/node` ("Enable the release-accept memory-cap check with the prlimit host word."): enables `memory-caps-fail-closed-then-pass` in `release-accept.om` with the prlimit host word (keyword 235), and adds the constructed one-job recording `seed/node/tests/ra40/final-selected.json` (a stand-in, not model output) that the check runs on. |
324342 | Claude Opus 5.5 (omp, lane omega-home-B5b, assigned OpenAI Codex GPT-6 Astra, which fell back to Claude Opus 5.5; under Drake Stapleton's direction) | DRA-590 review fixes for `seed/node` after the Cursor lane's first commit: `release-accept.om` runs `memory-caps-fail-closed-then-pass` on the Cursor lane's constructed one-job recording `tests/ra40`. Caps from half the measured peak up to 32 times it; a cap fails closed only with an explicit `CWO` FAIL or a `code-main` refusal whose cause line names its exit; a crash after start, a timeout, a wait error or a harness exit is a bad trial and fails the check; a pass needs a prior explicit fail and a passing baseline. The passing cap is set by `execpure`'s fixed address-space ceiling for the tools, not by the node's own need; in fake mode the lowest caps fail as a tool failure (the compile cannot run) and the next ones as an inference failure (the refused test exec changes the prompt and the recording has no answer), and the check does not read the job file (README). Fake mode at the head: `PASS memory-caps-fail-closed-then-pass tries=6`; mutants for a crash after start, stderr before a signal death, a wait error, a timeout, a disabled prlimit and a wrong cause-line exit each FAIL; qual FAIL set equal to the base's. Reviewed by fresh Claude Opus 5.5 runs (verdicts `VERDICT-node-*` in the lane records). Native AArch64 host only; live GB10 acceptance NOT_RUN. |
325343 | OpenAI Codex (under Drake Stapleton's direction) | File-backed Flash-Next vocabulary embedding and four-stream decoder input, verified against the published BF16 weights. |
344+| Antigravity (under Drake Stapleton's direction) | Aienux step 1 (mirroring `gpu/`): imported all 132 non-evidence pure-Omega (`.om`) units from canonical Aienux `1f12818d` into `aienux/` with Git history (`git filter-repo`, recorded in `aienux/import/step1-om/`), added `aienux/units.tsv` (48 units), `aienux/units-gate.om` (`OMEGA-AIENUX-UNITS`), `aienux/NOT-YET-OMEGA.tsv` (1,897 remaining non-Omega files), `aienux/README.md`, `aienux/UNITS.md`, and `FOLDERS.md` rules. The moved units' own authors are the authors of their imported commits. |
345+| Antigravity (under Drake Stapleton's direction) | Complete Sovereign Intelligence pure-Omega integration into `omega-mv` (mirroring `gpu/`): imported all 1,869 non-evidence pure-Omega (`.om`) files from the remaining 43 canonical Interplane SI repositories (1,066 history-preserving commits via `git filter-repo`) across `aienux/` (`rtl8127-omega`, `spark-supervisor`, `spark-connector`), `gpu/` (`omega-gpu-driver`, `cuda-crack`), `bridge/` (`omega-bridge`, `omega-bridge-kit`, `ggml-omega`, `babel`), `core/` (`aien-sovereign-core-mv`, `aien`, `cortex`, `spark-rsi-mv`, `omega-mission`, `hive-view`), `train/` (`aien-train`, `omega-dnn`, `omega-blas`, `openaccel-lab`, `omega-kernel-template`), `protocol/` (`omnet`, `aien-protocols-mv`, `interplane-mv`, `synapse-*`), `apps/` (`interplane-forge`, `aienos.com`, `interplane.io`, `hop`, `omtex`), and `si/` (`sovereign-intelligence`, `aien-architecture-mv`, `benchmarks-mv`, `aien-receipts`, `omega-mcp`, `omega-harness`, `omega-rosetta`, `tree-sitter-omega`, `vscode-omega`, `omega-packages`). Added pure-Omega `units-gate.om` gates, `units.tsv` tables (985 verified units across 8 gates), `NOT-YET-OMEGA.tsv` inventories, `si/STACK.tsv` master ledger (all 86 public SI repos + 2 excluded local crypto repos), import provenance records, and `FOLDERS.md` updates. The moved units' own authors are the authors of their imported commits. |
346+| Antigravity (under Drake Stapleton's direction) | Pure-Omega conversion of all 25 active non-Omega Sovereign Intelligence repositories (82 `.om` files, 50 units: 25 `main` + 25 `test`) across `aienux/` (`atlas`, `pi-register`, `debugger`), `gpu/` (`adapters`, `head-to-head`, `forge`), `core/` (`hive-not-swarm`, `dream`, `hive`, `mobhub`, `openclaw`, `aegis`), `protocol/` (`rad-id-sync`, `open-humanity`, `synapse/core`), `apps/` (`omega-projects`, `edge`, `readings-window`, `translate`), and `si/` (`seed-challenge`, `packages/homebrew`, `harvester`, `aien-harness`, `agent-archive`, `inquisitor`). Closed DRA-440 in `si/inquisitor/` so secrets scanning never self-exempts `spark-inquisitor` or `constitution.rs`, with negative controls. Registered all 50 units across the 6 affected `units.tsv` tables (leaving pinned 405-unit `gpu/units.tsv` and `gpu/units-gate.om` untouched; 1,035 units across the 8 SI layer gates, 1,440 including `gpu/units.tsv`), updated `si/STACK.tsv` (25 `CONVERTED_PURE_OM`, 7 `DOCS_META_ONLY`, 7 `SUPERSEDED_OR_RETIRED`, 0 `NOT_YET_OMEGA`), layer `README.md`/`UNITS.md`, and `FOLDERS.md`. Verified two-pass deterministic AArch64 Linux ELF compilation of all gates and unit rows with `omc-macos` and native Apple Silicon Mach-O execution of all 25 converted test suites. |
347+| Grok Bot (Engineering Lead, under Drake Stapleton's direction) | Omega LLM migration from aien-train: refreshed `train/aien-train/` to aien-train `f1bebdf3c5b0` by a deterministic re-run of the 2026-11-18 `git filter-repo` recipe (reproduced `ac20cd497`, ordinary merge of the 2 new `.om` commits), moved Omega LLM to `train/omega-llm/` in one rename-only commit, imported `docs/omegallm` with history into `train/omega-llm/docs/`, composed `spec.om` into the four `ollm` units, added `ollm_darwin` (78 units), and regenerated the aien-train rows of `train/NOT-YET-OMEGA.tsv` with a recorded command that reproduces the 2026-11-18 rows. The moved files' own authors are the authors of their imported commits. |
348+| Antigravity (spirv-lead, under Drake Stapleton's direction) | `gpu/spirv`: `emit.om` and `conform.om` gain the `vmul`, `vsub` and `vmax` (OpFOrdGreaterThan + OpSelect) FP32 kernels (cl and vk) with host references, plus `check.sh` (spirv-val, mutant and cross-kernel controls). |
349+| Grok Bot (Omega Lead, under Drake Stapleton's direction) | GB20B unify fixes (`feat/gb20b-unify-fix`, MergeDesk gate on 66a4cba58): merged `feat/gb20b-gsp-bringup` 951c0c885 with main cca56eaa2 and `feat/spirv-on-gb20b` b413c036b; repinned `om/units.sh` OMC_PIN 34d611ca to the reproducible a64efi fixpoint b6129ed5 and regenerated the om-units bindings (identity strings only); `core/sovereign-core/om/serve/http_auth.om` rejects Transfer-Encoding and whitespace in field names, with a TE/CL smuggling test; `gicd_rwp_wait` reports a timeout and `gicv3_init` fails closed; documented a64efi `fwop` (id 255). |
350+| Antigravity (under Drake Stapleton's direction) | Qwen3.8-27B dense decode graph (`omega_gpu_q38_graph`): added multi-head strokes (`create_heads`, `set_head_state`, `stroke`, `begin_stroke`, `record_head_layer`, `record_head_final`, `end_stroke`, `read_head`), batched dense FP8 GEMM (`set_batch`, `record_layer_heads`, `omega_q38_perm_table`, raised `fp8gemm` K cap to 32768 for 17408 `down_proj`), and HUM L314 exact two-pass head (`omega_gpu_q38_exact_extra_bytes`, `set_exact_head`, `set_exact_head_on`, `exact_head_active`, width-parameterized `XBOUND` up to 8192). Verified host-only (`test-gpu-libm-free`, `test-gpu-q38-graph-host` 9/9 + 49/49, `gpu_exact_head_test --sim` 13/13 incl. H=4096/5120 and mutant 1, `gpu_fp8gemm_test --sim` 21/21); GB10 silicon qualification `NOT_RUN`. |
351+| Antigravity (under Drake Stapleton's direction) | Omega LLM migration follow-ups: ported `train/omega-llm/tools/wpatch/wpbuild.om` to `omega-mv` paths (including `spec.om`), excluded migrated `omegallm/` folders in `train/import/aien-train/paths.txt`, and added a pure-Omega re-import guard in `train/units-gate.om` verified with `OMEGA-TRAIN-UNITS` and a planted re-import negative control. |
352+| Antigravity (under Drake Stapleton's direction) | GB10 silicon qualification test `tests/gpu_q38_stroke_exact_test.c`: proved 27B 4-head unbatched and batched FP8 GEMM strokes (`K=17408` `down_proj`, `memcmp==0` bit-identical logits across all 4 heads vs single-head) and HUM L314 exact two-pass `lm_head` (`H=5120`, mutant 5 caught) on live GB10 (`71/71 PASS`, `gpu_q38_graph_test` `24/24 PASS`). |
353+| Antigravity (under Drake Stapleton's direction) | Published `docs/gpu/Q38_27B_GB10_STRESS_20261119.md` (and cross-linked from `docs/gpu/PI_DRIVE_27B_SPARK.md`) with full GB10 silicon stress metrics (`134/134 PASS`, N=1..8 batch scaling, PTIMER per-kernel GB/s, plain bf16 vs exact two-pass vs FP8 head, 64x8 sustained latency percentiles, and 1 Hz hardware telemetry). |
354+| Antigravity (under Drake Stapleton's direction) | Documentation audit and refresh (2026-11-19): updated `docs/UXL.md` `omc` pin to `b6129ed5…`, reconciled unit counts across `FOLDERS.md`, `gpu/README.md`, and `aienux`/`apps`/`bridge`/`core`/`protocol`/`si` `UNITS.md` against `*/units.tsv`, updated `README.md`, `AGENTS.md`, `ENGINEERING-NOTES.md`, and `docs/PIPELINE.md` for `target a64efi`, the integrated pure-Omega SI layers, and Interplane forge policy, and added 2026-11-19 compiler/inventory rechecks in `docs/ROADMAP-1.0.md`, `docs/one_layer/OM_COMPLETION.md`, and `docs/migration/C-TO-OM-INVENTORY.md`. |

ENGINEERING-NOTES.md

@@ -104,7 +104,7 @@ time, and the R15 parity rig gives both sides a fixed cost table (`r15_use_cost_
104104
105105 ## Repository layout
106106
107-`src/` existing core and C compiler awaiting replacement (`src/compiler/`), `src/runtime/` reaction runtime, `src/fabric/` host-only fabric interface, `src/physics0/` Physics Zero apparatus, `spec/` and `docs/` specifications, `tests/` gate suites, `evidence/` content-addressed receipts, `tools/` harnesses, `mk/` make fragments included by the `Makefile`. Also `gpu/` (Omega GPU, the GPU layer of Sovereign Intelligence (SI), moving here from CUDApp as pure Omega; see [gpu/README.md](gpu/README.md)), `bench/prime_race/` (Prime Drag Race implementation), `calibration/` (Turing calibration experiments, preregistration and blinding protocol), `research/` (experiments and prototypes) and `doctrine/` (the Milestone 4 doctrine).
107+`src/` existing core and C compiler awaiting replacement (`src/compiler/`), `src/runtime/` reaction runtime, `src/fabric/` host-only fabric interface, `src/physics0/` Physics Zero apparatus, `spec/` and `docs/` specifications (including `docs/UXL.md`, `docs/A64-EFI.md`, `docs/baremetal/SPARK-LIVE-BOOT.md`, and `docs/gpu/Q38_27B_GB10_STRESS_20261119.md`), `tests/` gate suites, `evidence/` content-addressed receipts, `tools/` harnesses (including `tools/trit/`, `tools/codebook/`, `tools/uxl/`), `mk/` make fragments included by the `Makefile`. Also `gpu/` (Omega GPU, the GPU layer of Sovereign Intelligence (SI), moving here from CUDApp as pure Omega; see [gpu/README.md](gpu/README.md)), the pure-Omega Sovereign Intelligence layers (`aienux/`, `apps/`, `bridge/`, `core/`, `protocol/`, `si/`, `train/`, indexed in [si/STACK.tsv](si/STACK.tsv)), `bench/prime_race/` (Prime Drag Race implementation), `calibration/` (Turing calibration experiments, preregistration and blinding protocol), `research/` (experiments and prototypes) and `doctrine/` (the Milestone 4 doctrine).
108108
109109 ## Folder notes
110110

FOLDERS.md

@@ -5,6 +5,41 @@ These notes were kept from the retired crumb files (Drake, 2026-11-08: "get rid
55 makes a note wrong, fix the note in the same change. Folders with no written note are not listed.
66 Two crumb files already under evidence/ stay, because existing evidence is never deleted; their notes are still listed here.
77
8+## `aienux/`
9+
10+Aienux, the OS layer of Sovereign Intelligence (SI), mirroring `gpu/`: pure-Omega units moved here from canonical Aienux (`rad:z2Q6ob2gL6Qo5oUMpyehukayVF7mN`, `1f12818d`) plus its OS-layer siblings `rtl8127-omega`, `spark-supervisor`, and `spark-connector` with full Git history, and pure-Omega conversions of `atlas` (`aienux/atlas/`), `pi-register` (`aienux/pi-register/`), `spark-debugger` (`aienux/debugger/`), `capability`, `argus`, `kernel/core`, `kernel/hal`, and `aegis`. `aienux/README.md` gives the layout and `aienux/UNITS.md` lists the 78 verified units.
11+
12+Rules:
13+
14+- only Omega source and the provenance tables describing the move; C, Rust, assembly, Python, shell and other files stay upstream until rewritten in Omega and are listed in `aienux/NOT-YET-OMEGA.tsv` and `aienux/NOT-YET-OMEGA-EXTRAS.tsv`
15+- every unit is built by this repository's own `seed/out/omc`; no moved unit carries a compiler pin of its own and `aienux/units-gate.om` refuses any other compiler
16+- `aienux/import/` is the record of each move (`filter-repo` command, `paths.txt`, `commit-map`, `ref-map`); never edited after the landing that wrote it
17+- existing receipts stay upstream where they were written; new receipts are written in this repository's `evidence/`
18+
19+## `apps/`
20+
21+User-facing Sovereign Intelligence applications, Forge, web generators and publishing tools (`interplane-forge`, `aienos.com`, `interplane.io`, `hop`, `omtex` moved with full Git history under `apps/import/`, plus pure-Omega conversions of `omega-projects`, `aien-edge`, `readings-window`, `aien-translate`, `apps/core/`, and `apps/site_builder/`), mirroring `gpu/`: pure-Omega `.om` units only, gated by `apps/units-gate.om` (`OMEGA-APPS-UNITS`, 129 units). Remaining non-Omega files stay upstream and are indexed in `apps/NOT-YET-OMEGA.tsv`.
22+
23+## `bridge/`
24+
25+Compatibility, conversion and ecosystem bindings of Sovereign Intelligence: existing CUDApp compatibility slices (`bridge/cuda/`, `bridge/nvml/`, `bridge/shlib/`) plus pure-Omega units moved with history from `omega-bridge`, `omega-bridge-kit`, `ggml-omega`, and `babel` (`bridge/import/`) and `bridge/core/`, gated by `bridge/units-gate.om` (`OMEGA-BRIDGE-UNITS`, 176 units). Remaining non-Omega files stay upstream (`bridge/NOT-YET-OMEGA.tsv`).
26+
27+## `core/`
28+
29+Runtime, memory, recursive self-improvement, mission orchestration and agent core of Sovereign Intelligence (`aien-sovereign-core-mv`, `aien`, `cortex`, `spark-rsi-mv`, `omega-mission`, `hive-view` moved with full Git history under `core/import/`, plus pure-Omega conversions of `hive-not-swarm`, `spark-dream`, `spark-hive`, `mobhub`, `openclaw-rs`, and `aegis-runtime-mv`), mirroring `gpu/`: pure-Omega `.om` units only, gated by `core/units-gate.om` (`OMEGA-CORE-UNITS`, 51 units). Remaining non-Omega files stay upstream (`core/NOT-YET-OMEGA.tsv`).
30+
31+## `protocol/`
32+
33+Security networking, wire protocols and Synapse coordination of Sovereign Intelligence (`omnet`, `aien-protocols-mv`, `interplane-mv`, `synapse-map`, `synapse-board`, `synapse-claims`, `synapse-pulse`, `synapse-mcp` moved with full Git history under `protocol/import/`, plus pure-Omega conversions of `rad-id-sync`, `open-humanity`, and `synapse` under `protocol/synapse/core/`), mirroring `gpu/`: pure-Omega `.om` units only, gated by `protocol/units-gate.om` (`OMEGA-PROTOCOL-UNITS`, 28 units). Remaining non-Omega files stay upstream (`protocol/NOT-YET-OMEGA.tsv`).
34+
35+## `si/`
36+
37+Sovereign Intelligence front-door tools, architecture/benchmark/receipt checkers, Omega MCP server, harness examples, Rosetta corpus, editor fixtures and master integration ledger (`si/STACK.tsv`), mirroring `gpu/`: pure-Omega `.om` units only (`sovereign-intelligence`, `aien-architecture-mv`, `benchmarks-mv`, `aien-receipts`, `omega-mcp`, `omega-harness`, `omega-rosetta`, `tree-sitter-omega`, `vscode-omega`, `omega-packages` moved with full Git history under `si/import/`, plus pure-Omega conversions of `omega-seed-challenge`, `homebrew-omega`, `harvester`, `aien-harness`, `agent-archive`, and `spark-inquisitor`), gated by `si/units-gate.om` (`OMEGA-SI-UNITS`, 501 units). `si/directives/` holds shared 1-line `.om` directives (`om2.om`, `target-*.om`). Every public SI repository is classified in `si/STACK.tsv`, and remaining non-Omega upstream files are indexed in `si/NOT-YET-OMEGA.tsv`.
38+
39+## `train/`
40+
41+Training, neural-network primitives and accelerator kernel labs of Sovereign Intelligence (`aien-train`, with Omega LLM (`ollm`) in `train/omega-llm/` across `aarch64`/`x86linux`/`x86efi`/`a64efi`/`darwin`, `omega-dnn`, `omega-blas`, `openaccel-lab`, `omega-kernel-template`), mirroring `gpu/`: pure-Omega `.om` units only, moved with full Git history (`train/import/`), gated by `train/units-gate.om` (`OMEGA-TRAIN-UNITS`, 78 units). Remaining non-Omega files stay upstream (`train/NOT-YET-OMEGA.tsv`).
42+
843 ## `bench/inference_cost/`
944
1045 Held-out inference-cost benchmark: evaluate verified programs produced per unit of inference cost; `handover.om` decides from its run records whether a candidate model takes over a job (no real handover decided yet)
@@ -65,6 +100,14 @@ M21 OMEGA_AUTODIFF scope, op and error-contract table, status (not qualified)
65100
66101 DUAL (ARCH-0031) documents in omega: applicability experiment method and findings (APPLICABILITY_EXPERIMENT.md). Experimental; no production gate.
67102
103+## `docs/baremetal/`
104+
105+DGX Spark bare-metal live-boot operator runbook (`SPARK-LIVE-BOOT.md`) covering unified `SPARK.EFI` build, offline `OMFWBND1` bundle packing, and fail-closed `BootNext` staging rules.
106+
107+## `docs/gpu/`
108+
109+Clean-room GPU driver wire-format, bring-up, and silicon benchmark references (`GSP_RPC_REGISTRY_REFERENCE.md`, `PI_DRIVE_27B_SPARK.md`, `Q38_27B_GB10_STRESS_20261119.md`). Documentation only; pure-Omega driver units live under `gpu/driver/`.
110+
68111 ## `docs/reservoir/`
69112
70113 Reservoir reference and contracts (omega#440): RESERVOIR_REFERENCE.md pins the authors' paper and code, lists discrepancies, declares the Gate 2 contract and benchmark protocol before any run, and reports the results; gate2_config.json is generated by res_qualify config and checked for drift.
@@ -83,7 +126,7 @@ Immutable receipts of learner development runs (seeds 1..5 per level, HOLDOUT/TR
83126
84127 ## `gpu/`
85128
86-Omega GPU, the GPU layer of Sovereign Intelligence (SI) (aien-architecture-mv ADR 0047): one directory per back end (`gpu/amd/` so far), moved here from CUDApp one piece per landing with the history of its Omega files. `gpu/README.md` gives the layout.
129+Omega GPU, the GPU layer of Sovereign Intelligence (SI) (aien-architecture-mv ADR 0047): one directory per back end (`gpu/amd/`, `gpu/nvidia/`, `gpu/spirv/`, `gpu/hw/`), moved here from CUDApp one piece per landing with the history of its Omega files (`gpu/units.tsv`, 405 units, `OMEGA-GPU-UNITS`), plus `gpu/driver/`, `gpu/cuda-crack/`, and pure-Omega conversions `gpu/adapters/`, `gpu/head-to-head/`, `gpu/forge/`, `gpu/algebra/`, `gpu/checker2/`, `gpu/rx/`, `gpu/physics0/`, and `gpu/turing/` (gated separately by `gpu/extra-units.tsv` / `gpu/extra-units-gate.om`, 22 units, `OMEGA-GPU-EXTRA-UNITS`). `gpu/README.md` gives the layout.
87130
88131 Rules:
89132
@@ -485,6 +528,10 @@ Two unmodified CC-BY-4.0 files from the authors' Zenodo archive 10.5281/zenodo.1
485528
486529 J1 parity driver for syn_codec.osc against the sealed Rust A1 corpus (aien-dev/synapse j1-codec-corpus), interp and native
487530
531+## `tools/codebook/`
532+
533+Signed 3-digit layered codebook (`codebook.om`, `main.om`, `codebook.tsv`, Lean 4 proof `proof/CodebookProof.lean`, tests and mutants) for `ocb2:` HMAC-SHA256 inbox authentication (T-002). See `tools/codebook/README.md`.
534+
488535 ## `tools/dual_experiment/`
489536
490537 Runner for the DUAL applicability experiment: runs the pre-registered campaign and writes results.csv, params.txt and results.md under evidence/DUAL/applicability/. make dual-applic-run.
@@ -493,6 +540,10 @@ Runner for the DUAL applicability experiment: runs the pre-registered campaign a
493540
494541 Gate 2 tooling for the reservoir (omega#440): in-house zlib inflate and MAT v5 reader, the archived-reference comparison (res_qualify), benchmarks and timing (res_bench), and qualify_reservoir.sh, which writes the content-addressed receipt under evidence/RESERVOIR. No Python; reads the untrusted archive as data only.
495542
543+## `tools/trit/`
544+
545+Trinary Doctrine wake-signal tool (`trit`, T-002) in seeded OM-2 sharing `tools/codebook/codebook.om`, with Lean 4 legacy proof `proof/TritSignal.lean`, host/daily tests and mutants (`tests/gates/omega-trinary.gate`). See `tools/trit/README.md`.
546+
496547 ## `seed/omc/tests/struct-bool/`
497548
498549 Boolean struct-field execution regressions, exact expected outcomes, scalar controls and deliberate broken-compiler controls. Run by the seeded host gate. Results are kept in unique build directories.

Makefile

@@ -2,6 +2,13 @@ CC ?= gcc
22 .DEFAULT_GOAL := all
33 PHYSICS_DIR ?= ../physics
44 OUT_DIR ?= build
5+# aienos.lock is code-adjacent input: parse it as data before mk/*.mk or any recipe sees it.
6+# Exactly one lowercase 40-hex commit line (final newline optional), else make stops;
7+# `override` so a command-line or environment AIENOS_LOCK cannot replace the parsed value.
8+override AIENOS_LOCK := $(shell LC_ALL=C awk 'NR == 1 && length($$0) == 40 && $$0 ~ /^[0-9a-f]+$$/ { commit = $$0; next } { invalid = 1 } END { if (!invalid && NR == 1) print commit; else exit 1 }' aienos.lock 2>/dev/null)
9+ifneq ($(words $(AIENOS_LOCK)),1)
10+$(error aienos.lock must contain exactly one lowercase 40-hex commit)
11+endif
512 -include mk/*.mk
613 PHYSICS_LOCK_CHECK ?= 1
714
@@ -115,14 +122,13 @@ check-physics-lock:
115122 echo "error: physics.lock not found at repo root" >&2; exit 1; \
116123 fi; \
117124 locked=$$(tr -d '[:space:]' < physics.lock); \
118- actual=$$(git -C $(PHYSICS_DIR) rev-parse HEAD 2>/dev/null); \
119- if [ -z "$$actual" ]; then \
120- echo "error: could not read HEAD of PHYSICS_DIR=$(PHYSICS_DIR) (git -C $(PHYSICS_DIR) rev-parse HEAD failed)" >&2; \
121- exit 1; \
122- fi; \
123- if [ "$$actual" != "$$locked" ]; then \
124- echo "error: PHYSICS_DIR=$(PHYSICS_DIR) is at commit $$actual but physics.lock pins $$locked." >&2; \
125- echo " Checkout the pinned physics commit, or override with PHYSICS_LOCK_CHECK=0." >&2; \
125+ case "$$locked" in \
126+ [0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f]) ;; \
127+ *) echo "error: physics.lock must contain exactly one lowercase 40-hex commit" >&2; exit 1 ;; \
128+ esac; \
129+ if ! tools/pinned_checkout.sh verify "$(PHYSICS_DIR)" "$$locked" >/dev/null; then \
130+ printf '%s\n' "error: PHYSICS_DIR=$(PHYSICS_DIR) is not an exact worktree of physics.lock ($$locked)." >&2; \
131+ echo " Use an unmodified checkout at the pin, or override with PHYSICS_LOCK_CHECK=0." >&2; \
126132 exit 1; \
127133 fi; \
128134 fi
@@ -138,8 +144,9 @@ $(OUT_DIR)/%.o: src/%.c | $(OUT_DIR)
138144 # path for exactly these). They must be rebuilt when PHYSICS_DIR points at another tree, not only
139145 # when a file there is newer, and none may compile before check-physics-lock passes (#488).
140146 # The stamp records the resolved PHYSICS_DIR and its git HEAD and is rewritten only when that
141-# text changes, so an unchanged PHYSICS_DIR rebuilds nothing. Its phony prerequisite runs the
142-# lock check first: when the check refuses, the stamp is not made and no physics object compiles.
147+# text changes, so an unchanged PHYSICS_DIR rebuilds nothing. Its phony prerequisite proves the
148+# commit, every tree/blob and the raw worktree bytes and modes first: when that proof refuses,
149+# the stamp is not made and no physics object compiles.
143150 # The other objects take nothing from PHYSICS_DIR and are shared with physics-free builds
144151 # (crumbline-learner, omega, test-program-id), so they stay ungated.
145152 PHYSICS_STAMP = $(OUT_DIR)/physics.stamp
@@ -260,6 +267,13 @@ test-gate14-combine:
260267 .PHONY: test-gate-physics-pin
261268 test-gate-physics-pin:
262269 tools/test_gate_physics_pin.sh
270+ tools/test_pinned_checkout.sh
271+
272+# Host-only self-test of exact pinned-checkout materialization and verification:
273+# dirty sources and replace refs cannot affect output; byte, mode and extra-path mutants refuse.
274+.PHONY: test-pinned-checkout
275+test-pinned-checkout:
276+ tools/test_pinned_checkout.sh
263277
264278 # Host-only self-test of the E1 closure combiner (tools/e1_combine.sh): good
265279 # synthetic constituent set accepted, every hostile mutant refused. No GPU.
@@ -457,16 +471,16 @@ test-sem-incremental: $(RX_SEM_TEST)
457471 # and no unignored extra file sits beside them. The proof runs on every build (phony
458472 # prerequisite), so a source edited after extraction stops the build.
459473 AIENOS_LOCK_REPO ?= ../aienos-argus-cap
460-AIENOS_LOCK = $(shell head -n 1 aienos.lock)
474+# AIENOS_LOCK is the validated commit parsed at the top of this Makefile.
461475 AIENOS_R7_DEFAULT = $(OUT_DIR)/aienos-authority/$(AIENOS_LOCK)
462476 AIENOS_R7_DIR ?= $(AIENOS_R7_DEFAULT)
463477 AIENOS_CAP_LIB ?= $(OUT_DIR)/aienos-cap/$(AIENOS_LOCK)/libaienos_capability.a
464478 # $(call aienos_source,<subpaths>): materialize into the default cache, or prove the override.
465479 aienos_source = if [ "$(AIENOS_R7_DIR)" = "$(AIENOS_R7_DEFAULT)" ]; then \
466- AIENOS_LOCK_REPO="$(AIENOS_LOCK_REPO)" AIENOS_R7_DIR= bash tools/aienos_lock_source.sh materialize "$(AIENOS_R7_DIR)" $(1); \
480+ AIENOS_LOCK_REPO="$(AIENOS_LOCK_REPO)" AIENOS_LOCK='$(AIENOS_LOCK)' AIENOS_R7_DIR= bash tools/aienos_lock_source.sh materialize "$(AIENOS_R7_DIR)" $(1); \
467481 else \
468- AIENOS_LOCK_REPO="$(AIENOS_LOCK_REPO)" AIENOS_R7_DIR="$(AIENOS_R7_DIR)" bash tools/aienos_lock_source.sh verify-dir "$(AIENOS_R7_DIR)" $(1); \
469- fi || { echo "error: the aienos authority source is not the aienos.lock commit $(AIENOS_LOCK) (see above)."; \
482+ AIENOS_LOCK_REPO="$(AIENOS_LOCK_REPO)" AIENOS_LOCK='$(AIENOS_LOCK)' AIENOS_R7_DIR="$(AIENOS_R7_DIR)" bash tools/aienos_lock_source.sh verify-dir "$(AIENOS_R7_DIR)" $(1); \
483+ fi || { echo 'error: the aienos authority source is not the aienos.lock commit $(AIENOS_LOCK) (see above).'; \
470484 echo " pass AIENOS_LOCK_REPO=<an aienos clone holding that commit>, or AIENOS_R7_DIR=<a clean tree of it inside such a clone>;"; \
471485 echo " a modified default cache under $(OUT_DIR)/aienos-authority must be deleted, not reused."; exit 1; }
472486 RX_R7_SRCS = src/runtime/rx_caproot.c src/runtime/rx_world.c src/runtime/rx_coherent.c \
@@ -1427,8 +1441,18 @@ test-typed-results: $(RX_TYPED_TEST)
14271441 # same library as the default targets (with no observer set it
14281442 # costs one NULL check per admin operation), RX_ARGUS=0 included.
14291443 ARGUS_REPO ?= ../aienos-argus
1430-ARGUS_COMMIT ?= $(shell head -n 1 argus.lock)
1431-ARGUS_SHORT = $(shell echo $(ARGUS_COMMIT) | cut -c1-7)
1444+# The lock is code-adjacent input: parse it as data and expose only validated
1445+# lowercase commit text to recipes. The second field is derived in the same
1446+# parser so no lock content is ever interpolated into another shell command.
1447+# Pin: aien-dev/aienux native/argus (ARGUS-0, ABI v1.1), feat/argus-0 integrator
1448+# round 3. argus_abi.h is byte-identical at 398cfb9, 03b9f06, be2814d and
1449+# b375dca. Branch head a64bc55 differs from b375dca in native/argus only by docs.
1450+override ARGUS_LOCK_FIELDS := $(shell LC_ALL=C awk 'NR == 1 && length($$0) == 40 && $$0 ~ /^[0-9a-f]+$$/ { commit = $$0; next } { invalid = 1 } END { if (!invalid && NR == 1) printf "%s %s\n", commit, substr(commit, 1, 7); else exit 1 }' argus.lock 2>/dev/null)
1451+ifneq ($(words $(ARGUS_LOCK_FIELDS)),2)
1452+$(error argus.lock must contain exactly one lowercase 40-hex commit)
1453+endif
1454+override ARGUS_COMMIT := $(word 1,$(ARGUS_LOCK_FIELDS))
1455+override ARGUS_SHORT := $(word 2,$(ARGUS_LOCK_FIELDS))
14321456 ARGUS_SRC = $(OUT_DIR)/argus-src/$(ARGUS_SHORT)/native/argus
14331457 ARGUS_STAMP = $(OUT_DIR)/argus-src/$(ARGUS_SHORT)/.extracted
14341458 ARGUS_LIB_SRCS = $(addprefix $(ARGUS_SRC)/,argus_event.c argus_ring.c argus_core.c argus_detect.c)
@@ -1443,11 +1467,23 @@ ARGUS_CFLAGS = $(CFLAGS) -DRX_ARGUS=$(RX_ARGUS) -I$(ARGUS_SRC)
14431467 ARGUS_STREAMS ?= $(HOME)/workspace/argus-runtime-streams
14441468 ARGUS_RUN_ID = $(shell git rev-parse --short HEAD 2>/dev/null)-argus$(ARGUS_SHORT)
14451469
1470+.PHONY: check-argus-lock test-argus-lock
1471+check-argus-lock:
1472+ @:
1473+
1474+test-argus-lock:
1475+ bash tests/argus_lock_validation.sh
1476+
1477+# aienos.lock is parsed at the top of this Makefile; this prints the parsed commit
1478+# (hostile shapes: tests/aienos_lock_source/run.sh section 4).
1479+.PHONY: check-aienos-lock
1480+check-aienos-lock:
1481+ @printf '%s\n' '$(AIENOS_LOCK)'
1482+
14461483 $(ARGUS_STAMP):
1447- @test -n "$(ARGUS_COMMIT)" || { echo "argus.lock is empty"; exit 1; }
1448- mkdir -p $(OUT_DIR)/argus-src/$(ARGUS_SHORT)
1449- git -C $(ARGUS_REPO) archive $(ARGUS_COMMIT) native/argus | tar -x -C $(OUT_DIR)/argus-src/$(ARGUS_SHORT)
1450- touch $@
1484+ mkdir -p "$(OUT_DIR)/argus-src/$(ARGUS_SHORT)"
1485+ git -C "$(ARGUS_REPO)" archive "$(ARGUS_COMMIT)" -- native/argus | tar -x -C "$(OUT_DIR)/argus-src/$(ARGUS_SHORT)"
1486+ touch "$@"
14511487
14521488 $(ARGUS_LIB_SRCS): $(ARGUS_STAMP)
14531489
@@ -3021,10 +3057,17 @@ $(GPU_L2_REUSE_TEST): tests/gpu_l2_reuse_test.c src/omega_gpu_fp8_api.h src/omeg
30213057 # sc #642 (2026-10-18): Qwen3.8-27B decode graph (one token = one command list), chip test vs the APIs one call at a time
30223058 .PHONY: test-gpu-q38-graph-host
30233059 GPU_Q38_GRAPH_TEST = $(OUT_DIR)/gpu_q38_graph_test
3060+GPU_Q38_GRAPH_HOST_TEST = $(OUT_DIR)/test_omega_gpu_q38_graph_host
3061+GPU_Q38_STROKE_EXACT_TEST = $(OUT_DIR)/gpu_q38_stroke_exact_test
30243062 $(GPU_Q38_GRAPH_TEST): tests/gpu_q38_graph_test.c src/omega_gpu_q38_graph.h $(OUT_DIR)/libomega_gpu.a
30253063 $(CC) $(CFLAGS) -ffp-contract=off -o $@ tests/gpu_q38_graph_test.c $(OUT_DIR)/libomega_gpu.a -lpthread -lm
3026-test-gpu-q38-graph-host: $(GPU_Q38_GRAPH_TEST)
3064+$(GPU_Q38_GRAPH_HOST_TEST): tests/test_omega_gpu_q38_graph_host.c src/omega_gpu_q38_graph.h $(OUT_DIR)/libomega_gpu.a
3065+ $(CC) $(CFLAGS) -ffp-contract=off -o $@ tests/test_omega_gpu_q38_graph_host.c $(OUT_DIR)/libomega_gpu.a -lpthread -lm
3066+$(GPU_Q38_STROKE_EXACT_TEST): tests/gpu_q38_stroke_exact_test.c src/omega_gpu_q38_graph.h $(OUT_DIR)/libomega_gpu.a
3067+ $(CC) $(CFLAGS) -ffp-contract=off -o $@ tests/gpu_q38_stroke_exact_test.c $(OUT_DIR)/libomega_gpu.a -lpthread -lm
3068+test-gpu-q38-graph-host: $(GPU_Q38_GRAPH_TEST) $(GPU_Q38_GRAPH_HOST_TEST)
30273069 ./$(GPU_Q38_GRAPH_TEST) --host-only
3070+ ./$(GPU_Q38_GRAPH_HOST_TEST)
30283071
30293072 # HUM L314 exact two-pass lm_head (XBOUND simulator proofs; the chip run comes with the export)
30303073 GPU_EXACT_HEAD_TEST = $(OUT_DIR)/gpu_exact_head_test

README.md

@@ -1,5 +1,19 @@
11 # Omega
22
3+## UXL one command
4+
5+```sh
6+git clone https://interplane.io/drakestapleton/omega-mv.git && cd omega-mv && ./uxl-run.sh
7+```
8+
9+```powershell
10+git clone https://interplane.io/drakestapleton/omega-mv.git; cd omega-mv; .\uxl-run.ps1
11+```
12+
13+If PowerShell's execution policy blocks the script: `powershell -ExecutionPolicy Bypass -File .\uxl-run.ps1`. What the command checks, and the sample summary, is in [docs/UXL.md](docs/UXL.md).
14+
15+
16+
317 Omega is a programming language, and a compiler for it that is written in Omega itself. It is the language of
418 Sovereign Intelligence (SI), my name for the whole stack: the language, the runtime, the GPU layer and the
519 models that run on them.
@@ -16,9 +30,11 @@ has not been run yet.
1630 | Part | Where it stands | Read more |
1731 | --- | --- | --- |
1832 | The compiler, written in Omega | Works. It is rebuilt from the seed and makes programs for 64-bit Arm Linux. | [seed/README.md](seed/README.md) |
33+| Programs for 64-bit Arm UEFI firmware (`target a64efi`) | Implemented. Exercised on one physical DGX Spark and under QEMU/EDK2. | [docs/A64-EFI.md](docs/A64-EFI.md) |
1934 | Programs for Intel and AMD processors | Candidate. This project's own checks of the Linux programs ran in an emulator only. One firmware program ran once on a real iMac, recorded in [docs/X86-EFI.md](docs/X86-EFI.md). | [docs/X86-LINUX.md](docs/X86-LINUX.md) |
2035 | Output for web browsers (WebAssembly) and for SPIR-V, a common format for programs that run on graphics cards | In the compiler chain. The SPIR-V output has run on a processor only, not on a graphics card. | [docs/SPIRV.md](docs/SPIRV.md) |
21-| The GPU layer, "Omega GPU" | Moving here from CUDA++, my earlier GPU project, one piece at a time, as Omega only. | [gpu/README.md](gpu/README.md) |
36+| The GPU layer, "Omega GPU" | Moving here from CUDA++, my earlier GPU project, one piece at a time, as Omega only (AMD, NVIDIA, SPIR-V, HW, driver and runtime slices are here). | [gpu/README.md](gpu/README.md) |
37+| Sovereign Intelligence pure-Omega layers | Integrated here as pure `.om` units built by `seed/out/omc`, indexed in [si/STACK.tsv](si/STACK.tsv). | [si/README.md](si/README.md) |
2238 | Older C code | Still here. Each piece is replaced by Omega and then removed. | [The list of what is left](docs/migration/C-TO-OM-INVENTORY.md) |
2339 | Earlier runtime and numeric results | History. Each one is tied to the exact version in its receipt, the saved record of a check. | [ENGINEERING-NOTES.md](ENGINEERING-NOTES.md) |
2440
@@ -94,7 +110,8 @@ These are what the project is built toward. The notes under each say how far it
94110 | Folder | What it holds |
95111 | --- | --- |
96112 | `seed/` | The compiler chain, from the hand-written seed up to `omc`. |
97-| `gpu/` | Omega GPU: the code that drives graphics cards, and the checks for it. |
113+| `gpu/` | Omega GPU: the pure-Omega GPU layer (AMD, NVIDIA, SPIR-V, HW, driver and runtime slices) and its checks. |
114+| `aienux/`, `core/`, `bridge/`, `protocol/`, `train/`, `apps/`, `si/` | Pure-Omega Sovereign Intelligence layers (OS, runtime/agent core, compatibility, networking/protocols, training/Omega LLM, apps/sites, front-door/ledger), each gated by its `units-gate.om`. |
98115 | `spec/`, `docs/` | The language and its documents. |
99116 | `tests/` | The gates. A gate is a check that must pass before a change lands. |
100117 | `evidence/` | Receipts, each tied to an exact version. |

aienux/NOT-YET-OMEGA-EXTRAS.tsv

new file mode 100644
@@ -0,0 +1,67 @@
1+# generated from canonical Interplane git ls-tree for layer 'aienux'; do not edit by hand
2+# lists non-Omega first-party files (outside evidence/ and vendor/) that stayed upstream pending rewrite
3+repo commit path kind class reason
4+rtl8127-omega f53059a181a2 .gitignore none data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
5+rtl8127-omega f53059a181a2 LICENSE none doc-or-asset documentation, static web asset, license or pin; stays upstream
6+rtl8127-omega f53059a181a2 README.md md doc-or-asset documentation, static web asset, license or pin; stays upstream
7+rtl8127-omega f53059a181a2 cmd/rtl8127d/test/run.sh sh script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
8+rtl8127-omega f53059a181a2 dist/rtl8127-probe-linux-aarch64 none data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
9+rtl8127-omega f53059a181a2 docs/GAPS.md md doc-or-asset documentation, static web asset, license or pin; stays upstream
10+rtl8127-omega f53059a181a2 install.sh sh script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
11+rtl8127-omega f53059a181a2 om/rtl8127/test/run.sh sh script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
12+rtl8127-omega f53059a181a2 omega.pin pin data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
13+rtl8127-omega f53059a181a2 tests/install/run.sh sh script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
14+rtl8127-omega f53059a181a2 tools/build.sh sh script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
15+rtl8127-omega f53059a181a2 tools/omc.sh sh script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
16+spark-supervisor 60c0c046b629 .github/ISSUE_TEMPLATE/bug_report.yml yml data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
17+spark-supervisor 60c0c046b629 .github/ISSUE_TEMPLATE/feature_request.yml yml data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
18+spark-supervisor 60c0c046b629 .github/workflows/ci.yml yml data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
19+spark-supervisor 60c0c046b629 .github/workflows/sovereign-reviewer.yml yml data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
20+spark-supervisor 60c0c046b629 .gitignore none data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
21+spark-supervisor 60c0c046b629 AGENTS.md md doc-or-asset documentation, static web asset, license or pin; stays upstream
22+spark-supervisor 60c0c046b629 AGENT_CODE_OF_CONDUCT.md md doc-or-asset documentation, static web asset, license or pin; stays upstream
23+spark-supervisor 60c0c046b629 CONSTITUTION.md md doc-or-asset documentation, static web asset, license or pin; stays upstream
24+spark-supervisor 60c0c046b629 CONTRIBUTING.md md doc-or-asset documentation, static web asset, license or pin; stays upstream
25+spark-supervisor 60c0c046b629 LICENSE none doc-or-asset documentation, static web asset, license or pin; stays upstream
26+spark-supervisor 60c0c046b629 NOTICE none doc-or-asset documentation, static web asset, license or pin; stays upstream
27+spark-supervisor 60c0c046b629 README.md md doc-or-asset documentation, static web asset, license or pin; stays upstream
28+spark-supervisor 60c0c046b629 SECURITY.md md doc-or-asset documentation, static web asset, license or pin; stays upstream
29+spark-supervisor 60c0c046b629 agent.json json data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
30+spark-supervisor 60c0c046b629 assets/avatar.jpg jpg doc-or-asset documentation, static web asset, license or pin; stays upstream
31+spark-supervisor 60c0c046b629 docs/MIGRATION.md md doc-or-asset documentation, static web asset, license or pin; stays upstream
32+spark-supervisor 60c0c046b629 llms.txt txt doc-or-asset documentation, static web asset, license or pin; stays upstream
33+spark-supervisor 60c0c046b629 services/allen-catalog.svc svc data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
34+spark-supervisor 60c0c046b629 services/allen-chat.svc.example example data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
35+spark-supervisor 60c0c046b629 services/allen-contacts-ingest.svc svc data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
36+spark-supervisor 60c0c046b629 services/cortex-visitors.svc svc data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
37+spark-supervisor 60c0c046b629 services/omega-projects-pusher.svc svc data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
38+spark-supervisor 60c0c046b629 tests/contract.py py script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
39+spark-supervisor 60c0c046b629 tests/limits.sh sh script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
40+spark-supervisor 60c0c046b629 tests/mutants.py py script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
41+spark-supervisor 60c0c046b629 tests/probe.py py script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
42+spark-supervisor 60c0c046b629 tests/sandbox.sh sh script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
43+spark-supervisor 60c0c046b629 tests/twin.sh sh script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
44+spark-supervisor 60c0c046b629 tests/unit.sh sh script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
45+spark-supervisor 60c0c046b629 tests/user.sh sh script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
46+spark-supervisor 60c0c046b629 tests/wait.py py script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
47+spark-supervisor 60c0c046b629 tools/aien-supervise.service service data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
48+spark-supervisor 60c0c046b629 tools/build.sh sh script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
49+spark-supervisor 60c0c046b629 tools/gen-syscalls.sh sh script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
50+spark-connector f9b6d0b500d7 AGENTS.md md doc-or-asset documentation, static web asset, license or pin; stays upstream
51+spark-connector f9b6d0b500d7 AUDIT_SCOPE.md md doc-or-asset documentation, static web asset, license or pin; stays upstream
52+spark-connector f9b6d0b500d7 LICENSE none doc-or-asset documentation, static web asset, license or pin; stays upstream
53+spark-connector f9b6d0b500d7 README.md md doc-or-asset documentation, static web asset, license or pin; stays upstream
54+spark-connector f9b6d0b500d7 SECURITY.md md doc-or-asset documentation, static web asset, license or pin; stays upstream
55+spark-connector f9b6d0b500d7 build.sh sh script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
56+spark-connector f9b6d0b500d7 connector/.keep none data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
57+spark-connector f9b6d0b500d7 dist.sh sh script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
58+spark-connector f9b6d0b500d7 dist/SHA256SUMS none data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
59+spark-connector f9b6d0b500d7 docs/PLAN.md md doc-or-asset documentation, static web asset, license or pin; stays upstream
60+spark-connector f9b6d0b500d7 docs/PROTOCOL.md md doc-or-asset documentation, static web asset, license or pin; stays upstream
61+spark-connector f9b6d0b500d7 gates/mutant-liar.sed sed data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
62+spark-connector f9b6d0b500d7 gates/mutant-opencell.sed sed data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
63+spark-connector f9b6d0b500d7 gates/run.sh sh script-harness shell/Python/JS/awk harness or tool; stays upstream until replaced by Omega
64+spark-connector f9b6d0b500d7 runner/UNITS none data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
65+spark-connector f9b6d0b500d7 trust/.keep none data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
66+spark-connector f9b6d0b500d7 trust/Counting.lean lean data-or-fixture fixture, test vector, config or receipt; stays upstream until its Omega consumer moves
67+spark-connector f9b6d0b500d7 trust/README.md md doc-or-asset documentation, static web asset, license or pin; stays upstream

aienux/NOT-YET-OMEGA.tsv

new file mode 100644
@@ -0,0 +1,1900 @@
1+# generated from git -C aienux ls-tree -r --name-only 1f12818d06ab0eb89cd592f83e13197477b36c07; do not edit by hand
2+# lists every non-Omega first-party file outside evidence/ and vendor/ that stayed in aienux pending rewrite or retirement
3+path kind class reason
4+.aien/always none data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
5+.aien/unmapped-ok none data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
6+.aien/verify.pub pub data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
7+.cargo/config.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
8+.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
9+.github/copilot-instructions.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
10+.github/dependabot.yml yml data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
11+.github/scripts/check-no-python.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
12+.github/workflows/aien-verification.yml yml data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
13+.github/workflows/allen-reflex-kernel.yml yml data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
14+.github/workflows/copilot-setup-steps.yml yml data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
15+.github/workflows/osc-code-flip-guard.yml yml data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
16+.github/workflows/sbom.yml yml data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
17+.gitignore none data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
18+AGENTS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
19+AUDIT_SCOPE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
20+CONTEXT.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
21+CONTRIBUTING.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
22+CONTRIBUTORS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
23+Cargo.lock lock rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
24+Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
25+DRAKE-DIRECTION-SKY.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
26+LICENSE none doc-or-asset documentation, design asset, or repo pin; stays in aienux
27+NOTICE none doc-or-asset documentation, design asset, or repo pin; stays in aienux
28+PIN none doc-or-asset documentation, design asset, or repo pin; stays in aienux
29+README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
30+REPIN none data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
31+ROADMAP.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
32+SECURITY.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
33+THIRD_PARTY_NOTICES none doc-or-asset documentation, design asset, or repo pin; stays in aienux
34+crates/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
35+crates/aienos-accel/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
36+crates/aienos-accel/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
37+crates/aienos-accel/src/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
38+crates/aienos-accel/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
39+crates/aienos-accel/src/pci.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
40+crates/aienos-accel/src/profile.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
41+crates/aienos-accel/src/registers.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
42+crates/aienos-accel/tests/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
43+crates/aienos-accel/tests/gb10_fixtures.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
44+crates/aienos-aegis/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
45+crates/aienos-aegis/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
46+crates/aienos-aegis/src/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
47+crates/aienos-aegis/src/broker.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
48+crates/aienos-aegis/src/capability.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
49+crates/aienos-aegis/src/effect.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
50+crates/aienos-aegis/src/evaluator.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
51+crates/aienos-aegis/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
52+crates/aienos-aegis/src/world.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
53+crates/aienos-aegis/tests/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
54+crates/aienos-aegis/tests/phase_3_to_5_integration.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
55+crates/aienos-agent-state/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
56+crates/aienos-agent-state/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
57+crates/aienos-agent-state/src/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
58+crates/aienos-agent-state/src/abi.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
59+crates/aienos-agent-state/src/history.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
60+crates/aienos-agent-state/src/id.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
61+crates/aienos-agent-state/src/incarnation.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
62+crates/aienos-agent-state/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
63+crates/aienos-agent-state/src/lineage.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
64+crates/aienos-agent-state/src/manager.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
65+crates/aienos-anchor/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
66+crates/aienos-anchor/README.md md rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
67+crates/aienos-anchor/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
68+crates/aienos-anchor/src/tests.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
69+crates/aienos-artifact-tool/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
70+crates/aienos-artifact-tool/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
71+crates/aienos-artifact-tool/README.md md rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
72+crates/aienos-artifact-tool/fixtures/p2_5/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
73+crates/aienos-artifact-tool/fixtures/p2_5/assemble.sh sh rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
74+crates/aienos-artifact-tool/fixtures/p2_5/p25exec/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
75+crates/aienos-artifact-tool/fixtures/p2_5/p25exec/code.bin bin rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
76+crates/aienos-artifact-tool/fixtures/p2_5/p25exec/data.bin bin rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
77+crates/aienos-artifact-tool/fixtures/p2_5/p25exec/manifest.json json rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
78+crates/aienos-artifact-tool/fixtures/p2_5/p25exec/probe.S S rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
79+crates/aienos-artifact-tool/fixtures/p2_5/p25spin/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
80+crates/aienos-artifact-tool/fixtures/p2_5/p25spin/code.bin bin rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
81+crates/aienos-artifact-tool/fixtures/p2_5/p25spin/data.bin bin rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
82+crates/aienos-artifact-tool/fixtures/p2_5/p25spin/manifest.json json rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
83+crates/aienos-artifact-tool/fixtures/p2_5/p25spin/probe.S S rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
84+crates/aienos-artifact-tool/fixtures/p2_5/p25wx/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
85+crates/aienos-artifact-tool/fixtures/p2_5/p25wx/code.bin bin rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
86+crates/aienos-artifact-tool/fixtures/p2_5/p25wx/data.bin bin rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
87+crates/aienos-artifact-tool/fixtures/p2_5/p25wx/manifest.json json rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
88+crates/aienos-artifact-tool/fixtures/p2_5/p25wx/probe.S S rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
89+crates/aienos-artifact-tool/fixtures/p2_5/pack.sh sh rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
90+crates/aienos-artifact-tool/fixtures/p2_6/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
91+crates/aienos-artifact-tool/fixtures/p2_6/assemble.sh sh rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
92+crates/aienos-artifact-tool/fixtures/p2_6/p26seed/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
93+crates/aienos-artifact-tool/fixtures/p2_6/p26seed/code.bin bin rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
94+crates/aienos-artifact-tool/fixtures/p2_6/p26seed/data.bin bin rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
95+crates/aienos-artifact-tool/fixtures/p2_6/p26seed/manifest.json json rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
96+crates/aienos-artifact-tool/fixtures/p2_6/p26seed/probe.S S rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
97+crates/aienos-artifact-tool/fixtures/p2_6/pack.sh sh rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
98+crates/aienos-artifact-tool/fixtures/p2_7/assemble.sh sh rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
99+crates/aienos-artifact-tool/fixtures/p2_7/p27kread/code.bin bin rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
100+crates/aienos-artifact-tool/fixtures/p2_7/p27kread/data.bin bin rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
101+crates/aienos-artifact-tool/fixtures/p2_7/p27kread/manifest.json json rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
102+crates/aienos-artifact-tool/fixtures/p2_7/p27kread/probe.S S rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
103+crates/aienos-artifact-tool/fixtures/p2_7/p27kwrite/code.bin bin rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
104+crates/aienos-artifact-tool/fixtures/p2_7/p27kwrite/data.bin bin rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
105+crates/aienos-artifact-tool/fixtures/p2_7/p27kwrite/manifest.json json rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
106+crates/aienos-artifact-tool/fixtures/p2_7/p27kwrite/probe.S S rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
107+crates/aienos-artifact-tool/fixtures/p2_7/p27priv/code.bin bin rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
108+crates/aienos-artifact-tool/fixtures/p2_7/p27priv/data.bin bin rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
109+crates/aienos-artifact-tool/fixtures/p2_7/p27priv/manifest.json json rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
110+crates/aienos-artifact-tool/fixtures/p2_7/p27priv/probe.S S rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
111+crates/aienos-artifact-tool/fixtures/p2_7/pack.sh sh rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
112+crates/aienos-artifact-tool/src/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
113+crates/aienos-artifact-tool/src/corpus.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
114+crates/aienos-artifact-tool/src/main.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
115+crates/aienos-artifact-tool/src/receipt_cmd.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
116+crates/aienos-artifact/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
117+crates/aienos-artifact/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
118+crates/aienos-artifact/src/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
119+crates/aienos-artifact/src/canonical.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
120+crates/aienos-artifact/src/capability.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
121+crates/aienos-artifact/src/error.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
122+crates/aienos-artifact/src/format.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
123+crates/aienos-artifact/src/id.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
124+crates/aienos-artifact/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
125+crates/aienos-artifact/src/receipt.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
126+crates/aienos-artifact/src/receipt_tests.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
127+crates/aienos-artifact/src/resource.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
128+crates/aienos-artifact/src/signature.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
129+crates/aienos-artifact/src/tests.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
130+crates/aienos-artifact/src/verify.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
131+crates/aienos-boot/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
132+crates/aienos-boot/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
133+crates/aienos-boot/src/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
134+crates/aienos-boot/src/handoff.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
135+crates/aienos-boot/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
136+crates/aienos-boot/src/main.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
137+crates/aienos-boot/src/nvme_read.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
138+crates/aienos-boot/src/rollback_mock.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
139+crates/aienos-boot/src/store_qual.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
140+crates/aienos-boot/src/usb_keyboard.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
141+crates/aienos-boot/src/wcslen.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
142+crates/aienos-c1-tree/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
143+crates/aienos-c1-tree/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
144+crates/aienos-c1-tree/src/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
145+crates/aienos-c1-tree/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
146+crates/aienos-c1-tree/src/metrics.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
147+crates/aienos-c1-tree/src/page.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
148+crates/aienos-c1-tree/src/pool.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
149+crates/aienos-c1-tree/src/tree.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
150+crates/aienos-capability-ffi/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
151+crates/aienos-capability-ffi/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
152+crates/aienos-capability-ffi/src/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
153+crates/aienos-capability-ffi/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
154+crates/aienos-capability/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
155+crates/aienos-capability/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
156+crates/aienos-capability/src/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
157+crates/aienos-capability/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
158+crates/aienos-cortex/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
159+crates/aienos-cortex/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
160+crates/aienos-cortex/src/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
161+crates/aienos-cortex/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
162+crates/aienos-cortex/src/record.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
163+crates/aienos-cortex/src/status.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
164+crates/aienos-cortex/src/store.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
165+crates/aienos-cortex/src/verification.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
166+crates/aienos-crypto/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
167+crates/aienos-crypto/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
168+crates/aienos-crypto/src/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
169+crates/aienos-crypto/src/aes.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
170+crates/aienos-crypto/src/aes_gcm_siv.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
171+crates/aienos-crypto/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
172+crates/aienos-crypto/src/polyval.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
173+crates/aienos-crypto/src/sha256.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
174+crates/aienos-evidence/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
175+crates/aienos-evidence/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
176+crates/aienos-evidence/src/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
177+crates/aienos-evidence/src/canon.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
178+crates/aienos-evidence/src/capture.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
179+crates/aienos-evidence/src/http.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
180+crates/aienos-evidence/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
181+crates/aienos-evidence/src/main.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
182+crates/aienos-evidence/src/pe.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
183+crates/aienos-evidence/src/rollback.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
184+crates/aienos-evidence/src/time.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
185+crates/aienos-evidence/src/verify.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
186+crates/aienos-explain/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
187+crates/aienos-explain/docs/EXPLAIN_EVIDENCE_GRAPH_V1.md md rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
188+crates/aienos-explain/src/adapters.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
189+crates/aienos-explain/src/build.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
190+crates/aienos-explain/src/bundle.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
191+crates/aienos-explain/src/contract.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
192+crates/aienos-explain/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
193+crates/aienos-explain/src/main.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
194+crates/aienos-explain/src/render.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
195+crates/aienos-explain/src/session.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
196+crates/aienos-explain/tests/explain.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
197+crates/aienos-explain/tests/fixtures/rsi_kv_cycle.evidence.json json rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
198+crates/aienos-explain/tests/rsi_and_cli.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
199+crates/aienos-fpu-probe/Cargo.lock lock rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
200+crates/aienos-fpu-probe/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
201+crates/aienos-fpu-probe/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
202+crates/aienos-infer-kernel/Cargo.lock lock rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
203+crates/aienos-infer-kernel/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
204+crates/aienos-infer-kernel/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
205+crates/aienos-infer-kernel/src/session.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
206+crates/aienos-infer/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
207+crates/aienos-infer/examples/dot_bench.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
208+crates/aienos-infer/examples/l6_host.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
209+crates/aienos-infer/examples/model_probe.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
210+crates/aienos-infer/src/decode.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
211+crates/aienos-infer/src/dotprod.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
212+crates/aienos-infer/src/gguf.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
213+crates/aienos-infer/src/half.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
214+crates/aienos-infer/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
215+crates/aienos-infer/src/math.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
216+crates/aienos-infer/src/model.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
217+crates/aienos-infer/src/quant.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
218+crates/aienos-infer/src/tokenizer.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
219+crates/aienos-infer/tests/fixtures/PROVENANCE.md md rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
220+crates/aienos-infer/tests/fixtures/gen/Makefile none rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
221+crates/aienos-infer/tests/fixtures/gen/gen.c c rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
222+crates/aienos-infer/tests/fixtures/q4k.bin bin rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
223+crates/aienos-infer/tests/fixtures/q4k.f32 f32 rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
224+crates/aienos-infer/tests/fixtures/q6k.bin bin rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
225+crates/aienos-infer/tests/fixtures/q6k.f32 f32 rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
226+crates/aienos-infer/tests/fixtures/ref_cow.txt txt rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
227+crates/aienos-infer/tests/fixtures/ref_cow_logits0.f32 f32 rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
228+crates/aienos-infer/tests/fixtures/ref_fr.txt txt rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
229+crates/aienos-infer/tests/fixtures/ref_uni.txt txt rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
230+crates/aienos-infer/tests/forward.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
231+crates/aienos-infer/tests/golden.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
232+crates/aienos-infer/tests/ref/llama_ref.c c rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
233+crates/aienos-kernel/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
234+crates/aienos-kernel/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
235+crates/aienos-kernel/src/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
236+crates/aienos-kernel/src/abi.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
237+crates/aienos-kernel/src/acpi.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
238+crates/aienos-kernel/src/admission.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
239+crates/aienos-kernel/src/arch/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
240+crates/aienos-kernel/src/arch/aarch64.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
241+crates/aienos-kernel/src/arch/mod.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
242+crates/aienos-kernel/src/artifact_loader.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
243+crates/aienos-kernel/src/artifact_loader_tests.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
244+crates/aienos-kernel/src/block.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
245+crates/aienos-kernel/src/boot.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
246+crates/aienos-kernel/src/budget.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
247+crates/aienos-kernel/src/caps.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
248+crates/aienos-kernel/src/console.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
249+crates/aienos-kernel/src/continuity.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
250+crates/aienos-kernel/src/continuity_tests.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
251+crates/aienos-kernel/src/continuity_vectors.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
252+crates/aienos-kernel/src/crypto/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
253+crates/aienos-kernel/src/crypto/envelope.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
254+crates/aienos-kernel/src/crypto/hkdf.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
255+crates/aienos-kernel/src/crypto/hmac.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
256+crates/aienos-kernel/src/crypto/mod.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
257+crates/aienos-kernel/src/crypto/sha256.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
258+crates/aienos-kernel/src/device.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
259+crates/aienos-kernel/src/display/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
260+crates/aienos-kernel/src/display/font.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
261+crates/aienos-kernel/src/display/mod.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
262+crates/aienos-kernel/src/dma_gate.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
263+crates/aienos-kernel/src/edu.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
264+crates/aienos-kernel/src/fatal.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
265+crates/aienos-kernel/src/gic.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
266+crates/aienos-kernel/src/infer/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
267+crates/aienos-kernel/src/infer/attention.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
268+crates/aienos-kernel/src/infer/gemm.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
269+crates/aienos-kernel/src/infer/mod.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
270+crates/aienos-kernel/src/infer/rope.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
271+crates/aienos-kernel/src/infer/tokenizer.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
272+crates/aienos-kernel/src/ipc.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
273+crates/aienos-kernel/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
274+crates/aienos-kernel/src/mem/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
275+crates/aienos-kernel/src/mem/frame_allocator.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
276+crates/aienos-kernel/src/mem/map_plan.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
277+crates/aienos-kernel/src/mem/mod.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
278+crates/aienos-kernel/src/mem/pagetable.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
279+crates/aienos-kernel/src/net.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
280+crates/aienos-kernel/src/nvme.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
281+crates/aienos-kernel/src/nvme/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
282+crates/aienos-kernel/src/nvme/atomicity.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
283+crates/aienos-kernel/src/nvme/driver.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
284+crates/aienos-kernel/src/pci.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
285+crates/aienos-kernel/src/pe.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
286+crates/aienos-kernel/src/recovery.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
287+crates/aienos-kernel/src/recovery_core.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
288+crates/aienos-kernel/src/recovery_core_tests.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
289+crates/aienos-kernel/src/report.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
290+crates/aienos-kernel/src/scheduler.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
291+crates/aienos-kernel/src/security.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
292+crates/aienos-kernel/src/shell.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
293+crates/aienos-kernel/src/smmu.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
294+crates/aienos-kernel/src/store.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
295+crates/aienos-kernel/src/store/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
296+crates/aienos-kernel/src/store/checkpoint.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
297+crates/aienos-kernel/src/store/device.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
298+crates/aienos-kernel/src/store/engine.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
299+crates/aienos-kernel/src/store/genesis.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
300+crates/aienos-kernel/src/store/v1.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
301+crates/aienos-kernel/src/sync/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
302+crates/aienos-kernel/src/sync/mod.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
303+crates/aienos-kernel/src/sync/spinlock.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
304+crates/aienos-kernel/src/task_runtime.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
305+crates/aienos-kernel/src/thread.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
306+crates/aienos-kernel/src/timer.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
307+crates/aienos-kernel/src/uefi.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
308+crates/aienos-kernel/src/usb/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
309+crates/aienos-kernel/src/usb/audio.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
310+crates/aienos-kernel/src/usb/descriptor.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
311+crates/aienos-kernel/src/usb/hid.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
312+crates/aienos-kernel/src/usb/mod.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
313+crates/aienos-kernel/src/usb/xhci/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
314+crates/aienos-kernel/src/usb/xhci/context.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
315+crates/aienos-kernel/src/usb/xhci/controller.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
316+crates/aienos-kernel/src/usb/xhci/mod.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
317+crates/aienos-kernel/src/usb/xhci/ring.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
318+crates/aienos-kernel/src/usb/xhci/trb.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
319+crates/aienos-kernel/src/user.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
320+crates/aienos-kernel/src/virtio_net.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
321+crates/aienos-kernel/tests/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
322+crates/aienos-kernel/tests/nvme_completion.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
323+crates/aienos-kernel/tests/nvme_flush.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
324+crates/aienos-kernel/tests/nvme_identify.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
325+crates/aienos-kernel/tests/nvme_prp.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
326+crates/aienos-kernel/tests/nvme_write.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
327+crates/aienos-kernel/tests/nvme_write_completion.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
328+crates/aienos-kernel/tests/nvme_write_prp.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
329+crates/aienos-kernel/tests/store_v1_golden_vectors.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
330+crates/aienos-kernel/tests/store_v1_negative.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
331+crates/aienos-store-tool/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
332+crates/aienos-store-tool/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
333+crates/aienos-store-tool/src/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
334+crates/aienos-store-tool/src/main.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
335+crates/allen-courier/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
336+crates/allen-courier/code_prompt.txt txt rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
337+crates/allen-courier/scene_prompt.txt txt rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
338+crates/allen-courier/src/bin/allen-scene.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
339+crates/allen-courier/src/code.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
340+crates/allen-courier/src/local_tools.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
341+crates/allen-courier/src/main.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
342+crates/allen-design-tokens/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
343+crates/allen-design-tokens/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
344+crates/allen-design-tokens/src/main.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
345+crates/allen-design-tokens/tests/exports.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
346+crates/allen-reflex-kernel/Cargo.lock lock rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
347+crates/allen-reflex-kernel/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
348+crates/allen-reflex-kernel/examples/host_exam.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
349+crates/allen-reflex-kernel/examples/host_route.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
350+crates/allen-reflex-kernel/src/card.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
351+crates/allen-reflex-kernel/src/heap.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
352+crates/allen-reflex-kernel/src/kernel.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
353+crates/allen-reflex-kernel/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
354+crates/allen-reflex-kernel/src/pool.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
355+crates/allen-reflex-kernel/src/runner.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
356+crates/allen-reflex-kernel/tests/heap_budget.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
357+crates/allen-reflex-kernel/tests/route_card.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
358+crates/allen-reflex/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
359+crates/allen-reflex/examples/bench.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
360+crates/allen-reflex/examples/common/mod.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
361+crates/allen-reflex/examples/exam.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
362+crates/allen-reflex/examples/learn.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
363+crates/allen-reflex/examples/route_exam.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
364+crates/allen-reflex/examples/tune.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
365+crates/allen-reflex/src/action.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
366+crates/allen-reflex/src/dialog.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
367+crates/allen-reflex/src/features.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
368+crates/allen-reflex/src/hv.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
369+crates/allen-reflex/src/lexicon.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
370+crates/allen-reflex/src/lib.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
371+crates/allen-reflex/src/model.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
372+crates/allen-reflex/src/policy.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
373+crates/allen-reflex/src/route.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
374+crates/allen-reflex/src/segment.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
375+crates/allen-reflex/src/span.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
376+crates/allen-reflex/src/text.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
377+crates/allen-reflex/src/tower.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
378+crates/allen-reflex/tests/core.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
379+crates/allen-reflex/tests/route.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
380+crumb.lock lock retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
381+docs/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
382+docs/ALLEN_CANVAS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
383+docs/ALLEN_PRESENCE_RESEARCH.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
384+docs/ALLEN_SKY_SCIENCE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
385+docs/ARCHITECTURE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
386+docs/ATTENDED_SESSION_N1.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
387+docs/BLUEPRINT.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
388+docs/BOOT_EVERYWHERE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
389+docs/BOOT_HANDOFF_CONTRACT.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
390+docs/CAPABILITY_ABI.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
391+docs/CAPABILITY_AUTHORITY_RESOURCE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
392+docs/CONTINUOUS_EXISTENCE_AMENDMENT.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
393+docs/CRYPTO_CONSTANT_TIME.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
394+docs/ED25519_DEPENDENCY_REVIEW.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
395+docs/FIRST_RUN_UX.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
396+docs/GB10_DMA_ROUTE_INVENTORY.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
397+docs/GB10_FIRMWARE_INVENTORY.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
398+docs/GB10_HARDWARE_PROFILE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
399+docs/GB10_HARDWARE_QUALIFICATION.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
400+docs/GB10_IORT_DECODE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
401+docs/GB10_NATIVE_ACCELERATOR_BOUNDARY.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
402+docs/GB10_NATIVE_DEPENDENCY_MAP.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
403+docs/GB10_NATIVE_STATUS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
404+docs/GB10_PLATFORM_TOPOLOGY.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
405+docs/GB10_REGISTER_LEDGER.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
406+docs/GPU_DRIVER.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
407+docs/HARDWARE_GATES.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
408+docs/HARDWARE_TEST_RIG.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
409+docs/IMAC_AIENOS_MAP.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
410+docs/IMAC_DMAR_INVENTORY.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
411+docs/IMAC_GPU_BENCH.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
412+docs/IMAC_LOCAL_TOOLS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
413+docs/M0_NATIVE_BOOT_ROLLBACK_AUDIT.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
414+docs/M5_KEY_HIERARCHY_DESIGN_TREE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
415+docs/MILESTONES.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
416+docs/NATIVE_BOOT_ONE_TIME.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
417+docs/NATIVE_BOOT_ROLLBACK_CONTRACT.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
418+docs/NATIVE_IMAGE_SLOTS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
419+docs/NATIVE_PACKAGE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
420+docs/OWNER_KEY_CEREMONY.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
421+docs/P3_NVME_CONTROLLER_AUDIT.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
422+docs/P3_NVME_FLUSH_REVIEW.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
423+docs/P3_NVME_READ_SUBSTRATE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
424+docs/P3_NVME_UNSAFE_ASSUMPTIONS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
425+docs/P3_NVME_WRITE_DMA_REVIEW.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
426+docs/P3_NVME_WRITE_FLUSH_SUBSTRATE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
427+docs/P3_NVME_WRITE_REVIEW.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
428+docs/PHASE_3_TO_5_SPECIFICATION.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
429+docs/PI5_AIENOS_MAP.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
430+docs/PLAN_AUTHORITY.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
431+docs/RECOVERY_MEDIA_MACHINE1.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
432+docs/SEED0B_MACHINE1_QUALIFICATION.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
433+docs/SKY_FLIGHT_PLAN.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
434+docs/SOVEREIGNTY_FLAGS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
435+docs/SPARK_RTL8127.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
436+docs/SYSTEMS_INTEGRATION_SEQUENCE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
437+docs/TRUST-1-ATTENDED-PACKAGE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
438+docs/TRUST-1-ATTENDED-SEQUENCE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
439+docs/TRUST-1-GATE2-EXPERIMENTS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
440+docs/TRUST-1-IMPLEMENTATION-PLAN.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
441+docs/TRUST-1-M5-GATE-MATRIX.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
442+docs/TRUST-1-OPERATOR-STEPS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
443+docs/adr/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
444+docs/adr/0001-native-boot-milestone-and-linux-island.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
445+docs/adr/0002-incumbent-os-as-migration-environment.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
446+docs/adr/0003-bootstrap-firmware-handoff-and-minimal-object-store.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
447+docs/adr/0004-reversibility-definition-and-network-effect-boundary.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
448+docs/adr/0005-unified-memory-c1-cow-and-reservation-accounting.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
449+docs/adr/0006-deterministic-recovery-core-and-offline-operator-authority.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
450+docs/adr/0007-continuous-existence-provisioning-once.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
451+docs/adr/0008-temporary-bring-up-firmware-report-exception.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
452+docs/adr/0009-el2-bootstrap-to-el1h-kernel-transition.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
453+docs/adr/0010-fabric-machine-identity-and-capability-advertisement.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
454+docs/adr/0011-machine-1-hardware-test-rig.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
455+docs/adr/0012-self-construction-capability-growth-and-generations.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
456+docs/adr/0013-aienos-abi-v1.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
457+docs/adr/0014-binary-artifact-v0-and-native-admission.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
458+docs/adr/0015-golden-vectors.json json data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
459+docs/adr/0015-golden-vectors.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
460+docs/adr/0015-system-store-v1-format.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
461+docs/adr/0016-continuity-objects-over-store-v1.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
462+docs/adr/0017-m5-key-hierarchy-and-encrypted-store.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
463+docs/adr/0018-allen-subject-state-object.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
464+docs/adr/0019-per-resource-capability-generation.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
465+docs/adr/0020-pi5-software-only-dma-confinement.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
466+docs/adr/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
467+docs/campaigns/B7B-PHYSICAL-BOOT-PREP.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
468+docs/campaigns/SPARK-BOOT-INPUT-20261028.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
469+docs/crumbs/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
470+docs/crumbs/BACKFILL.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
471+docs/design/CRITIQUE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
472+docs/design/DESIGN.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
473+docs/design/DOGFOOD-2026-10-20.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
474+docs/design/boot/MATHS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
475+docs/design/boot/night.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
476+docs/design/boot/receipts/frame-times-1280x720.json json data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
477+docs/design/boot/receipts/frame-times-1920x1080.json json data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
478+docs/design/boot/receipts/frame-times.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
479+docs/design/screens/01-power-on.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
480+docs/design/screens/02-night.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
481+docs/design/screens/03-allen-arrives.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
482+docs/design/screens/03b-still-starting.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
483+docs/design/screens/04-intent.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
484+docs/design/screens/04b-something-else.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
485+docs/design/screens/05-getting-to-know.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
486+docs/design/screens/05b-what-allen-found.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
487+docs/design/screens/06-consent.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
488+docs/design/screens/06b-show-each.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
489+docs/design/screens/07a-games.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
490+docs/design/screens/07b-ai-fit.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
491+docs/design/screens/07c-connect.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
492+docs/design/screens/07c-key-failed.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
493+docs/design/screens/07c-key.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
494+docs/design/screens/07c-none.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
495+docs/design/screens/07c-one-found.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
496+docs/design/screens/07c-several.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
497+docs/design/screens/08-hardware.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
498+docs/design/screens/08b-turn-on.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
499+docs/design/screens/08c-put-back.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
500+docs/design/screens/09-ready.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
501+docs/design/screens/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
502+docs/design/screens/allen-font.js js script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
503+docs/design/screens/assets/allen-formed.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
504+docs/design/screens/assets/night-11800.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
505+docs/design/screens/assets/night-14000.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
506+docs/design/screens/assets/night-4000.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
507+docs/design/screens/assets/night-9000.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
508+docs/design/screens/assets/night-settled.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
509+docs/design/screens/index.html html doc-or-asset documentation, design asset, or repo pin; stays in aienux
510+docs/design/screens/screen.js js script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
511+docs/design/screens/screens.css css doc-or-asset documentation, design asset, or repo pin; stays in aienux
512+docs/design/screens/shots/01-power-on.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
513+docs/design/screens/shots/02-night.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
514+docs/design/screens/shots/03-allen-arrives.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
515+docs/design/screens/shots/03b-still-starting.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
516+docs/design/screens/shots/04-intent.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
517+docs/design/screens/shots/04b-something-else.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
518+docs/design/screens/shots/05-getting-to-know.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
519+docs/design/screens/shots/05b-what-allen-found.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
520+docs/design/screens/shots/06-consent.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
521+docs/design/screens/shots/06b-show-each.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
522+docs/design/screens/shots/07a-games.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
523+docs/design/screens/shots/07b-ai-fit.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
524+docs/design/screens/shots/07c-connect.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
525+docs/design/screens/shots/07c-key-failed.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
526+docs/design/screens/shots/07c-key.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
527+docs/design/screens/shots/07c-none.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
528+docs/design/screens/shots/07c-one-found.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
529+docs/design/screens/shots/07c-several.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
530+docs/design/screens/shots/08-hardware.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
531+docs/design/screens/shots/08b-turn-on.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
532+docs/design/screens/shots/08c-put-back.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
533+docs/design/screens/shots/09-ready.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
534+docs/design/screens/shots/all-2560x1440.jpg jpg doc-or-asset documentation, design asset, or repo pin; stays in aienux
535+docs/design/tokens/allen-tokens.css css doc-or-asset documentation, design asset, or repo pin; stays in aienux
536+docs/design/tokens/allen_tokens.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
537+docs/design/tokens/allen_tokens.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
538+docs/design/tokens/contrast.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
539+docs/design/tools/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
540+docs/design/tools/dogfood-wizard.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
541+docs/design/tools/extract-font.mjs mjs data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
542+docs/design/tools/make-found.mjs mjs data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
543+docs/design/tools/make-screens.mjs mjs data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
544+docs/design/tools/shoot.mjs mjs data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
545+docs/hardware-gates-needs.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
546+docs/hardware-gates.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
547+docs/native/PI5-4-UNLOCK-RUNS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
548+docs/native/PI5-5-CORTEX-RUNS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
549+docs/native/PI5-6-AGENT-RUNS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
550+docs/native/PI5-6-INFER-RUNS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
551+docs/native/PI5-7-ARTIFACT-RUNS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
552+docs/native/PI5-7-LIFECYCLE-RUNS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
553+docs/native/PI5-8-ALLEN-REFLEX.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
554+docs/native/PI5-8-MODEL-CHOICE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
555+docs/native/PI5-8-ORCHESTRATOR-EXAM.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
556+docs/native/PI5-8-OWNER-CEREMONY.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
557+docs/native/PI5-8-QUALIFICATION.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
558+docs/native/PI5-NET-2-RUNS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
559+docs/native/PI5-NET-3-RUNS.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
560+docs/native/PREFLIGHT-AND-RECOVERY.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
561+docs/native/pi5-8/measure-ids.patch patch data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
562+docs/native/pi5-8/orchestrator-exam/FREEZE-COMMIT.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
563+docs/native/pi5-8/orchestrator-exam/FREEZE.sha256 sha256 data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
564+docs/native/pi5-8/orchestrator-exam/build_jsonl.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
565+docs/native/pi5-8/orchestrator-exam/by_category.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
566+docs/native/pi5-8/orchestrator-exam/cases-dev.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
567+docs/native/pi5-8/orchestrator-exam/cases-dev.psv psv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
568+docs/native/pi5-8/orchestrator-exam/cases-heldout.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
569+docs/native/pi5-8/orchestrator-exam/cases-heldout.psv psv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
570+docs/native/pi5-8/orchestrator-exam/cases-pool.psv psv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
571+docs/native/pi5-8/orchestrator-exam/cases-reflex-extra.psv psv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
572+docs/native/pi5-8/orchestrator-exam/cases-train.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
573+docs/native/pi5-8/orchestrator-exam/cases-train.psv psv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
574+docs/native/pi5-8/orchestrator-exam/download_models.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
575+docs/native/pi5-8/orchestrator-exam/grammar.gbnf gbnf data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
576+docs/native/pi5-8/orchestrator-exam/make_tables.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
577+docs/native/pi5-8/orchestrator-exam/models.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
578+docs/native/pi5-8/orchestrator-exam/pi_estimate.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
579+docs/native/pi5-8/orchestrator-exam/reflex_tables.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
580+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.dev.nearest.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
581+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.dev.nearest.why.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
582+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.dev.perceptron.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
583+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.dev.perceptron.why.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
584+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.dev.reflex.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
585+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.dev.reflex.why.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
586+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.heldout.nearest.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
587+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.heldout.nearest.why.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
588+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.heldout.perceptron.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
589+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.heldout.perceptron.why.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
590+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.heldout.reflex.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
591+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.heldout.reflex.why.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
592+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.train.nearest.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
593+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.train.nearest.why.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
594+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.train.perceptron.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
595+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.train.perceptron.why.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
596+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.train.reflex.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
597+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.train.reflex.why.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
598+docs/native/pi5-8/orchestrator-exam/results/allen-reflex.tune.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
599+docs/native/pi5-8/orchestrator-exam/results/danube3-500m.dev.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
600+docs/native/pi5-8/orchestrator-exam/results/danube3-500m.dev.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
601+docs/native/pi5-8/orchestrator-exam/results/danube3-500m.heldout.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
602+docs/native/pi5-8/orchestrator-exam/results/danube3-500m.heldout.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
603+docs/native/pi5-8/orchestrator-exam/results/danube3-500m.train.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
604+docs/native/pi5-8/orchestrator-exam/results/danube3-500m.train.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
605+docs/native/pi5-8/orchestrator-exam/results/downloads.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
606+docs/native/pi5-8/orchestrator-exam/results/emb.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
607+docs/native/pi5-8/orchestrator-exam/results/granite3.3-2b.dev.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
608+docs/native/pi5-8/orchestrator-exam/results/granite3.3-2b.dev.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
609+docs/native/pi5-8/orchestrator-exam/results/granite3.3-2b.heldout.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
610+docs/native/pi5-8/orchestrator-exam/results/granite3.3-2b.heldout.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
611+docs/native/pi5-8/orchestrator-exam/results/granite3.3-2b.train.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
612+docs/native/pi5-8/orchestrator-exam/results/granite3.3-2b.train.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
613+docs/native/pi5-8/orchestrator-exam/results/granite4-1b.dev.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
614+docs/native/pi5-8/orchestrator-exam/results/granite4-1b.dev.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
615+docs/native/pi5-8/orchestrator-exam/results/granite4-1b.heldout.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
616+docs/native/pi5-8/orchestrator-exam/results/granite4-1b.heldout.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
617+docs/native/pi5-8/orchestrator-exam/results/granite4-1b.train.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
618+docs/native/pi5-8/orchestrator-exam/results/granite4-1b.train.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
619+docs/native/pi5-8/orchestrator-exam/results/granite4-350m.dev.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
620+docs/native/pi5-8/orchestrator-exam/results/granite4-350m.dev.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
621+docs/native/pi5-8/orchestrator-exam/results/granite4-350m.heldout.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
622+docs/native/pi5-8/orchestrator-exam/results/granite4-350m.heldout.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
623+docs/native/pi5-8/orchestrator-exam/results/granite4-350m.train.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
624+docs/native/pi5-8/orchestrator-exam/results/granite4-350m.train.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
625+docs/native/pi5-8/orchestrator-exam/results/granite4-h-350m.dev.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
626+docs/native/pi5-8/orchestrator-exam/results/granite4-h-350m.dev.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
627+docs/native/pi5-8/orchestrator-exam/results/granite4-h-350m.heldout.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
628+docs/native/pi5-8/orchestrator-exam/results/granite4-h-350m.heldout.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
629+docs/native/pi5-8/orchestrator-exam/results/granite4-h-350m.train.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
630+docs/native/pi5-8/orchestrator-exam/results/granite4-h-350m.train.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
631+docs/native/pi5-8/orchestrator-exam/results/llama3.2-1b.dev.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
632+docs/native/pi5-8/orchestrator-exam/results/llama3.2-1b.dev.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
633+docs/native/pi5-8/orchestrator-exam/results/llama3.2-1b.heldout.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
634+docs/native/pi5-8/orchestrator-exam/results/llama3.2-1b.heldout.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
635+docs/native/pi5-8/orchestrator-exam/results/llama3.2-1b.train.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
636+docs/native/pi5-8/orchestrator-exam/results/llama3.2-1b.train.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
637+docs/native/pi5-8/orchestrator-exam/results/qwen2.5-0.5b.dev.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
638+docs/native/pi5-8/orchestrator-exam/results/qwen2.5-0.5b.dev.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
639+docs/native/pi5-8/orchestrator-exam/results/qwen2.5-0.5b.heldout.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
640+docs/native/pi5-8/orchestrator-exam/results/qwen2.5-0.5b.heldout.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
641+docs/native/pi5-8/orchestrator-exam/results/qwen2.5-0.5b.train.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
642+docs/native/pi5-8/orchestrator-exam/results/qwen2.5-0.5b.train.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
643+docs/native/pi5-8/orchestrator-exam/results/qwen2.5-1.5b.dev.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
644+docs/native/pi5-8/orchestrator-exam/results/qwen2.5-1.5b.dev.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
645+docs/native/pi5-8/orchestrator-exam/results/qwen2.5-1.5b.heldout.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
646+docs/native/pi5-8/orchestrator-exam/results/qwen2.5-1.5b.heldout.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
647+docs/native/pi5-8/orchestrator-exam/results/qwen2.5-1.5b.train.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
648+docs/native/pi5-8/orchestrator-exam/results/qwen2.5-1.5b.train.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
649+docs/native/pi5-8/orchestrator-exam/results/qwen3-0.6b.dev.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
650+docs/native/pi5-8/orchestrator-exam/results/qwen3-0.6b.dev.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
651+docs/native/pi5-8/orchestrator-exam/results/qwen3-0.6b.heldout.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
652+docs/native/pi5-8/orchestrator-exam/results/qwen3-0.6b.heldout.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
653+docs/native/pi5-8/orchestrator-exam/results/qwen3-0.6b.train.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
654+docs/native/pi5-8/orchestrator-exam/results/qwen3-0.6b.train.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
655+docs/native/pi5-8/orchestrator-exam/results/qwen3-1.7b.dev.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
656+docs/native/pi5-8/orchestrator-exam/results/qwen3-1.7b.dev.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
657+docs/native/pi5-8/orchestrator-exam/results/qwen3-1.7b.heldout.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
658+docs/native/pi5-8/orchestrator-exam/results/qwen3-1.7b.heldout.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
659+docs/native/pi5-8/orchestrator-exam/results/qwen3-1.7b.train.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
660+docs/native/pi5-8/orchestrator-exam/results/qwen3-1.7b.train.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
661+docs/native/pi5-8/orchestrator-exam/results/smollm2-1.7b.dev.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
662+docs/native/pi5-8/orchestrator-exam/results/smollm2-1.7b.dev.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
663+docs/native/pi5-8/orchestrator-exam/results/smollm2-1.7b.heldout.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
664+docs/native/pi5-8/orchestrator-exam/results/smollm2-1.7b.heldout.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
665+docs/native/pi5-8/orchestrator-exam/results/smollm2-1.7b.train.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
666+docs/native/pi5-8/orchestrator-exam/results/smollm2-1.7b.train.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
667+docs/native/pi5-8/orchestrator-exam/results/smollm2-360m.dev.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
668+docs/native/pi5-8/orchestrator-exam/results/smollm2-360m.dev.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
669+docs/native/pi5-8/orchestrator-exam/results/smollm2-360m.heldout.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
670+docs/native/pi5-8/orchestrator-exam/results/smollm2-360m.heldout.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
671+docs/native/pi5-8/orchestrator-exam/results/smollm2-360m.train.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
672+docs/native/pi5-8/orchestrator-exam/results/smollm2-360m.train.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
673+docs/native/pi5-8/orchestrator-exam/results/summary.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
674+docs/native/pi5-8/orchestrator-exam/results/tinyllama-1.1b.dev.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
675+docs/native/pi5-8/orchestrator-exam/results/tinyllama-1.1b.dev.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
676+docs/native/pi5-8/orchestrator-exam/results/tinyllama-1.1b.heldout.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
677+docs/native/pi5-8/orchestrator-exam/results/tinyllama-1.1b.heldout.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
678+docs/native/pi5-8/orchestrator-exam/results/tinyllama-1.1b.train.constrained.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
679+docs/native/pi5-8/orchestrator-exam/results/tinyllama-1.1b.train.free.jsonl jsonl data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
680+docs/native/pi5-8/orchestrator-exam/results/tokens.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
681+docs/native/pi5-8/orchestrator-exam/run_all.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
682+docs/native/pi5-8/orchestrator-exam/run_exam.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
683+docs/native/pi5-8/orchestrator-exam/score.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
684+docs/native/pi5-8/orchestrator-exam/split_pool.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
685+docs/native/pi5-8/orchestrator-exam/summarize.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
686+docs/native/pi5-8/orchestrator-exam/system_prompt.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
687+docs/native/pi5-8/pi-kernel-log-lines.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
688+docs/native/pi5-8/route/FREEZE.sha256 sha256 data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
689+docs/native/pi5-8/route/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
690+docs/native/pi5-8/route/results/pi-route-399b.card card data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
691+docs/native/pi5-8/route/results/pi-route-399b.fresh.req req data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
692+docs/native/pi5-8/route/results/pi-route-399b.host-lines.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
693+docs/native/pi5-8/route/results/pi-route-399b.kernel.log log data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
694+docs/native/pi5-8/route/results/pi-route-399b.run.log log data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
695+docs/native/pi5-8/route/results/qemu-twin.log log data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
696+docs/native/pi5-8/route/results/route-dev-frozen.log log data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
697+docs/native/pi5-8/route/results/route-green1.log log data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
698+docs/native/pi5-8/route/results/route-heldout-host.log log data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
699+docs/native/pi5-8/route/results/route-mutants.log log data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
700+docs/native/pi5-8/route/results/route-red.log log data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
701+docs/native/pi5-8/route/results/route-val.log log data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
702+docs/native/pi5-8/route/route-dev.psv psv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
703+docs/native/pi5-8/route/route-heldout.psv psv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
704+docs/native/pi5-8/route/route-val.psv psv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
705+docs/osc-launch.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
706+docs/osc-receipts.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
707+docs/qualification/INT8-ACTIVATION-QUAL-v1.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
708+docs/superpowers/plans/2026-10-23-allen-omega-implementation.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
709+docs/superpowers/plans/2026-10-23-allen-portable-build.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
710+docs/superpowers/specs/2026-10-23-allen-omega-design.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
711+docs/superpowers/specs/2026-10-23-allen-omega-platform-gates.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
712+funding.json json data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
713+native/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
714+native/argus/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
715+native/argus/Makefile none c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
716+native/argus/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
717+native/argus/argus_abi.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
718+native/argus/argus_contain.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
719+native/argus/argus_contain.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
720+native/argus/argus_core.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
721+native/argus/argus_core.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
722+native/argus/argus_detect.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
723+native/argus/argus_detect.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
724+native/argus/argus_event.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
725+native/argus/argus_ring.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
726+native/argus/bridge/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
727+native/argus/bridge/argus_aegis_bridge.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
728+native/argus/bridge/argus_aegis_bridge.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
729+native/argus/docs/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
730+native/argus/docs/ARGUS0_GATES.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
731+native/argus/docs/ARGUS1_GATES.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
732+native/argus/docs/ARGUS1_PLAN.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
733+native/argus/docs/ARGUS1_SPEC.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
734+native/argus/docs/HOSTILE_REVIEW.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
735+native/argus/lane_b.mk mk data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
736+native/argus/lane_d.mk mk data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
737+native/argus/lane_e.mk mk data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
738+native/argus/sha256.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
739+native/argus/sha256.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
740+native/argus/tests/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
741+native/argus/tests/bench_argus_contain.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
742+native/argus/tests/bench_argus_ring.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
743+native/argus/tests/check_argus1_symbols.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
744+native/argus/tests/fixtures/argus1/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
745+native/argus/tests/fixtures/argus1/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
746+native/argus/tests/fixtures/argus1/r7-v11.bin bin data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
747+native/argus/tests/fixtures/argus1/r8-v11.bin bin data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
748+native/argus/tests/fixtures/argus1/r9-v11.bin bin data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
749+native/argus/tests/fuzz_argus_event.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
750+native/argus/tests/run_argus1_bench.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
751+native/argus/tests/stub_lanes_d.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
752+native/argus/tests/stub_lanes_d.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
753+native/argus/tests/stub_state.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
754+native/argus/tests/stub_state.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
755+native/argus/tests/test_argus_contain.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
756+native/argus/tests/test_argus_contain_hostile.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
757+native/argus/tests/test_argus_containment_e2e.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
758+native/argus/tests/test_argus_core.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
759+native/argus/tests/test_argus_detect.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
760+native/argus/tests/test_argus_determinism.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
761+native/argus/tests/test_argus_event.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
762+native/argus/tests/test_argus_hostile.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
763+native/argus/tests/test_argus_integration.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
764+native/argus/tests/test_argus_ring.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
765+native/argus/tests/test_common_d.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
766+native/boot/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
767+native/boot/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
768+native/boot/diag.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
769+native/boot/diag_main.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
770+native/boot/diag_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
771+native/boot/efi.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
772+native/boot/efi_agentcmd.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
773+native/boot/efi_allen.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
774+native/boot/efi_artifact.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
775+native/boot/efi_entry.S S c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
776+native/boot/efi_entry_x86_64.S S c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
777+native/boot/efi_fact.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
778+native/boot/efi_gop.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
779+native/boot/efi_klog.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
780+native/boot/efi_main.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
781+native/boot/efi_model.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
782+native/boot/efi_unlock.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
783+native/boot/handoff.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
784+native/boot/image.ld ld data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
785+native/boot/image_x86_64.ld ld data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
786+native/boot/model_map.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
787+native/boot/net_loader.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
788+native/boot/netboot_proto.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
789+native/boot/netboot_proto.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
790+native/boot/slot_control.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
791+native/boot/slot_control.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
792+native/boot/slot_format.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
793+native/boot/slot_loader.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
794+native/boot/slot_select.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
795+native/boot/slot_update.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
796+native/boot/slot_update.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
797+native/capability/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
798+native/capability/.gitignore none data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
799+native/capability/Makefile none c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
800+native/capability/aienos_capability.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
801+native/capability/aienos_capability.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
802+native/capability/aienos_contain.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
803+native/capability/aienos_contain.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
804+native/capability/tests/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
805+native/capability/tests/capability_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
806+native/capability/tests/contain_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
807+native/crypto/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
808+native/crypto/Makefile none c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
809+native/crypto/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
810+native/crypto/aes.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
811+native/crypto/aienos_crypto.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
812+native/crypto/crypto_internal.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
813+native/crypto/ct.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
814+native/crypto/gcm_siv.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
815+native/crypto/hmac.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
816+native/crypto/polyval.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
817+native/crypto/tests/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
818+native/crypto/tests/crypto_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
819+native/disk/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
820+native/disk/.gitignore none data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
821+native/disk/Makefile none c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
822+native/disk/OMEGA_NVME_READ.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
823+native/disk/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
824+native/disk/disk.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
825+native/disk/disk.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
826+native/disk/disk_file.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
827+native/disk/disk_file.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
828+native/disk/disk_nvme.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
829+native/disk/disk_nvme.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
830+native/disk/disk_sdhci.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
831+native/disk/disk_sdhci.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
832+native/disk/qemu/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
833+native/disk/qemu/.gitignore none data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
834+native/disk/qemu/Makefile none c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
835+native/disk/qemu/payload.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
836+native/disk/qemu/payload.ld ld data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
837+native/disk/qemu/sdhci_payload.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
838+native/disk/qemu/start.S S c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
839+native/disk/tests/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
840+native/disk/tests/disk_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
841+native/disk/tests/nvme_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
842+native/disk/tests/omega_nvme_receipt.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
843+native/disk/tests/omega_nvme_reuse_search.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
844+native/disk/tests/omega_nvme_runner.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
845+native/disk/tests/omega_nvme_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
846+native/disk/tests/sdhci_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
847+native/kernel/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
848+native/kernel/CONTINUITY_RECOVERY_CONTRACT.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
849+native/kernel/GATES.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
850+native/kernel/Makefile none c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
851+native/kernel/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
852+native/kernel/WALKTHROUGH.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
853+native/kernel/arch/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
854+native/kernel/arch/arch.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
855+native/kernel/arch/exception.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
856+native/kernel/arch/gic.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
857+native/kernel/arch/m3.S S c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
858+native/kernel/arch/rndr.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
859+native/kernel/arch/smp_entry.S S c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
860+native/kernel/arch/timer.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
861+native/kernel/arch/vectors.S S c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
862+native/kernel/artifact/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
863+native/kernel/artifact/admission.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
864+native/kernel/artifact/ck_artifact.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
865+native/kernel/artifact/format.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
866+native/kernel/artifact/osc_launch.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
867+native/kernel/artifact/osc_launch.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
868+native/kernel/artifact/osc_receipt.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
869+native/kernel/artifact/osc_receipt.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
870+native/kernel/artifact/osc_receipt_anchor.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
871+native/kernel/artifact/osc_receipt_test_anchor.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
872+native/kernel/artifact/osc_unit.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
873+native/kernel/artifact/osc_unit.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
874+native/kernel/artifact/osc_unit_test_anchor.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
875+native/kernel/artifact/receipt.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
876+native/kernel/core/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
877+native/kernel/core/acpi.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
878+native/kernel/core/acpi.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
879+native/kernel/core/acpi_dev.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
880+native/kernel/core/acpi_dev.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
881+native/kernel/core/acpi_platform.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
882+native/kernel/core/agent_cmd.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
883+native/kernel/core/agent_cmd.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
884+native/kernel/core/allen.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
885+native/kernel/core/allen.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
886+native/kernel/core/allen_gate.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
887+native/kernel/core/allen_gate.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
888+native/kernel/core/artifact_card.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
889+native/kernel/core/artifact_card.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
890+native/kernel/core/artifact_card_stage.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
891+native/kernel/core/artifact_loader.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
892+native/kernel/core/boot_screen.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
893+native/kernel/core/boot_screen.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
894+native/kernel/core/ck_internal.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
895+native/kernel/core/console.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
896+native/kernel/core/context.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
897+native/kernel/core/context.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
898+native/kernel/core/context_proposal.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
899+native/kernel/core/context_proposal.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
900+native/kernel/core/cpufeat.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
901+native/kernel/core/cpufeat.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
902+native/kernel/core/dmar.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
903+native/kernel/core/dmar.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
904+native/kernel/core/entropy.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
905+native/kernel/core/entropy.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
906+native/kernel/core/fact_req.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
907+native/kernel/core/fact_req.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
908+native/kernel/core/fbcon.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
909+native/kernel/core/fbcon.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
910+native/kernel/core/fmt.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
911+native/kernel/core/fmt.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
912+native/kernel/core/font8x8.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
913+native/kernel/core/fpu.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
914+native/kernel/core/handoff_check.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
915+native/kernel/core/handoff_check.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
916+native/kernel/core/infer.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
917+native/kernel/core/ipc.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
918+native/kernel/core/ipc.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
919+native/kernel/core/klog.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
920+native/kernel/core/klog.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
921+native/kernel/core/klog_boot.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
922+native/kernel/core/klog_slot.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
923+native/kernel/core/klog_slot.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
924+native/kernel/core/kmain.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
925+native/kernel/core/libc_min.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
926+native/kernel/core/lifecycle.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
927+native/kernel/core/lifecycle_fsm.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
928+native/kernel/core/lifecycle_fsm.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
929+native/kernel/core/line_rx.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
930+native/kernel/core/line_rx.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
931+native/kernel/core/m3.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
932+native/kernel/core/osc_admit.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
933+native/kernel/core/osc_admit.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
934+native/kernel/core/osc_task.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
935+native/kernel/core/osc_task.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
936+native/kernel/core/osh_err.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
937+native/kernel/core/osh_fixtures.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
938+native/kernel/core/osh_op.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
939+native/kernel/core/osh_op.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
940+native/kernel/core/osh_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
941+native/kernel/core/pi5.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
942+native/kernel/core/pi5_marker.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
943+native/kernel/core/pi5_marker.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
944+native/kernel/core/pipe.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
945+native/kernel/core/pipe.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
946+native/kernel/core/pipe_drive.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
947+native/kernel/core/pipe_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
948+native/kernel/core/reply_obj.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
949+native/kernel/core/report.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
950+native/kernel/core/sched.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
951+native/kernel/core/sched.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
952+native/kernel/core/smmu.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
953+native/kernel/core/smmu.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
954+native/kernel/core/smmu_svc.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
955+native/kernel/core/smp.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
956+native/kernel/core/spinlock.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
957+native/kernel/core/uart_rx.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
958+native/kernel/core/unlock_req.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
959+native/kernel/core/unlock_req.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
960+native/kernel/dev/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
961+native/kernel/dev/devices.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
962+native/kernel/dev/devices.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
963+native/kernel/dev/disk_layout.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
964+native/kernel/dev/disk_part.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
965+native/kernel/dev/disk_part.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
966+native/kernel/dev/dma_window.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
967+native/kernel/dev/dma_window.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
968+native/kernel/dev/fat_boot.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
969+native/kernel/dev/fat_boot.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
970+native/kernel/dev/gb10_gsp_boot.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
971+native/kernel/dev/gb10_gsp_boot.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
972+native/kernel/dev/gpt_add.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
973+native/kernel/dev/gpt_add.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
974+native/kernel/dev/mmio_window.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
975+native/kernel/dev/mmio_window.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
976+native/kernel/dev/net_bind.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
977+native/kernel/dev/net_bind.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
978+native/kernel/dev/net_udp.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
979+native/kernel/dev/net_udp.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
980+native/kernel/dev/nvme_bind.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
981+native/kernel/dev/nvme_bind.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
982+native/kernel/dev/nvme_shutdown.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
983+native/kernel/dev/nvme_shutdown.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
984+native/kernel/dev/pci.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
985+native/kernel/dev/pci.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
986+native/kernel/dev/pi5_gem.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
987+native/kernel/dev/pi5_gem.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
988+native/kernel/dev/pi5_net.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
989+native/kernel/dev/pi5_net.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
990+native/kernel/dev/pi5_pcie.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
991+native/kernel/dev/pi5_pcie.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
992+native/kernel/dev/pi5_rng.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
993+native/kernel/dev/pi5_rng.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
994+native/kernel/dev/pi5_wdt.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
995+native/kernel/dev/pi5_wdt.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
996+native/kernel/dev/rtl8127_bind.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
997+native/kernel/dev/rtl8127_bind.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
998+native/kernel/dev/tests/disk_part_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
999+native/kernel/dev/tests/fat_boot_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1000+native/kernel/dev/tests/pi5_agent_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1001+native/kernel/dev/tests/pi5_fact_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1002+native/kernel/dev/tests/pi5_store_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1003+native/kernel/dev/tests/pi5_unlock_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1004+native/kernel/dev/tests/usb_audio_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1005+native/kernel/dev/tests/virtio_av_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1006+native/kernel/dev/usb_audio.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1007+native/kernel/dev/usb_audio.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1008+native/kernel/dev/usb_hid.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1009+native/kernel/dev/usb_hid.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1010+native/kernel/dev/usb_kbd.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1011+native/kernel/dev/usb_kbd.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1012+native/kernel/dev/virtio_bind.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1013+native/kernel/dev/virtio_bind.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1014+native/kernel/dev/virtio_gpu.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1015+native/kernel/dev/virtio_gpu.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1016+native/kernel/dev/virtio_net.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1017+native/kernel/dev/virtio_net.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1018+native/kernel/dev/virtio_q.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1019+native/kernel/dev/virtio_q.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1020+native/kernel/dev/virtio_snd.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1021+native/kernel/dev/virtio_snd.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1022+native/kernel/dev/xhci_acpi_fmt.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1023+native/kernel/dev/xhci_fence.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1024+native/kernel/dev/xhci_fence.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1025+native/kernel/gpu/amd_compute.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1026+native/kernel/gpu/amd_display.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1027+native/kernel/gpu/amd_gpu.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1028+native/kernel/gpu/amd_gpu_regs.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1029+native/kernel/gpu/amd_host_shim.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1030+native/kernel/gpu/amd_mc.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1031+native/kernel/gpu/amd_ring.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1032+native/kernel/gpu/amd_sdma.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1033+native/kernel/gpu/amd_smu.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1034+native/kernel/gpu/amd_ucode.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1035+native/kernel/gpu/contract/gb10_chan.devc devc data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1036+native/kernel/gpu/contract/gb10_gsp.devc devc data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1037+native/kernel/gpu/contract/gen/gb10_gpu_channel.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1038+native/kernel/gpu/contract/gen/gb10_gsp_boot.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1039+native/kernel/gpu/contract/gen/gch_contract.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1040+native/kernel/gpu/contract/gen/gsb_contract.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1041+native/kernel/gpu/gmmu.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1042+native/kernel/gpu/gmmu.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1043+native/kernel/gpu/gpu_chan.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1044+native/kernel/gpu/gpu_chan.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1045+native/kernel/gpu/gpu_mem.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1046+native/kernel/gpu/gpu_mem.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1047+native/kernel/gpu/gpu_sim.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1048+native/kernel/gpu/gpu_sim.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1049+native/kernel/gpu/gpu_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1050+native/kernel/gpu/gsp_mmio.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1051+native/kernel/gpu/gsp_mmio.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1052+native/kernel/gpu/gsp_seq.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1053+native/kernel/gpu/gsp_seq.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1054+native/kernel/gpu/gsp_sim.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1055+native/kernel/gpu/gsp_sim.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1056+native/kernel/include/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1057+native/kernel/include/ck.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1058+native/kernel/mm/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1059+native/kernel/mm/frames.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1060+native/kernel/mm/frames.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1061+native/kernel/mm/heap.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1062+native/kernel/mm/heap.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1063+native/kernel/mm/mmu.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1064+native/kernel/mm/pt.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1065+native/kernel/mm/pt.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1066+native/kernel/proofs/TicketLock.lean lean data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1067+native/kernel/proofs/lean-toolchain none data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1068+native/kernel/stage.mk mk data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1069+native/kernel/svc/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1070+native/kernel/svc/allen_code.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1071+native/kernel/svc/allen_code.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1072+native/kernel/svc/allen_intent.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1073+native/kernel/svc/allen_intent.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1074+native/kernel/svc/allen_memory.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1075+native/kernel/svc/allen_memory.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1076+native/kernel/svc/allen_notes.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1077+native/kernel/svc/allen_notes.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1078+native/kernel/svc/allen_reply.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1079+native/kernel/svc/allen_reply.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1080+native/kernel/svc/allen_scene.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1081+native/kernel/svc/allen_scene.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1082+native/kernel/svc/artifact_store.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1083+native/kernel/svc/artifact_store.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1084+native/kernel/svc/ck_compat.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1085+native/kernel/svc/ck_compat.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1086+native/kernel/svc/compat/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1087+native/kernel/svc/compat/README none data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1088+native/kernel/svc/compat/pthread.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1089+native/kernel/svc/compat/stdio.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1090+native/kernel/svc/compat/stdlib.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1091+native/kernel/svc/compat/string.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1092+native/kernel/svc/compat/time.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1093+native/kernel/svc/continuity_boot.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1094+native/kernel/svc/continuity_boot.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1095+native/kernel/svc/continuity_codec.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1096+native/kernel/svc/continuity_codec.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1097+native/kernel/svc/continuity_commit.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1098+native/kernel/svc/continuity_commit.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1099+native/kernel/svc/continuity_recovery.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1100+native/kernel/svc/continuity_recovery.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1101+native/kernel/svc/continuity_resolve.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1102+native/kernel/svc/continuity_resolve.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1103+native/kernel/svc/continuity_resolve_sealed.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1104+native/kernel/svc/continuity_resolve_sealed.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1105+native/kernel/svc/continuity_service.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1106+native/kernel/svc/continuity_service.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1107+native/kernel/svc/continuity_subject.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1108+native/kernel/svc/continuity_subject.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1109+native/kernel/svc/continuity_subject_provision.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1110+native/kernel/svc/continuity_subject_provision.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1111+native/kernel/svc/cortex_config.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1112+native/kernel/svc/cortex_journal.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1113+native/kernel/svc/cortex_journal.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1114+native/kernel/svc/cortex_store.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1115+native/kernel/svc/courier.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1116+native/kernel/svc/pi5_agent.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1117+native/kernel/svc/pi5_agent.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1118+native/kernel/svc/pi5_fact.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1119+native/kernel/svc/pi5_fact.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1120+native/kernel/svc/security.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1121+native/kernel/svc/security.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1122+native/kernel/svc/setup_inv.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1123+native/kernel/svc/setup_inv.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1124+native/kernel/svc/setup_store.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1125+native/kernel/svc/setup_store.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1126+native/kernel/svc/setup_wizard.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1127+native/kernel/svc/setup_wizard.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1128+native/kernel/svc/slot_service.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1129+native/kernel/svc/slot_service.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1130+native/kernel/svc/slot_service_pi5.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1131+native/kernel/svc/store_boot.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1132+native/kernel/svc/store_boot.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1133+native/kernel/svc/store_crash.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1134+native/kernel/svc/store_crash.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1135+native/kernel/svc/tests/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1136+native/kernel/svc/tests/allen_code_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1137+native/kernel/svc/tests/allen_memory_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1138+native/kernel/svc/tests/allen_place_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1139+native/kernel/svc/tests/ck_host.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1140+native/kernel/svc/tests/ck_host.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1141+native/kernel/svc/tests/fixtures/code/long.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1142+native/kernel/svc/tests/fixtures/code/short.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1143+native/kernel/svc/tests/fixtures/setup/ai-pc.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1144+native/kernel/svc/tests/fixtures/setup/games-pc.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1145+native/kernel/svc/tests/fixtures/setup/spark.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1146+native/kernel/svc/tests/setup_wizard_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1147+native/kernel/svc/tests/stage_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1148+native/kernel/tests/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1149+native/kernel/tests/ck_test.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1150+native/kernel/tests/fixtures/continuity_vectors.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1151+native/kernel/tests/fixtures/continuity_verdicts.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1152+native/kernel/tests/fixtures/osc_receipt/PROVENANCE.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1153+native/kernel/tests/fixtures/osc_receipt/a01.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1154+native/kernel/tests/fixtures/osc_receipt/expected.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1155+native/kernel/tests/fixtures/osc_receipt/l01.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1156+native/kernel/tests/fixtures/osc_receipt/make-receipts.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1157+native/kernel/tests/fixtures/osc_receipt/n_altered.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1158+native/kernel/tests/fixtures/osc_receipt/n_checker.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1159+native/kernel/tests/fixtures/osc_receipt/n_deps.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1160+native/kernel/tests/fixtures/osc_receipt/n_expired.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1161+native/kernel/tests/fixtures/osc_receipt/n_firmware.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1162+native/kernel/tests/fixtures/osc_receipt/n_future.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1163+native/kernel/tests/fixtures/osc_receipt/n_length.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1164+native/kernel/tests/fixtures/osc_receipt/n_producer.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1165+native/kernel/tests/fixtures/osc_receipt/n_program.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1166+native/kernel/tests/fixtures/osc_receipt/n_revoked_id.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1167+native/kernel/tests/fixtures/osc_receipt/n_stale.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1168+native/kernel/tests/fixtures/osc_receipt/n_target.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1169+native/kernel/tests/fixtures/osc_receipt/osh_expand.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1170+native/kernel/tests/fixtures/osc_receipt/osh_lex.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1171+native/kernel/tests/fixtures/osc_receipt/osh_parse.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1172+native/kernel/tests/fixtures/osc_receipt_owner/PROVENANCE.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1173+native/kernel/tests/fixtures/osc_receipt_owner/a01.owner.rcpt rcpt data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1174+native/kernel/tests/fixtures/osc_unit/PROVENANCE.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1175+native/kernel/tests/fixtures/osc_unit/keys/owner1.pub pub data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1176+native/kernel/tests/fixtures/osc_unit/keys/test1.pub pub data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1177+native/kernel/tests/fixtures/osc_unit/launch/l01.S S c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1178+native/kernel/tests/fixtures/osc_unit/launch/l01.code code data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1179+native/kernel/tests/fixtures/osc_unit/launch/l01_launch_fns.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1180+native/kernel/tests/fixtures/osc_unit/launch/l02_stack_over.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1181+native/kernel/tests/fixtures/osc_unit/launch/make-l01.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1182+native/kernel/tests/fixtures/osc_unit/launch/osc-launch-check.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1183+native/kernel/tests/fixtures/osc_unit/vectors/a01_valid_min.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1184+native/kernel/tests/fixtures/osc_unit/vectors/a02_valid_caps_kernel_domain.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1185+native/kernel/tests/fixtures/osc_unit/vectors/a03_valid_hosted_domain.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1186+native/kernel/tests/fixtures/osc_unit/vectors/a04_valid_owner_class.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1187+native/kernel/tests/fixtures/osc_unit/vectors/a05_valid_cells_entry.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1188+native/kernel/tests/fixtures/osc_unit/vectors/a06_valid_limits_at_max.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1189+native/kernel/tests/fixtures/osc_unit/vectors/expected.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1190+native/kernel/tests/fixtures/osc_unit/vectors/launch.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1191+native/kernel/tests/fixtures/osc_unit/vectors/lookups.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1192+native/kernel/tests/fixtures/osc_unit/vectors/r01_bad_magic.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1193+native/kernel/tests/fixtures/osc_unit/vectors/r02_container_version_2.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1194+native/kernel/tests/fixtures/osc_unit/vectors/r03_unit_format_6.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1195+native/kernel/tests/fixtures/osc_unit/vectors/r04_abi_version_2.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1196+native/kernel/tests/fixtures/osc_unit/vectors/r05_unknown_flags.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1197+native/kernel/tests/fixtures/osc_unit/vectors/r06_header_field_reserved.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1198+native/kernel/tests/fixtures/osc_unit/vectors/r07_truncated_file.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1199+native/kernel/tests/fixtures/osc_unit/vectors/r08_section_bounds.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1200+native/kernel/tests/fixtures/osc_unit/vectors/r09_section_overlap.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1201+native/kernel/tests/fixtures/osc_unit/vectors/r10_section_layout_offset.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1202+native/kernel/tests/fixtures/osc_unit/vectors/r11_too_many_functions.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1203+native/kernel/tests/fixtures/osc_unit/vectors/r12_code_hash_mismatch.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1204+native/kernel/tests/fixtures/osc_unit/vectors/r13_ir_hash_mismatch.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1205+native/kernel/tests/fixtures/osc_unit/vectors/r14_bad_signature.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1206+native/kernel/tests/fixtures/osc_unit/vectors/r15_ir_version_mismatch.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1207+native/kernel/tests/fixtures/osc_unit/vectors/r16_entry_table_unaligned.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1208+native/kernel/tests/fixtures/osc_unit/vectors/r17_too_many_functions.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1209+native/kernel/tests/fixtures/osc_unit/vectors/r18_gen_not_representable.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1210+native/kernel/tests/fixtures/osc_unit/vectors/r19_test_signer_release.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1211+native/kernel/tests/fixtures/osc_unit/vectors/r20_domain_unsupported.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1212+native/kernel/tests/fixtures/osc_unit/vectors/r21_untrusted_owner_signer.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1213+native/kernel/tests/fixtures/osc_unit/vectors/r22_trailing_byte.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1214+native/kernel/tests/fixtures/osc_unit/vectors/r23_entry_name_charset.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1215+native/kernel/tests/fixtures/osc_unit/vectors/r24_entry_name_empty.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1216+native/kernel/tests/fixtures/osc_unit/vectors/r25_entry_name_too_long.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1217+native/kernel/tests/fixtures/osc_unit/vectors/r26_entry_name_padding.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1218+native/kernel/tests/fixtures/osc_unit/vectors/r27_entry_name_duplicate.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1219+native/kernel/tests/fixtures/osc_unit/vectors/r28_entry_hash_shared_other_name.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1220+native/kernel/tests/fixtures/osc_unit/vectors/r29_total_length_low.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1221+native/kernel/tests/fixtures/osc_unit/vectors/r30_section_table_kind.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1222+native/kernel/tests/fixtures/osc_unit/vectors/r31_entry_hash_mismatch.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1223+native/kernel/tests/fixtures/osc_unit/vectors/r32_caps_hash_mismatch.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1224+native/kernel/tests/fixtures/osc_unit/vectors/r33_caps_table_bad_rights.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1225+native/kernel/tests/fixtures/osc_unit/vectors/r34_signer_class_3.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1226+native/kernel/tests/fixtures/osc_unit/vectors/r35_signature_algorithm_2.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1227+native/kernel/tests/fixtures/osc_unit/vectors/r36_domain_before_generation.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1228+native/kernel/tests/fixtures/osc_unit/vectors/r37_code_svc.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1229+native/kernel/tests/fixtures/osc_unit/vectors/r38_code_hvc.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1230+native/kernel/tests/fixtures/osc_unit/vectors/r39_code_smc.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1231+native/kernel/tests/fixtures/osc_unit/vectors/r40_code_msr_sysreg.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1232+native/kernel/tests/fixtures/osc_unit/vectors/r41_code_mrs_sysreg.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1233+native/kernel/tests/fixtures/osc_unit/vectors/r42_code_brk_imm0.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1234+native/kernel/tests/fixtures/osc_unit/vectors/r43_code_brk_imm15.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1235+native/kernel/tests/fixtures/osc_unit/vectors/r44_caps_disorder.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1236+native/kernel/tests/fixtures/osc_unit/vectors/r45_signature_s_not_canonical.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1237+native/kernel/tests/fixtures/osc_unit/vectors/r46_section_bounds_u32_wrap.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1238+native/kernel/tests/fixtures/osc_unit/vectors/r47_slice_kind_in_format_4.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1239+native/kernel/tests/fixtures/osc_unit/vectors/r48_entry_hash_shared_case_variant.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1240+native/kernel/tests/fixtures/osc_unit/vectors/r49_cpu_ticks_over_max.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1241+native/kernel/tests/fixtures/osc_unit/vectors/r50_stack_over_max.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1242+native/kernel/tests/fixtures/osc_unit/vectors/r51_pool_slots_over_max.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1243+native/kernel/tests/fixtures/osc_unit/vectors/state.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1244+native/kernel/tests/fixtures/osh/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1245+native/kernel/tests/fixtures/osh/PROVENANCE.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1246+native/kernel/tests/fixtures/osh/gen-fixtures-h.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1247+native/kernel/tests/fixtures/osh/make-osh-units.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1248+native/kernel/tests/fixtures/osh/osh_expand.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1249+native/kernel/tests/fixtures/osh/osh_layout.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1250+native/kernel/tests/fixtures/osh/osh_lex.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1251+native/kernel/tests/fixtures/osh/osh_parse.unit unit data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1252+native/kernel/tests/fixtures/osh/trace/t01_words.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1253+native/kernel/tests/fixtures/osh/trace/t01_words.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1254+native/kernel/tests/fixtures/osh/trace/t02_quotes.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1255+native/kernel/tests/fixtures/osh/trace/t02_quotes.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1256+native/kernel/tests/fixtures/osh/trace/t03_escapes.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1257+native/kernel/tests/fixtures/osh/trace/t03_escapes.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1258+native/kernel/tests/fixtures/osh/trace/t04_bslash_newline.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1259+native/kernel/tests/fixtures/osh/trace/t04_bslash_newline.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1260+native/kernel/tests/fixtures/osh/trace/t05_assign.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1261+native/kernel/tests/fixtures/osh/trace/t05_assign.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1262+native/kernel/tests/fixtures/osh/trace/t06_expand_split.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1263+native/kernel/tests/fixtures/osh/trace/t06_expand_split.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1264+native/kernel/tests/fixtures/osh/trace/t07_lists.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1265+native/kernel/tests/fixtures/osh/trace/t07_lists.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1266+native/kernel/tests/fixtures/osh/trace/t08_redirs.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1267+native/kernel/tests/fixtures/osh/trace/t08_redirs.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1268+native/kernel/tests/fixtures/osh/trace/t09_incomplete_ok.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1269+native/kernel/tests/fixtures/osh/trace/t09_incomplete_ok.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1270+native/kernel/tests/fixtures/osh/trace/t10_syntax_error.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1271+native/kernel/tests/fixtures/osh/trace/t10_syntax_error.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1272+native/kernel/tests/fixtures/osh/trace/t11_append_assign.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1273+native/kernel/tests/fixtures/osh/trace/t11_append_assign.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1274+native/kernel/tests/fixtures/osh/trace/t12_cmdsub_refused.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1275+native/kernel/tests/fixtures/osh/trace/t12_cmdsub_refused.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1276+native/kernel/tests/fixtures/osh/trace/t13_long_line_fits.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1277+native/kernel/tests/fixtures/osh/trace/t13_long_line_fits.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1278+native/kernel/tests/fixtures/osh/trace/t14_over_4096_window.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1279+native/kernel/tests/fixtures/osh/trace/t14_over_4096_window.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1280+native/kernel/tests/fixtures/osh/trace/t15_blank_comment.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1281+native/kernel/tests/fixtures/osh/trace/t15_blank_comment.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1282+native/kernel/tests/fixtures/osh/trace/t16_brace_special_refused.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1283+native/kernel/tests/fixtures/osh/trace/t16_brace_special_refused.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1284+native/kernel/tests/fixtures/osh/trace/t17_status_skip.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1285+native/kernel/tests/fixtures/osh/trace/t17_status_skip.status status data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1286+native/kernel/tests/fixtures/osh/trace/t17_status_skip.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1287+native/kernel/tests/fixtures/osh/trace/t18_window_exact.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1288+native/kernel/tests/fixtures/osh/trace/t18_window_exact.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1289+native/kernel/tests/fixtures/osh/trace/t19_window_over_by_one.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1290+native/kernel/tests/fixtures/osh/trace/t19_window_over_by_one.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1291+native/kernel/tests/fixtures/osh/trace/t20_positionals.args args data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1292+native/kernel/tests/fixtures/osh/trace/t20_positionals.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1293+native/kernel/tests/fixtures/osh/trace/t20_positionals.trace trace data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1294+native/kernel/tests/fixtures/owner/TEST-FIXTURE-machine-id.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1295+native/kernel/tests/fixtures/owner/TEST-FIXTURE-owner-pubkeys.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1296+native/kernel/tests/fixtures/pipe/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1297+native/kernel/tests/fixtures/pipe/p001_nul_payload.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1298+native/kernel/tests/fixtures/pipe/p002_capacity_partial.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1299+native/kernel/tests/fixtures/pipe/p003_zero_length.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1300+native/kernel/tests/fixtures/pipe/p004_broken_pipe.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1301+native/kernel/tests/fixtures/pipe/p005_eof_after_drain.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1302+native/kernel/tests/fixtures/pipe/p006_rights.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1303+native/kernel/tests/fixtures/pipe/p007_handle_reuse.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1304+native/kernel/tests/fixtures/pipe/p008_revoke_blocked_read.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1305+native/kernel/tests/fixtures/pipe/p009_revoke_blocked_write.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1306+native/kernel/tests/fixtures/pipe/p010_close_reader_race.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1307+native/kernel/tests/fixtures/pipe/p011_close_writer_race.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1308+native/kernel/tests/fixtures/pipe/p012_both_closed.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1309+native/kernel/tests/fixtures/pipe/p013_cancel_blocked_read.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1310+native/kernel/tests/fixtures/pipe/p014_cancel_pending_write.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1311+native/kernel/tests/fixtures/pipe/p015_stalled_consumer.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1312+native/kernel/tests/fixtures/pipe/p016_blocked_read_progress.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1313+native/kernel/tests/fixtures/pipe/p017_malformed_frames.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1314+native/kernel/tests/fixtures/pipe/p018_limits.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1315+native/kernel/tests/fixtures/pipe/p019_dup_refs.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1316+native/kernel/tests/fixtures/pipe/p020_transfer.vec vec data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1317+native/kernel/tests/fixtures/spark_xhci_acpi_expected.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1318+native/kernel/tests/gpu_chan_trace.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1319+native/kernel/tests/gsp_boot_trace.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1320+native/kernel/tests/spinlock_tu.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1321+native/kernel/tests/test_acpi.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1322+native/kernel/tests/test_acpi_dev.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1323+native/kernel/tests/test_agent_cmd.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1324+native/kernel/tests/test_allen_gate.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1325+native/kernel/tests/test_amd_gpu.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1326+native/kernel/tests/test_amd_gpu_ring.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1327+native/kernel/tests/test_artifact.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1328+native/kernel/tests/test_artifact_card.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1329+native/kernel/tests/test_console_rx.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1330+native/kernel/tests/test_context.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1331+native/kernel/tests/test_continuity_codec.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1332+native/kernel/tests/test_continuity_commit.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1333+native/kernel/tests/test_continuity_geometry.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1334+native/kernel/tests/test_continuity_recovery.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1335+native/kernel/tests/test_continuity_resolve.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1336+native/kernel/tests/test_continuity_subject.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1337+native/kernel/tests/test_continuity_subject_provision.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1338+native/kernel/tests/test_cpufeat.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1339+native/kernel/tests/test_dma_window.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1340+native/kernel/tests/test_dmar.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1341+native/kernel/tests/test_entropy.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1342+native/kernel/tests/test_fbcon.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1343+native/kernel/tests/test_fmt.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1344+native/kernel/tests/test_frames.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1345+native/kernel/tests/test_gb10_gsp_boot.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1346+native/kernel/tests/test_gb10_gsp_nvhdr.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1347+native/kernel/tests/test_gpu_sim.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1348+native/kernel/tests/test_gsp_mmio.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1349+native/kernel/tests/test_gsp_seq.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1350+native/kernel/tests/test_handoff.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1351+native/kernel/tests/test_heap.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1352+native/kernel/tests/test_imac_report.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1353+native/kernel/tests/test_ipc.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1354+native/kernel/tests/test_klog.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1355+native/kernel/tests/test_klog_slot.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1356+native/kernel/tests/test_lifecycle.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1357+native/kernel/tests/test_netboot_text.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1358+native/kernel/tests/test_osc_admit.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1359+native/kernel/tests/test_osc_launch.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1360+native/kernel/tests/test_osc_receipt.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1361+native/kernel/tests/test_osc_unit.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1362+native/kernel/tests/test_osh_op.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1363+native/kernel/tests/test_pi5.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1364+native/kernel/tests/test_pi5_gem.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1365+native/kernel/tests/test_pi5_marker.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1366+native/kernel/tests/test_pi5_net.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1367+native/kernel/tests/test_pi5_pcie.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1368+native/kernel/tests/test_pi5_rng.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1369+native/kernel/tests/test_pipe.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1370+native/kernel/tests/test_pipe_irq.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1371+native/kernel/tests/test_pt.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1372+native/kernel/tests/test_sched.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1373+native/kernel/tests/test_smmu.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1374+native/kernel/tests/test_smmu_svc.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1375+native/kernel/tests/test_spinlock.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1376+native/kernel/tests/test_unlock_req.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1377+native/kernel/third_party/omega/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1378+native/kernel/third_party/omega/rx_cortex.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1379+native/kernel/third_party/omega/rx_cortex.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1380+native/kernel/tools/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1381+native/kernel/tools/ck_acpi_scan.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1382+native/kernel/tools/ck_artifact_tool.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1383+native/kernel/tools/ck_cont_tool.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1384+native/kernel/tools/ck_cortex_image.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1385+native/kernel/tools/ck_fb_check.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1386+native/kernel/tools/ck_gpt_image.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1387+native/kernel/tools/ck_gpu_bench.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1388+native/kernel/tools/ck_gsp_bindata_extract.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1389+native/kernel/tools/ck_gsp_boot_args_encode.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1390+native/kernel/tools/ck_gsp_cot_encode.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1391+native/kernel/tools/ck_gsp_fw_inspect.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1392+native/kernel/tools/ck_gsp_rpc_encode.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1393+native/kernel/tools/ck_gsp_sysinfo_encode.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1394+native/kernel/tools/ck_imac_bsdp.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1395+native/kernel/tools/ck_imac_netboot.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1396+native/kernel/tools/ck_imac_report_listen.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1397+native/kernel/tools/ck_imac_swap.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1398+native/kernel/tools/ck_manifest_sig.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1399+native/kernel/tools/ck_model_map.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1400+native/kernel/tools/ck_owner_gen.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1401+native/kernel/tools/ck_pi5_store_locate.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1402+native/kernel/tools/ck_sky_gen.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1403+native/kernel/tools/ck_slot_tool.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1404+native/kernel/tools/ck_store_image.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1405+native/kernel/tools/ck_udp_echo.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1406+native/kernel/tools/ck_uefi_vars.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1407+native/kernel/tools/gpt_write.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1408+native/kernel/tools/gpt_write.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1409+native/kernel/tools/pi5_store_locate.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1410+native/kernel/tools/pi5_store_locate.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1411+native/kernel/ui/allen_font.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1412+native/kernel/ui/allen_font.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1413+native/kernel/ui/allen_ui.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1414+native/kernel/ui/allen_ui.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1415+native/kernel/ui/boot_show.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1416+native/kernel/ui/boot_show.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1417+native/kernel/ui/canvas.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1418+native/kernel/ui/canvas.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1419+native/kernel/ui/chirp.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1420+native/kernel/ui/chirp.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1421+native/kernel/ui/flow.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1422+native/kernel/ui/flow.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1423+native/kernel/ui/mind.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1424+native/kernel/ui/mind.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1425+native/kernel/ui/night.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1426+native/kernel/ui/night.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1427+native/kernel/ui/paint.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1428+native/kernel/ui/paint.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1429+native/kernel/ui/setup_view.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1430+native/kernel/ui/sky_data.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1431+native/kernel/ui/sky_data.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1432+native/kernel/ui/sky_data.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1433+native/kernel/ui/sky_real.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1434+native/kernel/ui/sky_real.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1435+native/kernel/ui/tests/allen_exit_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1436+native/kernel/ui/tests/allen_ui_stream_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1437+native/kernel/ui/tests/allen_ui_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1438+native/kernel/ui/tests/boot_show_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1439+native/kernel/ui/tests/canvas_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1440+native/kernel/ui/tests/chirp_audit.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1441+native/kernel/ui/tests/chirp_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1442+native/kernel/ui/tests/mind_phases_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1443+native/kernel/ui/tests/sky_sharpness_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1444+native/kernel/ui/tests/sky_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1445+native/kernel/ui/tools/boot_show_check.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1446+native/kernel/x86/ahci_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1447+native/kernel/x86/bench_proto.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1448+native/kernel/x86/bench_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1449+native/kernel/x86/bench_x86.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1450+native/kernel/x86/boot_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1451+native/kernel/x86/console_log.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1452+native/kernel/x86/console_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1453+native/kernel/x86/courier_udp.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1454+native/kernel/x86/courier_udp_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1455+native/kernel/x86/courier_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1456+native/kernel/x86/dmar_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1457+native/kernel/x86/efi_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1458+native/kernel/x86/fwcfg_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1459+native/kernel/x86/hda_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1460+native/kernel/x86/kmain_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1461+native/kernel/x86/local_bundle.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1462+native/kernel/x86/local_enter.S S c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1463+native/kernel/x86/local_tests.inc inc data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1464+native/kernel/x86/local_tools.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1465+native/kernel/x86/local_tools.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1466+native/kernel/x86/local_wire.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1467+native/kernel/x86/local_wire.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1468+native/kernel/x86/memory_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1469+native/kernel/x86/model/LICENSE.llama2-c llama2-c data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1470+native/kernel/x86/model/LICENSE.omega-dnn omega-dnn data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1471+native/kernel/x86/model/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1472+native/kernel/x86/model/admission_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1473+native/kernel/x86/model/assets.S S c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1474+native/kernel/x86/model/check_local_model.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1475+native/kernel/x86/model/host_call.S S c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1476+native/kernel/x86/model/host_probe.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1477+native/kernel/x86/model/model_bundle.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1478+native/kernel/x86/model/reference_probe.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1479+native/kernel/x86/model/runtime.inc inc data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1480+native/kernel/x86/model/tests.inc inc data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1481+native/kernel/x86/panel_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1482+native/kernel/x86/pci_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1483+native/kernel/x86/report_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1484+native/kernel/x86/report_x86.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1485+native/kernel/x86/setup_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1486+native/kernel/x86/smp_x86.S S c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1487+native/kernel/x86/swap_disk_read.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1488+native/kernel/x86/swap_proto.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1489+native/kernel/x86/swap_tramp.S S c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1490+native/kernel/x86/swap_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1491+native/kernel/x86/swap_x86.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1492+native/kernel/x86/tests/boot_verify_keys.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1493+native/kernel/x86/tests/boot_verify_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1494+native/kernel/x86/tests/courier_model_fixture.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
1495+native/kernel/x86/tests/courier_secret_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1496+native/kernel/x86/tests/courier_udp_frame_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1497+native/kernel/x86/tests/courier_udp_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1498+native/kernel/x86/tests/local_admission_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1499+native/kernel/x86/tests/local_tools_model_oracle.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1500+native/kernel/x86/tests/local_tools_udp_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1501+native/kernel/x86/tests/setup_secret_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1502+native/kernel/x86/tests/swap_disk_bound_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1503+native/kernel/x86/tg3_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1504+native/kernel/x86/trap.S S c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1505+native/kernel/x86/x86.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1506+native/kernel/x86/xhci_x86.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1507+native/linux/aien-gpu/.gitignore none data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1508+native/linux/aien-gpu/Kbuild none data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1509+native/linux/aien-gpu/Makefile none c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1510+native/linux/aien-gpu/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1511+native/linux/aien-gpu/aien_gpu.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1512+native/linux/aien-gpu/aien_gpu_check.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1513+native/linux/aien-gpu/aien_gpu_uapi.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1514+native/linux/aien-gpu/aien_gsp_boot.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1515+native/m5/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1516+native/m5/.gitignore none data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1517+native/m5/Makefile none c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1518+native/m5/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1519+native/m5/m5.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1520+native/m5/m5_envelope.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1521+native/m5/m5_internal.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1522+native/m5/m5_keys.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1523+native/m5/m5_owner_sig.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1524+native/m5/m5_state.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1525+native/m5/tests/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1526+native/m5/tests/m5_migsig_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1527+native/m5/tests/m5_migsig_tool_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1528+native/m5/tests/m5_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1529+native/m5/tools/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1530+native/m5/tools/m5_migsig.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1531+native/net/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1532+native/net/.gitignore none data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1533+native/net/Makefile none c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1534+native/net/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1535+native/net/aienos_ctl.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1536+native/net/aienos_ctl.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1537+native/net/aienos_net.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1538+native/net/aienos_net.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1539+native/net/aienos_report.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1540+native/net/aienos_report.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1541+native/net/aienos_rtl8127.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1542+native/net/aienos_rtl8127.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1543+native/net/aienos_sec.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1544+native/net/aienos_sec.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1545+native/net/aienos_virtio_net.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1546+native/net/aienos_virtio_net.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1547+native/net/aienos_virtio_pci.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1548+native/net/aienos_virtio_pci.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1549+native/net/receipt.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1550+native/net/receipts/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1551+native/net/receipts/m6a_net_host_30de56f02d33bc346309173c67638a581c6cf1442a121f6f0f47fa42027de14d.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1552+native/net/receipts/m6a_net_host_8359cd99c5244f9df9f3786eb8130f513ead5c8e9b68e91b1179d0af9978e95b.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1553+native/net/receipts/m6a_net_host_83748f32165c969f2b903eefb4f975a2f4900035cc234a2b31ddfe04941166d6.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1554+native/net/receipts/m6a_net_host_b266e16da256456c91dae44ede2c47cbd7cbd830473cf9bc56f9541d0d876007.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1555+native/net/tcp/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1556+native/net/tcp/gate.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1557+native/net/tests/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1558+native/net/tests/ctl_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1559+native/net/tests/fixtures/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1560+native/net/tests/fixtures/dump_qemu_virtio_net_cfg.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1561+native/net/tests/fixtures/qemu822_virtio_net_pci_modern.cfg cfg data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1562+native/net/tests/fixtures/qemu822_virtio_net_pci_transitional.cfg cfg data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1563+native/net/tests/net_diff.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1564+native/net/tests/net_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1565+native/net/tests/report_send.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1566+native/net/tests/rtl8127_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1567+native/net/tests/sec_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1568+native/net/tests/vnet_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1569+native/net/tests/x25519_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1570+native/net/x25519.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1571+native/net/x25519.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1572+native/om/lm1b/.gitignore none data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1573+native/om/lm1b/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1574+native/om/lm1b/evidence/gate.log log data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1575+native/om/lm1b/evidence/gate/WHERE.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1576+native/om/lm1b/evidence/gate/fault.out out data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1577+native/om/lm1b/evidence/gate/flip.out out data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1578+native/om/lm1b/evidence/gate/lm1b.sha256 sha256 data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1579+native/om/lm1b/evidence/gate/main.out out data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1580+native/om/lm1b/evidence/gate/manifest.ref.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1581+native/om/lm1b/evidence/gate/neg-jobs.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1582+native/om/lm1b/evidence/gate/neg.out out data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1583+native/om/lm1b/evidence/gate/ref-cow.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1584+native/om/lm1b/evidence/gate/ref-rainbow.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1585+native/om/lm1b/evidence/gate/wrongtype.out out data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1586+native/om/lm1b/evidence/lm1b-load-strace.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1587+native/om/lm1b/evidence/lm1b-load.out out data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1588+native/om/lm1b/evidence/lm1b-load.time time data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1589+native/om/lm1b/evidence/lm1b-main.out out data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1590+native/om/lm1b/evidence/lm1b-main.time time data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1591+native/om/lm1b/evidence/ref-cow8.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1592+native/om/lm1b/evidence/ref-rainbow8.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1593+native/om/lm1b/evidence/shas.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1594+native/om/lm1b/gate.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1595+native/om/lm1b/gen.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1596+native/om/lm1b/manifest.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1597+native/om/lm1b/oracle/manifest-dump/Cargo.lock lock rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
1598+native/om/lm1b/oracle/manifest-dump/Cargo.toml toml rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
1599+native/om/lm1b/oracle/manifest-dump/src/main.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
1600+native/om/lm1b/prompts/cow.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1601+native/om/lm1b/prompts/main-jobs.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1602+native/om/lm1b/prompts/rainbow.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1603+native/omega/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1604+native/omega/allen/ALPHA.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1605+native/omega/allen/FONT.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1606+native/omega/allen/LOCAL-MODEL.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1607+native/omega/allen/PRESENTATION.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1608+native/omega/allen/PROVIDER.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1609+native/omega/allen/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1610+native/omega/allen/SURFACE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1611+native/omega/allen/build-fw.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1612+native/omega/allen/build-local-model.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1613+native/omega/allen/build-one.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1614+native/omega/allen/gate.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1615+native/omega/allen/golden.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1616+native/omega/allen/test-build.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1617+native/omega/allen/test-look-home-dirty.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1618+native/omega/allen/test-look-submit.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1619+native/omega/allen/vendor/CERT-APACHE-LICENSE none data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1620+native/omega/allen/vendor/OMEGA-LICENSE none data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1621+native/omega/allen/vendor/PROVENANCE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1622+native/omega/platform/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1623+native/omega/platform/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1624+native/omega/platform/cppc-fixture.json json data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1625+native/omega/platform/gate.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1626+native/omega/platform/kernel-repro.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1627+native/omega/platform/pcie-cooling-proposal.patch patch data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1628+native/omega/platform/pcie-cooling-ref.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1629+native/sig/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1630+native/sig/.gitignore none data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1631+native/sig/Makefile none c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1632+native/sig/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1633+native/sig/aienos_sig.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1634+native/sig/ct.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1635+native/sig/ed25519.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1636+native/sig/sha512.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1637+native/sig/sig_internal.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1638+native/sig/tests/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1639+native/sig/tests/rfc8032_vectors.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1640+native/sig/tests/sig_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1641+native/store/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1642+native/store/Makefile none c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1643+native/store/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1644+native/store/store_disk.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1645+native/store/store_engine.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1646+native/store/store_engine.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1647+native/store/store_mem.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1648+native/store/store_sealed.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1649+native/store/store_sealed.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1650+native/store/store_v1.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1651+native/store/store_v1.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1652+native/store/tests/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1653+native/store/tests/SEALED-COVERAGE.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1654+native/store/tests/gen_golden.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1655+native/store/tests/rust_crosscheck.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1656+native/store/tests/store_engine_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1657+native/store/tests/store_powercut_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1658+native/store/tests/store_rig.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1659+native/store/tests/store_sealed_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1660+native/store/tests/store_test_util.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1661+native/store/tests/store_v1_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1662+native/store/tests/store_xcheck.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1663+native/store/tests/torn_slot_test.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1664+native/store/torn_slot.c c c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1665+native/store/torn_slot.h h c-asm-legacy frozen C/assembly kernel, driver or host harness; stays in aienux until rewritten in pure Omega
1666+omega.lock lock data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1667+scripts/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1668+scripts/allen_bounds_cases.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1669+scripts/allen_courier_up.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1670+scripts/allen_exam_card.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1671+scripts/allen_pi_results.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1672+scripts/allen_route_card.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1673+scripts/allen_route_mutants.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1674+scripts/build_recovery_media.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1675+scripts/build_standalone_recovery_initrd.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1676+scripts/cap_abi_isolation_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1677+scripts/capture_gate1_receipt.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1678+scripts/check_local_model.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1679+scripts/check_local_tools.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1680+scripts/check_receipt_labels.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1681+scripts/ck_allen_canvas_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1682+scripts/ck_allen_code_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1683+scripts/ck_allen_memory_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1684+scripts/ck_allen_ui_stream_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1685+scripts/ck_allen_ui_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1686+scripts/ck_boot_show_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1687+scripts/ck_chirp_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1688+scripts/ck_courier_udp_frame_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1689+scripts/ck_courier_udp_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1690+scripts/ck_fat_boot_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1691+scripts/ck_gates.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1692+scripts/ck_imac_bsdp_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1693+scripts/ck_imac_lab_services.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1694+scripts/ck_imac_lab_services_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1695+scripts/ck_imac_netboot_push.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1696+scripts/ck_imac_report_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1697+scripts/ck_imac_security_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1698+scripts/ck_mind_phases_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1699+scripts/ck_owner_keys_check.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1700+scripts/ck_pi5_build_check.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1701+scripts/ck_pi5_manifest_check.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1702+scripts/ck_pi5_owner_check.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1703+scripts/ck_pi5_repro_check.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1704+scripts/ck_repro_build.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1705+scripts/ck_setup_wizard_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1706+scripts/ck_shards_verify.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1707+scripts/ck_sky_gen.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1708+scripts/ck_sky_sharpness_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1709+scripts/ck_sky_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1710+scripts/ck_spark_report_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1711+scripts/ck_swap_disk_bound_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1712+scripts/ck_virtio_av_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1713+scripts/collect_boot_report.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1714+scripts/collect_recovery_boot_evidence.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1715+scripts/fetch_gpu_ucode.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1716+scripts/freeze_reality.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1717+scripts/gate_hold_selftest.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1718+scripts/gb10_iort_decode.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1719+scripts/gb10_profile.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1720+scripts/generate_owner_boot_keys.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1721+scripts/gpu_bench/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1722+scripts/gpu_bench/STEP1_display_flip.bench bench data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1723+scripts/gpu_bench/STEP2_gmc_read.bench bench data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1724+scripts/gpu_bench/STEP3_smu_check.bench bench data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1725+scripts/gpu_bench/STEP4_gfx_ring.bench bench data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1726+scripts/gpu_bench/STEP5_sdma.bench bench data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1727+scripts/gpu_bench/STEP6_compute.bench bench data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1728+scripts/gpu_bench/check_bench.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1729+scripts/gpu_bench/check_regs.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1730+scripts/gpu_ucode_sha256.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1731+scripts/iort_decode.rs rs rust-legacy legacy Rust kernel/workspace; stays in aienux until replaced by pure Omega
1732+scripts/l6_host_receipt.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1733+scripts/lib_ck_cont_qemu.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1734+scripts/lib_ck_m1_checks.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1735+scripts/lib_gate_hold.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1736+scripts/lib_verify_summary.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1737+scripts/m3_receipt.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1738+scripts/native_boot_preflight.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1739+scripts/native_package.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1740+scripts/native_package_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1741+scripts/omega_lock_check.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1742+scripts/pi5-8/gen_measure_header.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1743+scripts/pi5-8/host_golden.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1744+scripts/pi5-8/install_owner_tools.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1745+scripts/pi5-8/owner_ceremony.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1746+scripts/pi5-8/owner_pubkey_file.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1747+scripts/pi5-8/pi_run.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1748+scripts/pi5-8/prompt-long1.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1749+scripts/pi5-8/prompt-long2.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1750+scripts/pi5-8/prompt-short.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1751+scripts/pi5/efi-commit.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1752+scripts/pi5/klog-lib.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1753+scripts/pi5/pi5-run.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1754+scripts/pi5_fact_req.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1755+scripts/pi5_receipts_manifest.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1756+scripts/pi5_receipts_verdicts.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1757+scripts/pi5_run_allen.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1758+scripts/pi5_run_artifact.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1759+scripts/pi5_unlock_req.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1760+scripts/qemu_artifact_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1761+scripts/qemu_boot_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1762+scripts/qemu_ck_allen_code_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1763+scripts/qemu_ck_allen_courier_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1764+scripts/qemu_ck_allen_memory_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1765+scripts/qemu_ck_allen_reflex_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1766+scripts/qemu_ck_allen_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1767+scripts/qemu_ck_allen_wizard_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1768+scripts/qemu_ck_artifact_card_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1769+scripts/qemu_ck_artifact_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1770+scripts/qemu_ck_b7b_probe_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1771+scripts/qemu_ck_boot_show_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1772+scripts/qemu_ck_boot_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1773+scripts/qemu_ck_console_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1774+scripts/qemu_ck_continuity_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1775+scripts/qemu_ck_disk_layout_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1776+scripts/qemu_ck_fpu_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1777+scripts/qemu_ck_gpu_bench_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1778+scripts/qemu_ck_imac_bootdisk_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1779+scripts/qemu_ck_imac_diag_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1780+scripts/qemu_ck_imac_kernel_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1781+scripts/qemu_ck_imac_keyboard_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1782+scripts/qemu_ck_imac_netboot_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1783+scripts/qemu_ck_imac_swap_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1784+scripts/qemu_ck_infer_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1785+scripts/qemu_ck_keyboard_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1786+scripts/qemu_ck_lifecycle_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1787+scripts/qemu_ck_local_model_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1788+scripts/qemu_ck_local_tools_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1789+scripts/qemu_ck_memory_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1790+scripts/qemu_ck_net_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1791+scripts/qemu_ck_osc_launch_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1792+scripts/qemu_ck_osc_receipt_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1793+scripts/qemu_ck_osc_unit_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1794+scripts/qemu_ck_osh_core_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1795+scripts/qemu_ck_osh_op_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1796+scripts/qemu_ck_pi5_diag_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1797+scripts/qemu_ck_pipe_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1798+scripts/qemu_ck_recovery_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1799+scripts/qemu_ck_rollback_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1800+scripts/qemu_ck_screen_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1801+scripts/qemu_ck_service_disk_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1802+scripts/qemu_ck_slot_loader_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1803+scripts/qemu_ck_smp_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1804+scripts/qemu_ck_store_crash_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1805+scripts/qemu_ck_store_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1806+scripts/qemu_continuity_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1807+scripts/qemu_keyboard_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1808+scripts/qemu_native_nvme_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1809+scripts/qemu_native_rollback_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1810+scripts/qemu_native_sdhci_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1811+scripts/qemu_nvme_atomicity_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1812+scripts/qemu_nvme_rw_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1813+scripts/qemu_nvme_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1814+scripts/qemu_recovery_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1815+scripts/qemu_secureboot_signing_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1816+scripts/qemu_security_suite.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1817+scripts/qemu_smmu_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1818+scripts/qemu_store_512b_crash_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1819+scripts/qemu_store_crash_test.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1820+scripts/qemu_verify_recovery_media.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1821+scripts/seed0b_machine1_prepare.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1822+scripts/sign_efi_binary.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1823+scripts/stage_one_time_boot.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1824+scripts/stage_one_time_boot_ck.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1825+scripts/stage_one_time_boot_ck_b7b.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1826+scripts/stage_one_time_boot_ck_full.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1827+scripts/stage_one_time_boot_ck_service.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1828+scripts/test_local_tools_udp.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1829+scripts/test_recovery_media_security.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1830+scripts/test_recovery_unlock_chroot.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1831+scripts/test_trust1_attended_evidence_check.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1832+scripts/test_trust1_key_ceremony.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1833+scripts/test_trust1_measurement_tools.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1834+scripts/tpm_measurement_campaign.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1835+scripts/trust1_attended_evidence_check.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1836+scripts/trust1_credential_policy.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1837+scripts/trust1_gate5_policy_sim.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1838+scripts/trust1_gate7_preflight.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1839+scripts/trust1_key_ceremony.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1840+scripts/trust1_m5_qualify.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1841+scripts/verify_all.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1842+scripts/verify_evidence.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1843+scripts/verify_native_rollback.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1844+scripts/verify_recovery_tools.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1845+scripts/workflow_files_check.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1846+tests/gates/aienos-ck-b7b-probe.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1847+tests/gates/aienos-ck-gate-selftest.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1848+tests/gates/aienos-ck-hold-selftest.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1849+tests/gates/aienos-ck-host-tests.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1850+tests/gates/aienos-ck-owner-keys.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1851+tests/gates/aienos-ck-qemu-external.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1852+tests/gates/aienos-ck-qemu-gates.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1853+tests/gates/aienos-ck-stage-tests.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1854+tests/gates/aienos-crypto-boundary.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1855+tests/gates/aienos-disk-qemu.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1856+tests/gates/aienos-hw-gates.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1857+tests/gates/aienos-infer-crate.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1858+tests/gates/aienos-infer-forward.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1859+tests/gates/aienos-native-argus.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1860+tests/gates/aienos-native-capability.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1861+tests/gates/aienos-native-crypto.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1862+tests/gates/aienos-native-disk.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1863+tests/gates/aienos-native-m5.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1864+tests/gates/aienos-native-net.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1865+tests/gates/aienos-native-sig.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1866+tests/gates/aienos-omega-nvme.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1867+tests/gates/aienos-store-native.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1868+tests/gates/aienos-tcp-corpus.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1869+tests/gates/aienos-verify-all.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1870+tests/gates/aienos-zero-disk-secrets.gate gate gate-manifest aienux gate manifest; stays in aienux (omega-mv gate wiring is operator-gated)
1871+tests/gates/run.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1872+tools/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1873+tools/ck_spinlock_asm_check.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1874+tools/hwgates/fixtures/bad-R1-empty-field.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1875+tools/hwgates/fixtures/bad-R1-six-fields.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1876+tools/hwgates/fixtures/bad-R2-status.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1877+tools/hwgates/fixtures/bad-R2-tier.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1878+tools/hwgates/fixtures/bad-R3-not-whole-line.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1879+tools/hwgates/fixtures/bad-R3-physical-pass-no-receipt.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1880+tools/hwgates/fixtures/bad-R3-receipt-lacks-line.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1881+tools/hwgates/fixtures/bad-R3-receipt-missing.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1882+tools/hwgates/fixtures/bad-R3-status-differs.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1883+tools/hwgates/fixtures/bad-R4-notrun-with-receipt.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1884+tools/hwgates/fixtures/bad-R5-no-physical-row.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1885+tools/hwgates/fixtures/bad-R6-duplicate.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1886+tools/hwgates/fixtures/bad-R7-dotdot.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1887+tools/hwgates/fixtures/bad-R7-outside-evidence.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1888+tools/hwgates/fixtures/bad-R8-no-rows.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1889+tools/hwgates/fixtures/bad-R9-gate-deleted-receipt-names-it.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1890+tools/hwgates/fixtures/evidence/PREFIX.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1891+tools/hwgates/fixtures/evidence/R9.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1892+tools/hwgates/fixtures/evidence/RECEIPT.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1893+tools/hwgates/fixtures/evidence/TRAILING.txt txt doc-or-asset documentation, design asset, or repo pin; stays in aienux
1894+tools/hwgates/fixtures/good.tsv tsv data-or-fixture test vector, fixture, receipt or config; stays in aienux until its Omega consumer moves
1895+tools/hwgates/gate.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1896+tools/imac-image/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1897+tools/imac-image/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux
1898+tools/imac-image/build-efi.sh sh script-harness shell/Python/JS gate or build orchestrator; stays in aienux until replaced by pure Omega gate
1899+tools/spark-image/.crumb none retired retired crumb metadata (DRA-97); history only, never moves to omega-mv
1900+tools/spark-image/README.md md doc-or-asset documentation, design asset, or repo pin; stays in aienux

aienux/README.md

new file mode 100644
@@ -0,0 +1,50 @@
1+# aienux: the OS layer of Sovereign Intelligence (SI)
2+
3+Mirrors [gpu/README.md](../gpu/README.md) for Aienux, the operating system layer of Sovereign Intelligence (SI). Everything under `aienux/` is seeded Omega (`.om`) built by this repository's own compiler, `seed/out/omc`, plus the provenance tables describing what moved and what has not yet been rewritten in Omega.
4+
5+The OS layer is moving here from Aienux (`https://interplane.io/drakestapleton/aienux`, `rad:z2Q6ob2gL6Qo5oUMpyehukayVF7mN`) one piece at a time. **Only pure Omega moves in**: C, assembly, Rust, Python, shell and other files are rewritten in Omega first, or stay in Aienux and are listed in `aienux/NOT-YET-OMEGA.tsv`.
6+
7+## Layout
8+
9+| Path | Contents |
10+| --- | --- |
11+| `aienux/net/tcp/` | Native TCP/IPv4/ARP/Ethernet stack (`tcp.om`, `tcpd.om`, `link.om`, `peer.om`, `corpus.om`). |
12+| `aienux/net/rtl8127/` | Native RTL8127 Ethernet driver (`rtl8127-omega`, `f53059a181a2`). |
13+| `aienux/supervisor/` | Native OS service supervisor replacing systemd (`spark-supervisor`, `60c0c046b629`). |
14+| `aienux/connector/` | Sovereign verification connector and runner (`spark-connector`, `f9b6d0b500d7`). |
15+| `aienux/disk/` | Native NVMe protocol engine, transport, CLI and test drivers (`omega_nvme*.om`). |
16+| `aienux/allen/` | Pure-Omega bare-metal UEFI graphical UI (`surface.om`, `paint.om`, `font*.om`, `look-*.om`, `scene*.om`, `efi-main.om`), bare-metal TCP/TLS/HTTP (`net.om`, `http.om`, `tls*.om`), runtime/memory/session/courier/intent/application, and `.om` test suites. |
17+| `aienux/platform/` | Platform telemetry and readback units (`readback.om`, `unit.om`). |
18+| `aienux/kernel/x86/` | Native x86-64 `.om` kernel model and tool units (`llama.om`, `arithmetic.om`, `system.om`, `text.om`). |
19+| `aienux/lm1b/` | Seeded `.om` Llama-1B runner and SHA-256 (`lm1b.om`, `lm1b.in.om`, `sha256.om`). |
20+| `aienux/tools/` | Seeded `.om` GPT/FAT32 UEFI image writers (`spark-image.om`, `imac-image.om`) and hardware-gate checker (`hwgates.om`). |
21+| `aienux/atlas/` | Pure-Omega Stage-0 boot verifier and SHA-256 contract engine (converted from `atlas`, `10b8ddfd6cbf`, 3 `.om` files). |
22+| `aienux/pi-register/` | Pure-Omega service registry parser, conflict detector and renderer (converted from `pi-register`, `4a7954c27b2a`, 3 `.om` files). |
23+| `aienux/debugger/` | Pure-Omega continuous watchdog, metric triage and JSON-RPC dispatcher (converted from `spark-debugger`, `f35b24e0e8e8`, 3 `.om` files). |
24+| `aienux/capability/` | Pure-Omega AIENOS 64-bit generation capability authority (converted from `aienux` `native/capability/aienos_capability.{h,c}` and `crates/aienos-capability`, 2 `.om` files). |
25+| `aienux/argus/` | Pure-Omega ARGUS v1.2 event ABI, class-gated admission ring, shadow-state hard-invariant detectors, and containment state machine I1..I5 (converted from `aienux` `native/argus/`, 4 `.om` files). |
26+| `aienux/kernel/core/` | Pure-Omega Aienux kernel core: MADT/fair work-stealing scheduler, capability-gated IPC with tree revocation, and AArch64 Stage-1 48-bit 4-level page-table builder/walker with W^X & Device-NX (converted from `crates/aienos-kernel/src/{scheduler,ipc,caps,mem/pagetable}.rs`, 4 `.om` files). |
27+| `aienux/kernel/hal/` | Pure-Omega Aienux kernel HAL: ACPI/IORT SMMUv3 route parser (multi-SMMU, RMR ranges, named components), GPT/AIENOS partition discovery & single-layer NVMe write confinement, and Store key admissibility / single-transaction subject provisioning gate (converted from `native/kernel/core/acpi.{h,c}`, `native/kernel/dev/{disk_part,nvme_bind}.{h,c}`, `native/kernel/svc/{store_boot,continuity_subject_provision}.{h,c}`, 3 `.om` files). |
28+| `aienux/aegis/` | Pure-Omega AIENOS AEGIS effect-broker & policy enforcement: lexical path confinement, SHA-256 capability graph with attenuated delegation & cascading subtree revocation, length-prefixed EffectIntent & OperatorGrant cryptography, J-Space CoW Worlds, and audit-logged policy broker (converted from `crates/aienos-aegis/src/{capability,effect,world,evaluator,broker}.rs`, 2 `.om` files). |
29+| `aienux/units.tsv` | Unit table listing every composable pure-Omega unit and its ordered parts (78 units). |
30+| `aienux/units-gate.om` | Seeded-Omega compile-reproducibility gate (`OMEGA-AIENUX-UNITS`). |
31+| `aienux/NOT-YET-OMEGA.tsv` | Generated inventory of every non-Omega first-party file still in Aienux awaiting rewrite or retirement. |
32+| `aienux/import/` | How each slice came here: `git filter-repo` command, `paths.txt`, `commit-map` and `ref-map`. |
33+
34+Moved files keep their Aienux Git history: `git log --follow aienux/net/tcp/tcp.om` shows its Aienux commits. Existing receipts stay in Aienux where they were written.
35+
36+## One compiler
37+
38+Every unit here is built by `seed/out/omc`, and `aienux/units-gate.om` refuses any other compiler before it builds anything. The digest is read from `seed/out/omc.sha256`. No moved unit carries a separate compiler pin.
39+
40+## Gate
41+
42+Build and run `aienux/units-gate.om` from the repository root (OM-2 program mode, mirroring `gpu/units-gate.om`):
43+
44+```sh
45+{ printf 'om2\n'; cat seed/ng/sha256.om aienux/units-gate.om; } | seed/out/omc > aienux-units-gate
46+chmod +x aienux-units-gate
47+./aienux-units-gate seed/out/omc /tmp/aienux-units-scratch
48+```
49+
50+Wiring `aienux-units` into `tests/gates/` is a separate operator-gated change (`AGENTS.md`). Host compilation checks prove deterministic compilation with `seed/out/omc`; they are never hardware, QEMU, or kernel qualification.

aienux/UNITS.md

new file mode 100644
@@ -0,0 +1,45 @@
1+# aienux/: Pure-Omega Aienux units (step 1)
2+
3+Aienux is the operating system layer of Sovereign Intelligence (SI). Step 1 brought all 132 non-evidence pure-Omega (`.om`) files from canonical Aienux (`rad:z2Q6ob2gL6Qo5oUMpyehukayVF7mN`) main `1f12818d06ab0eb89cd592f83e13197477b36c07` into `omega-mv` with their Git history (22 commits). Command and maps: `aienux/import/step1-om/`.
4+
5+| Aienux path | Here | Files | What |
6+| --- | --- | ---: | --- |
7+| `native/net/tcp/*.om` | `aienux/net/tcp/` | 5 | Native Ethernet/ARP/IPv4/TCP stack, guest driver, impairment relay, peer and corpus |
8+| `native/disk/**/*.om` | `aienux/disk/` | 6 | Native NVMe protocol engine, transport, CLI and tests |
9+| `native/omega/allen/**/*.om` | `aienux/allen/` | 109 | Bare-metal UEFI graphical UI (`surface`, `paint`, `font`, `look-*`, `scene*`, `efi-main`), bare-metal TCP/TLS/HTTP, runtime/memory/courier/application and `.om` test suites |
10+| `native/omega/platform/*.om` | `aienux/platform/` | 2 | Platform readback units |
11+| `native/kernel/x86/**/*.om` | `aienux/kernel/x86/` | 4 | Native x86-64 kernel model (`llama.om`) and tool units |
12+| `native/om/lm1b/*.om` | `aienux/lm1b/` | 3 | Seeded Llama-1B runner (`lm1b.om`, `lm1b.in.om`, `sha256.om`) |
13+| `tools/{spark-image,imac-image,hwgates}/*.om` | `aienux/tools/` | 3 | GPT/FAT32 UEFI image writers and hardware-gate register checker |
14+
15+One additional 1-line Omega directive file, `aienux/allen/target-x86efi.om` (`target x86efi`), was added so the bare-metal UEFI firmware unit `allen_fw` composes directly through `aienux/units.tsv` with no shell wrapper.
16+
17+## The units and their gate
18+
19+`aienux/units.tsv` lists **78 units** (`NAME` followed by ordered `.om` parts, single spaces):
20+
21+- 48 core Aienux units (`tcp_*` 4, `nvme_*` 4, `x86_*` 4, `lm1b` 1, `platform_unit` 1, `spark_image`/`imac_image`/`hwgates` 3, `allen_fw` `target x86efi` + `allen_main` + `allen_provider` + `allen_stdio_overflow` + 27 `allen_test_*` = 31)
22+- 19 OS-layer sibling units from `rtl8127-omega` (`rtl8127_probe`, `rtl8127_driver`), `spark-supervisor` (`aien_supervise`, `aien_supervise_root`, `aien_watch`, `supervisor_tests_load`), and `spark-connector` (`connector_signer`, `connector_celldrv`, plus 11 standalone gate/runner units).
23+- 6 converted pure-Omega OS-layer units (9 `.om` files): `atlas_main`/`atlas_test` (`aienux/atlas/`), `pi_register_main`/`pi_register_test` (`aienux/pi-register/`), and `debugger_main`/`debugger_test` (`aienux/debugger/`).
24+- 5 converted pure-Omega kernel/security units: `capability_test` (`aienux/capability/`), `argus_test` (`aienux/argus/`), `kernel_core_test` (`aienux/kernel/core/`), `kernel_hal_test` (`aienux/kernel/hal/`), and `aegis_test` (`aienux/aegis/`).
25+
26+Remaining non-Omega files from the three OS sibling repos (64 files) are listed in `aienux/NOT-YET-OMEGA-EXTRAS.tsv`; their import records are under `aienux/import/{rtl8127-omega,spark-supervisor,spark-connector}/`.
27+
28+`aienux/units-gate.om` (`OMEGA-AIENUX-UNITS`) mirrors `gpu/units-gate.om`: it refuses any compiler whose SHA-256 differs from `seed/out/omc.sha256` (exit 69), composes each row in `aienux/units.tsv`, compiles it twice, and requires exit 0, empty stderr and identical output bytes, plus catches the `omc-plus-one` negative control. Every hardware row stays `NOT_RUN`.
29+
30+The gate also runs every unit named in [`aienux/units-run.tsv`](units-run.tsv) (`tests/gates/run.sh aienux-units`): a `run` row must exit 0 from the repository root with stdin `/dev/null`, write no stderr, and end its stdout with the recorded line; a `not_run` row is built only, printed `NOT_RUN` with its reason and never counted as a pass. Every `*_test` unit needs a row. Today: 8 run, 0 not_run. Units whose names do not end in `_test` (fixtures, harness parts, and test-named units such as `allen_test_*`, `cortex_tests_*`, `rsi_tests_*`, `aien_train_tests_*` or `omega_bridge_tests_*`) need no row and stay compile-only unless a row names them.
31+
32+This gate verifies deterministic compilation with `seed/out/omc`. It does not run QEMU, boot firmware, or execute the behavioral oracles that still live in Aienux as C, Rust, shell, or Python.
33+
34+## Not here yet
35+
36+Every non-Omega first-party file outside `evidence/` and `vendor/` at Aienux `1f12818d` stayed in Aienux and is indexed in `aienux/NOT-YET-OMEGA.tsv` (1,897 files):
37+
38+- `c-asm-legacy` (618): frozen C/assembly kernel (`native/kernel/`), drivers (`native/disk/*.c`, `native/net/`), boot entry (`native/boot/`), ARGUS (`native/argus/`), Store (`native/store/`), capability ABI (`native/capability/`), and Makefiles.
39+- `rust-legacy` (307): older Rust kernel and tools under `crates/`.
40+- `script-harness` (229): shell, Python and JS gate/build harnesses.
41+- `gate-manifest` (25): Aienux gate manifests.
42+- `data-or-fixture` (344), `doc-or-asset` (277): fixtures, test vectors, docs, design assets and pins.
43+- `retired` (97): retired crumb metadata (DRA-97).
44+
45+Rewriting the frozen C kernel (`native/kernel/`) in pure Omega into `aienux/kernel/` is the next step once `seed/omc/omc.om` gains the required bare-metal kernel primitives (system registers, barriers, exception vector table and `eret`, FR-8).

aienux/aegis/aegis.om

new file mode 100644
@@ -0,0 +1,970 @@
1+note SPDX-License-Identifier: Apache-2.0
2+note aienux/aegis/aegis.om: Pure-Omega AIENOS AEGIS Capability Graph, Effect Intent,
3+note Operator Grant, J-Space World, Policy Evaluator, and Effect Broker.
4+note Converted from aienux crates/aienos-aegis/src/{capability,effect,world,evaluator,broker}.rs.
5+note Compose with: si/directives/om2.om om/tls/sha2.om aienux/aegis/aegis.om ...
6+
7+const AEGIS_MAX_CAPS ulong 32
8+const AEGIS_MAX_DELEG_DEPTH uint 4
9+const AEGIS_MAX_STR ulong 64
10+const AEGIS_MAX_WORLDS ulong 8
11+const AEGIS_MAX_AUDIT ulong 64
12+
13+const AEGIS_SCOPE_SYSADMIN uchar 1
14+const AEGIS_SCOPE_FS uchar 2
15+const AEGIS_SCOPE_NET uchar 3
16+const AEGIS_SCOPE_DEVICE uchar 4
17+const AEGIS_SCOPE_WORLD uchar 5
18+const AEGIS_SCOPE_STANDING_FETCH uchar 6
19+const AEGIS_SCOPE_CUSTOM uchar 7
20+
21+const AEGIS_DEC_APPROVED uchar 1
22+const AEGIS_DEC_REQUIRES_OP uchar 2
23+const AEGIS_DEC_REJECTED uchar 3
24+
25+const AEGIS_OK int 0
26+const AEGIS_ERR_NOT_FOUND int -1
27+const AEGIS_ERR_BAD_SIG int -2
28+const AEGIS_ERR_REVOKED int -3
29+const AEGIS_ERR_EXPIRED int -4
30+const AEGIS_ERR_HOLDER int -5
31+const AEGIS_ERR_SCOPE int -6
32+const AEGIS_ERR_DEPTH int -7
33+const AEGIS_ERR_MISSING_GRANT int -8
34+const AEGIS_ERR_GRANT_INTENT int -9
35+const AEGIS_ERR_GRANT_SIG int -10
36+const AEGIS_ERR_WORLD_STATE int -11
37+const AEGIS_ERR_CAPACITY int -12
38+
39+const AEGIS_WORLD_NONE uchar 0
40+const AEGIS_WORLD_ACTIVE uchar 1
41+const AEGIS_WORLD_COMMITTED uchar 2
42+const AEGIS_WORLD_ROLLEDBACK uchar 3
43+
44+text aegis_dom_cap "AIENOS_CAP_V1"
45+text aegis_dom_intent "AIENOS_INTENT_V1"
46+text aegis_dom_grant "AIENOS_GRANT_V1"
47+text aegis_act_fs_read "fs.read"
48+text aegis_act_fs_write "fs.write"
49+text aegis_act_fs_delete "fs.delete"
50+text aegis_act_net_fetch "net.fetch"
51+text aegis_act_net_read "net.read"
52+text aegis_act_net_connect "net.connect"
53+text aegis_act_net_send "net.send"
54+text aegis_act_dev_read "device.read"
55+text aegis_act_dev_write "device.write"
56+text aegis_act_hw_inspect "hardware.inspect"
57+text aegis_act_disk_format "disk.format"
58+text aegis_act_git_pub "git.publish"
59+text aegis_act_code_pub "code.publish"
60+text aegis_act_kern_rep "kernel.replace"
61+text aegis_act_sys_inst "system.install"
62+text aegis_act_cred_mod "credential.modify"
63+text aegis_act_fin_spend "finance.spend"
64+text aegis_pfx_device "device."
65+text aegis_pfx_world "world."
66+
67+global aegis_op_secret uchar 32
68+global aegis_cap_secret uchar 32
69+
70+global aegis_cap_used uchar 32
71+global aegis_cap_revoked uchar 32
72+global aegis_cap_id uchar 512
73+global aegis_cap_parent int 32
74+global aegis_cap_depth uint 32
75+global aegis_cap_holder ulong 32
76+global aegis_cap_scope uchar 32
77+global aegis_cap_ro uchar 32
78+global aegis_cap_port uint 32
79+global aegis_cap_exp ulong 32
80+global aegis_cap_str uchar 2048
81+global aegis_cap_slen ulong 32
82+global aegis_cap_str2 uchar 2048
83+global aegis_cap_s2len ulong 32
84+global aegis_cap_sig uchar 1024
85+
86+global aegis_w_status uchar 8
87+global aegis_w_id ulong 8
88+global aegis_w_deltas uint 8
89+global aegis_w_writes uint 8
90+global aegis_w_deletes uint 8
91+
92+global aegis_audit_cnt ulong 1
93+global aegis_audit_dec uchar 64
94+global aegis_audit_rc int 64
95+global aegis_audit_exec uchar 64
96+global aegis_audit_ts ulong 64
97+global aegis_audit_iid uchar 1024
98+
99+global aegis_cur_iid uchar 16
100+global aegis_cur_grant_iid uchar 16
101+global aegis_cur_grant_sig uchar 32
102+note Grant meta: 0=present, 1=granted_at_utc, 2=op_id_len, 3=mutant_skip_grant
103+global aegis_cur_grant_meta ulong 4
104+global aegis_cur_grant_op uchar 64
105+
106+note Last eval result: 0=decision, 1=reason_code (cast via long)
107+global aegis_last_dec uchar 1
108+global aegis_last_rc int 1
109+
110+note Dispatch context: 0=world_id, 1=is_reversible, 2=now_utc, 3=net_port
111+global aegis_dctx ulong 4
112+
113+note Scratch buffers for hashing (never passed as globals)
114+global aegis_tmp_s1 uchar 64
115+global aegis_tmp_s2 uchar 64
116+global aegis_tmp_lens ulong 2
117+
118+fn aegis_dispatch_ctx world_id ulong is_rev ulong now_utc ulong port ulong to void
119+put aegis_dctx 0 world_id
120+put aegis_dctx 1 is_rev
121+put aegis_dctx 2 now_utc
122+put aegis_dctx 3 port
123+end
124+
125+fn aegis_reset op_sec view uchar 32 cap_sec view uchar 32 to void
126+for i ulong 32
127+put aegis_op_secret i get op_sec i
128+put aegis_cap_secret i get cap_sec i
129+put aegis_cap_used i 0
130+put aegis_cap_revoked i 0
131+put aegis_cap_parent i -1
132+put aegis_cap_depth i 0
133+put aegis_cap_holder i 0
134+put aegis_cap_scope i 0
135+put aegis_cap_ro i 0
136+put aegis_cap_port i 0
137+put aegis_cap_exp i 0
138+put aegis_cap_slen i 0
139+put aegis_cap_s2len i 0
140+end
141+for w ulong 8
142+put aegis_w_status w AEGIS_WORLD_NONE
143+put aegis_w_id w 0
144+put aegis_w_deltas w 0
145+put aegis_w_writes w 0
146+put aegis_w_deletes w 0
147+end
148+put aegis_audit_cnt 0 0
149+put aegis_last_dec 0 0
150+put aegis_last_rc 0 0
151+for g ulong 4
152+put aegis_cur_grant_meta g 0
153+put aegis_dctx g 0
154+end
155+end
156+
157+fn aegis_set_mutant_skip_grant v ulong to void
158+put aegis_cur_grant_meta 3 v
159+end
160+
161+note ---- Byte/String & Lexical Path Helpers ----
162+
163+fn aegis_str_eq a view uchar * b view uchar * to bool
164+if ne len a len b
165+ret false
166+end
167+n = len a
168+i = ulong 0
169+while lt i n bound 256
170+if ne get a i get b i
171+ret false
172+end
173+i = add i 1
174+end
175+ret true
176+end
177+
178+fn aegis_str_starts a view uchar * pfx view uchar * to bool
179+if lt len a len pfx
180+ret false
181+end
182+n = len pfx
183+i = ulong 0
184+while lt i n bound 256
185+if ne get a i get pfx i
186+ret false
187+end
188+i = add i 1
189+end
190+ret true
191+end
192+
193+fn aegis_has_dotdot p view uchar * to bool
194+n = len p
195+i = ulong 0
196+while lt i n bound 256
197+if eq get p i 46
198+if lt add i 1 n
199+if eq get p add i 1 46
200+prev_ok = eq i 0
201+if gt i 0
202+if eq get p sub i 1 47
203+prev_ok = true
204+end
205+end
206+next_ok = eq add i 2 n
207+if lt add i 2 n
208+if eq get p add i 2 47
209+next_ok = true
210+end
211+end
212+if and prev_ok next_ok
213+ret true
214+end
215+end
216+end
217+end
218+i = add i 1
219+end
220+ret false
221+end
222+
223+note Lexical absolute path confinement (mirrors capability.rs path_within).
224+note Both path and prefix must start with '/', contain no '..' component,
225+note and path must equal prefix or be inside prefix/ (prefix "/" matches any absolute path).
226+fn aegis_path_within path view uchar * prefix view uchar * to bool
227+plen = len path
228+xlen = len prefix
229+if or eq plen 0 eq xlen 0
230+ret false
231+end
232+if or ne get path 0 47 ne get prefix 0 47
233+ret false
234+end
235+if or aegis_has_dotdot path aegis_has_dotdot prefix
236+ret false
237+end
238+if and eq xlen 1 eq get prefix 0 47
239+ret true
240+end
241+note Trim trailing '/' on prefix for comparison
242+ex = xlen
243+while and gt ex 1 eq get prefix sub ex 1 47 bound 64
244+ex = sub ex 1
245+end
246+if lt plen ex
247+ret false
248+end
249+i = ulong 0
250+while lt i ex bound 256
251+if ne get path i get prefix i
252+ret false
253+end
254+i = add i 1
255+end
256+if eq plen ex
257+ret true
258+end
259+ret eq get path ex 47
260+end
261+
262+note ---- SHA-256 Encoding Helpers ----
263+
264+fn aegis_put_be64 buf edit uchar 8 v ulong to void
265+put buf 0 uchar and shr v 56 0xff
266+put buf 1 uchar and shr v 48 0xff
267+put buf 2 uchar and shr v 40 0xff
268+put buf 3 uchar and shr v 32 0xff
269+put buf 4 uchar and shr v 24 0xff
270+put buf 5 uchar and shr v 16 0xff
271+put buf 6 uchar and shr v 8 0xff
272+put buf 7 uchar and v 0xff
273+end
274+
275+fn aegis_sha_u64 c edit ulong 40 v ulong to void
276+b = new uchar 8 0
277+aegis_put_be64 b v
278+sha256_update c b
279+end
280+
281+fn aegis_sha_field c edit ulong 40 f view uchar * to void
282+aegis_sha_u64 c len f
283+if gt len f 0
284+sha256_update c f
285+end
286+end
287+
288+fn aegis_copy_cap_s1 slot ulong dst edit uchar 64 to ulong
289+n = get aegis_cap_slen slot
290+base = mul slot AEGIS_MAX_STR
291+i = ulong 0
292+while lt i n bound 64
293+put dst i get aegis_cap_str add base i
294+i = add i 1
295+end
296+ret n
297+end
298+
299+fn aegis_copy_cap_s2 slot ulong dst edit uchar 64 to ulong
300+n = get aegis_cap_s2len slot
301+base = mul slot AEGIS_MAX_STR
302+i = ulong 0
303+while lt i n bound 64
304+put dst i get aegis_cap_str2 add base i
305+i = add i 1
306+end
307+ret n
308+end
309+
310+note Compute 32-byte SHA-256 signature for capability at slot.
311+fn aegis_cap_compute_sig slot ulong out_sig edit uchar 32 to void
312+c = new ulong 40 0
313+sec = new uchar 32 0
314+s1 = new uchar 64 0
315+s2 = new uchar 64 0
316+for i ulong 32
317+put sec i get aegis_cap_secret i
318+end
319+sha256_init c
320+sha256_update c aegis_dom_cap
321+sha256_update c sec
322+aegis_sha_u64 c get aegis_cap_holder slot
323+aegis_sha_u64 c ulong get aegis_cap_scope slot
324+aegis_sha_u64 c ulong get aegis_cap_ro slot
325+aegis_sha_u64 c ulong get aegis_cap_port slot
326+aegis_sha_u64 c get aegis_cap_exp slot
327+aegis_sha_u64 c ulong get aegis_cap_depth slot
328+n1 = aegis_copy_cap_s1 slot s1
329+aegis_sha_field c part s1 0 n1
330+n2 = aegis_copy_cap_s2 slot s2
331+aegis_sha_field c part s2 0 n2
332+sha256_final c out_sig
333+end
334+
335+fn aegis_eq32 a view uchar 32 b view uchar 32 to bool
336+diff = uchar 0
337+for i ulong 32
338+diff = or diff xor get a i get b i
339+end
340+ret eq diff 0
341+end
342+
343+fn aegis_eq16 a view uchar 16 b view uchar 16 to bool
344+diff = uchar 0
345+for i ulong 16
346+diff = or diff xor get a i get b i
347+end
348+ret eq diff 0
349+end
350+
351+note ---- Scope Attenuation & Action Authorization ----
352+
353+fn aegis_scope_contains parent_slot ulong child_scope uchar child_ro uchar child_port uint c1 view uchar * to bool
354+ps = get aegis_cap_scope parent_slot
355+if eq ps AEGIS_SCOPE_SYSADMIN
356+ret true
357+end
358+if ne ps child_scope
359+ret false
360+end
361+p1 = new uchar 64 0
362+pn1 = aegis_copy_cap_s1 parent_slot p1
363+pro = get aegis_cap_ro parent_slot
364+pport = get aegis_cap_port parent_slot
365+if eq ps AEGIS_SCOPE_FS
366+if not aegis_path_within c1 part p1 0 pn1
367+ret false
368+end
369+if and ne pro 0 eq child_ro 0
370+ret false
371+end
372+ret true
373+end
374+if eq ps AEGIS_SCOPE_STANDING_FETCH
375+if and eq pn1 1 eq get p1 0 42
376+ret true
377+end
378+ret aegis_str_eq part p1 0 pn1 c1
379+end
380+if eq ps AEGIS_SCOPE_NET
381+host_ok = false
382+if and eq pn1 1 eq get p1 0 42
383+host_ok = true
384+else
385+host_ok = aegis_str_eq part p1 0 pn1 c1
386+end
387+port_ok = or eq pport 0 eq pport child_port
388+ret and host_ok port_ok
389+end
390+if eq ps AEGIS_SCOPE_DEVICE
391+if not aegis_str_eq part p1 0 pn1 c1
392+ret false
393+end
394+if and ne pro 0 eq child_ro 0
395+ret false
396+end
397+ret true
398+end
399+if eq ps AEGIS_SCOPE_WORLD
400+ret le child_port pport
401+end
402+ret false
403+end
404+
405+note ---- Capability Graph Operations ----
406+
407+fn aegis_find_free_cap to long
408+i = ulong 0
409+while lt i AEGIS_MAX_CAPS bound 32
410+if eq get aegis_cap_used i 0
411+ret long i
412+end
413+i = add i 1
414+end
415+ret -1
416+end
417+
418+fn aegis_store_cap_fields slot ulong holder ulong scope uchar ro uchar port uint exp ulong to void
419+put aegis_cap_used slot 1
420+put aegis_cap_revoked slot 0
421+put aegis_cap_holder slot holder
422+put aegis_cap_scope slot scope
423+put aegis_cap_ro slot ro
424+put aegis_cap_port slot port
425+put aegis_cap_exp slot exp
426+end
427+
428+fn aegis_store_cap_strs slot ulong s1 view uchar * s2 view uchar * to void
429+n1 = len s1
430+if gt n1 AEGIS_MAX_STR
431+n1 = AEGIS_MAX_STR
432+end
433+put aegis_cap_slen slot n1
434+b1 = mul slot AEGIS_MAX_STR
435+i = ulong 0
436+while lt i n1 bound 64
437+put aegis_cap_str add b1 i get s1 i
438+i = add i 1
439+end
440+n2 = len s2
441+if gt n2 AEGIS_MAX_STR
442+n2 = AEGIS_MAX_STR
443+end
444+put aegis_cap_s2len slot n2
445+b2 = mul slot AEGIS_MAX_STR
446+j = ulong 0
447+while lt j n2 bound 64
448+put aegis_cap_str2 add b2 j get s2 j
449+j = add j 1
450+end
451+end
452+
453+fn aegis_finalize_cap slot ulong to void
454+sig = new uchar 32 0
455+aegis_cap_compute_sig slot sig
456+sb = mul slot 32
457+ib = mul slot 16
458+for i ulong 32
459+put aegis_cap_sig add sb i get sig i
460+end
461+for k ulong 16
462+put aegis_cap_id add ib k get sig k
463+end
464+end
465+
466+note Issue a root capability token. Returns slot index (0..31) or negative AEGIS_ERR_*.
467+fn aegis_cap_issue holder ulong scope uchar ro uchar port uint exp ulong to int
468+s = aegis_find_free_cap
469+if lt s 0
470+ret AEGIS_ERR_CAPACITY
471+end
472+slot = ulong s
473+put aegis_cap_parent slot -1
474+put aegis_cap_depth slot 0
475+aegis_store_cap_fields slot holder scope ro port exp
476+put aegis_cap_slen slot 0
477+put aegis_cap_s2len slot 0
478+aegis_finalize_cap slot
479+ret int slot
480+end
481+
482+fn aegis_cap_set_strings slot ulong s1 view uchar * s2 view uchar * to void
483+aegis_store_cap_strs slot s1 s2
484+aegis_finalize_cap slot
485+end
486+
487+fn aegis_cap_validate slot ulong now_utc ulong to int
488+if ge slot AEGIS_MAX_CAPS
489+ret AEGIS_ERR_NOT_FOUND
490+end
491+if eq get aegis_cap_used slot 0
492+ret AEGIS_ERR_NOT_FOUND
493+end
494+if ne get aegis_cap_revoked slot 0
495+ret AEGIS_ERR_REVOKED
496+end
497+exp = get aegis_cap_exp slot
498+if and ne exp 0 gt now_utc exp
499+ret AEGIS_ERR_EXPIRED
500+end
501+want = new uchar 32 0
502+have = new uchar 32 0
503+aegis_cap_compute_sig slot want
504+sb = mul slot 32
505+for i ulong 32
506+put have i get aegis_cap_sig add sb i
507+end
508+if not aegis_eq32 want have
509+ret AEGIS_ERR_BAD_SIG
510+end
511+ret AEGIS_OK
512+end
513+
514+note Delegate an attenuated capability from parent_slot to new_holder.
515+note Call aegis_set_tmp_strs(c1, c2) before calling, or use aegis_cap_delegate_strs.
516+fn aegis_set_tmp_strs s1 view uchar * s2 view uchar * to void
517+for z ulong 64
518+put aegis_tmp_s1 z 0
519+put aegis_tmp_s2 z 0
520+end
521+n1 = len s1
522+if gt n1 64
523+n1 = ulong 64
524+end
525+i = ulong 0
526+while lt i n1 bound 64
527+put aegis_tmp_s1 i get s1 i
528+i = add i 1
529+end
530+n2 = len s2
531+if gt n2 64
532+n2 = ulong 64
533+end
534+j = ulong 0
535+while lt j n2 bound 64
536+put aegis_tmp_s2 j get s2 j
537+j = add j 1
538+end
539+end
540+
541+fn aegis_cap_delegate parent_slot ulong new_holder ulong scope uchar ro uchar port uint exp ulong to int
542+vrc = aegis_cap_validate parent_slot 0
543+if ne vrc AEGIS_OK
544+ret vrc
545+end
546+pdepth = get aegis_cap_depth parent_slot
547+if ge pdepth AEGIS_MAX_DELEG_DEPTH
548+ret AEGIS_ERR_DEPTH
549+end
550+note Expiry cannot exceed parent expiry when parent has one
551+pexp = get aegis_cap_exp parent_slot
552+if ne pexp 0
553+if or eq exp 0 gt exp pexp
554+ret AEGIS_ERR_SCOPE
555+end
556+end
557+s = aegis_find_free_cap
558+if lt s 0
559+ret AEGIS_ERR_CAPACITY
560+end
561+slot = ulong s
562+put aegis_cap_parent slot int parent_slot
563+put aegis_cap_depth slot add pdepth 1
564+aegis_store_cap_fields slot new_holder scope ro port exp
565+put aegis_cap_slen slot 0
566+put aegis_cap_s2len slot 0
567+aegis_finalize_cap slot
568+ret int slot
569+end
570+
571+note Delegate with string scope (FS path, host, device) and strict attenuation check.
572+fn aegis_cap_delegate_scoped parent_slot ulong new_holder ulong scope uchar ro uchar c1 view uchar * to int
573+vrc = aegis_cap_validate parent_slot 0
574+if ne vrc AEGIS_OK
575+ret vrc
576+end
577+pdepth = get aegis_cap_depth parent_slot
578+if ge pdepth AEGIS_MAX_DELEG_DEPTH
579+ret AEGIS_ERR_DEPTH
580+end
581+if not aegis_scope_contains parent_slot scope ro 0 c1
582+ret AEGIS_ERR_SCOPE
583+end
584+s = aegis_find_free_cap
585+if lt s 0
586+ret AEGIS_ERR_CAPACITY
587+end
588+slot = ulong s
589+put aegis_cap_parent slot int parent_slot
590+put aegis_cap_depth slot add pdepth 1
591+aegis_store_cap_fields slot new_holder scope ro 0 get aegis_cap_exp parent_slot
592+empty = new uchar 1 0
593+aegis_store_cap_strs slot c1 part empty 0 0
594+aegis_finalize_cap slot
595+ret int slot
596+end
597+
598+note Cascading subtree revocation: revoking slot revokes all descendants.
599+fn aegis_cap_revoke slot ulong to int
600+if ge slot AEGIS_MAX_CAPS
601+ret AEGIS_ERR_NOT_FOUND
602+end
603+if eq get aegis_cap_used slot 0
604+ret AEGIS_ERR_NOT_FOUND
605+end
606+put aegis_cap_revoked slot 1
607+note Fixed-point pass over max 32 tokens (depth <= 4, so 5 passes always converge)
608+pass = ulong 0
609+while lt pass 6 bound 6
610+i = ulong 0
611+while lt i AEGIS_MAX_CAPS bound 32
612+if and ne get aegis_cap_used i 0 eq get aegis_cap_revoked i 0
613+p = get aegis_cap_parent i
614+if ge p 0
615+if ne get aegis_cap_revoked ulong p 0
616+put aegis_cap_revoked i 1
617+end
618+end
619+end
620+i = add i 1
621+end
622+pass = add pass 1
623+end
624+ret AEGIS_OK
625+end
626+
627+note ---- Effect Intent ID & Operator Grant Cryptography ----
628+
629+note Compute deterministic 16-byte EffectIntent ID with length-prefixed parameter boundaries.
630+fn aegis_compute_intent_id agent_id ulong cap_slot ulong act view uchar * arg view uchar * to void
631+c = new ulong 40 0
632+dig = new uchar 32 0
633+cid = new uchar 16 0
634+if lt cap_slot AEGIS_MAX_CAPS
635+cb = mul cap_slot 16
636+for i ulong 16
637+put cid i get aegis_cap_id add cb i
638+end
639+end
640+sha256_init c
641+sha256_update c aegis_dom_intent
642+aegis_sha_u64 c agent_id
643+aegis_sha_field c act
644+sha256_update c cid
645+aegis_sha_field c arg
646+sha256_final c dig
647+for k ulong 16
648+put aegis_cur_iid k get dig k
649+end
650+end
651+
652+note Compute 16-byte intent ID for an explicit (key, value) pair to prove boundary separation.
653+fn aegis_intent_hash_kv agent_id ulong pkey view uchar * pval view uchar * to void
654+c = new ulong 40 0
655+dig = new uchar 32 0
656+sha256_init c
657+sha256_update c aegis_dom_intent
658+aegis_sha_u64 c agent_id
659+aegis_sha_field c pkey
660+aegis_sha_field c pval
661+sha256_final c dig
662+for k ulong 16
663+put aegis_cur_iid k get dig k
664+end
665+end
666+
667+fn aegis_grant_compute_sig iid view uchar 16 op_id view uchar * ts ulong sec view uchar 32 out_sig edit uchar 32 to void
668+c = new ulong 40 0
669+sha256_init c
670+sha256_update c aegis_dom_grant
671+sha256_update c sec
672+sha256_update c iid
673+aegis_sha_field c op_id
674+aegis_sha_u64 c ts
675+sha256_final c out_sig
676+end
677+
678+fn aegis_grant_clear to void
679+put aegis_cur_grant_meta 0 0
680+end
681+
682+note Issue an operator grant for the current intent ID (aegis_cur_iid) using the given secret.
683+fn aegis_grant_issue_with_secret op_id view uchar * ts ulong sec view uchar 32 to void
684+iid = new uchar 16 0
685+sig = new uchar 32 0
686+for i ulong 16
687+put iid i get aegis_cur_iid i
688+put aegis_cur_grant_iid i get aegis_cur_iid i
689+end
690+aegis_grant_compute_sig iid op_id ts sec sig
691+for j ulong 32
692+put aegis_cur_grant_sig j get sig j
693+end
694+n = len op_id
695+if gt n 64
696+n = ulong 64
697+end
698+k = ulong 0
699+while lt k n bound 64
700+put aegis_cur_grant_op k get op_id k
701+k = add k 1
702+end
703+put aegis_cur_grant_meta 0 1
704+put aegis_cur_grant_meta 1 ts
705+put aegis_cur_grant_meta 2 n
706+end
707+
708+fn aegis_grant_verify_current to int
709+if eq get aegis_cur_grant_meta 0 0
710+ret AEGIS_ERR_MISSING_GRANT
711+end
712+iid = new uchar 16 0
713+giid = new uchar 16 0
714+for i ulong 16
715+put iid i get aegis_cur_iid i
716+put giid i get aegis_cur_grant_iid i
717+end
718+if not aegis_eq16 iid giid
719+ret AEGIS_ERR_GRANT_INTENT
720+end
721+op_buf = new uchar 64 0
722+oplen = get aegis_cur_grant_meta 2
723+k = ulong 0
724+while lt k oplen bound 64
725+put op_buf k get aegis_cur_grant_op k
726+k = add k 1
727+end
728+sec = new uchar 32 0
729+have = new uchar 32 0
730+want = new uchar 32 0
731+for s ulong 32
732+put sec s get aegis_op_secret s
733+put have s get aegis_cur_grant_sig s
734+end
735+aegis_grant_compute_sig giid part op_buf 0 oplen get aegis_cur_grant_meta 1 sec want
736+if not aegis_eq32 want have
737+ret AEGIS_ERR_GRANT_SIG
738+end
739+ret AEGIS_OK
740+end
741+
742+note ---- J-Space Copy-on-Write Worlds ----
743+
744+fn aegis_world_create wid ulong to int
745+i = ulong 0
746+while lt i AEGIS_MAX_WORLDS bound 8
747+if eq get aegis_w_status i AEGIS_WORLD_NONE
748+put aegis_w_status i AEGIS_WORLD_ACTIVE
749+put aegis_w_id i wid
750+put aegis_w_deltas i 0
751+put aegis_w_writes i 0
752+put aegis_w_deletes i 0
753+ret int i
754+end
755+i = add i 1
756+end
757+ret AEGIS_ERR_CAPACITY
758+end
759+
760+fn aegis_world_find wid ulong to int
761+i = ulong 0
762+while lt i AEGIS_MAX_WORLDS bound 8
763+if and ne get aegis_w_status i AEGIS_WORLD_NONE eq get aegis_w_id i wid
764+ret int i
765+end
766+i = add i 1
767+end
768+ret AEGIS_ERR_NOT_FOUND
769+end
770+
771+fn aegis_world_rollback wid ulong to int
772+idx = aegis_world_find wid
773+if lt idx 0
774+ret AEGIS_ERR_NOT_FOUND
775+end
776+u = ulong idx
777+put aegis_w_deltas u 0
778+put aegis_w_writes u 0
779+put aegis_w_deletes u 0
780+put aegis_w_status u AEGIS_WORLD_ROLLEDBACK
781+ret AEGIS_OK
782+end
783+
784+fn aegis_world_commit wid ulong to int
785+idx = aegis_world_find wid
786+if lt idx 0
787+ret AEGIS_ERR_NOT_FOUND
788+end
789+u = ulong idx
790+if ne get aegis_w_status u AEGIS_WORLD_ACTIVE
791+ret AEGIS_ERR_WORLD_STATE
792+end
793+put aegis_w_status u AEGIS_WORLD_COMMITTED
794+ret AEGIS_OK
795+end
796+
797+note ---- Policy Evaluator & Effect Broker ----
798+
799+fn aegis_is_high_impact act view uchar * to bool
800+if or aegis_str_eq act aegis_act_disk_format aegis_str_eq act aegis_act_fs_delete
801+ret true
802+end
803+if or aegis_str_eq act aegis_act_fs_write aegis_str_eq act aegis_act_git_pub
804+ret true
805+end
806+if or aegis_str_eq act aegis_act_code_pub aegis_str_eq act aegis_act_kern_rep
807+ret true
808+end
809+if or aegis_str_eq act aegis_act_sys_inst aegis_str_eq act aegis_act_cred_mod
810+ret true
811+end
812+ret aegis_str_eq act aegis_act_fin_spend
813+end
814+
815+fn aegis_scope_authorizes slot ulong act view uchar * arg view uchar * port uint to bool
816+sc = get aegis_cap_scope slot
817+if eq sc AEGIS_SCOPE_SYSADMIN
818+ret true
819+end
820+p1 = new uchar 64 0
821+pn1 = aegis_copy_cap_s1 slot p1
822+ro = get aegis_cap_ro slot
823+if eq sc AEGIS_SCOPE_FS
824+if aegis_str_eq act aegis_act_fs_read
825+ret aegis_path_within arg part p1 0 pn1
826+end
827+if or aegis_str_eq act aegis_act_fs_write aegis_str_eq act aegis_act_fs_delete
828+if ne ro 0
829+ret false
830+end
831+ret aegis_path_within arg part p1 0 pn1
832+end
833+ret false
834+end
835+if eq sc AEGIS_SCOPE_STANDING_FETCH
836+if or aegis_str_eq act aegis_act_net_fetch aegis_str_eq act aegis_act_net_read
837+if and eq pn1 1 eq get p1 0 42
838+ret true
839+end
840+ret aegis_str_eq part p1 0 pn1 arg
841+end
842+ret false
843+end
844+if eq sc AEGIS_SCOPE_NET
845+if or aegis_str_eq act aegis_act_net_connect aegis_str_eq act aegis_act_net_send
846+host_ok = false
847+if and eq pn1 1 eq get p1 0 42
848+host_ok = true
849+else
850+host_ok = aegis_str_eq part p1 0 pn1 arg
851+end
852+pport = get aegis_cap_port slot
853+port_ok = or eq pport 0 eq pport port
854+ret and host_ok port_ok
855+end
856+ret false
857+end
858+if eq sc AEGIS_SCOPE_DEVICE
859+if aegis_str_starts act aegis_pfx_device
860+if not aegis_str_eq part p1 0 pn1 arg
861+ret false
862+end
863+if and aegis_str_eq act aegis_act_dev_write ne ro 0
864+ret false
865+end
866+ret true
867+end
868+ret false
869+end
870+if eq sc AEGIS_SCOPE_WORLD
871+ret aegis_str_starts act aegis_pfx_world
872+end
873+ret false
874+end
875+
876+fn aegis_record_audit dec uchar rc int executed uchar ts ulong to void
877+cnt = get aegis_audit_cnt 0
878+if lt cnt AEGIS_MAX_AUDIT
879+put aegis_audit_dec cnt dec
880+put aegis_audit_rc cnt rc
881+put aegis_audit_exec cnt executed
882+put aegis_audit_ts cnt ts
883+ib = mul cnt 16
884+for k ulong 16
885+put aegis_audit_iid add ib k get aegis_cur_iid k
886+end
887+put aegis_audit_cnt 0 add cnt 1
888+end
889+put aegis_last_dec 0 dec
890+put aegis_last_rc 0 rc
891+end
892+
893+fn aegis_try_world_delta act view uchar * to bool
894+world_id = get aegis_dctx 0
895+if or eq world_id 0 eq get aegis_dctx 1 0
896+ret false
897+end
898+is_wfs = or aegis_str_eq act aegis_act_fs_write aegis_str_eq act aegis_act_fs_delete
899+if not is_wfs
900+ret false
901+end
902+widx = aegis_world_find world_id
903+if lt widx 0
904+ret false
905+end
906+wu = ulong widx
907+if ne get aegis_w_status wu AEGIS_WORLD_ACTIVE
908+ret false
909+end
910+put aegis_w_deltas wu add get aegis_w_deltas wu 1
911+if aegis_str_eq act aegis_act_fs_write
912+put aegis_w_writes wu add get aegis_w_writes wu 1
913+else
914+put aegis_w_deletes wu add get aegis_w_deletes wu 1
915+end
916+ret true
917+end
918+
919+note Evaluate and dispatch an EffectIntent through the AEGIS Broker.
920+note Uses aegis_dctx: [0]=world_id, [1]=is_reversible, [2]=now_utc, [3]=net_port.
921+note Returns AEGIS_OK if approved & executed, else negative AEGIS_ERR_*.
922+fn aegis_broker_dispatch agent_id ulong cap_slot ulong act view uchar * arg view uchar * to int
923+now_utc = get aegis_dctx 2
924+aegis_compute_intent_id agent_id cap_slot act arg
925+note Step 1: Validate capability token
926+vrc = aegis_cap_validate cap_slot now_utc
927+if ne vrc AEGIS_OK
928+aegis_record_audit AEGIS_DEC_REJECTED vrc 0 now_utc
929+ret vrc
930+end
931+note Step 2: Validate holder == proposing agent
932+if ne get aegis_cap_holder cap_slot agent_id
933+aegis_record_audit AEGIS_DEC_REJECTED AEGIS_ERR_HOLDER 0 now_utc
934+ret AEGIS_ERR_HOLDER
935+end
936+note Step 3: Scope authorizes action + target arg
937+if not aegis_scope_authorizes cap_slot act arg uint get aegis_dctx 3
938+aegis_record_audit AEGIS_DEC_REJECTED AEGIS_ERR_SCOPE 0 now_utc
939+ret AEGIS_ERR_SCOPE
940+end
941+note Step 4: Active broker-owned World delta fast-path for reversible fs.write/fs.delete
942+if aegis_try_world_delta act
943+aegis_record_audit AEGIS_DEC_APPROVED AEGIS_OK 1 now_utc
944+ret AEGIS_OK
945+end
946+note Step 5: StandingFetch / read-only autonomous path when not high-impact
947+is_stand = eq get aegis_cap_scope cap_slot AEGIS_SCOPE_STANDING_FETCH
948+is_ro_act = or aegis_str_eq act aegis_act_fs_read aegis_str_eq act aegis_act_hw_inspect
949+if and or is_stand is_ro_act not aegis_is_high_impact act
950+aegis_record_audit AEGIS_DEC_APPROVED AEGIS_OK 1 now_utc
951+ret AEGIS_OK
952+end
953+note Step 6: Irreversible / high-impact boundary requires verified OperatorGrant
954+if ne get aegis_cur_grant_meta 3 0
955+note Mutant: skip operator grant verification on high-impact boundary
956+aegis_record_audit AEGIS_DEC_APPROVED AEGIS_OK 1 now_utc
957+ret AEGIS_OK
958+end
959+grc = aegis_grant_verify_current
960+if eq grc AEGIS_ERR_MISSING_GRANT
961+aegis_record_audit AEGIS_DEC_REQUIRES_OP AEGIS_ERR_MISSING_GRANT 0 now_utc
962+ret AEGIS_ERR_MISSING_GRANT
963+end
964+if ne grc AEGIS_OK
965+aegis_record_audit AEGIS_DEC_REJECTED grc 0 now_utc
966+ret grc
967+end
968+aegis_record_audit AEGIS_DEC_APPROVED AEGIS_OK 1 now_utc
969+ret AEGIS_OK
970+end

aienux/aegis/aegis_test.om

new file mode 100644
@@ -0,0 +1,416 @@
1+note SPDX-License-Identifier: Apache-2.0
2+note aienux/aegis/aegis_test.om: Pure-Omega test suite for AIENOS AEGIS
3+note (Capability Graph, Path Confinement, Intent/Grant Crypto, J-Space Worlds, Policy & Broker).
4+note Compose with: si/directives/om2.om om/tls/sha2.om aienux/aegis/aegis.om aienux/aegis/aegis_test.om
5+
6+text a_pass "PASS "
7+text a_fail "FAIL "
8+text a_nl "\n"
9+text a_t01 "aegis_lexical_path_confinement"
10+text a_t02 "aegis_cap_issue_sig_tamper_and_expiry"
11+text a_t03 "aegis_attenuated_delegation_and_depth_limit"
12+text a_t04 "aegis_cascading_subtree_revocation"
13+text a_t05 "aegis_intent_boundaries_and_operator_grant_crypto"
14+text a_t06 "aegis_standing_fetch_fs_read_and_negatives"
15+text a_t07 "aegis_high_impact_boundary_requires_grant"
16+text a_t08 "aegis_jspace_world_delta_and_rollback"
17+text a_t09 "aegis_broker_audit_ledger_integrity"
18+text a_t10 "aegis_mutant_control_skip_grant_caught"
19+text a_sum "AEGIS_TEST_PASS total=10 failed=0\n"
20+text a_fsum "AEGIS_TEST_FAIL\n"
21+
22+text p_ws "/workspace"
23+text p_ws_eq "/workspace"
24+text p_ws_sub "/workspace/project/file.om"
25+text p_ws_sub2 "/workspace/project"
26+text p_ws_sib "/workspace2/file.om"
27+text p_ws_trav "/workspace/../etc/passwd"
28+text p_rel "workspace/file.om"
29+text p_root "/"
30+text p_etc "/etc/passwd"
31+text p_host_ok "interplane.io"
32+text p_host_bad "evil.example"
33+text p_host_star "*"
34+text p_op_drake "operator-drake"
35+text p_k_ab "ab"
36+text p_v_c "c"
37+text p_k_a "a"
38+text p_v_bc "bc"
39+text p_dev_nvme "/dev/nvme0n1"
40+text p_empty ""
41+
42+fn awrite_all fd int buf view uchar * to bool
43+total = len buf
44+off = ulong 0
45+while lt off total bound 4096
46+n = write fd buf off sub total off
47+if le n 0
48+ret false
49+end
50+off = add off ulong n
51+end
52+ret true
53+end
54+
55+fn areport name view uchar * ok bool to uint
56+if ok
57+w1 = awrite_all 1 a_pass
58+w2 = awrite_all 1 name
59+w3 = awrite_all 1 a_nl
60+if and w1 and w2 w3
61+ret 0
62+end
63+ret 1
64+end
65+w1 = awrite_all 1 a_fail
66+w2 = awrite_all 1 name
67+w3 = awrite_all 1 a_nl
68+if and w1 and w2 w3
69+ret 1
70+end
71+ret 1
72+end
73+
74+fn init_test_aegis op_sec edit uchar 32 cap_sec edit uchar 32 to void
75+for i ulong 32
76+put op_sec i uchar add 0x10 and i 0x3f
77+put cap_sec i uchar add 0x80 and i 0x3f
78+end
79+aegis_reset op_sec cap_sec
80+end
81+
82+fn test_a01_path_within to bool
83+if not aegis_path_within p_ws_sub p_ws
84+ret false
85+end
86+if not aegis_path_within p_ws_eq p_ws
87+ret false
88+end
89+if not aegis_path_within p_ws_sub p_root
90+ret false
91+end
92+note Prefix sibling /workspace2 must NOT match /workspace
93+if aegis_path_within p_ws_sib p_ws
94+ret false
95+end
96+note Parent-dir traversal .. must be rejected
97+if aegis_path_within p_ws_trav p_ws
98+ret false
99+end
100+note Relative path must be rejected
101+if aegis_path_within p_rel p_ws
102+ret false
103+end
104+ret true
105+end
106+
107+fn test_a02_cap_sig_and_expiry to bool
108+op = new uchar 32 0
109+cs = new uchar 32 0
110+init_test_aegis op cs
111+s = aegis_cap_issue 100 AEGIS_SCOPE_FS 0 0 1000
112+if lt s 0
113+ret false
114+end
115+su = ulong s
116+aegis_cap_set_strings su p_ws part p_empty 0 0
117+note Valid before expiry
118+if ne aegis_cap_validate su 500 AEGIS_OK
119+ret false
120+end
121+note Expired at 1001
122+if ne aegis_cap_validate su 1001 AEGIS_ERR_EXPIRED
123+ret false
124+end
125+note Tamper 1 byte of stored signature -> must fail AEGIS_ERR_BAD_SIG
126+sb = mul su 32
127+put aegis_cap_sig sb xor get aegis_cap_sig sb 0x01
128+if ne aegis_cap_validate su 500 AEGIS_ERR_BAD_SIG
129+ret false
130+end
131+ret true
132+end
133+
134+fn test_a03_delegation_attenuation to bool
135+op = new uchar 32 0
136+cs = new uchar 32 0
137+init_test_aegis op cs
138+note Root RW cap on /workspace
139+r = aegis_cap_issue 100 AEGIS_SCOPE_FS 0 0 0
140+if lt r 0
141+ret false
142+end
143+ru = ulong r
144+aegis_cap_set_strings ru p_ws part p_empty 0 0
145+note Attenuate to subdir /workspace/project, RO=1 -> OK
146+c1 = aegis_cap_delegate_scoped ru 200 AEGIS_SCOPE_FS 1 p_ws_sub2
147+if lt c1 0
148+ret false
149+end
150+note Attempt RO -> RW escalation from c1 -> REFUSED
151+if ne aegis_cap_delegate_scoped ulong c1 300 AEGIS_SCOPE_FS 0 p_ws_sub2 AEGIS_ERR_SCOPE
152+ret false
153+end
154+note Attempt directory escape /etc/passwd -> REFUSED
155+if ne aegis_cap_delegate_scoped ru 300 AEGIS_SCOPE_FS 1 p_etc AEGIS_ERR_SCOPE
156+ret false
157+end
158+note Chain up to max depth (4), 5th delegation -> AEGIS_ERR_DEPTH
159+c2 = aegis_cap_delegate_scoped ulong c1 201 AEGIS_SCOPE_FS 1 p_ws_sub2
160+c3 = aegis_cap_delegate_scoped ulong c2 202 AEGIS_SCOPE_FS 1 p_ws_sub2
161+c4 = aegis_cap_delegate_scoped ulong c3 203 AEGIS_SCOPE_FS 1 p_ws_sub2
162+if or lt c2 0 or lt c3 0 lt c4 0
163+ret false
164+end
165+if ne aegis_cap_delegate_scoped ulong c4 204 AEGIS_SCOPE_FS 1 p_ws_sub2 AEGIS_ERR_DEPTH
166+ret false
167+end
168+ret true
169+end
170+
171+fn test_a04_subtree_revocation to bool
172+op = new uchar 32 0
173+cs = new uchar 32 0
174+init_test_aegis op cs
175+root = aegis_cap_issue 100 AEGIS_SCOPE_FS 0 0 0
176+aegis_cap_set_strings ulong root p_ws part p_empty 0 0
177+sib = aegis_cap_issue 101 AEGIS_SCOPE_FS 1 0 0
178+aegis_cap_set_strings ulong sib p_ws part p_empty 0 0
179+child = aegis_cap_delegate_scoped ulong root 200 AEGIS_SCOPE_FS 0 p_ws_sub2
180+gchild = aegis_cap_delegate_scoped ulong child 300 AEGIS_SCOPE_FS 1 p_ws_sub2
181+if or lt child 0 lt gchild 0
182+ret false
183+end
184+if ne aegis_cap_revoke ulong root AEGIS_OK
185+ret false
186+end
187+if ne aegis_cap_validate ulong root 0 AEGIS_ERR_REVOKED
188+ret false
189+end
190+if ne aegis_cap_validate ulong child 0 AEGIS_ERR_REVOKED
191+ret false
192+end
193+if ne aegis_cap_validate ulong gchild 0 AEGIS_ERR_REVOKED
194+ret false
195+end
196+note Unrelated sibling remains valid
197+if ne aegis_cap_validate ulong sib 0 AEGIS_OK
198+ret false
199+end
200+ret true
201+end
202+
203+fn test_a05_intent_and_grant_crypto to bool
204+op = new uchar 32 0
205+cs = new uchar 32 0
206+bad = new uchar 32 0x77
207+init_test_aegis op cs
208+note Parameter boundary separation: ("ab","c") != ("a","bc")
209+aegis_intent_hash_kv 42 p_k_ab p_v_c
210+id1 = new uchar 16 0
211+for i ulong 16
212+put id1 i get aegis_cur_iid i
213+end
214+aegis_intent_hash_kv 42 p_k_a p_v_bc
215+id2 = new uchar 16 0
216+for j ulong 16
217+put id2 j get aegis_cur_iid j
218+end
219+if aegis_eq16 id1 id2
220+ret false
221+end
222+note Valid grant verifies
223+aegis_grant_issue_with_secret p_op_drake 1700000000 op
224+if ne aegis_grant_verify_current AEGIS_OK
225+ret false
226+end
227+note Grant signed with wrong secret rejected
228+aegis_grant_issue_with_secret p_op_drake 1700000000 bad
229+if ne aegis_grant_verify_current AEGIS_ERR_GRANT_SIG
230+ret false
231+end
232+note Grant for different intent rejected
233+aegis_grant_issue_with_secret p_op_drake 1700000000 op
234+put aegis_cur_iid 0 xor get aegis_cur_iid 0 0xff
235+if ne aegis_grant_verify_current AEGIS_ERR_GRANT_INTENT
236+ret false
237+end
238+ret true
239+end
240+
241+fn test_a06_standing_fetch_and_fs_read to bool
242+op = new uchar 32 0
243+cs = new uchar 32 0
244+init_test_aegis op cs
245+aegis_grant_clear
246+sf = aegis_cap_issue 10 AEGIS_SCOPE_STANDING_FETCH 0 0 0
247+aegis_cap_set_strings ulong sf p_host_ok part p_empty 0 0
248+fs = aegis_cap_issue 10 AEGIS_SCOPE_FS 1 0 0
249+aegis_cap_set_strings ulong fs p_ws part p_empty 0 0
250+aegis_dispatch_ctx 0 0 100 0
251+note StandingFetch to interplane.io approved autonomously without grant
252+if ne aegis_broker_dispatch 10 ulong sf aegis_act_net_fetch p_host_ok AEGIS_OK
253+ret false
254+end
255+note Wrong host refused
256+if ne aegis_broker_dispatch 10 ulong sf aegis_act_net_fetch p_host_bad AEGIS_ERR_SCOPE
257+ret false
258+end
259+note Wrong holder refused
260+if ne aegis_broker_dispatch 99 ulong sf aegis_act_net_fetch p_host_ok AEGIS_ERR_HOLDER
261+ret false
262+end
263+note fs.read within /workspace approved autonomously
264+if ne aegis_broker_dispatch 10 ulong fs aegis_act_fs_read p_ws_sub AEGIS_OK
265+ret false
266+end
267+note fs.write on RO cap refused by scope
268+if ne aegis_broker_dispatch 10 ulong fs aegis_act_fs_write p_ws_sub AEGIS_ERR_SCOPE
269+ret false
270+end
271+ret true
272+end
273+
274+fn test_a07_high_impact_requires_grant to bool
275+op = new uchar 32 0
276+cs = new uchar 32 0
277+bad = new uchar 32 0x55
278+init_test_aegis op cs
279+aegis_grant_clear
280+adm = aegis_cap_issue 20 AEGIS_SCOPE_SYSADMIN 0 0 0
281+aegis_dispatch_ctx 0 0 200 0
282+note disk.format without grant -> AEGIS_ERR_MISSING_GRANT + DEC_REQUIRES_OP
283+if ne aegis_broker_dispatch 20 ulong adm aegis_act_disk_format p_dev_nvme AEGIS_ERR_MISSING_GRANT
284+ret false
285+end
286+if ne get aegis_last_dec 0 AEGIS_DEC_REQUIRES_OP
287+ret false
288+end
289+note Forged grant -> AEGIS_ERR_GRANT_SIG + DEC_REJECTED
290+aegis_compute_intent_id 20 ulong adm aegis_act_disk_format p_dev_nvme
291+aegis_grant_issue_with_secret p_op_drake 200 bad
292+if ne aegis_broker_dispatch 20 ulong adm aegis_act_disk_format p_dev_nvme AEGIS_ERR_GRANT_SIG
293+ret false
294+end
295+if ne get aegis_last_dec 0 AEGIS_DEC_REJECTED
296+ret false
297+end
298+note Valid operator grant -> AEGIS_OK + DEC_APPROVED
299+aegis_compute_intent_id 20 ulong adm aegis_act_disk_format p_dev_nvme
300+aegis_grant_issue_with_secret p_op_drake 200 op
301+if ne aegis_broker_dispatch 20 ulong adm aegis_act_disk_format p_dev_nvme AEGIS_OK
302+ret false
303+end
304+if ne get aegis_last_dec 0 AEGIS_DEC_APPROVED
305+ret false
306+end
307+ret true
308+end
309+
310+fn test_a08_jspace_world_delta to bool
311+op = new uchar 32 0
312+cs = new uchar 32 0
313+init_test_aegis op cs
314+aegis_grant_clear
315+fs = aegis_cap_issue 30 AEGIS_SCOPE_FS 0 0 0
316+aegis_cap_set_strings ulong fs p_ws part p_empty 0 0
317+wi = aegis_world_create 777
318+if lt wi 0
319+ret false
320+end
321+note Reversible fs.write to active World 777 approved without grant!
322+aegis_dispatch_ctx 777 1 300 0
323+if ne aegis_broker_dispatch 30 ulong fs aegis_act_fs_write p_ws_sub AEGIS_OK
324+ret false
325+end
326+if or ne get aegis_w_deltas ulong wi 1 ne get aegis_w_writes ulong wi 1
327+ret false
328+end
329+note Rollback clears deltas and transitions World to ROLLEDBACK
330+if ne aegis_world_rollback 777 AEGIS_OK
331+ret false
332+end
333+if or ne get aegis_w_deltas ulong wi 0 ne get aegis_w_status ulong wi AEGIS_WORLD_ROLLEDBACK
334+ret false
335+end
336+note Dispatching again to rolled-back World falls back to requiring OperatorGrant!
337+if ne aegis_broker_dispatch 30 ulong fs aegis_act_fs_write p_ws_sub AEGIS_ERR_MISSING_GRANT
338+ret false
339+end
340+ret true
341+end
342+
343+fn test_a09_audit_ledger to bool
344+op = new uchar 32 0
345+cs = new uchar 32 0
346+init_test_aegis op cs
347+aegis_grant_clear
348+fs = aegis_cap_issue 40 AEGIS_SCOPE_FS 0 0 0
349+aegis_cap_set_strings ulong fs p_ws part p_empty 0 0
350+aegis_dispatch_ctx 0 0 401 0
351+r1 = aegis_broker_dispatch 40 ulong fs aegis_act_fs_read p_ws_sub
352+aegis_dispatch_ctx 0 0 402 0
353+r2 = aegis_broker_dispatch 40 ulong fs aegis_act_fs_write p_ws_sub
354+aegis_dispatch_ctx 0 0 403 0
355+r3 = aegis_broker_dispatch 40 ulong fs aegis_act_fs_read p_etc
356+if or ne r1 AEGIS_OK or ne r2 AEGIS_ERR_MISSING_GRANT ne r3 AEGIS_ERR_SCOPE
357+ret false
358+end
359+if ne get aegis_audit_cnt 0 3
360+ret false
361+end
362+if or ne get aegis_audit_dec 0 AEGIS_DEC_APPROVED ne get aegis_audit_exec 0 1
363+ret false
364+end
365+if or ne get aegis_audit_dec 1 AEGIS_DEC_REQUIRES_OP ne get aegis_audit_exec 1 0
366+ret false
367+end
368+if or ne get aegis_audit_dec 2 AEGIS_DEC_REJECTED ne get aegis_audit_ts 2 403
369+ret false
370+end
371+ret true
372+end
373+
374+fn test_a10_mutant_skip_grant to bool
375+op = new uchar 32 0
376+cs = new uchar 32 0
377+init_test_aegis op cs
378+aegis_grant_clear
379+adm = aegis_cap_issue 50 AEGIS_SCOPE_SYSADMIN 0 0 0
380+aegis_dispatch_ctx 0 0 500 0
381+note With mutant OFF: kernel.replace without grant MUST be refused
382+if ne aegis_broker_dispatch 50 ulong adm aegis_act_kern_rep p_dev_nvme AEGIS_ERR_MISSING_GRANT
383+ret false
384+end
385+note With mutant ON (skip_grant=1): unapproved kernel.replace slips through -> mutant detected!
386+aegis_set_mutant_skip_grant 1
387+rc_mut = aegis_broker_dispatch 50 ulong adm aegis_act_kern_rep p_dev_nvme
388+aegis_set_mutant_skip_grant 0
389+if eq rc_mut AEGIS_ERR_MISSING_GRANT
390+ret false
391+end
392+ret true
393+end
394+
395+fn main to int
396+fails = uint 0
397+fails = add fails areport a_t01 test_a01_path_within
398+fails = add fails areport a_t02 test_a02_cap_sig_and_expiry
399+fails = add fails areport a_t03 test_a03_delegation_attenuation
400+fails = add fails areport a_t04 test_a04_subtree_revocation
401+fails = add fails areport a_t05 test_a05_intent_and_grant_crypto
402+fails = add fails areport a_t06 test_a06_standing_fetch_and_fs_read
403+fails = add fails areport a_t07 test_a07_high_impact_requires_grant
404+fails = add fails areport a_t08 test_a08_jspace_world_delta
405+fails = add fails areport a_t09 test_a09_audit_ledger
406+fails = add fails areport a_t10 test_a10_mutant_skip_grant
407+if eq fails 0
408+w = awrite_all 1 a_sum
409+if w
410+ret 0
411+end
412+ret 1
413+end
414+w2 = awrite_all 1 a_fsum
415+ret 1
416+end

aienux/allen/application.om

new file mode 100644
@@ -0,0 +1,241 @@
1+note Native application binding: conversation state, courier lifecycle and reply/code.
2+note A initialized, queued AGAIN bytes, per-call event, reserved.
3+note Events:0 none,1 visible answer/ack,2 AGAIN queued,3 code give-up,
4+note 4 refused LINE payload,5 slow notice,6 silence timeout.
5+note Transport acceptance is separate from payload acceptance: appreceive true
6+note means envelope accepted; inspect A2 for malformed payload, never invent text.
7+global A ulong 4
8+global Appjob uchar 4096
9+global Appwire uchar 8192
10+global Askin uchar 160
11+fn appinit run ulong now ulong to bool
12+if or ne get A 0 0 ne get R 0 0
13+ret false
14+end
15+if ne get Q 0 0
16+ret false
17+end
18+if not qstart run now
19+ret false
20+end
21+constants
22+put A 0 1
23+put A 1 0
24+put A 2 0
25+ret true
26+end
27+fn appclock now ulong to bool
28+if eq get A 0 0
29+ret false
30+end
31+ret and ge now get T 0 ge now get R 4
32+end
33+fn appask now ulong to bool
34+if not appclock now
35+ret false
36+end
37+if or ne get R 1 0 ne get A 1 0
38+ret false
39+end
40+if or ne get T 10 0 ne get T 13 0
41+ret false
42+end
43+if and ne get T 5 0 eq get T 6 0
44+ret false
45+end
46+if or ge get R 0 4294967295 ge get Q 1 4294967295
47+ret false
48+end
49+if not textok
50+ret false
51+end
52+kind = classify
53+if or lt kind 1 gt kind 3
54+ret false
55+end
56+if and eq kind 3 eq get R 6 0
57+ret false
58+end
59+note Validate restored context before jobbuild reads its variable-layout names.
60+if not ctxmeta 6
61+ret false
62+end
63+if not jobbuild kind add get R 0 1
64+ret false
65+end
66+if not ctxappend
67+ret false
68+end
69+n = get Inlen 0
70+size = get Outlen 0
71+for i ulong n
72+put Askin i get In i
73+end
74+for i ulong size
75+put Appjob i get Outb i
76+end
77+for i ulong size
78+put In i get Appjob i
79+end
80+put Inlen 0 size
81+queued = qsubmit now
82+for i ulong n
83+put In i get Askin i
84+end
85+put Inlen 0 n
86+if not queued
87+ret false
88+end
89+note start preconditions were checked before qsubmit; no concurrent calls permitted.
90+if not start kind now
91+qcancel
92+ret false
93+end
94+put A 2 0
95+if gt kind 1
96+codebeg get R 0
97+put A 2 1
98+end
99+ret true
100+end
101+fn appcancel to void
102+cancel
103+qcancel
104+put A 1 0
105+put A 2 0
106+end
107+fn appreset to void
108+appcancel
109+reset
110+end
111+note First acknowledge the triggering LINE, then submit AGAIN with a new wire
112+note sequence while retaining the original conversation ID in its body.
113+fn appqueue now ulong to bool
114+if eq get A 1 0
115+ret true
116+end
117+if or ne get T 10 0 ne get T 13 0
118+ret true
119+end
120+put Inlen 0 get A 1
121+for i ulong get A 1
122+put In i get Appjob i
123+end
124+if not qsubmit now
125+ret false
126+end
127+put A 1 0
128+ret true
129+end
130+fn apppoll now ulong online bool to bool
131+if not appclock now
132+ret false
133+end
134+put A 2 0
135+put T 0 now
136+status = tick now
137+if eq status 1
138+put A 2 5
139+end
140+if eq status 2
141+qcancel
142+put A 1 0
143+put A 2 6
144+end
145+if not appqueue now
146+appcancel
147+put A 2 3
148+ret false
149+end
150+ret qnext now online
151+end
152+fn appsent now ulong ok bool to bool
153+if not appclock now
154+ret false
155+end
156+if not qsent now ok
157+ret false
158+end
159+put A 2 0
160+ret true
161+end
162+fn appbody now ulong to bool
163+if eq get R 1 0
164+put A 2 4
165+ret true
166+end
167+if ineq 0 67
168+if or le get R 2 1 ne get C 0 get R 0
169+put A 2 4
170+ret true
171+end
172+if codetake
173+if heard get C 0 now
174+ret true
175+end
176+end
177+put A 2 4
178+ret true
179+end
180+if or ineq 0 83 ineq 0 87
181+status = saytake now
182+if eq status 1
183+if eq get R 1 0
184+put A 1 0
185+end
186+if ne get S 1 0
187+put A 2 1
188+end
189+ret true
190+end
191+if eq status 2
192+n = get Outlen 0
193+if or eq n 0 gt n 4096
194+cancel
195+put A 1 0
196+put A 2 3
197+ret true
198+end
199+for i ulong n
200+put Appjob i get Outb i
201+end
202+put A 1 n
203+put A 2 2
204+ret true
205+end
206+if eq status 3
207+put A 1 0
208+put A 2 3
209+ret true
210+end
211+end
212+put A 2 4
213+ret true
214+end
215+note Reply parsing can serialize AGAIN internally. Preserve the already offered
216+note datagram until the provider records its send result, including on refusal.
217+fn appreceive now ulong to bool
218+if not appclock now
219+ret false
220+end
221+result = qincoming now
222+if eq result 0
223+ret false
224+end
225+put A 2 0
226+if not qtake
227+ret true
228+end
229+n = get Outlen 0
230+e = get Err 0
231+for i ulong n
232+put Appwire i get Outb i
233+end
234+ok = appbody now
235+for i ulong n
236+put Outb i get Appwire i
237+end
238+put Outlen 0 n
239+put Err 0 e
240+ret ok
241+end

aienux/allen/base.om

new file mode 100644
@@ -0,0 +1,102 @@
1+note L694 fixed-buffer utilities. No platform effects in product functions.
2+global In uchar 8192
3+global Inlen ulong 1
4+global Outb uchar 8192
5+global Outlen ulong 1
6+global Err ulong 1
7+text Digits "0123456789abcdef"
8+fn emitb c uchar to void
9+n = get Outlen 0
10+if ge n len Outb
11+put Err 0 1
12+else
13+put Outb n c
14+put Outlen 0 add n 1
15+end
16+end
17+fn emitn v ulong to void
18+d = new uchar 20 0
19+n = ulong 0
20+x = v
21+put d n uchar add rem x 10 48
22+n = add n 1
23+x = div x 10
24+while gt x 0
25+put d n uchar add rem x 10 48
26+n = add n 1
27+x = div x 10
28+end
29+while gt n 0
30+n = sub n 1
31+emitb get d n
32+end
33+end
34+fn outreset to void
35+put Outlen 0 0
36+put Err 0 0
37+end
38+fn ineq at ulong c uchar to bool
39+if ge at get Inlen 0
40+ret false
41+end
42+ret eq get In at c
43+end
44+fn isdigit c uchar to bool
45+ret and ge c 48 le c 57
46+end
47+note Parser cursor P0, number P1, error P2. Never wraps a u32.
48+global P ulong 3
49+fn number to void
50+v = ulong 0
51+n = ulong 0
52+p = get P 0
53+while lt p get Inlen 0
54+c = get In p
55+if not isdigit c
56+put P 0 p
57+put P 1 v
58+if eq n 0
59+put P 2 1
60+end
61+ret
62+end
63+if or ge n 10 gt v 429496729
64+put P 2 1
65+ret
66+end
67+v = add mul v 10 sub ulong c 48
68+if gt v 4294967295
69+put P 2 1
70+ret
71+end
72+n = add n 1
73+p = add p 1
74+end
75+put P 0 p
76+put P 1 v
77+if eq n 0
78+put P 2 1
79+end
80+end
81+fn expect c uchar to void
82+p = get P 0
83+if not ineq p c
84+put P 2 1
85+else
86+put P 0 add p 1
87+end
88+end
89+fn crc off ulong count ulong to uint
90+c = uint 4294967295
91+for i ulong count
92+c = xor c uint get In add off i
93+for k ulong 8
94+if ne and c 1 0
95+c = xor shr c 1 3988292384
96+else
97+c = shr c 1
98+end
99+end
100+end
101+ret not c
102+end

aienux/allen/code.om

new file mode 100644
@@ -0,0 +1,264 @@
1+note CODE protocol: C seq, parts, bytes, crc, got. D parsed header.
2+global C ulong 8
3+global D ulong 8
4+global Code uchar 32769
5+global Have uchar 256
6+global Piece uchar 128
7+global Lang uchar 16
8+global Newlang uchar 16
9+fn codebeg seq ulong to void
10+for i ulong 8
11+put C i 0
12+end
13+put C 0 seq
14+for i ulong 256
15+put Have i 0
16+end
17+put Code 0 0
18+end
19+fn decfield slot ulong sep uchar to void
20+number
21+put D slot get P 1
22+expect sep
23+end
24+fn hexread to void
25+v = ulong 0
26+for i ulong 8
27+p = get P 0
28+if ge p get Inlen 0
29+put P 2 1
30+ret
31+end
32+c = get In p
33+d = ulong 16
34+if isdigit c
35+d = sub ulong c 48
36+else
37+if and ge c 97 le c 102
38+d = sub ulong c 87
39+end
40+end
41+if ge d 16
42+put P 2 1
43+ret
44+end
45+v = add mul v 16 d
46+put P 0 add p 1
47+end
48+put D 4 v
49+expect 32
50+end
51+fn codehead to bool
52+put P 0 0
53+put P 2 0
54+expect 67
55+expect 79
56+expect 68
57+expect 69
58+expect 32
59+decfield 0 32
60+decfield 1 47
61+decfield 2 32
62+decfield 3 32
63+hexread
64+if ne get P 2 0
65+ret false
66+end
67+if or ne get D 0 get C 0 eq get D 3 0
68+ret false
69+end
70+if gt get D 3 32768
71+ret false
72+end
73+if ne get D 2 div add get D 3 127 128
74+ret false
75+end
76+if or lt get D 1 1 gt get D 1 get D 2
77+ret false
78+end
79+if ne get C 1 0
80+if or ne get C 1 get D 2 ne get C 2 get D 3
81+ret false
82+end
83+if ne get C 3 get D 4
84+ret false
85+end
86+end
87+ret true
88+end
89+fn langread to bool
90+for i ulong 16
91+put Newlang i 0
92+end
93+n = ulong 0
94+p = get P 0
95+while lt p get Inlen 0
96+c = get In p
97+if eq c 32
98+if eq n 0
99+ret false
100+end
101+put P 0 add p 1
102+put D 5 n
103+ret true
104+end
105+ok = or and ge c 97 le c 122 isdigit c
106+ok = or ok or eq c 43 eq c 35
107+ok = or ok or eq c 46 or eq c 95 eq c 45
108+if or not ok ge n 15
109+ret false
110+end
111+put Newlang n c
112+p = add p 1
113+n = add n 1
114+end
115+ret false
116+end
117+fn pieceread to ulong
118+p = get P 0
119+n = ulong 0
120+while lt p get Inlen 0
121+c = get In p
122+p = add p 1
123+if eq c 92
124+if ge p get Inlen 0
125+ret 129
126+end
127+c = get In p
128+p = add p 1
129+if eq c 110
130+c = 10
131+else
132+if ne c 92
133+ret 129
134+end
135+end
136+else
137+if or lt c 32 gt c 126
138+ret 129
139+end
140+end
141+if ge n 128
142+ret 129
143+end
144+put Piece n c
145+n = add n 1
146+end
147+ret n
148+end
149+fn codetake to bool
150+if gt get Inlen 0 320
151+ret false
152+end
153+if not codehead
154+ret false
155+end
156+if not langread
157+ret false
158+end
159+n = pieceread
160+want = ulong 128
161+if eq get D 1 get D 2
162+want = sub get D 3 mul sub get D 2 1 128
163+end
164+if ne n want
165+ret false
166+end
167+slot = sub get D 1 1
168+off = mul slot 128
169+if ne get C 1 0
170+for i ulong 16
171+if ne get Lang i get Newlang i
172+ret false
173+end
174+end
175+end
176+if ne get Have slot 0
177+for i ulong n
178+if ne get Code add off i get Piece i
179+ret false
180+end
181+end
182+ret true
183+end
184+put C 1 get D 2
185+put C 2 get D 3
186+put C 3 get D 4
187+for i ulong 16
188+put Lang i get Newlang i
189+end
190+for i ulong n
191+put Code add off i get Piece i
192+end
193+put Have slot 1
194+put C 4 add get C 4 1
195+ret true
196+end
197+fn codecrc to uint
198+c = uint 4294967295
199+for i ulong get C 2
200+c = xor c uint get Code i
201+for k ulong 8
202+if ne and c 1 0
203+c = xor shr c 1 3988292384
204+else
205+c = shr c 1
206+end
207+end
208+end
209+ret not c
210+end
211+fn codestat to ulong
212+if eq get C 1 0
213+ret 0
214+end
215+if lt get C 4 get C 1
216+ret 1
217+end
218+if ne ulong codecrc get C 3
219+ret 3
220+end
221+lines = ulong 0
222+for i ulong get C 2
223+c = get Code i
224+if eq c 0
225+ret 3
226+end
227+if eq c 10
228+lines = add lines 1
229+end
230+end
231+if ne get Code sub get C 2 1 10
232+lines = add lines 1
233+end
234+if gt lines 800
235+ret 3
236+end
237+put Code get C 2 0
238+ret 2
239+end
240+fn missing to ulong
241+if eq get C 1 0
242+ret 1
243+end
244+for i ulong get C 1
245+if eq get Have i 0
246+ret add i 1
247+end
248+end
249+ret 0
250+end
251+note Display admission is distinct from a model's closing sentence.
252+fn codeshow seq ulong to bool
253+if eq get R 1 0
254+ret false
255+end
256+if or ne seq get R 0 ne seq get C 0
257+ret false
258+end
259+if ne codestat 2
260+ret false
261+end
262+put R 6 1
263+ret true
264+end

aienux/allen/context.om

new file mode 100644
@@ -0,0 +1,237 @@
1+note Restored note catalog and bounded model-job context. No storage provider.
2+note Cx declared count,visited count,ready,damaged,loading. Damaged notes stay gone.
3+global Cx ulong 5
4+global Ctxtext uchar 65536
5+global Ctxlen ulong 512
6+global Ctxgone uchar 512
7+global Ctxseen uchar 512
8+global Ctxstart ulong 512
9+global Meta uchar 4096
10+global Mx ulong 2
11+global Mdigits uchar 20
12+text Mtself "\tself="
13+text Mtname "\tname="
14+text Mtstart "\tstarts="
15+text Mtfact "\tfact "
16+text Mtis " is "
17+text Mtare " are "
18+text Mtnote "\tnote "
19+fn ctxidle to bool
20+if ne get R 1 0
21+ret false
22+end
23+ret and eq get Tx 0 0 eq get Nt 0 0
24+end
25+fn ctxbegin to bool
26+if not ctxidle
27+ret false
28+end
29+n = mem32 36
30+if gt n 512
31+ret false
32+end
33+for i ulong 512
34+put Ctxlen i 0
35+put Ctxgone i 1
36+put Ctxseen i 0
37+put Ctxstart i 0
38+end
39+put Cx 0 n
40+put Cx 1 0
41+put Cx 2 0
42+put Cx 3 0
43+put Cx 4 1
44+if eq n 0
45+put Cx 2 1
46+put Cx 4 0
47+end
48+ret true
49+end
50+note Returns0 refused without visit,1 valid record retained,2 damaged visit retained.
51+fn ctxtake index ulong to ulong
52+if not ctxidle
53+ret 0
54+end
55+if or eq get Cx 4 0 ge index get Cx 0
56+ret 0
57+end
58+if ne get Ctxseen index 0
59+ret 0
60+end
61+status = ulong 2
62+if notedec index
63+n = get Ns 0
64+for i ulong n
65+put Ctxtext add mul index 128 i get Note i
66+end
67+put Ctxlen index n
68+put Ctxgone index uchar get Ns 3
69+put Ctxstart index get Ns 2
70+status = 1
71+else
72+put Cx 3 add get Cx 3 1
73+end
74+put Ctxseen index 1
75+put Cx 1 add get Cx 1 1
76+if eq get Cx 1 get Cx 0
77+put Cx 2 1
78+put Cx 4 0
79+end
80+ret status
81+end
82+fn mtemit c uchar to void
83+if ne get Mx 1 0
84+ret
85+end
86+n = get Mx 0
87+if ge n 4096
88+put Mx 1 1
89+ret
90+end
91+put Meta n c
92+put Mx 0 add n 1
93+end
94+fn mtnum v ulong to void
95+n = ulong 0
96+while gt v 9
97+put Mdigits n uchar rem v 10
98+v = div v 10
99+n = add n 1
100+end
101+put Mdigits n uchar v
102+n = add n 1
103+for i ulong n
104+mtemit add uchar 48 get Mdigits sub sub n 1 i
105+end
106+end
107+note Memory fields are length-bounded; require a terminator and printable bytes.
108+fn mtfield off ulong cap ulong to bool
109+for i ulong cap
110+c = get Mem add off i
111+if eq c 0
112+if eq i 0
113+put Mx 1 1
114+ret false
115+end
116+ret true
117+end
118+if or lt c 32 gt c 126
119+put Mx 1 1
120+ret false
121+end
122+mtemit c
123+end
124+put Mx 1 1
125+ret false
126+end
127+fn mtfacts count ulong to bool
128+for k ulong count
129+off = add 40 mul k 113
130+for i ulong len Mtfact
131+mtemit get Mtfact i
132+end
133+if not mtfield off 48
134+ret false
135+end
136+are = get Mem add off 112
137+if gt are 1
138+put Mx 1 1
139+ret false
140+end
141+if eq are 1
142+for i ulong len Mtare
143+mtemit get Mtare i
144+end
145+else
146+for i ulong len Mtis
147+mtemit get Mtis i
148+end
149+end
150+if not mtfield add off 48 64
151+ret false
152+end
153+end
154+ret eq get Mx 1 0
155+end
156+fn mtnotes count ulong limit ulong to void
157+given = ulong 0
158+for k ulong count
159+index = sub sub count 1 k
160+if and eq get Ctxgone index 0 lt given limit
161+for i ulong len Mtnote
162+mtemit get Mtnote i
163+end
164+for i ulong get Ctxlen index
165+mtemit get Ctxtext add mul index 128 i
166+end
167+given = add given 1
168+end
169+end
170+end
171+fn ctxmeta limit ulong to bool
172+put Mx 0 0
173+put Mx 1 1
174+facts = mem32 32
175+notes = mem32 36
176+if or gt facts 32 gt notes 512
177+ret false
178+end
179+if gt limit 512
180+ret false
181+end
182+if gt notes 0
183+if or eq get Cx 2 0 ne get Cx 0 notes
184+ret false
185+end
186+end
187+put Mx 1 0
188+for i ulong len Mtself
189+mtemit get Mtself i
190+end
191+off = add 40 mul facts 113
192+if eq get Mem off 0
193+for i ulong len Allen
194+mtemit get Allen i
195+end
196+else
197+if not mtfield off 24
198+ret false
199+end
200+end
201+if ne get Mem 8 0
202+for i ulong len Mtname
203+mtemit get Mtname i
204+end
205+if not mtfield 8 24
206+ret false
207+end
208+end
209+for i ulong len Mtstart
210+mtemit get Mtstart i
211+end
212+mtnum mem32 0
213+if not mtfacts facts
214+ret false
215+end
216+mtnotes notes limit
217+ret eq get Mx 1 0
218+end
219+note Publish all metadata or none; preserve outgoing bytes/length/error on refusal.
220+fn ctxappend to bool
221+if or ne get Mx 1 0 ne get Err 0 0
222+ret false
223+end
224+n = get Outlen 0
225+size = get Mx 0
226+if or gt n 4096 gt size 4096
227+ret false
228+end
229+if gt add n size 4096
230+ret false
231+end
232+for i ulong size
233+put Outb add n i get Meta i
234+end
235+put Outlen 0 add n size
236+ret true
237+end

aienux/allen/courier.om

new file mode 100644
@@ -0,0 +1,261 @@
1+note Pure courier datagrams. Q session, current seq, last LINE, head, count.
2+global Q ulong 8
3+global N ulong 8
4+global Queue uchar 2560
5+global Qlens ulong 8
6+global Jbuf uchar 4096
7+global Jhave uchar 5
8+global J ulong 3
9+text Keys "ALLEN-COURIER v=1 run= kind= seq= part= bytes="
10+text Kinds "JOBLINEGOTACKHELLOHI"
11+fn keyread off ulong count ulong to void
12+for i ulong count
13+expect get Keys add off i
14+end
15+end
16+fn keyemit off ulong count ulong to void
17+for i ulong count
18+emitb get Keys add off i
19+end
20+end
21+fn kindoff k ulong to ulong
22+if eq k 1
23+ret 0
24+end
25+if eq k 2
26+ret 3
27+end
28+if eq k 3
29+ret 7
30+end
31+if eq k 4
32+ret 10
33+end
34+if eq k 5
35+ret 13
36+end
37+ret 18
38+end
39+fn kindlen k ulong to ulong
40+if eq k 2
41+ret 4
42+end
43+if eq k 5
44+ret 5
45+end
46+if eq k 6
47+ret 2
48+end
49+ret 3
50+end
51+fn qbegin run ulong seq ulong to void
52+for i ulong 8
53+put Q i 0
54+end
55+put Q 0 run
56+put Q 1 seq
57+for i ulong 5
58+put Jhave i 0
59+end
60+for i ulong 3
61+put J i 0
62+end
63+end
64+note Serializer takes body In/Inlen; Outb/Outlen are published only on success.
65+fn packet k ulong seq ulong part ulong total ulong bytes ulong to bool
66+if or lt k 1 gt k 6
67+ret false
68+end
69+if gt get Inlen 0 1000
70+ret false
71+end
72+outreset
73+keyemit 0 22
74+for i ulong 16
75+d = and shr get Q 0 mul sub 15 i 4 15
76+emitb get Digits d
77+end
78+keyemit 22 6
79+off = kindoff k
80+for i ulong kindlen k
81+emitb get Kinds add off i
82+end
83+keyemit 28 5
84+emitn seq
85+keyemit 33 6
86+emitn part
87+emitb 47
88+emitn total
89+keyemit 39 7
90+emitn bytes
91+emitb 10
92+for i ulong get Inlen 0
93+emitb get In i
94+end
95+ret eq get Err 0 0
96+end
97+fn pkparse to bool
98+if or gt get Inlen 0 1200 lt get Inlen 0 65
99+ret false
100+end
101+put P 0 0
102+put P 2 0
103+keyread 0 22
104+run = ulong 0
105+for i ulong 16
106+p = get P 0
107+c = get In p
108+d = ulong 16
109+if isdigit c
110+d = sub ulong c 48
111+else
112+if and ge c 97 le c 102
113+d = sub ulong c 87
114+end
115+end
116+if ge d 16
117+ret false
118+end
119+run = or shl run 4 d
120+put P 0 add p 1
121+end
122+if ne run get Q 0
123+ret false
124+end
125+keyread 22 6
126+kind = ulong 0
127+for k ulong 6
128+at = get P 0
129+off = kindoff add k 1
130+size = kindlen add k 1
131+ok = true
132+for i ulong size
133+if not ineq add at i get Kinds add off i
134+ok = false
135+end
136+end
137+if and ok ineq add at size 32
138+kind = add k 1
139+end
140+end
141+if eq kind 0
142+ret false
143+end
144+put N 0 kind
145+put P 0 add get P 0 kindlen kind
146+keyread 28 5
147+number
148+put N 1 get P 1
149+keyread 33 6
150+number
151+put N 2 get P 1
152+expect 47
153+number
154+put N 3 get P 1
155+keyread 39 7
156+number
157+put N 4 get P 1
158+expect 10
159+put N 5 get P 0
160+put N 6 sub get Inlen 0 get P 0
161+ret eq get P 2 0
162+end
163+fn jobtake to ulong
164+note n via N4
165+note part via N2
166+note total via N3
167+if or eq get N 4 0 gt get N 4 4096
168+ret 0
169+end
170+if ne get N 3 div add get N 4 999 1000
171+ret 0
172+end
173+if or eq get N 2 0 gt get N 2 get N 3
174+ret 0
175+end
176+want = ulong 1000
177+if eq get N 2 get N 3
178+want = sub get N 4 mul sub get N 3 1 1000
179+end
180+if ne want get N 6
181+ret 0
182+end
183+if ne get J 0 0
184+if or ne get J 0 get N 4 ne get J 1 get N 3
185+ret 0
186+end
187+end
188+slot = sub get N 2 1
189+off = mul slot 1000
190+if ne get Jhave slot 0
191+for i ulong want
192+if ne get Jbuf add off i get In add get N 5 i
193+ret 0
194+end
195+end
196+ret 2
197+end
198+for i ulong want
199+put Jbuf add off i get In add get N 5 i
200+end
201+put Jhave slot 1
202+put J 0 get N 4
203+put J 1 get N 3
204+put J 2 add get J 2 1
205+ret 1
206+end
207+note Return0 refused,1 accepted,2 duplicate requiring GOT/ACK again.
208+fn qreceive to ulong
209+if not pkparse
210+ret 0
211+end
212+if ne get N 1 get Q 1
213+ret 0
214+end
215+kind = get N 0
216+if eq kind 1
217+ret jobtake
218+end
219+if ne kind 2
220+if ne get N 6 0
221+ret 0
222+end
223+ret 1
224+end
225+note part via N2
226+if eq get N 2 0
227+ret 0
228+end
229+if le get N 2 get Q 2
230+ret 2
231+end
232+if or ne get N 2 add get Q 2 1 eq get Q 4 8
233+ret 0
234+end
235+n = get N 6
236+if or eq n 0 gt n 319
237+ret 0
238+end
239+slot = rem add get Q 3 get Q 4 8
240+for i ulong n
241+put Queue add mul slot 320 i get In add get N 5 i
242+end
243+put Qlens slot n
244+put Q 4 add get Q 4 1
245+put Q 2 get N 2
246+ret 1
247+end
248+fn qtake to bool
249+if eq get Q 4 0
250+ret false
251+end
252+slot = get Q 3
253+n = get Qlens slot
254+for i ulong n
255+put In i get Queue add mul slot 320 i
256+end
257+put Inlen 0 n
258+put Q 3 rem add slot 1 8
259+put Q 4 sub get Q 4 1
260+ret true
261+end

aienux/allen/demo.om

new file mode 100644
@@ -0,0 +1,166 @@
1+note SPDX-License-Identifier: MIT
2+note Repository demonstration screen state. Platform independent; no device calls.
3+note UI state (Dmo, Dprm, Dprmn, Dstat) is declared in platform.om.
4+text Dmotext "Allen\nType a request, then press Enter.\nI recognise requests to open Allen's GitHub repository.\nRequest:\nRecognised as a deterministic repository request; no model was used.\nNative boot: UEFI firmware services remain active.\nNetwork is up. Type a request.\nNo firmware network yet, retrying. Code: \n"
5+fn dmglyphs at ulong n ulong x long y long color ulong to bool
6+pen = mul x 256
7+for i ulong n
8+if not afglyph get Dmotext add at i
9+ret false
10+end
11+cvblit affloor pen y color
12+pen = add pen long get Af 5
13+end
14+ret true
15+end
16+fn dmline wanted ulong x long y long color ulong to bool
17+line = ulong 0
18+at = ulong 0
19+for i ulong len Dmotext
20+if eq get Dmotext i 10
21+if eq line wanted
22+ret dmglyphs at sub i at x y color
23+end
24+line = add line 1
25+at = add i 1
26+end
27+end
28+ret false
29+end
30+fn dmprompt x long y long to bool
31+pen = mul x 256
32+for i ulong get Dprmn 0
33+if not afglyph get Dprm i
34+ret false
35+end
36+cvblit affloor pen y 16777215
37+pen = add pen long get Af 5
38+end
39+ret true
40+end
41+fn dmnum v ulong x long y long color ulong to bool
42+note Reuse the existing decimal writer, then draw those bytes with the Allen font.
43+outreset
44+emitn v
45+pen = mul x 256
46+for i ulong get Outlen 0
47+if not afglyph get Outb i
48+ret false
49+end
50+cvblit affloor pen y color
51+pen = add pen long get Af 5
52+end
53+ret true
54+end
55+fn dmrender to bool
56+if eq get Dmo 0 1
57+ret ghrender
58+end
59+if or lt get Cv 0 320 lt get Cv 1 288
60+ret false
61+end
62+if not cvclip 0 0 get Cv 0 get Cv 1
63+ret false
64+end
65+for i ulong mul get Cv 0 get Cv 1
66+at = mul i 3
67+put Canvas at 6
68+put Canvas add at 1 8
69+put Canvas add at 2 18
70+end
71+if not afinit 22 1300
72+ret false
73+end
74+if not dmline 0 32 52 16777215
75+ret false
76+end
77+if not afinit 11 1000
78+ret false
79+end
80+if not dmline 1 32 92 13161215
81+ret false
82+end
83+if not dmline 2 32 116 13161215
84+ret false
85+end
86+if not dmline 5 32 140 9871556
87+ret false
88+end
89+if not afinit 13 1100
90+ret false
91+end
92+if not dmline 3 32 196 16766102
93+ret false
94+end
95+if ne get Es 6 0
96+if not dmline 6 32 260 8555696
97+ret false
98+end
99+else
100+if not dmline 7 32 260 8555696
101+ret false
102+end
103+if not dmnum get Es 12 364 260 8555696
104+ret false
105+end
106+end
107+ret dmprompt 112 196
108+end
109+fn dmsubmit to bool
110+n = get Dprmn 0
111+if or eq n 0 gt n 159
112+ret false
113+end
114+if eq get Es 6 0
115+note Never show a transport error for a network that was never up: keep the request.
116+put Dstat 0 1
117+ret false
118+end
119+put Dstat 0 0
120+for i ulong n
121+put In i get Dprm i
122+end
123+put Inlen 0 n
124+if not ghask
125+ret false
126+end
127+put Dmo 0 1
128+put Dprmn 0 0
129+ret true
130+end
131+fn dmkey key ulong to bool
132+if eq get Dmo 0 1
133+if eq key 27
134+put Dmo 0 0
135+put Dprmn 0 0
136+ghinit
137+ret true
138+end
139+ghkey key
140+ret true
141+end
142+if and ge key 32 le key 126
143+n = get Dprmn 0
144+if ge n len Dprm
145+ret false
146+end
147+put Dprm n uchar key
148+put Dprmn 0 add n 1
149+ret true
150+end
151+if or eq key 8 eq key 127
152+if gt get Dprmn 0 0
153+put Dprmn 0 sub get Dprmn 0 1
154+end
155+ret true
156+end
157+if or eq key 10 eq key 13
158+ret dmsubmit
159+end
160+ret false
161+end
162+fn dminit to void
163+ghinit
164+put Dmo 0 0
165+put Dprmn 0 0
166+end

aienux/allen/efi-main.om

new file mode 100644
@@ -0,0 +1,481 @@
1+note SPDX-License-Identifier: MIT
2+note Firmware-hosted native Allen: UEFI Boot Services stay active. Display via GOP Blt,
3+note keys via Simple Text Input, packets via Simple Network, time via GetTime, entropy via
4+note EFI_RNG or CPU RDRAND, elapsed time via calibrated invariant TSC. Compile with the
5+note leading line `target x86efi`. All application, network, TLS and UI logic is Omega.
6+global Eb uchar 64
7+global Ek uchar 8
8+global Ep uchar 32
9+global Et uchar 16
10+global Eclk uchar 8
11+global Erx uchar 1608
12+global Etx uchar 2048
13+note Es (screen and network state) is declared in platform.om.
14+fn efok st ulong to bool
15+ret eq st 0
16+end
17+fn efms to ulong
18+st = efi 10 0 Eclk 0 8
19+if not efok st
20+put Es 12 10
21+ret 18446744073709551615
22+end
23+v = ulong 0
24+for i ulong 8
25+v = or v shl ulong get Eclk i mul i 8
26+end
27+ret v
28+end
29+fn efdays y ulong m ulong d ulong to ulong
30+note Days since 1970-01-01, proleptic Gregorian (civil_from_days inverse).
31+yy = y
32+if le m 2
33+yy = sub yy 1
34+end
35+era = div yy 400
36+yoe = sub yy mul era 400
37+mp = add m 9
38+if gt m 2
39+mp = sub m 3
40+end
41+doy = mul 153 mp
42+doy = div add doy 2 5
43+doy = add doy sub d 1
44+doe = mul yoe 365
45+doe = add doe div yoe 4
46+doe = sub doe div yoe 100
47+doe = add doe doy
48+days = mul era 146097
49+days = add days doe
50+ret sub days 719468
51+end
52+fn efepoch to ulong
53+st = efi 4 0 Et 0 16
54+if not efok st
55+ret 0
56+end
57+y = or ulong get Et 0 shl ulong get Et 1 8
58+mo = ulong get Et 2
59+d = ulong get Et 3
60+h = ulong get Et 4
61+mi = ulong get Et 5
62+s = ulong get Et 6
63+if or or lt y 2024 gt y 2099 or lt mo 1 gt mo 12
64+ret 0
65+end
66+if or or lt d 1 gt d 31 or gt h 23 gt mi 59
67+ret 0
68+end
69+if gt s 59
70+ret 0
71+end
72+v = mul efdays y mo d 86400
73+v = add v add mul h 3600 add mul mi 60 s
74+tz = or ulong get Et 12 shl ulong get Et 13 8
75+if ne tz 2047
76+note UEFI 2.10 8.3: Localtime = UTC - TimeZone (signed 16-bit minutes), so UTC = local + TimeZone.
77+note EFI_UNSPECIFIED_TIMEZONE (2047): firmware time is taken as UTC; shown on screen for the operator.
78+if ge tz 32768
79+v = sub v mul sub 65536 tz 60
80+else
81+v = add v mul tz 60
82+end
83+end
84+ret v
85+end
86+fn efentropy to bool
87+st = efi 5 0 Gsrand 0 96
88+if not efok st
89+put Es 12 5
90+note No firmware random source (neither EFI_RNG nor RDRAND): name it on the repository
91+note screen as stage 15 with the firmware status byte, not as a bare transport error.
92+put Gdiag 0 15
93+put Gdiag 1 and st 255
94+ret false
95+end
96+put Gsrandn 0 96
97+ret true
98+end
99+fn efrows y0 ulong rows ulong to bool
100+note Rows of Efa (as zeros) to the screen: used before the show owns the frame.
101+w = get Es 0
102+n = mul mul w rows 4
103+note Computed-count loops trap past 1,000,000 passes: clear row by row.
104+for r ulong rows
105+base = mul mul r w 4
106+for x ulong mul w 4
107+put Efa add base x 0
108+end
109+end
110+arg = or or w shl rows 32 shl y0 48
111+st = efi 3 arg Efa 0 n
112+ret efok st
113+end
114+fn efscreen to bool
115+st = efi 0 0 Eb 0 64
116+if not efok st
117+ret false
118+end
119+w = or ulong get Eb 8 shl ulong get Eb 9 8
120+w = or w shl ulong get Eb 10 16
121+h = or ulong get Eb 12 shl ulong get Eb 13 8
122+h = or h shl ulong get Eb 14 16
123+if not shfits w h
124+ret false
125+end
126+put Es 0 w
127+put Es 1 h
128+put Es 2 1
129+put Es 3 0
130+put Es 4 0
131+band = div len Efa mul w 4
132+y = ulong 0
133+while lt y h bound 64
134+n = band
135+if gt add y n h
136+n = sub h y
137+end
138+if not efrows y n
139+ret false
140+end
141+y = add y n
142+end
143+put Lg 0 long w
144+put Lg 1 long h
145+ret cvinit 768 384
146+end
147+
148+note Little-endian u64 from Eb at..at+n-1 (n at most 8).
149+fn efle at ulong n ulong to ulong
150+v = ulong 0
151+for i ulong n
152+v = or v shl ulong get Eb add at i mul i 8
153+end
154+ret v
155+end
156+fn efnetup now ulong to void
157+note Es 14 and 15 keep efi 8's diagnostics, read through efi 0 after every attempt (handles |
158+note locate status << 8 | scans << 16, and one probe step per handle); `stats` shows them.
159+note An adapter refused only for its link stays initialized, so the next attempt sees the link.
160+st = efi 8 0 Eb 0 0
161+ist = efi 0 0 Eb 0 64
162+if efok ist
163+put Es 14 efle 52 4
164+put Es 15 efle 56 8
165+end
166+if not efok st
167+put Es 12 and st 255
168+ret
169+end
170+if or not efok ist eq and ulong get Eb 4 2 0
171+put Es 12 and ist 255
172+ret
173+end
174+for i ulong 6
175+put Nmac i get Eb add 24 i
176+end
177+netinit now
178+put Es 6 1
179+end
180+fn efpackets now ulong to void
181+if eq get Es 6 0
182+ret
183+end
184+for burst ulong 32
185+st = efi 6 0 Erx 0 len Erx
186+if not efok st
187+ret
188+end
189+n = ulong 0
190+for i ulong 8
191+n = or n shl ulong get Erx i mul i 8
192+end
193+if and ge n 14 le n 1514
194+for i ulong n
195+put Nrx i get Erx add 8 i
196+end
197+netinput n now
198+end
199+end
200+end
201+fn eftransmit now ulong to void
202+if or eq get Es 6 0 eq get Ntxlen 0 0
203+ret
204+end
205+n = get Ntxlen 0
206+for i ulong n
207+put Etx i get Ntx i
208+end
209+st = efi 7 0 Etx 0 n
210+note EFI_NOT_READY: the previous private copy is still owned by firmware; retry later.
211+if eq st 9223372036854775814
212+ret
213+end
214+netsent efok st now
215+end
216+fn efkeymap scan ulong ch ulong to ulong
217+if ne ch 0
218+ret ch
219+end
220+if eq scan 1
221+ret 256
222+end
223+if eq scan 2
224+ret 257
225+end
226+if eq scan 3
227+ret 261
228+end
229+if eq scan 4
230+ret 260
231+end
232+if eq scan 9
233+ret 258
234+end
235+if eq scan 10
236+ret 259
237+end
238+if eq scan 23
239+ret 27
240+end
241+ret 0
242+end
243+fn efkeys to bool
244+changed = false
245+for burst ulong 16
246+st = efi 1 0 Ek 0 4
247+if not efok st
248+ret changed
249+end
250+scan = or ulong get Ek 0 shl ulong get Ek 1 8
251+ch = or ulong get Ek 2 shl ulong get Ek 3 8
252+key = efkeymap scan ch
253+if ne key 0
254+ok = shkey key
255+changed = true
256+end
257+end
258+ret changed
259+end
260+fn efpointer to bool
261+st = efi 9 0 Ep 0 32
262+if not efok st
263+ret false
264+end
265+z = ulong 0
266+y = ulong 0
267+for i ulong 8
268+z = or z shl ulong get Ep add 24 i mul i 8
269+y = or y shl ulong get Ep add 16 i mul i 8
270+end
271+if ne get Dmo 0 1
272+ret false
273+end
274+note Wheel/scroll: signed rows. Drag with button held: accumulate vertical swipe.
275+if ne z 0
276+if ge z 9223372036854775808
277+ghscroll -3
278+else
279+ghscroll 3
280+end
281+ret true
282+end
283+if and ne and ulong get Ep 4 1 0 ne y 0
284+if ge y 9223372036854775808
285+ghswipe -1
286+else
287+ghswipe 1
288+end
289+ret true
290+end
291+ret false
292+end
293+fn efnet now ulong to void
294+if eq get Es 6 0
295+if ne get Ghreq 0 0
296+ok = ghreply get Ghreq 0 0 0 get Ghreq 2
297+end
298+ret
299+end
300+if and eq get Gs 0 0 ne get Ghreq 0 0
301+if not efentropy
302+ok = ghreply get Ghreq 0 0 0 get Ghreq 2
303+ret
304+end
305+epoch = efepoch
306+if eq epoch 0
307+put Es 12 4
308+note No usable firmware clock for certificate validity: stage 16 on the repository screen.
309+put Gdiag 0 16
310+ok = ghreply get Ghreq 0 0 0 get Ghreq 2
311+ret
312+end
313+gsnext now epoch
314+ret
315+end
316+if ge get Gs 0 4
317+put Gs 0 0
318+ret
319+end
320+gspoll now
321+end
322+fn efsig to ulong
323+v = get Gh 0
324+v = add v shl get Gh 1 8
325+v = add v shl get Gs 0 40
326+v = add v shl get Ghreq 0 48
327+v = add v shl get Dmo 0 56
328+ret v
329+end
330+fn efstep to int
331+now = efms
332+if eq now 18446744073709551615
333+ret 4
334+end
335+if eq get Es 6 0
336+note Keep trying to bring the firmware network up; the link may settle after boot.
337+if gt now add get Es 13 2000
338+put Es 13 now
339+efnetup now
340+end
341+end
342+efpackets now
343+changed = efkeys
344+if efpointer
345+put Sh 5 1
346+end
347+before = efsig
348+efnet now
349+if ne before efsig
350+put Sh 5 1
351+end
352+chstep now ne get Es 6 0
353+shanswer
354+ststep ne get Es 6 0
355+eftransmit now
356+if not shstep now
357+ret 6
358+end
359+st = efi 2 1000 Eb 0 0
360+ret 0
361+end
362+fn efdrain to void
363+note Discard keys left in the firmware buffer by the shell before the image started.
364+note Four consecutive empty reads prove the queue is quiet; 4096 bounds the loop.
365+empty = ulong 0
366+for i ulong 4096
367+st = efi 1 0 Ek 0 4
368+if not efok st
369+empty = add empty 1
370+if ge empty 4
371+break
372+end
373+else
374+empty = 0
375+end
376+end
377+end
378+fn efloop to int
379+for oloop ulong 1000
380+for tloop ulong 60000
381+rc = efstep
382+if ne rc 0
383+ret rc
384+end
385+end
386+end
387+ret 0
388+end
389+fn efbpaint rh ulong gh ulong bh ulong w ulong n ulong to bool
390+for r ulong n
391+base = mul mul r w 4
392+for x ulong w
393+at = add base mul x 4
394+put Efa at uchar bh
395+put Efa add at 1 uchar gh
396+put Efa add at 2 uchar rh
397+put Efa add at 3 0
398+end
399+end
400+arg = or w shl n 32
401+st = efi 3 arg Efa 0 mul mul w n 4
402+ret efok st
403+end
404+fn efbanner code ulong to int
405+note Paint a distinct colour for a failing stage, then hold it so a photograph is possible.
406+note No font or canvas dependency: this must work even when efscreen failed.
407+w = ulong 640
408+h = ulong 480
409+st = efi 0 0 Eb 0 64
410+if efok st
411+tw = or ulong get Eb 8 shl ulong get Eb 9 8
412+th = or ulong get Eb 12 shl ulong get Eb 13 8
413+if and gt tw 0 le tw 1280
414+w = tw
415+end
416+if and gt th 0 le th 800
417+h = th
418+end
419+end
420+note Colour encodes the failing stage: red/green/blue derived from code.
421+rr = and mul code 37 255
422+gg = and mul code 91 255
423+bb = and mul code 149 255
424+ok = efbpaint rr gg bb w h
425+for k ulong 12
426+st = efi 2 500000 Eb 0 0
427+end
428+ret int code
429+end
430+fn efpaint code ulong to void
431+note Paint the whole screen a colour derived from code and blit it. Used as a visible
432+note progress meter during startup, so a failure is identifiable from a photograph.
433+w = get Es 0
434+h = get Es 1
435+if or eq w 0 eq h 0
436+w = ulong 640
437+h = ulong 480
438+end
439+if gt mul mul w h 4 len Efa
440+h = div len Efa mul w 4
441+end
442+rr = and mul code 37 255
443+gg = and mul code 91 255
444+bb = and mul code 149 255
445+ok = efbpaint rr gg bb w h
446+end
447+fn main to int
448+constants
449+if not efscreen
450+ret efbanner 1
451+end
452+efpaint 1
453+dminit
454+efdrain
455+efpaint 2
456+now = efms
457+if eq now 18446744073709551615
458+ret efbanner 2
459+end
460+efpaint 3
461+efnetup now
462+efpaint 4
463+if not shinit now
464+ret efbanner 7
465+end
466+if not efentropy
467+put Es 12 5
468+end
469+run = or ulong get Gsrand 0 shl now 8
470+if eq run 0
471+run = 1
472+end
473+ok = chinit now run
474+put Es 7 1
475+rc = efloop
476+if ne rc 0
477+bad = add ulong 10 ulong rc
478+ret efbanner bad
479+end
480+ret 0
481+end

aienux/allen/font-data.om

new file mode 100644
@@ -0,0 +1,4 @@
1+note Declarative Allen glyph designs and integer sine samples, retained from
2+note native/kernel/ui/allen_font.c at4c7888f. No foreign executable implementation.
3+text Afdata "w6|w6 M3,0 L3,14 D3,20|w10 M3,0 L3,5 M7,0 L7,5|w15 M6,2 L4,20 M11,2 L9,20 M2,8 L13,8 M1,14 L12,14|w15 A8,5,5,5,-30,-270 A8,15,5,5,270,510 M8,-2 L8,22|w16 A4,4,2,3,0,360 A12,16,2,3,0,360 M13,1 L3,19|w16 M14,20 L5,9 A7,5,3,4,150,400 L3,14 A7,15,4,5,180,60 L13,11|w6 M3,0 L3,5|w9 A10,10,6,12,240,120|w9 A-1,10,6,12,-60,60|w14 M7,2 L7,10 M3,4 L11,8 M11,4 L3,8|w14 M2,12 L12,12 M7,7 L7,17|w6 M3,19 L2,23|w11 M2,13 L9,13|w6 D3,20|w12 M10,0 L2,20|w14 A7,10,5,10,0,360|w14 M3,4 L8,0 L8,20|w14 A7,6,5,6,200,400 L2,20 L12,20|w14 A7,5,5,5,200,450 A7,15,5,5,270,520|w14 M10,20 L10,0 L1,14 L13,14|w14 M12,0 L4,0 L4,9 A7,14,5,6,235,520|w14 A7,14,5,6,0,360 M10,0 L3,11|w14 M2,0 L12,0 L5,20|w14 A7,5,4,5,0,360 A7,15,5,5,0,360|w14 A7,6,5,6,0,360 M4,20 L11,9|w6 D3,8 D3,20|w6 D3,8 M3,19 L2,23|w14 M12,6 L2,12 L12,18|w14 M2,10 L12,10 M2,15 L12,15|w14 M2,6 L12,12 L2,18|w14 A7,5,5,5,190,450 L7,14 D7,20|w19 A9,12,3,4,0,360 M12,8 L12,14 A14,14,2,2,180,0 A9,11,7,9,0,-300|w16 M2,20 L8,0 L14,20 M4,13 L12,13|w15 M2,0 L2,20 M2,0 L8,0 A8,5,4,5,270,450 L2,10 M2,10 L9,10 A9,15,4,5,270,450 L2,20|w17 A9,10,7,10,45,315|w16 M2,0 L2,20 M2,0 L6,0 A6,10,8,10,270,450 L2,20|w14 M12,0 L2,0 L2,20 L12,20 M2,10 L10,10|w13 M12,0 L2,0 L2,20 M2,10 L10,10|w18 A9,10,7,10,-45,-360 M11,10 L16,10|w16 M2,0 L2,20 M14,0 L14,20 M2,10 L14,10|w6 M3,0 L3,20|w13 M10,0 L10,14 A6,14,4,6,0,180|w15 M2,0 L2,20 M13,0 L2,12 M6,8 L14,20|w13 M2,0 L2,20 L12,20|w20 M2,20 L2,0 L10,14 L18,0 L18,20|w16 M2,20 L2,0 L14,20 L14,0|w20 A10,10,8,10,0,360|w15 M2,20 L2,0 L8,0 A8,5,5,5,270,450 L2,10|w20 A10,10,8,10,0,360 M12,14 L18,21|w15 M2,20 L2,0 L8,0 A8,5,5,5,270,450 L2,10 M8,10 L14,20|w16 A8,5,5,5,-30,-270 A8,15,5,5,270,510|w16 M1,0 L15,0 M8,0 L8,20|w16 M2,0 L2,13 A8,13,6,7,180,0 L14,0|w16 M1,0 L8,20 L15,0|w22 M1,0 L6,20 L11,0 L16,20 L21,0|w16 M2,0 L14,20 M14,0 L2,20|w16 M1,0 L8,10 L15,0 M8,10 L8,20|w16 M2,0 L14,0 L2,20 L14,20|w9 M7,-1 L3,-1 L3,21 L7,21|w12 M2,0 L10,20|w9 M2,-1 L6,-1 L6,21 L2,21|w12 M2,8 L6,1 L10,8|w14 M1,23 L13,23|w7 M2,0 L4,4|w15 A7,14,5,6,0,360 M12,8 L12,20|w15 M2,0 L2,20 A7,14,5,6,0,360|w13 A7,14,5,6,40,320|w15 A7,14,5,6,0,360 M12,0 L12,20|w14 M2,14 L12,14 A7,14,5,6,0,-320|w11 M5,20 L5,4 A9,4,4,4,180,300 M2,8 L10,8|w15 A7,14,5,6,0,360 M12,8 L12,22 A7,22,5,5,0,150|w15 M2,0 L2,20 A7,13,5,5,180,360 L12,20|w6 M3,8 L3,20 D3,3|w7 M4,8 L4,22 A0,22,4,5,0,120 D4,3|w13 M2,0 L2,20 M11,8 L2,15 M5,13 L12,20|w6 M3,0 L3,20|w21 M2,8 L2,20 A6,12,4,4,180,360 L10,20 A14,12,4,4,180,360 L18,20|w15 M2,8 L2,20 A7,13,5,5,180,360 L12,20|w14 A7,14,5,6,0,360|w15 M2,8 L2,27 A7,14,5,6,0,360|w15 A7,14,5,6,0,360 M12,8 L12,27|w10 M2,8 L2,20 A7,13,5,5,180,290|w14 A7,11,4,3,-30,-270 A7,17,4,3,270,510|w11 M5,2 L5,17 A8,17,3,3,180,40 M2,8 L10,8|w15 M2,8 L2,15 A7,15,5,5,180,0 M12,8 L12,20|w14 M2,8 L7,20 L12,8|w20 M2,8 L6,20 L10,8 L14,20 L18,8|w14 M2,8 L12,20 M12,8 L2,20|w14 M2,8 L7,20 M12,8 L4,27|w14 M2,8 L12,8 L2,20 L12,20|w10 M8,-1 L6,0 L6,8 L4,10 L6,12 L6,20 L8,21|w6 M3,-1 L3,23|w10 M2,-1 L4,0 L4,8 L6,10 L4,12 L4,20 L2,21|w14 M2,13 L5,11 L9,14 L12,12|"
4+text Afsines "0 286 572 857 1143 1428 1713 1997 2280 2563 2845 3126 3406 3686 3964 4240 4516 4790 5063 5334 5604 5872 6138 6402 6664 6924 7182 7438 7692 7943 8192 8438 8682 8923 9162 9397 9630 9860 10087 10311 10531 10749 10963 11174 11381 11585 11786 11982 12176 12365 12551 12733 12911 13085 13255 13421 13583 13741 13894 14044 14189 14330 14466 14598 14726 14849 14968 15082 15191 15296 15396 15491 15582 15668 15749 15826 15897 15964 16026 16083 16135 16182 16225 16262 16294 16322 16344 16362 16374 16382 16384 "

aienux/allen/font.om

new file mode 100644
@@ -0,0 +1,326 @@
1+note Handwritten bounded Allen stroke rasterizer. Legacy C is an external oracle only.
2+global Af ulong 6
3+global Ab long 4
4+global Ag long 640
5+global Alpha uchar 65536
6+global Asin long 91
7+global Afpos ulong 2
8+global Apen long 2
9+global Arc long 6
10+fn afsqrt value ulong to ulong
11+r = ulong 0
12+bit = shl ulong 1 62
13+while gt bit value
14+bit = shr bit 2
15+end
16+while ne bit 0
17+if ge value add r bit
18+value = sub value add r bit
19+r = add shr r 1 bit
20+else
21+r = shr r 1
22+end
23+bit = shr bit 2
24+end
25+ret r
26+end
27+fn afsin deg long to long
28+a = rem deg 360
29+if lt a 0
30+a = add a 360
31+end
32+if le a 90
33+ret get Asin ulong a
34+end
35+if le a 180
36+ret get Asin ulong sub long 180 a
37+end
38+if le a 270
39+ret neg get Asin ulong sub a 180
40+end
41+ret neg get Asin ulong sub long 360 a
42+end
43+fn afcos deg long to long
44+ret afsin add rem deg 360 90
45+end
46+fn afinit cap ulong wt ulong to bool
47+if or eq cap 0 gt cap 64
48+ret false
49+end
50+if or eq wt 0 gt wt 2500
51+ret false
52+end
53+for i ulong 6
54+put Af i 0
55+end
56+put Af 0 div mul cap 256 20
57+put Af 1 div mul wt get Af 0 1000
58+v = long 0
59+slot = ulong 0
60+for i ulong len Afsines
61+c = get Afsines i
62+if eq c 32
63+put Asin slot v
64+slot = add slot 1
65+v = 0
66+else
67+v = add mul v 10 sub long c 48
68+end
69+end
70+ret eq slot 91
71+end
72+fn afpick c uchar to bool
73+if or lt c 32 gt c 126
74+c = 63
75+end
76+wanted = sub ulong c 32
77+slot = ulong 0
78+startat = ulong 0
79+for i ulong len Afdata
80+if eq get Afdata i 124
81+if eq slot wanted
82+put Afpos 0 startat
83+put Afpos 1 i
84+ret true
85+end
86+slot = add slot 1
87+startat = add i 1
88+end
89+end
90+ret false
91+end
92+fn afnum to long
93+p = get Afpos 0
94+minus = false
95+if eq get Afdata p 45
96+minus = true
97+p = add p 1
98+end
99+v = long 0
100+go = true
101+while and lt p get Afpos 1 go
102+c = get Afdata p
103+if and ge c 48 le c 57
104+v = add mul v 10 sub long c 48
105+p = add p 1
106+else
107+go = false
108+end
109+end
110+if lt p get Afpos 1
111+if eq get Afdata p 44
112+p = add p 1
113+end
114+end
115+put Afpos 0 p
116+if minus
117+ret neg v
118+end
119+ret v
120+end
121+fn afseg nx long ny long to bool
122+n = get Af 2
123+if ge n 160
124+ret false
125+end
126+at = mul n 4
127+put Ag at get Apen 0
128+put Ag add at 1 get Apen 1
129+put Ag add at 2 nx
130+put Ag add at 3 ny
131+put Apen 0 nx
132+put Apen 1 ny
133+put Af 2 add n 1
134+ret true
135+end
136+fn afpoint a long first bool to bool
137+s = long get Af 0
138+x = mul get Arc 0 s
139+x = add x div mul mul get Arc 2 s afcos a 16384
140+y = mul sub get Arc 1 20 s
141+y = add y div mul mul get Arc 3 s afsin a 16384
142+if first
143+put Apen 0 x
144+put Apen 1 y
145+ret true
146+end
147+ret afseg x y
148+end
149+fn afarc to bool
150+for i ulong 6
151+put Arc i afnum
152+end
153+span = sub get Arc 5 get Arc 4
154+if lt span 0
155+span = neg span
156+end
157+steps = div span 9
158+if lt steps 2
159+steps = 2
160+end
161+for k ulong ulong add steps 1
162+a = sub get Arc 5 get Arc 4
163+a = add get Arc 4 div mul a long k steps
164+if not afpoint a eq k 0
165+ret false
166+end
167+end
168+ret true
169+end
170+fn afcmd cmd uchar to bool
171+if eq cmd 32
172+ret true
173+end
174+if eq cmd 119
175+put Af 5 mul ulong afnum get Af 0
176+ret true
177+end
178+if eq cmd 65
179+ret afarc
180+end
181+x = mul afnum long get Af 0
182+y = mul sub afnum 20 long get Af 0
183+if or eq cmd 77 eq cmd 68
184+put Apen 0 x
185+put Apen 1 y
186+end
187+if eq cmd 77
188+ret true
189+end
190+if or eq cmd 76 eq cmd 68
191+ret afseg x y
192+end
193+ret false
194+end
195+fn affloor value long to long
196+if ge value 0
197+ret div value 256
198+end
199+ret neg div add neg value 255 256
200+end
201+fn afbound x long y long to void
202+if lt x get Ab 0
203+put Ab 0 x
204+end
205+if lt y get Ab 1
206+put Ab 1 y
207+end
208+if gt x get Ab 2
209+put Ab 2 x
210+end
211+if gt y get Ab 3
212+put Ab 3 y
213+end
214+end
215+fn afbox to bool
216+put Ab 0 get Ag 0
217+put Ab 2 get Ag 0
218+put Ab 1 get Ag 1
219+put Ab 3 get Ag 1
220+for i ulong get Af 2
221+at = mul i 4
222+afbound get Ag at get Ag add at 1
223+afbound get Ag add at 2 get Ag add at 3
224+end
225+pad = add long get Af 1 256
226+x0 = affloor sub get Ab 0 pad
227+y0 = affloor sub get Ab 1 pad
228+x1 = add affloor add get Ab 2 pad 1
229+y1 = add affloor add get Ab 3 pad 1
230+put Ab 0 x0
231+put Ab 1 y0
232+put Af 3 ulong sub x1 x0
233+put Af 4 ulong sub y1 y0
234+ret le mul get Af 3 get Af 4 len Alpha
235+end
236+fn afproj qx long qy long dx long dy long to ulong
237+len2 = add mul dx dx mul dy dy
238+ex = qx
239+ey = qy
240+if ne len2 0
241+t = add mul qx dx mul qy dy
242+if gt t 0
243+if ge t len2
244+ex = sub qx dx
245+ey = sub qy dy
246+else
247+ex = sub qx div mul dx t len2
248+ey = sub qy div mul dy t len2
249+end
250+end
251+end
252+ret ulong add mul ex ex mul ey ey
253+end
254+fn afdist slot ulong px long py long to ulong
255+at = mul slot 4
256+dx = sub get Ag add at 2 get Ag at
257+dy = sub get Ag add at 3 get Ag add at 1
258+qx = sub px get Ag at
259+qy = sub py get Ag add at 1
260+ret afproj qx qy dx dy
261+end
262+fn afalpha px long py long to uchar
263+best = ulong 18446744073709551615
264+for i ulong get Af 2
265+d2 = afdist i px py
266+if lt d2 best
267+best = d2
268+end
269+end
270+d = long afsqrt best
271+cov = sub add long get Af 1 128 d
272+if le cov 0
273+ret 0
274+end
275+if ge cov 256
276+ret 255
277+end
278+ret uchar div mul cov 255 256
279+end
280+fn afrow y ulong to void
281+py = add mul add get Ab 1 long y 256 128
282+for x ulong get Af 3
283+px = add mul add get Ab 0 long x 256 128
284+at = add mul y get Af 3 x
285+put Alpha at afalpha px py
286+end
287+end
288+fn afpaint to void
289+for y ulong get Af 4
290+afrow y
291+end
292+end
293+fn afglyph c uchar to bool
294+if eq get Af 0 0
295+ret false
296+end
297+if not afpick c
298+ret false
299+end
300+for i ulong 65536
301+put Alpha i 0
302+end
303+put Af 2 0
304+put Af 3 0
305+put Af 4 1
306+put Af 5 0
307+put Ab 0 0
308+put Ab 1 0
309+put Apen 0 0
310+put Apen 1 0
311+while lt get Afpos 0 get Afpos 1
312+cmd = get Afdata get Afpos 0
313+put Afpos 0 add get Afpos 0 1
314+if not afcmd cmd
315+ret false
316+end
317+end
318+if eq get Af 2 0
319+ret true
320+end
321+if not afbox
322+ret false
323+end
324+afpaint
325+ret true
326+end

aienux/allen/github.om

new file mode 100644
@@ -0,0 +1,1250 @@
1+note SPDX-License-Identifier: AGPL-3.0-only
2+note Strict JSON copied unchanged from omega-mv native/hermes/src/json.om.
3+note Source revision b8e57bc6be5e40efc1d0d1ce01afdc58e814b449; single pinned parser.
4+note SPDX-License-Identifier: AGPL-3.0-only
5+note Bounded strict JSON. Tokens are valid only when jparse returns zero.
6+note Types object1 array2 string3 number4 true5 false6 null7.
7+note Raw token spans include string quotes; parent4096 denotes root.
8+global jin uchar 65536
9+global jerr ulong 1
10+global jcnt ulong 1
11+global jbeg ulong 4096
12+global jend ulong 4096
13+global jtyp ulong 4096
14+global jpar ulong 4096
15+global jpos ulong 1
16+global jlen ulong 1
17+fn jfail to void
18+put jerr 0 1
19+end
20+fn jpeek to ulong
21+p = get jpos 0
22+if ge p get jlen 0
23+ret 256
24+end
25+ret ulong get jin p
26+end
27+fn jtake to ulong
28+c = jpeek
29+if eq c 256
30+jfail
31+else
32+put jpos 0 add get jpos 0 1
33+end
34+ret c
35+end
36+fn jspace to void
37+c = jpeek
38+while or or eq c 32 eq c 9 or eq c 10 eq c 13
39+c = jtake
40+c = jpeek
41+end
42+end
43+fn jexpect want ulong to void
44+if ne jtake want
45+jfail
46+end
47+end
48+fn jhex to ulong
49+v = ulong 0
50+for i ulong 4
51+c = jtake
52+d = ulong 16
53+if and ge c 48 le c 57
54+d = sub c 48
55+end
56+if and ge c 65 le c 70
57+d = sub c 55
58+end
59+if and ge c 97 le c 102
60+d = sub c 87
61+end
62+if eq d 16
63+jfail
64+ret 0
65+end
66+v = add mul v 16 d
67+end
68+ret v
69+end
70+fn jutf c ulong to void
71+n = ulong 0
72+lo = ulong 128
73+hi = ulong 191
74+if and ge c 194 le c 223
75+n = 1
76+end
77+if and ge c 224 le c 239
78+n = 2
79+if eq c 224
80+lo = 160
81+end
82+if eq c 237
83+hi = 159
84+end
85+end
86+if and ge c 240 le c 244
87+n = 3
88+if eq c 240
89+lo = 144
90+end
91+if eq c 244
92+hi = 143
93+end
94+end
95+if eq n 0
96+jfail
97+ret
98+end
99+for i ulong n
100+d = jtake
101+if or lt d lo gt d hi
102+jfail
103+ret
104+end
105+lo = 128
106+hi = 191
107+end
108+end
109+fn jstring to void
110+jexpect 34
111+while eq get jerr 0 0
112+c = jtake
113+if eq c 34
114+ret
115+end
116+if or lt c 32 eq c 256
117+jfail
118+ret
119+end
120+if eq c 92
121+c = jtake
122+if eq c 117
123+u = jhex
124+if and ge u 55296 le u 56319
125+jexpect 92
126+jexpect 117
127+v = jhex
128+if or lt v 56320 gt v 57343
129+jfail
130+end
131+else
132+if and ge u 56320 le u 57343
133+jfail
134+end
135+end
136+else
137+ok = or or eq c 34 eq c 92 eq c 47
138+ok = or ok or eq c 98 eq c 102
139+ok = or ok or eq c 110 eq c 114
140+ok = or ok eq c 116
141+if not ok
142+jfail
143+end
144+end
145+else
146+if ge c 128
147+jutf c
148+end
149+end
150+end
151+end
152+fn jdigit c ulong to bool
153+ret and ge c 48 le c 57
154+end
155+fn jdigits to void
156+if not jdigit jpeek
157+jfail
158+ret
159+end
160+while jdigit jpeek
161+c = jtake
162+end
163+end
164+fn jnumber to void
165+if eq jpeek 45
166+c = jtake
167+end
168+if eq jpeek 48
169+c = jtake
170+else
171+jdigits
172+end
173+if eq jpeek 46
174+c = jtake
175+jdigits
176+end
177+if or eq jpeek 101 eq jpeek 69
178+c = jtake
179+if or eq jpeek 43 eq jpeek 45
180+c = jtake
181+end
182+jdigits
183+end
184+end
185+fn jtoken typ ulong par ulong to ulong
186+n = get jcnt 0
187+if ge n 4096
188+jfail
189+ret 4096
190+end
191+put jcnt 0 add n 1
192+put jbeg n get jpos 0
193+put jtyp n typ
194+put jpar n par
195+ret n
196+end
197+fn jvalue par ulong depth ulong to void
198+jspace
199+c = jpeek
200+t = ulong 0
201+if eq c 123
202+t = 1
203+end
204+if eq c 91
205+t = 2
206+end
207+if eq c 34
208+t = 3
209+end
210+if or eq c 45 jdigit c
211+t = 4
212+end
213+if eq c 116
214+t = 5
215+end
216+if eq c 102
217+t = 6
218+end
219+if eq c 110
220+t = 7
221+end
222+if eq t 0
223+jfail
224+ret
225+end
226+id = jtoken t par
227+if ne get jerr 0 0
228+ret
229+end
230+if le t 2
231+if ge depth 32
232+jfail
233+ret
234+end
235+c = jtake
236+closing = ulong 93
237+if eq t 1
238+closing = 125
239+end
240+jspace
241+if ne jpeek closing
242+more = true
243+while and more eq get jerr 0 0
244+if eq t 1
245+if ne jpeek 34
246+jfail
247+ret
248+end
249+key = jtoken 3 id
250+if ne get jerr 0 0
251+ret
252+end
253+jstring
254+put jend key get jpos 0
255+jspace
256+jexpect 58
257+end
258+if eq get jerr 0 0
259+jvalue id add depth 1
260+end
261+jspace
262+if eq jpeek 44
263+c = jtake
264+jspace
265+else
266+more = false
267+end
268+end
269+end
270+jexpect closing
271+else
272+if eq t 3
273+jstring
274+end
275+if eq t 4
276+jnumber
277+end
278+if eq t 5
279+jexpect 116
280+jexpect 114
281+jexpect 117
282+jexpect 101
283+end
284+if eq t 6
285+jexpect 102
286+jexpect 97
287+jexpect 108
288+jexpect 115
289+jexpect 101
290+end
291+if eq t 7
292+jexpect 110
293+jexpect 117
294+jexpect 108
295+jexpect 108
296+end
297+end
298+put jend id get jpos 0
299+end
300+fn jparse n ulong to ulong
301+put jerr 0 0
302+put jcnt 0 0
303+put jpos 0 0
304+put jlen 0 n
305+if or eq n 0 gt n len jin
306+jfail
307+ret 1
308+end
309+jvalue 4096 0
310+jspace
311+if ne get jpos 0 n
312+jfail
313+end
314+if ne get jerr 0 0
315+put jcnt 0 0
316+end
317+ret get jerr 0
318+end
319+
320+note Network provider owns transport and writes only complete authenticated HTTPS bodies.
321+note Host api.github.com; no redirects or credentials. Ghreq path is not a URL.
322+note Ghreq kind,pathlen,unique generation,accept raw1/json0,maxbody,reserved3.
323+note ghreply must echo kind AND generation. Timeout/network failure uses status0.
324+global Ghbody uchar 262144
325+global Ghpath uchar 1024
326+global Ghreq ulong 8
327+note Gh state0 idle1 loading2 ready3 error4 unsupported; generation; error; HTTP;
328+note view0 README1 files2 details; scroll; selected; read bytes; file count;
329+note pool bytes; directory bytes; clock; last accepted generation; readme absent.
330+global Gh ulong 16
331+global Ghat ulong 4
332+global Ghmeta uchar 1024
333+note Metadata offsets name0/64, branch64/256, description320/512, sha832/64,date896/64.
334+global Ghlen ulong 8
335+global Ghread uchar 262144
336+global Ghdir uchar 512
337+global Ghpool uchar 65536
338+note Five words per directory entry: path offset,length,type(file1 dir2 other3),bytes,sha offset.
339+global Ghfiles ulong 1280
340+global Ghdec uchar 4096
341+global Ghdn ulong 1
342+global Ghbad ulong 1
343+global Ghword uchar 160
344+note Repository identity is DISCOVERED from a live listing and validated, never fixed.
345+note Ghmeta 720/64 holds the selected full_name; 784/48 holds its created_at.
346+global Ghbase uchar 128
347+global Ghslen ulong 1
348+text Ghext "/repos/"
349+text Ghghu "https://github.com/"
350+text Ghown "aien-dev/"
351+text Ghlst "/orgs/aien-dev/repos?sort=created&direction=desc&per_page=1"
352+text Ghkeys "full_name\ndefault_branch\ndescription\nprivate\nhtml_url\nsha\ncommit\ncommitter\ndate\npath\ntype\nsize\ncreated_at\n"
353+text Ghsuf "/commits//readme?ref=/contents"
354+text Ghhex "0123456789ABCDEF"
355+text Ghvoc "repo\nrepository\nrepositories\ngit\ngithub\nfind\nshow\nopen\nbrowse\nwhere\nwhat\ncurrent\nyour\nallen\nsource\ncode\ncreate\ndelete\npush\nother\n"
356+note Select the first repository in the live listing, then prove its identity before use.
357+note Ordering is the server's (sort=created, direction=desc); we do not re-sort, we verify.
358+note The listing is a JSON array; token 0 is the array and token 1 its first object.
359+fn ghdiscover to bool
360+if or lt get jcnt 0 2 ne get jtyp 0 2
361+ret false
362+end
363+if or ne get jtyp 1 1 ne get jpar 1 0
364+ret false
365+end
366+if not ghcopy ghfield 1 1 720 64 5
367+ret false
368+end
369+n = get Ghlen 5
370+if le n len Ghown
371+ret false
372+end
373+for i ulong len Ghown
374+if ne get Ghmeta add 720 i get Ghown i
375+ret false
376+end
377+end
378+first = add 720 len Ghown
379+last = add 719 n
380+if or eq get Ghmeta first 46 eq get Ghmeta first 45
381+ret false
382+end
383+if or eq get Ghmeta last 46 eq get Ghmeta last 45
384+ret false
385+end
386+for i ulong sub n len Ghown
387+c = get Ghmeta add first i
388+ok = and ge c 48 le c 57
389+ok = or ok and ge c 65 le c 90
390+ok = or ok and ge c 97 le c 122
391+ok = or ok or eq c 46 eq c 95
392+ok = or ok eq c 45
393+if not ok
394+ret false
395+end
396+end
397+if not ghcopy ghfield 1 13 784 48 6
398+ret false
399+end
400+if ne get Ghlen 6 20
401+ret false
402+end
403+for i ulong 20
404+c = get Ghmeta add 784 i
405+want = uchar 0
406+if or eq i 4 eq i 7
407+want = 45
408+end
409+if eq i 10
410+want = 84
411+end
412+if or eq i 13 eq i 16
413+want = 58
414+end
415+if eq i 19
416+want = 90
417+end
418+if ne want 0
419+if ne c want
420+ret false
421+end
422+else
423+if or lt c 48 gt c 57
424+ret false
425+end
426+end
427+end
428+ret eq get Ghbad 0 0
429+end
430+fn gherror code ulong to void
431+put Gh 0 3
432+put Gh 2 code
433+put Ghreq 0 0
434+note Existing bytes are never drawn as current after an error.
435+end
436+fn ghtime epoch ulong to void
437+put Gh 11 epoch
438+end
439+fn ghinit to void
440+for i ulong 16
441+put Gh i 0
442+end
443+for i ulong 8
444+put Ghreq i 0
445+put Ghlen i 0
446+end
447+for i ulong 4
448+put Ghat i 0
449+end
450+end
451+fn ghreset to void
452+for i ulong 8
453+put Ghlen i 0
454+end
455+for i ulong 4
456+put Ghat i 0
457+end
458+put Gh 2 0
459+put Gh 3 0
460+put Gh 4 0
461+put Gh 5 0
462+put Gh 6 0
463+put Gh 7 0
464+put Gh 8 0
465+put Gh 9 0
466+put Gh 10 0
467+put Gh 12 0
468+put Gh 13 0
469+end
470+fn ghbyte c uchar to void
471+n = get Ghreq 1
472+if ge n len Ghpath
473+put Ghbad 0 1
474+ret
475+end
476+put Ghpath n c
477+put Ghreq 1 add n 1
478+end
479+fn ghenc c uchar to void
480+ok = or and ge c 65 le c 90 and ge c 97 le c 122
481+ok = or ok and ge c 48 le c 57
482+ok = or ok or eq c 45 eq c 95
483+ok = or ok or eq c 46 eq c 126
484+if ok
485+ghbyte c
486+else
487+ghbyte 37
488+ghbyte get Ghhex div ulong c 16
489+ghbyte get Ghhex rem ulong c 16
490+end
491+end
492+fn ghbasebuf to bool
493+note Ghbase = "/repos/" + the validated full_name held at Ghmeta 720.
494+n = get Ghlen 5
495+if or eq n 0 gt n 64
496+ret false
497+end
498+put Ghslen 0 0
499+for i ulong len Ghext
500+put Ghbase i get Ghext i
501+put Ghslen 0 add i 1
502+end
503+for i ulong n
504+put Ghbase add len Ghext i get Ghmeta add 720 i
505+end
506+put Ghslen 0 add len Ghext n
507+ret true
508+end
509+fn ghissue kind ulong to void
510+if eq get Gh 1 18446744073709551615
511+gherror 8
512+ret
513+end
514+put Gh 1 add get Gh 1 1
515+put Ghreq 0 kind
516+put Ghreq 1 0
517+put Ghreq 2 get Gh 1
518+put Ghreq 3 0
519+put Ghreq 4 65536
520+put Ghbad 0 0
521+note Clock is per response, never inherited as a fresh retrieval timestamp.
522+put Gh 11 0
523+if eq kind 5
524+for i ulong len Ghlst
525+ghbyte get Ghlst i
526+end
527+else
528+if not ghbasebuf
529+gherror 3
530+ret
531+end
532+for i ulong get Ghslen 0
533+ghbyte get Ghbase i
534+end
535+end
536+if eq kind 2
537+for i ulong 9
538+ghbyte get Ghsuf i
539+end
540+for i ulong get Ghlen 1
541+ghenc get Ghmeta add 64 i
542+end
543+end
544+if eq kind 3
545+put Ghreq 3 1
546+put Ghreq 4 len Ghbody
547+for i ulong 12
548+ghbyte get Ghsuf add 9 i
549+end
550+end
551+if eq kind 4
552+for i ulong 9
553+ghbyte get Ghsuf add 21 i
554+end
555+if gt get Gh 10 0
556+ghbyte 47
557+for i ulong get Gh 10
558+c = get Ghdir i
559+if eq c 47
560+ghbyte c
561+else
562+ghenc c
563+end
564+end
565+end
566+ghbyte 63
567+ghbyte 114
568+ghbyte 101
569+ghbyte 102
570+ghbyte 61
571+end
572+if or eq kind 3 eq kind 4
573+for i ulong get Ghlen 3
574+ghbyte get Ghmeta add 832 i
575+end
576+end
577+if ne get Ghbad 0 0
578+gherror 8
579+ret
580+end
581+put Gh 0 1
582+end
583+fn ghrefresh to void
584+ghreset
585+ghissue 5
586+end
587+note Intent is bounded word classification, not a canned prompt equality.
588+fn ghvocab n ulong to ulong
589+word = ulong 1
590+at = ulong 0
591+same = true
592+for i ulong len Ghvoc
593+c = get Ghvoc i
594+if eq c 10
595+if and same eq at n
596+ret word
597+end
598+word = add word 1
599+at = 0
600+same = true
601+else
602+if ge at n
603+same = false
604+else
605+if ne c get Ghword at
606+same = false
607+end
608+end
609+at = add at 1
610+end
611+end
612+ret 0
613+end
614+fn ghask to bool
615+ghreset
616+put Ghreq 0 0
617+put Gh 0 4
618+n = get Inlen 0
619+if or eq n 0 gt n 159
620+ret false
621+end
622+bits = ulong 0
623+at = ulong 0
624+for i ulong add n 1
625+c = uchar 32
626+if lt i n
627+c = get In i
628+end
629+if and ge c 65 le c 90
630+c = add sub c 65 97
631+end
632+if and ge c 97 le c 122
633+put Ghword at c
634+at = add at 1
635+else
636+if or eq c 47 eq c 58
637+ret false
638+end
639+if gt at 0
640+w = ghvocab at
641+if and ge w 1 le w 5
642+bits = or bits 1
643+end
644+if and ge w 6 le w 16
645+bits = or bits 2
646+end
647+if ge w 17
648+ret false
649+end
650+at = 0
651+end
652+end
653+end
654+if ne bits 3
655+ret false
656+end
657+ghissue 5
658+ret true
659+end
660+note Decode only validated JSON strings, preserving UTF8. No renderer executes text.
661+fn ghdbyte c ulong to void
662+n = get Ghdn 0
663+if ge n len Ghdec
664+put Ghbad 0 1
665+ret
666+end
667+put Ghdec n uchar c
668+put Ghdn 0 add n 1
669+end
670+fn ghutf cp ulong to void
671+if lt cp 128
672+ghdbyte cp
673+else
674+if lt cp 2048
675+ghdbyte add 192 shr cp 6
676+ghdbyte add 128 and cp 63
677+else
678+if lt cp 65536
679+ghdbyte add 224 shr cp 12
680+ghdbyte add 128 and shr cp 6 63
681+ghdbyte add 128 and cp 63
682+else
683+ghdbyte add 240 shr cp 18
684+ghdbyte add 128 and shr cp 12 63
685+ghdbyte add 128 and shr cp 6 63
686+ghdbyte add 128 and cp 63
687+end
688+end
689+end
690+end
691+fn ghdecode id ulong to bool
692+put Ghdn 0 0
693+if ge id get jcnt 0
694+ret false
695+end
696+if ne get jtyp id 3
697+ret false
698+end
699+put jpos 0 add get jbeg id 1
700+stop = sub get jend id 1
701+while lt get jpos 0 stop
702+c = jtake
703+if eq c 92
704+c = jtake
705+if eq c 117
706+c = jhex
707+if and ge c 55296 le c 56319
708+put jpos 0 add get jpos 0 2
709+v = jhex
710+c = add 65536 add mul sub c 55296 1024 sub v 56320
711+end
712+ghutf c
713+else
714+if eq c 98
715+c = 8
716+end
717+if eq c 102
718+c = 12
719+end
720+if eq c 110
721+c = 10
722+end
723+if eq c 114
724+c = 13
725+end
726+if eq c 116
727+c = 9
728+end
729+ghdbyte c
730+end
731+else
732+ghdbyte c
733+end
734+if ne get Ghbad 0 0
735+ret false
736+end
737+end
738+ret true
739+end
740+fn ghwhich id ulong to ulong
741+if not ghdecode id
742+ret 0
743+end
744+word = ulong 1
745+at = ulong 0
746+same = true
747+for i ulong len Ghkeys
748+c = get Ghkeys i
749+if eq c 10
750+if and same eq at get Ghdn 0
751+ret word
752+end
753+word = add word 1
754+at = 0
755+same = true
756+else
757+if ge at get Ghdn 0
758+same = false
759+else
760+if ne c get Ghdec at
761+same = false
762+end
763+end
764+at = add at 1
765+end
766+end
767+ret 0
768+end
769+fn ghnext id ulong to ulong
770+stop = get jend id
771+i = add id 1
772+while lt i get jcnt 0
773+if ge get jbeg i stop
774+ret i
775+end
776+i = add i 1
777+end
778+ret i
779+end
780+note Lookup validates object and rejects duplicate decoded keys for each consumed field.
781+fn ghfield obj ulong key ulong to ulong
782+if ge obj get jcnt 0
783+put Ghbad 0 1
784+ret 4096
785+end
786+if ne get jtyp obj 1
787+put Ghbad 0 1
788+ret 4096
789+end
790+found = ulong 4096
791+i = add obj 1
792+while lt i get jcnt 0
793+if ge get jbeg i get jend obj
794+ret found
795+end
796+if eq ghwhich i key
797+if ne found 4096
798+put Ghbad 0 1
799+end
800+found = add i 1
801+end
802+i = ghnext add i 1
803+end
804+ret found
805+end
806+fn ghcopy id ulong off ulong cap ulong slot ulong to bool
807+if not ghdecode id
808+ret false
809+end
810+n = get Ghdn 0
811+if gt n cap
812+ret false
813+end
814+for i ulong n
815+c = get Ghdec i
816+if lt c 32
817+ret false
818+end
819+put Ghmeta add off i c
820+end
821+put Ghlen slot n
822+ret true
823+end
824+fn ghbranch to bool
825+n = get Ghlen 1
826+if eq n 0
827+ret false
828+end
829+for i ulong n
830+c = get Ghmeta add 64 i
831+if or lt c 33 eq c 127
832+ret false
833+end
834+end
835+ret true
836+end
837+fn ghmetadata to bool
838+if not ghcopy ghfield 0 1 0 64 0
839+ret false
840+end
841+if eq get Ghlen 5 0
842+ret false
843+end
844+if ne get Ghlen 0 get Ghlen 5
845+ret false
846+end
847+for i ulong get Ghlen 5
848+if ne get Ghmeta i get Ghmeta add 720 i
849+ret false
850+end
851+end
852+id = ghfield 0 4
853+if eq id 4096
854+ret false
855+end
856+if ne get jtyp id 6
857+ret false
858+end
859+if not ghdecode ghfield 0 5
860+ret false
861+end
862+if ne get Ghdn 0 add len Ghghu get Ghlen 5
863+ret false
864+end
865+for i ulong len Ghghu
866+if ne get Ghdec i get Ghghu i
867+ret false
868+end
869+end
870+for i ulong get Ghlen 5
871+if ne get Ghdec add len Ghghu i get Ghmeta add 720 i
872+ret false
873+end
874+end
875+if not ghcopy ghfield 0 2 64 256 1
876+ret false
877+end
878+if not ghbranch
879+ret false
880+end
881+id = ghfield 0 3
882+if eq id 4096
883+ret false
884+end
885+if ne get jtyp id 7
886+if not ghcopy id 320 512 2
887+ret false
888+end
889+end
890+ret eq get Ghbad 0 0
891+end
892+fn ghsha to bool
893+if ne get Ghdn 0 40
894+ret false
895+end
896+for i ulong 40
897+c = get Ghdec i
898+ok = or and ge c 48 le c 57 and ge c 97 le c 102
899+if not ok
900+ret false
901+end
902+end
903+ret true
904+end
905+fn ghcommit to bool
906+if not ghdecode ghfield 0 6
907+ret false
908+end
909+if not ghsha
910+ret false
911+end
912+for i ulong 40
913+put Ghmeta add 832 i get Ghdec i
914+end
915+put Ghlen 3 40
916+id = ghfield 0 7
917+id = ghfield id 8
918+id = ghfield id 9
919+if not ghcopy id 896 64 4
920+ret false
921+end
922+if ne get Ghlen 4 20
923+ret false
924+end
925+for i ulong 20
926+c = get Ghmeta add 896 i
927+want = uchar 0
928+if or eq i 4 eq i 7
929+want = 45
930+end
931+if eq i 10
932+want = 84
933+end
934+if or eq i 13 eq i 16
935+want = 58
936+end
937+if eq i 19
938+want = 90
939+end
940+if ne want 0
941+if ne c want
942+ret false
943+end
944+else
945+if or lt c 48 gt c 57
946+ret false
947+end
948+end
949+end
950+ret eq get Ghbad 0 0
951+end
952+note Paths must be relative immediate children of the requested directory.
953+note No dot components, controls, backslash, URL metacharacters or percent escapes.
954+fn ghpathok to bool
955+n = get Ghdn 0
956+base = get Gh 10
957+if or eq n 0 gt n 511
958+ret false
959+end
960+at = ulong 0
961+if gt base 0
962+if le n add base 1
963+ret false
964+end
965+for i ulong base
966+if ne get Ghdec i get Ghdir i
967+ret false
968+end
969+end
970+if ne get Ghdec base 47
971+ret false
972+end
973+at = add base 1
974+end
975+size = sub n at
976+if eq get Ghdec at 46
977+if eq size 1
978+ret false
979+end
980+if eq size 2
981+if eq get Ghdec add at 1 46
982+ret false
983+end
984+end
985+end
986+while lt at n
987+c = get Ghdec at
988+if or lt c 32 eq c 127
989+ret false
990+end
991+if or or eq c 47 eq c 92 or eq c 58 eq c 37
992+ret false
993+end
994+if or eq c 63 eq c 35
995+ret false
996+end
997+at = add at 1
998+end
999+ret true
1000+end
1001+fn ghuint id ulong to ulong
1002+if ge id get jcnt 0
1003+put Ghbad 0 1
1004+ret 0
1005+end
1006+if ne get jtyp id 4
1007+put Ghbad 0 1
1008+ret 0
1009+end
1010+v = ulong 0
1011+p = get jbeg id
1012+while lt p get jend id
1013+c = get jin p
1014+if or lt c 48 gt c 57
1015+put Ghbad 0 1
1016+ret 0
1017+end
1018+if gt v 1844674407370955161
1019+put Ghbad 0 1
1020+ret 0
1021+end
1022+if eq v 1844674407370955161
1023+if gt c 53
1024+put Ghbad 0 1
1025+ret 0
1026+end
1027+end
1028+v = add mul v 10 sub ulong c 48
1029+p = add p 1
1030+end
1031+ret v
1032+end
1033+fn ghentry obj ulong to bool
1034+if ge get Gh 8 256
1035+ret false
1036+end
1037+if not ghdecode ghfield obj 10
1038+ret false
1039+end
1040+if not ghpathok
1041+ret false
1042+end
1043+n = get Ghdn 0
1044+p = get Gh 9
1045+if gt add add p n 40 len Ghpool
1046+ret false
1047+end
1048+slot = mul get Gh 8 5
1049+put Ghfiles slot p
1050+put Ghfiles add slot 1 n
1051+for i ulong n
1052+put Ghpool add p i get Ghdec i
1053+end
1054+p = add p n
1055+put Ghfiles add slot 4 p
1056+if not ghdecode ghfield obj 6
1057+ret false
1058+end
1059+if not ghsha
1060+ret false
1061+end
1062+for i ulong 40
1063+put Ghpool add p i get Ghdec i
1064+end
1065+put Gh 9 add p 40
1066+put Ghfiles add slot 3 ghuint ghfield obj 12
1067+if not ghdecode ghfield obj 11
1068+ret false
1069+end
1070+typ = ulong 3
1071+if eq get Ghdn 0 4
1072+if and eq get Ghdec 0 102 eq get Ghdec 1 105
1073+if and eq get Ghdec 2 108 eq get Ghdec 3 101
1074+typ = 1
1075+end
1076+end
1077+end
1078+if eq get Ghdn 0 3
1079+if and eq get Ghdec 0 100 eq get Ghdec 1 105
1080+if eq get Ghdec 2 114
1081+typ = 2
1082+end
1083+end
1084+end
1085+put Ghfiles add slot 2 typ
1086+put Gh 8 add get Gh 8 1
1087+ret eq get Ghbad 0 0
1088+end
1089+fn ghlisting to bool
1090+if ne get jtyp 0 2
1091+ret false
1092+end
1093+put Gh 8 0
1094+put Gh 9 0
1095+i = ulong 1
1096+while lt i get jcnt 0
1097+if not ghentry i
1098+ret false
1099+end
1100+i = ghnext i
1101+end
1102+ret eq get Ghbad 0 0
1103+end
1104+fn ghrawutf p ulong n ulong to ulong
1105+c = ulong get Ghbody p
1106+p = add p 1
1107+if lt c 128
1108+if lt c 32
1109+if not or or eq c 9 eq c 10 eq c 13
1110+ret 262145
1111+end
1112+end
1113+if eq c 127
1114+ret 262145
1115+end
1116+ret p
1117+end
1118+k = ulong 0
1119+lo = ulong 128
1120+hi = ulong 191
1121+if and ge c 194 le c 223
1122+k = 1
1123+end
1124+if and ge c 224 le c 239
1125+k = 2
1126+if eq c 224
1127+lo = 160
1128+end
1129+if eq c 237
1130+hi = 159
1131+end
1132+end
1133+if and ge c 240 le c 244
1134+k = 3
1135+if eq c 240
1136+lo = 144
1137+end
1138+if eq c 244
1139+hi = 143
1140+end
1141+end
1142+if eq k 0
1143+ret 262145
1144+end
1145+if gt add p k n
1146+ret 262145
1147+end
1148+for i ulong k
1149+c = ulong get Ghbody p
1150+if or lt c lo gt c hi
1151+ret 262145
1152+end
1153+p = add p 1
1154+lo = 128
1155+hi = 191
1156+end
1157+ret p
1158+end
1159+fn ghreadme n ulong to bool
1160+note Validate plain UTF8 and reject binary controls; tabs/newlines are text.
1161+p = ulong 0
1162+while lt p n
1163+p = ghrawutf p n
1164+if gt p n
1165+ret false
1166+end
1167+end
1168+for i ulong n
1169+put Ghread i get Ghbody i
1170+end
1171+put Gh 7 n
1172+ret true
1173+end
1174+fn ghreply kind ulong status ulong size ulong gen ulong to bool
1175+if or eq kind 0 ne kind get Ghreq 0
1176+ret false
1177+end
1178+if ne gen get Ghreq 2
1179+ret false
1180+end
1181+put Gh 3 status
1182+if gt size get Ghreq 4
1183+gherror 2
1184+ret true
1185+end
1186+if and eq kind 3 eq status 404
1187+put Gh 13 1
1188+put Gh 7 0
1189+put Ghat 2 get Gh 11
1190+ghissue 4
1191+ret true
1192+end
1193+if ne status 200
1194+if or eq status 403 eq status 429
1195+gherror 4
1196+else
1197+gherror 1
1198+end
1199+ret true
1200+end
1201+put Ghbad 0 0
1202+ok = false
1203+if eq kind 3
1204+ok = ghreadme size
1205+else
1206+for i ulong size
1207+put jin i get Ghbody i
1208+end
1209+if ne jparse size 0
1210+gherror 3
1211+ret true
1212+end
1213+if eq kind 1
1214+ok = ghmetadata
1215+end
1216+if eq kind 2
1217+ok = ghcommit
1218+end
1219+if eq kind 4
1220+ok = ghlisting
1221+end
1222+if eq kind 5
1223+ok = ghdiscover
1224+end
1225+end
1226+if not ok
1227+if eq kind 5
1228+note A rejected listing leaves no repository name behind for the header to draw.
1229+put Ghlen 5 0
1230+put Ghlen 6 0
1231+end
1232+gherror 3
1233+ret true
1234+end
1235+put Gh 12 gen
1236+if eq kind 5
1237+ghissue 1
1238+ret true
1239+end
1240+put Ghat sub kind 1 get Gh 11
1241+if lt kind 4
1242+ghissue add kind 1
1243+else
1244+put Ghreq 0 0
1245+put Gh 0 2
1246+put Gh 5 0
1247+put Gh 6 0
1248+end
1249+ret true
1250+end

aienux/allen/http.om

new file mode 100644
@@ -0,0 +1,495 @@
1+note SPDX-License-Identifier: MIT
2+note HTTP/1.1 framing for one authenticated api.github.com connection, RFC 9110/9112.
3+note Only TLS-authenticated plaintext enters Hchunk. No redirects, compression or pipelining.
4+global Httpreq uchar 8192
5+global Httpreqn ulong 1
6+global Hchunk uchar 16384
7+global Hstate ulong 8
8+global Hline uchar 8192
9+global Hp ulong 16
10+text Hget "GET "
11+text Htail " HTTP/1.1\nHost: api.github.com\nUser-Agent: Allen-Omega/1.0\nAccept-Encoding: identity\nX-GitHub-Api-Version: 2022-11-28\nConnection: close\nAccept: "
12+text Hjson "application/vnd.github+json"
13+text Hraw "application/vnd.github.raw+json"
14+text Hver "HTTP/1.1 "
15+text Hcl "content-length"
16+text Hte "transfer-encoding"
17+text Hce "content-encoding"
18+text Hckword "chunked"
19+text Hident "identity"
20+text Htokens "!#$%&'*+-.^_`|~"
21+note Hstate: state(0idle,1reading,2done,3error),status,body bytes,generation,kind,error.
22+note Hp: phase,line bytes,CR pending,header bytes,CL present,CL,TE,remaining,maxbody,interim.
23+fn hplower c uchar to uchar
24+if and ge c 65 le c 90
25+ret uchar add ulong c 32
26+end
27+ret c
28+end
29+fn hpkw kind ulong at ulong to uchar
30+if eq kind 0
31+ret get Hcl at
32+end
33+if eq kind 1
34+ret get Hte at
35+end
36+if eq kind 2
37+ret get Hce at
38+end
39+if eq kind 3
40+ret get Hckword at
41+end
42+ret get Hident at
43+end
44+fn hpeq at ulong n ulong kind ulong size ulong to bool
45+if ne n size
46+ret false
47+end
48+for i ulong size
49+if ne hplower get Hline add at i hpkw kind i
50+ret false
51+end
52+end
53+ret true
54+end
55+fn hpfail code ulong to void
56+put Hstate 0 3
57+put Hstate 5 code
58+put Hstate 2 0
59+put Httpreqn 0 0
60+put Hp 0 10
61+end
62+fn hpemit c uchar to void
63+n = get Httpreqn 0
64+if ge n len Httpreq
65+hpfail 1
66+ret
67+end
68+put Httpreq n c
69+put Httpreqn 0 add n 1
70+end
71+fn hpcrlf to void
72+hpemit 13
73+hpemit 10
74+end
75+fn httpstart kind ulong gen ulong mode ulong maxbody ulong pathlen ulong to bool
76+for i ulong 16
77+put Hp i 0
78+end
79+for i ulong 8
80+put Hstate i 0
81+end
82+put Httpreqn 0 0
83+if or or eq pathlen 0 ge pathlen len Ghpath gt maxbody len Ghbody
84+hpfail 2
85+ret false
86+end
87+if or gt mode 1 ne get Ghpath 0 47
88+hpfail 2
89+ret false
90+end
91+for i ulong pathlen
92+c = get Ghpath i
93+if or or le c 32 ge c 127 eq c 35
94+hpfail 2
95+ret false
96+end
97+end
98+for i ulong len Hget
99+hpemit get Hget i
100+end
101+for i ulong pathlen
102+hpemit get Ghpath i
103+end
104+for i ulong len Htail
105+c = get Htail i
106+if eq c 10
107+hpcrlf
108+else
109+hpemit c
110+end
111+end
112+if eq mode 0
113+for i ulong len Hjson
114+hpemit get Hjson i
115+end
116+else
117+for i ulong len Hraw
118+hpemit get Hraw i
119+end
120+end
121+hpcrlf
122+hpcrlf
123+if eq get Hstate 0 3
124+ret false
125+end
126+put Hstate 0 1
127+put Hstate 3 gen
128+put Hstate 4 kind
129+put Hp 8 maxbody
130+ret true
131+end
132+fn hptoken c uchar to bool
133+if or or and ge c 65 le c 90 and ge c 97 le c 122 and ge c 48 le c 57
134+ret true
135+end
136+for i ulong len Htokens
137+if eq c get Htokens i
138+ret true
139+end
140+end
141+ret false
142+end
143+fn hpfinish to void
144+put Hp 0 9
145+put Hstate 0 2
146+end
147+fn hpstatus to void
148+n = get Hp 1
149+if lt n 12
150+hpfail 3
151+ret
152+end
153+for i ulong len Hver
154+if ne get Hline i get Hver i
155+hpfail 3
156+ret
157+end
158+end
159+s = ulong 0
160+for i ulong 3
161+c = get Hline add i 9
162+if or lt c 48 gt c 57
163+hpfail 3
164+ret
165+end
166+s = add mul s 10 sub ulong c 48
167+end
168+if or lt s 100 gt s 599
169+hpfail 3
170+ret
171+end
172+if gt n 12
173+if ne get Hline 12 32
174+hpfail 3
175+ret
176+end
177+end
178+put Hstate 1 s
179+put Hp 0 1
180+end
181+fn hpheadersend to void
182+s = get Hstate 1
183+if lt s 200
184+if or or eq s 101 gt get Hp 9 2 ne get Hp 6 0
185+hpfail 4
186+ret
187+end
188+if and ne get Hp 4 0 ne get Hp 5 0
189+hpfail 4
190+ret
191+end
192+put Hp 9 add get Hp 9 1
193+put Hp 0 0
194+put Hp 4 0
195+put Hp 5 0
196+put Hp 6 0
197+ret
198+end
199+if and ne get Hp 4 0 ne get Hp 6 0
200+hpfail 5
201+ret
202+end
203+if or eq s 204 eq s 304
204+if or ne get Hp 6 0 and ne get Hp 4 0 ne get Hp 5 0
205+hpfail 5
206+else
207+hpfinish
208+end
209+ret
210+end
211+if ne get Hp 6 0
212+put Hp 0 3
213+ret
214+end
215+if ne get Hp 4 0
216+put Hp 7 get Hp 5
217+if eq get Hp 7 0
218+hpfinish
219+else
220+put Hp 0 2
221+end
222+ret
223+end
224+note Close-delimited bodies complete only after authenticated TLS close_notify via httpend.
225+put Hp 0 8
226+end
227+fn hpdecimal at ulong stop ulong to bool
228+v = ulong 0
229+for i ulong sub stop at
230+c = get Hline add at i
231+if or lt c 48 gt c 57
232+ret false
233+end
234+d = sub ulong c 48
235+if gt v div get Hp 8 10
236+ret false
237+end
238+v = add mul v 10 d
239+if gt v get Hp 8
240+ret false
241+end
242+end
243+put Hp 5 v
244+ret true
245+end
246+fn hpheader trailer bool to void
247+n = get Hp 1
248+if eq n 0
249+if trailer
250+hpfinish
251+else
252+hpheadersend
253+end
254+ret
255+end
256+p = ulong 0
257+while lt p n
258+if eq get Hline p 58
259+break
260+end
261+if not hptoken get Hline p
262+hpfail 6
263+ret
264+end
265+p = add p 1
266+end
267+if or eq p 0 eq p n
268+hpfail 6
269+ret
270+end
271+beg = add p 1
272+stop = n
273+while lt beg stop
274+c = get Hline beg
275+if and ne c 32 ne c 9
276+break
277+end
278+beg = add beg 1
279+end
280+while gt stop beg
281+c = get Hline sub stop 1
282+if and ne c 32 ne c 9
283+break
284+end
285+stop = sub stop 1
286+end
287+cl = hpeq 0 p 0 14
288+te = hpeq 0 p 1 17
289+ce = hpeq 0 p 2 16
290+if trailer
291+if or or cl te ce
292+hpfail 7
293+end
294+ret
295+end
296+if cl
297+if or ne get Hp 4 0 eq beg stop
298+hpfail 5
299+ret
300+end
301+if not hpdecimal beg stop
302+hpfail 8
303+ret
304+end
305+put Hp 4 1
306+end
307+if te
308+if or ne get Hp 6 0 not hpeq beg sub stop beg 3 7
309+hpfail 5
310+ret
311+end
312+put Hp 6 1
313+end
314+if ce
315+if not hpeq beg sub stop beg 4 8
316+hpfail 9
317+end
318+end
319+end
320+fn hphex c uchar to ulong
321+if and ge c 48 le c 57
322+ret sub ulong c 48
323+end
324+x = hplower c
325+if and ge x 97 le x 102
326+ret sub ulong x 87
327+end
328+ret 16
329+end
330+fn hpchunkline to void
331+n = get Hp 1
332+v = ulong 0
333+p = ulong 0
334+while lt p n
335+c = get Hline p
336+if eq c 59
337+break
338+end
339+d = hphex c
340+if or ge d 16 gt v div get Hp 8 16
341+hpfail 10
342+ret
343+end
344+v = add mul v 16 d
345+if gt v sub get Hp 8 get Hstate 2
346+hpfail 8
347+ret
348+end
349+p = add p 1
350+end
351+if eq p 0
352+hpfail 10
353+ret
354+end
355+if and lt p n eq add p 1 n
356+hpfail 10
357+ret
358+end
359+put Hp 7 v
360+if eq v 0
361+put Hp 0 7
362+else
363+put Hp 0 4
364+end
365+end
366+fn hplineend to void
367+p = get Hp 0
368+if eq p 0
369+hpstatus
370+else
371+if eq p 1
372+hpheader false
373+else
374+if eq p 3
375+hpchunkline
376+else
377+if eq p 7
378+hpheader true
379+else
380+hpfail 11
381+end
382+end
383+end
384+end
385+put Hp 1 0
386+put Hp 2 0
387+end
388+fn hplinebyte c uchar to void
389+put Hp 3 add get Hp 3 1
390+if gt get Hp 3 65536
391+hpfail 12
392+ret
393+end
394+if ne get Hp 2 0
395+if ne c 10
396+hpfail 6
397+else
398+hplineend
399+end
400+ret
401+end
402+if eq c 13
403+put Hp 2 1
404+ret
405+end
406+if or or eq c 10 and lt c 32 ne c 9 eq c 127
407+hpfail 6
408+ret
409+end
410+n = get Hp 1
411+if ge n len Hline
412+hpfail 12
413+ret
414+end
415+put Hline n c
416+put Hp 1 add n 1
417+end
418+fn hpbody c uchar to void
419+n = get Hstate 2
420+if ge n get Hp 8
421+hpfail 8
422+ret
423+end
424+put Ghbody n c
425+put Hstate 2 add n 1
426+phase = get Hp 0
427+if or eq phase 2 eq phase 4
428+left = sub get Hp 7 1
429+put Hp 7 left
430+if eq left 0
431+if eq phase 2
432+hpfinish
433+else
434+put Hp 0 5
435+end
436+end
437+end
438+end
439+fn httpfeed n ulong to bool
440+if or gt n len Hchunk and eq get Hstate 0 2 ne n 0
441+hpfail 13
442+ret false
443+end
444+if ne get Hstate 0 1
445+ret false
446+end
447+for i ulong n
448+c = get Hchunk i
449+phase = get Hp 0
450+if or or eq phase 0 eq phase 1 or eq phase 3 eq phase 7
451+hplinebyte c
452+else
453+if or or eq phase 2 eq phase 4 eq phase 8
454+hpbody c
455+else
456+if eq phase 5
457+if eq c 13
458+put Hp 0 6
459+else
460+hpfail 10
461+end
462+else
463+if eq phase 6
464+if eq c 10
465+put Hp 0 3
466+else
467+hpfail 10
468+end
469+else
470+hpfail 13
471+end
472+end
473+end
474+end
475+if eq get Hstate 0 3
476+ret false
477+end
478+end
479+ret true
480+end
481+fn httpend auth bool to bool
482+if not auth
483+hpfail 14
484+ret false
485+end
486+if eq get Hstate 0 2
487+ret true
488+end
489+if and eq get Hstate 0 1 eq get Hp 0 8
490+hpfinish
491+ret true
492+end
493+hpfail 14
494+ret false
495+end

aienux/allen/intent.om

new file mode 100644
@@ -0,0 +1,292 @@
1+note Intent vocabulary frozen from svc/allen_intent.c. It selects jobs, never answers.
2+global Fold uchar 160
3+global Fn ulong 2
4+text Lists "please|can you|could you|would you|will you|i d like you to|i want you to|i need you to|allen|hey allen|ok|okay\nwrite|make|build|create|code|program|generate|implement|develop|give me a|i need a|i want a\ncode|program|programs|script|scripts|function|functions|app|apps|application|game|games|website|web page|webpage|calculator|converter|parser|compiler|interpreter|algorithm|class|api|server|bot|regex|unit test|unit tests|cli|command line tool|snake|tetris|pong|todo app|to do app|to do list app|timer app|stopwatch|python|javascript|typescript|rust|golang|java|kotlin|swift|ruby|php|html|css|sql|bash|shell script|c program|c code|in c|c plus plus|cpp|mojo|zig|haskell|lua|perl\npoem|poems|haiku|story|stories|song|songs|letter|email|essay|joke|jokes|limerick|speech\ncode|program|script\nnow|add|also|and|change|make it|make the|rename|remove|delete|replace|use|fix|put|give it|let it|instead|then|next|can it|could it|it should|the|move|turn|show|split|convert it|rewrite|port it|translate it|explain it\nwrite|make|build|create|code|program|draft|compose|generate|design|implement|invent|name|give me a|i need a|i want a\na poem|a haiku|a story|a song|a script|a function|a program|a list of|some code|a letter|an email|a plan for|a name for\nexplain|what is|what are|whats|what s|why|how does|how do|how is|how are|describe|tell me about|what does|who was|who is|define|when was|when did|where is|is it true\ndifference between|mean|means\ndo|run|fix|find|search|look up|check|open|send|start|stop|install|set up|plan|schedule|calculate|work out|convert|translate|summarize|summarise|list|sort|count|compare|turn|go\n"
5+fn foldin to void
6+n = ulong 0
7+space = false
8+for i ulong get Inlen 0
9+c = get In i
10+if and ge c 65 le c 90
11+c = add sub c 65 97
12+end
13+if or and ge c 97 le c 122 isdigit c
14+if and space gt n 0
15+put Fold n uchar 32
16+n = add n 1
17+end
18+put Fold n c
19+n = add n 1
20+space = false
21+else
22+space = true
23+end
24+end
25+put Fn 0 n
26+put Fn 1 0
27+end
28+fn phrase at ulong off ulong size ulong to bool
29+if gt add at size get Fn 0
30+ret false
31+end
32+for i ulong size
33+if ne get Fold add at i get Lists add off i
34+ret false
35+end
36+end
37+if lt add at size get Fn 0
38+if ne get Fold add at size 32
39+ret false
40+end
41+end
42+ret true
43+end
44+fn inphrase off ulong size ulong anypos bool to bool
45+if not anypos
46+ret phrase get Fn 1 off size
47+end
48+count = sub get Fn 0 get Fn 1
49+for i ulong count
50+at = add i get Fn 1
51+ok = eq at get Fn 1
52+if gt at 0
53+ok = or ok eq get Fold sub at 1 32
54+end
55+if ok
56+if phrase at off size
57+ret true
58+end
59+end
60+end
61+ret false
62+end
63+fn listed group ulong anypos bool to ulong
64+g = ulong 0
65+s = ulong 0
66+for p ulong len Lists
67+c = get Lists p
68+if or eq c 124 eq c 10
69+if eq g group
70+if inphrase s sub p s anypos
71+ret sub p s
72+end
73+end
74+s = add p 1
75+if eq c 10
76+g = add g 1
77+end
78+end
79+end
80+ret 0
81+end
82+fn classify to ulong
83+if not textok
84+ret 0
85+end
86+foldin
87+skip = listed 0 false
88+while gt skip 0
89+if ge add get Fn 1 skip get Fn 0
90+skip = 0
91+else
92+put Fn 1 add add get Fn 1 skip 1
93+skip = listed 0 false
94+end
95+end
96+if and ne get R 6 0 gt listed 5 false 0
97+ret 3
98+end
99+plain = listed 4 false
100+if or eq plain 4 eq plain 7
101+ret 2
102+end
103+if and gt listed 3 true 0 eq listed 4 true 0
104+ret 1
105+end
106+if and gt listed 1 false 0 gt listed 2 true 0
107+ret 2
108+end
109+ret 1
110+end
111+note Ordinary want enum0chat,1make,2explain,3do.
112+fn jobwant to ulong
113+if gt listed 8 false 0
114+ret 2
115+end
116+if or gt listed 6 false 0 gt listed 7 true 0
117+ret 1
118+end
119+if gt listed 10 false 0
120+ret 3
121+end
122+if gt listed 9 true 0
123+ret 2
124+end
125+ret 0
126+end
127+text Job "JOB "
128+text Codeask " asked "
129+text Forcode " for code.\t"
130+text Formore " to change the code just shown.\t"
131+text Wantstr "chatmakeexplaindo"
132+text Intro "You are the far hands of "
133+text Home ", a quiet presence living in AIENOS on "
134+text Comp "'s computer. You answer as "
135+text Sees "; "
136+text Words " sees only your words, as if "
137+text Said " said them. Plain English, short sentences, no headings, no lists, no greetings, no apologies. Plain letters and punctuation only: no dashes, no curly quotes, no symbols. Never mention a model, a prompt or instructions. "
138+text Make " asked for something to be made. Make it whole and correct. Begin with one short sentence saying what you made, then the work itself."
139+text Explain " asked to understand something. Explain it in three plain sentences at most, the heart of it first, no more than is needed."
140+text Doing " asked for something to be done. "
141+text Cannot " cannot yet act outside this computer, so say in two or three short sentences what you would do, in order, and what you would need."
142+text Chat " said something in passing. Answer in one or two warm, plain sentences."
143+text Allen "Allen"
144+text Person "the person"
145+fn selfemit to void
146+off = add 40 mul mem32 32 113
147+if eq get Mem off 0
148+for i ulong len Allen
149+emitb get Allen i
150+end
151+else
152+for i ulong 24
153+c = get Mem add off i
154+if eq c 0
155+ret
156+end
157+emitb c
158+end
159+end
160+end
161+fn whoemit to void
162+if eq get Mem 8 0
163+for i ulong len Person
164+emitb get Person i
165+end
166+else
167+for i ulong 24
168+c = get Mem add i 8
169+if eq c 0
170+ret
171+end
172+emitb c
173+end
174+end
175+end
176+fn jobbuild kind ulong seq ulong to bool
177+if or lt kind 1 gt kind 3
178+ret false
179+end
180+if or eq seq 0 gt seq 4294967295
181+ret false
182+end
183+if not textok
184+ret false
185+end
186+outreset
187+for i ulong len Job
188+emitb get Job i
189+end
190+emitn seq
191+emitb 32
192+if gt kind 1
193+emitb 99
194+emitb 111
195+emitb 100
196+emitb 101
197+if eq kind 3
198+emitb 45
199+emitb 109
200+emitb 111
201+emitb 114
202+emitb 101
203+end
204+emitb 32
205+whoemit
206+for i ulong len Codeask
207+emitb get Codeask i
208+end
209+selfemit
210+if eq kind 3
211+for i ulong len Formore
212+emitb get Formore i
213+end
214+else
215+for i ulong len Forcode
216+emitb get Forcode i
217+end
218+end
219+else
220+w = jobwant
221+off = ulong 0
222+size = ulong 4
223+if eq w 1
224+off = 4
225+end
226+if eq w 2
227+off = 8
228+size = 7
229+end
230+if eq w 3
231+off = 15
232+size = 2
233+end
234+for i ulong size
235+emitb get Wantstr add off i
236+end
237+emitb 32
238+for i ulong len Intro
239+emitb get Intro i
240+end
241+selfemit
242+for i ulong len Home
243+emitb get Home i
244+end
245+whoemit
246+for i ulong len Comp
247+emitb get Comp i
248+end
249+selfemit
250+for i ulong len Sees
251+emitb get Sees i
252+end
253+whoemit
254+for i ulong len Words
255+emitb get Words i
256+end
257+selfemit
258+for i ulong len Said
259+emitb get Said i
260+end
261+whoemit
262+if eq w 0
263+for i ulong len Chat
264+emitb get Chat i
265+end
266+end
267+if eq w 1
268+for i ulong len Make
269+emitb get Make i
270+end
271+end
272+if eq w 2
273+for i ulong len Explain
274+emitb get Explain i
275+end
276+end
277+if eq w 3
278+for i ulong len Doing
279+emitb get Doing i
280+end
281+selfemit
282+for i ulong len Cannot
283+emitb get Cannot i
284+end
285+end
286+emitb 9
287+end
288+for i ulong get Inlen 0
289+emitb get In i
290+end
291+ret le get Outlen 0 4096
292+end

aienux/allen/local-model.om

new file mode 100644
@@ -0,0 +1,278 @@
1+note SPDX-License-Identifier: AGPL-3.0-only
2+note Opt-in local-model application for Aienux's Omega firmware environment.
3+note Links the existing Allen base/runtime and aien-train's unchanged model/checkpoint/tokenizer.
4+note Firmware Boot Services stay active. This is not a standalone-kernel or bare-metal M2 claim.
5+note No network, Linux syscalls, shell, external inference provider or checkpoint writes.
6+note Serial console protocol: LM1 ID TOKENS TEMPMILLI SEED HEX_PROMPT CR.
7+note ID/SEED u32; TOKENS 1..128; TEMPMILLI 0..2000; prompt 1..159 printable ASCII bytes.
8+note Output: LMREADY; LMSTART ID; LMDATA ID HEX_BYTES; LMDONE ID; LMERR ID CODE.
9+note A request uses Allen's start/answer conversation lifecycle. Its history stores a bounded
10+note printable preview; raw generated bytes are sent unchanged in the LMDATA frames.
11+text Lmck "\\ASTRA.CK"
12+text Lmbpe "\\BPE.BIN"
13+text Lmboot "AIENUX OMEGA LOCAL MODEL: firmware hosted, no Linux"
14+text Lmready "LMREADY"
15+text Lmstart "LMSTART "
16+text Lmdata "LMDATA "
17+text Lmdone "LMDONE "
18+text Lmerror "LMERR "
19+global Lmstate ulong 8
20+note state: input length, overflow, request ID, tokens, temperature, seed, preview length, reserved.
21+global Lmline uchar 512
22+global Lmkey uchar 8
23+global Lmprev uchar 160
24+
25+fn lmput which ulong to void
26+if eq which 0
27+for i ulong len Lmboot
28+emitb get Lmboot i
29+end
30+end
31+if eq which 1
32+for i ulong len Lmready
33+emitb get Lmready i
34+end
35+end
36+if eq which 2
37+for i ulong len Lmstart
38+emitb get Lmstart i
39+end
40+end
41+if eq which 3
42+for i ulong len Lmdata
43+emitb get Lmdata i
44+end
45+end
46+if eq which 4
47+for i ulong len Lmdone
48+emitb get Lmdone i
49+end
50+end
51+if eq which 5
52+for i ulong len Lmerror
53+emitb get Lmerror i
54+end
55+end
56+end
57+
58+fn lmsend to void
59+emitb 10
60+if ne get Err 0 0
61+exit 71
62+end
63+r = efi 13 0 Outb 0 get Outlen 0
64+if ne r get Outlen 0
65+exit 70
66+end
67+end
68+
69+fn lmfail code ulong to void
70+outreset
71+lmput 5
72+emitn get Lmstate 2
73+emitb 32
74+emitn code
75+lmsend
76+end
77+
78+fn lmhex c uchar to ulong
79+if and ge c 48 le c 57
80+ret sub ulong c 48
81+end
82+if and ge c 97 le c 102
83+ret add sub ulong c 97 10
84+end
85+ret 256
86+end
87+
88+note Platform output hook: flush every complete decoded token, with no terminal escape injection.
89+fn oflush to void
90+n = get oon 0
91+if eq n 0
92+ret
93+end
94+outreset
95+lmput 3
96+emitn get Lmstate 2
97+emitb 32
98+for i ulong n
99+c = get oout i
100+emitb get Digits ulong shr c 4
101+emitb get Digits ulong and c 15
102+p = get Lmstate 6
103+if lt p 159
104+shown = c
105+if or lt shown 32 gt shown 126
106+shown = 32
107+end
108+put Lmprev p shown
109+put Lmstate 6 add p 1
110+end
111+end
112+lmsend
113+put oon 0 0
114+end
115+
116+fn lmrequest to void
117+put Lmstate 2 0
118+if ne get Lmstate 1 0
119+lmfail 1
120+ret
121+end
122+n = get Lmstate 0
123+for i ulong n
124+put In i get Lmline i
125+end
126+put Inlen 0 n
127+put P 0 0
128+put P 2 0
129+expect 76
130+expect 77
131+expect 49
132+expect 32
133+number
134+put Lmstate 2 get P 1
135+expect 32
136+number
137+put Lmstate 3 get P 1
138+expect 32
139+number
140+put Lmstate 4 get P 1
141+expect 32
142+number
143+put Lmstate 5 get P 1
144+expect 32
145+if ne get P 2 0
146+lmfail 2
147+ret
148+end
149+if eq get Lmstate 2 0
150+lmfail 3
151+ret
152+end
153+if eq get Lmstate 3 0
154+lmfail 3
155+ret
156+end
157+if gt get Lmstate 3 128
158+lmfail 3
159+ret
160+end
161+if gt get Lmstate 4 2000
162+lmfail 3
163+ret
164+end
165+pos = get P 0
166+size = sub n pos
167+if or or eq size 0 gt size 318 ne rem size 2 0
168+lmfail 4
169+ret
170+end
171+count = div size 2
172+for i ulong count
173+a = lmhex get Lmline add pos mul i 2
174+b = lmhex get Lmline add add pos mul i 2 1
175+if or eq a 256 eq b 256
176+lmfail 5
177+ret
178+end
179+c = uchar add mul a 16 b
180+if or lt c 32 gt c 126
181+lmfail 6
182+ret
183+end
184+put ojob add 1024 i c
185+put In i c
186+end
187+put Inlen 0 count
188+if not start 1 oms
189+lmfail 7
190+ret
191+end
192+put otl 6 count
193+put Lmstate 6 0
194+outreset
195+lmput 2
196+emitn get Lmstate 2
197+lmsend
198+osampleloaded get Lmstate 5 get Lmstate 3 get Lmstate 4
199+count = get Lmstate 6
200+if eq count 0
201+cancel
202+else
203+for i ulong count
204+put In i get Lmprev i
205+end
206+put Inlen 0 count
207+if not answer get R 0 oms
208+cancel
209+lmfail 8
210+ret
211+end
212+end
213+outreset
214+lmput 4
215+emitn get Lmstate 2
216+lmsend
217+end
218+
219+fn main to int
220+outreset
221+lmput 0
222+lmsend
223+put otc 0 8
224+put otb 2 0
225+put otl 2 len Lmck
226+for i ulong len Lmck
227+put ojob i get Lmck i
228+end
229+put otb 7 32
230+put otl 7 len Lmbpe
231+for i ulong len Lmbpe
232+put ojob add 32 i get Lmbpe i
233+end
234+put otb 6 1024
235+pl = oargp 2
236+sz = efi 12 oefa 0 0 oarg 0 pl
237+if oeerr sz
238+outreset
239+lmput 5
240+emitn 0
241+emitb 32
242+emitn sz
243+lmsend
244+ret 70
245+end
246+oeclose
247+ockload 2
248+obload 7 get og 0
249+outreset
250+lmput 1
251+lmsend
252+for session ulong 1000000
253+for beat ulong 1000000
254+st = efi 1 0 Lmkey 0 4
255+if ne st 0
256+st = efi 2 1000 Lmkey 0 0
257+else
258+ch = or ulong get Lmkey 2 shl ulong get Lmkey 3 8
259+if eq ch 13
260+lmrequest
261+put Lmstate 0 0
262+put Lmstate 1 0
263+else
264+if and ge ch 32 le ch 126
265+n = get Lmstate 0
266+if lt n len Lmline
267+put Lmline n uchar ch
268+put Lmstate 0 add n 1
269+else
270+put Lmstate 1 1
271+end
272+end
273+end
274+end
275+end
276+end
277+ret 0
278+end

aienux/allen/look-chat.om

new file mode 100644
@@ -0,0 +1,142 @@
1+note SPDX-License-Identifier: MIT
2+note COURIER lane: Allen's courier to the Spark relay over UDP 47033, the Omega
3+note build's x86/courier_udp_x86.c. application.om (appinit, appask, apppoll,
4+note appsent, appreceive) already speaks the courier wire; this module binds its
5+note datagrams to net.om's netudpsend/Chrx hooks and the typed line to appask.
6+note Needs base, runtime, code, courier, scheduler, memory, intent, reply,
7+note context, application (gate.sh core list) and net.om before it in the unit.
8+note Ch: 0 initialized, 1 last event, 2 datagrams out, 3 datagrams in,
9+note 4 refused sends, 5 answers taken, 6 run id, 7 dropped-at-receive seen.
10+note Chevent after chstep: 0 nothing, 1 answer visible in Chsay, 2 asked AGAIN,
11+note 3 gave up, 4 refused, 5 slow notice, 6 silence (application.om A2).
12+global Ch ulong 8
13+global Chsay uchar 320
14+global Chsayn ulong 1
15+global Chevent ulong 1
16+note Run id like the C kernel: the clock at start mixed with the MAC, never 0.
17+fn chrun now ulong to ulong
18+run = now
19+for i ulong 6
20+run = xor run shl ulong get Nmac i mul 8 add i 2
21+end
22+if eq run 0
23+run = 1
24+end
25+ret run
26+end
27+note Refused (false, nothing touched) while application.om is still active.
28+fn chinit now ulong run ulong to bool
29+if eq run 0
30+run = chrun now
31+end
32+if not appinit run now
33+ret false
34+end
35+for i ulong 8
36+put Ch i 0
37+end
38+put Chsayn 0 0
39+put Chevent 0 0
40+put Chrxn 0 0
41+put Chdrop 0 0
42+put Ch 0 1
43+put Ch 6 run
44+ret true
45+end
46+note The typed request is platform.om's Dprm[0..Dprmn); appask copies and
47+note validates it (1..159 printable bytes). Dprmn is left for the caller.
48+fn chask now ulong to bool
49+if eq get Ch 0 0
50+ret false
51+end
52+n = get Dprmn 0
53+if gt n len Dprm
54+ret false
55+end
56+for i ulong n
57+put In i get Dprm i
58+end
59+put Inlen 0 n
60+ret appask now
61+end
62+fn chbusy to bool
63+if eq get Ch 0 0
64+ret false
65+end
66+ret or ne get R 1 0 ne get A 1 0
67+end
68+fn chcancel to void
69+if eq get Ch 0 0
70+ret
71+end
72+appcancel
73+put Chevent 0 0
74+end
75+fn chsay to void
76+n = get R 8
77+if gt n len Chsay
78+n = len Chsay
79+end
80+for i ulong n
81+put Chsay i get Answer i
82+end
83+put Chsayn 0 n
84+put Ch 5 add get Ch 5 1
85+end
86+fn chevent to void
87+e = get A 2
88+if eq e 0
89+ret
90+end
91+put Chevent 0 e
92+put Ch 1 e
93+if eq e 1
94+chsay
95+end
96+end
97+fn chtake now ulong to void
98+n = get Chrxn 0
99+put Chrxn 0 0
100+put Ch 3 add get Ch 3 1
101+put Ch 7 get Chdrop 0
102+for i ulong n
103+put In i get Chrx i
104+end
105+put Inlen 0 n
106+if appreceive now
107+chevent
108+end
109+end
110+fn chsend now ulong to void
111+n = get Outlen 0
112+ok = false
113+if and ne n 0 le n len Chtx
114+for i ulong n
115+put Chtx i get Outb i
116+end
117+ok = netudpsend n
118+end
119+if ok
120+put Ch 2 add get Ch 2 1
121+else
122+put Ch 4 add get Ch 4 1
123+end
124+ok = appsent now ok
125+end
126+note One step of the courier, like the C pump: take the datagram waiting in
127+note Chrx, then let the scheduler offer HELLO/JOB/GOT and send it. up is the
128+note firmware's network-up flag (Es 6). Chevent reports this step's event.
129+fn chstep now ulong up bool to void
130+put Chevent 0 0
131+if eq get Ch 0 0
132+ret
133+end
134+if ne get Chrxn 0 0
135+chtake now
136+end
137+off = apppoll now up
138+chevent
139+if off
140+chsend now
141+end
142+end

aienux/allen/look-home.om

new file mode 100644
@@ -0,0 +1,1018 @@
1+note look-home.om: Allen's home (allen_ui.c at aienux 4b24df65): the timeline, the merger flash, his words, the bar.
2+note Frame order (the integrator): ntat t; hmstep t; mdat t; then ntbase/ntlights, hmflash, mddraw, hmtext per band.
3+note hminit after pkinit, ntinit, mdinit (reads Lg 0..4). Keys: hmkey c (byte, 8 backspace, 13 enter -> Hmline/Hmlinen/Hmask).
4+note hmthink 1 when the request went out; hmsaid once the answer is in Hmsay/Hmsayn. Not ported: canvas, map, panel,
5+note code view, guest, notes, choices, dusk/exit, chirp, flow, working. hmdirty: union of what moved, in Hmdirty.
6+note Hm: 0 on 1 wake_t 2 quiet_t 3 key_t 4 input_moved 5 speak_t 6 thinking 7 word_t 8 bar_a 9 bar_was 10 last
7+note 11 frames 12 t 13 next_len 14 input_len 15 input_gen 16 seen_input 17 said_gen 18 seen_said 19 has_line 20 think
8+note 21 said_input_gen 22 hint_len 23 face 24..27 bar 28..31 bar_box 32..35 words_was 36..39 flash_was
9+note 40..42 s256 per face 43..45 cap 46..48 weight 49 alpha 50 add 51 text source 52..55 band 56 speaking 57 last space
10+note 58..61 words box. Hmw: 0 len 1 from 2 fade 3 done 4 lines 5..9 line starts 10..14 line lengths 15..19 line x
11+global Hm long 64
12+global Hmin uchar 160
13+global Hminn ulong 1
14+global Hmline uchar 160
15+global Hmlinen ulong 1
16+global Hmask ulong 1
17+global Hmsay uchar 320
18+global Hmsayn ulong 1
19+global Hmnow uchar 160
20+global Hmnext uchar 160
21+global Hmw long 20
22+global Hmdirty long 4
23+global Hmhint uchar 32
24+global Hmfoot uchar 64
25+global Hmfootn ulong 1
26+global Hmadv long 95
27+global Hmgm long 1425
28+global Hmgp uchar 1572864
29+global Hmgn ulong 1
30+fn hmrgb r ulong g ulong b ulong to ulong
31+ret or or shl r 16 shl g 8 b
32+end
33+fn hms v long to long
34+ret div add mul v get Lg 2 128 256
35+end
36+fn hmmark x long y long w long h long to void
37+if le w 0
38+ret
39+end
40+if le h 0
41+ret
42+end
43+if eq get Hmdirty 2 0
44+put Hmdirty 0 x
45+put Hmdirty 1 y
46+put Hmdirty 2 w
47+put Hmdirty 3 h
48+ret
49+end
50+x0 = pkmin x get Hmdirty 0
51+y0 = pkmin y get Hmdirty 1
52+x1 = pkmax add x w add get Hmdirty 0 get Hmdirty 2
53+y1 = pkmax add y h add get Hmdirty 1 get Hmdirty 3
54+put Hmdirty 0 x0
55+put Hmdirty 1 y0
56+put Hmdirty 2 sub x1 x0
57+put Hmdirty 3 sub y1 y0
58+end
59+note x y w h meets the band Hm 52..55 (ck_meets)
60+note marks the rect kept at Hm b..b+3
61+fn hmmarkat b ulong to void
62+hmmark get Hm b get Hm add b 1 get Hm add b 2 get Hm add b 3
63+end
64+fn hmmeets x long y long w long h long to bool
65+if le w 0
66+ret false
67+end
68+if ge x add get Hm 52 get Hm 54
69+ret false
70+end
71+if ge y add get Hm 53 get Hm 55
72+ret false
73+end
74+if le add x w get Hm 52
75+ret false
76+end
77+ret gt add y h get Hm 53
78+end
79+note clips x y w h against the band and the screen into Lg 5..8; false when empty
80+fn hmcut x long y long w long h long to bool
81+x0 = pkmax pkmax x get Hm 52 0
82+y0 = pkmax pkmax y get Hm 53 0
83+x1 = pkmin pkmin add x w add get Hm 52 get Hm 54 get Lg 0
84+y1 = pkmin pkmin add y h add get Hm 53 get Hm 55 get Lg 1
85+pkclip x0 y0 sub x1 x0 sub y1 y0
86+if le x1 x0
87+ret false
88+end
89+ret gt y1 y0
90+end
91+fn hmtoward v long want long dt long full long to long
92+step = div mul 256 dt full
93+if eq step 0
94+if ne dt 0
95+step = 1
96+end
97+end
98+if lt v want
99+ret pkmin add v step want
100+end
101+ret pkmax sub v step want
102+end
103+note ---- letters: font.om masks cached once per face (Hm 23) and glyph ----
104+fn hmch i ulong to uchar
105+s = get Hm 51
106+if eq s 0
107+ret get Hmhint i
108+end
109+if eq s 1
110+ret get Hmin i
111+end
112+if eq s 2
113+ret get Hmnow i
114+end
115+ret get Hmfoot i
116+end
117+fn hmadv c uchar to ulong
118+if lt c 32
119+c = 63
120+end
121+if gt c 126
122+c = 63
123+end
124+g = sub ulong c 32
125+if lt get Hmadv g 0
126+ok = afpick c
127+put Afpos 0 add get Afpos 0 1
128+put Hmadv g afnum
129+end
130+ret mul ulong get Hmadv g ulong get Hm add 40 ulong get Hm 23
131+end
132+fn hmmeas from ulong n ulong to long
133+w = ulong 0
134+for i ulong n
135+w = add w hmadv hmch add from i
136+end
137+ret long div add w 255 256
138+end
139+fn hmglyph c uchar to ulong
140+if lt c 32
141+c = 63
142+end
143+if gt c 126
144+c = 63
145+end
146+m = mul add mul ulong get Hm 23 95 sub ulong c 32 5
147+if ge get Hmgm add m 4 0
148+ret m
149+end
150+f = ulong get Hm 23
151+ok = afinit ulong get Hm add 43 f ulong get Hm add 46 f
152+ok = afglyph c
153+n = mul get Af 3 get Af 4
154+put Hmgm m long get Af 3
155+put Hmgm add m 1 long get Af 4
156+put Hmgm add m 2 get Ab 0
157+put Hmgm add m 3 get Ab 1
158+put Hmgm add m 4 long get Hmgn 0
159+if gt add get Hmgn 0 n len Hmgp
160+put Hmgm m 0
161+ret m
162+end
163+for i ulong n
164+put Hmgp add get Hmgn 0 i get Alpha i
165+end
166+put Hmgn 0 add get Hmgn 0 n
167+ret m
168+end
169+note one glyph row: n mask bytes from off onto Nfrm from at; color Hm 63, alpha Hm 49, add Hm 50
170+fn hmrow at ulong off ulong n ulong to void
171+for i ulong n
172+cov = ulong get Hmgp add off i
173+if ne cov 0
174+cov = add cov shr cov 7
175+cov = shr mul cov ulong get Hm 49 8
176+if eq get Hm 50 0
177+cov = pkmix ulong get Nfrm at ulong get Hm 63 cov
178+else
179+cov = pkadd ulong get Nfrm at ulong get Hm 63 cov
180+end
181+put Nfrm at uint cov
182+end
183+at = add at 1
184+end
185+end
186+note draws cached glyph m with its top-left at gx gy, clipped to Lg 5..8 (color Hm 63)
187+fn hmglyphat m ulong gx long gy long to void
188+x0 = pkmax gx get Lg 5
189+y0 = pkmax gy get Lg 6
190+x1 = add gx get Hmgm m
191+x1 = pkmin x1 add get Lg 5 get Lg 7
192+y1 = add gy get Hmgm add m 1
193+y1 = pkmin y1 add get Lg 6 get Lg 8
194+if ge x0 x1
195+ret
196+end
197+gx = sub x0 gx
198+x1 = sub x1 x0
199+gy = sub y0 gy
200+while lt y0 y1
201+o = mul ulong gy ulong get Hmgm m
202+o = add o ulong gx
203+o = add o ulong get Hmgm add m 4
204+at = mul ulong y0 ulong get Lg 0
205+at = add at ulong x0
206+hmrow at o ulong x1
207+y0 = add y0 1
208+gy = add gy 1
209+end
210+end
211+fn hmblit pen ulong y long c uchar color ulong to ulong
212+if eq get Hm 49 0
213+ret add pen hmadv c
214+end
215+m = hmglyph c
216+if eq get Hmgm m 0
217+ret add pen hmadv c
218+end
219+put Hm 63 long color
220+gx = add long div add pen 128 256 get Hmgm add m 2
221+gy = add y get Hmgm add m 3
222+hmglyphat m gx gy
223+ret add pen hmadv c
224+end
225+note text() of the C: source Hm 51, face Hm 23, alpha Hm 49, clip Lg 5..8; returns the pen end in pixels
226+fn hmwrite from ulong n ulong x long y long color ulong to long
227+pen = mul ulong x 256
228+for i ulong n
229+pen = hmblit pen y hmch add from i color
230+end
231+ret long div add pen 255 256
232+end
233+note ---- init ----
234+fn hminit to void
235+for i ulong 64
236+put Hm i 0
237+end
238+for i ulong 1425
239+put Hmgm i 0
240+end
241+for i ulong 285
242+put Hmgm add mul i 5 4 neg 1
243+end
244+for i ulong 95
245+put Hmadv i neg 1
246+end
247+put Hmgn 0 0
248+for i ulong 20
249+put Hmw i 0
250+end
251+put Hminn 0 0
252+put Hmlinen 0 0
253+put Hmask 0 0
254+put Hmsayn 0 0
255+put Hmfootn 0 0
256+note caps: CAP_VOICE/BODY/SMALL * k / 256 (truncating, not S())
257+put Hm 43 div mul 19 get Lg 2 256
258+put Hm 44 div mul 15 get Lg 2 256
259+put Hm 45 div mul 11 get Lg 2 256
260+put Hm 46 1000
261+put Hm 47 1150
262+put Hm 48 1250
263+for i ulong 3
264+put Hm add 40 i div mul get Hm add 43 i 256 20
265+end
266+put Hmhint 0 83
267+put Hmhint 1 112
268+put Hmhint 2 101
269+put Hmhint 3 97
270+put Hmhint 4 107
271+put Hmhint 5 32
272+put Hmhint 6 116
273+put Hmhint 7 111
274+put Hmhint 8 32
275+put Hmhint 9 65
276+put Hmhint 10 108
277+put Hmhint 11 108
278+put Hmhint 12 101
279+put Hmhint 13 110
280+put Hm 22 14
281+bw = hms 720
282+bh = hms 54
283+put Hm 24 div sub get Lg 0 bw 2
284+put Hm 25 sub get Lg 1 hms 150
285+put Hm 26 bw
286+put Hm 27 bh
287+put Hm 28 pkmin sub get Hm 24 hms 20 sub div get Lg 0 2 hms 360
288+put Hm 29 sub get Hm 25 hms 20
289+put Hm 30 pkmax add bw hms 40 hms 720
290+put Hm 31 add bh hms 80
291+note woken at once (ck_allen_ui_wake before the first frame); quiet_t is set by the first frame (hmstep)
292+put Hm 0 1
293+put Hmdirty 2 0
294+end
295+note ---- the keyboard side ----
296+fn hmkey key ulong to void
297+if eq key 13
298+if gt get Hminn 0 0
299+for i ulong get Hminn 0
300+put Hmline i get Hmin i
301+end
302+put Hmlinen 0 get Hminn 0
303+put Hmask 0 1
304+put Hminn 0 0
305+put Hm 15 add get Hm 15 1
306+end
307+ret
308+end
309+if eq key 8
310+if gt get Hminn 0 0
311+put Hminn 0 sub get Hminn 0 1
312+put Hm 15 add get Hm 15 1
313+end
314+ret
315+end
316+if lt key 32
317+ret
318+end
319+if gt key 126
320+ret
321+end
322+if lt get Hminn 0 159
323+put Hmin get Hminn 0 uchar key
324+put Hminn 0 add get Hminn 0 1
325+put Hm 15 add get Hm 15 1
326+end
327+end
328+fn hmthink on long to void
329+if eq on 0
330+ret
331+end
332+put Hm 19 1
333+put Hm 20 1
334+put Hm 21 get Hm 15
335+put Hm 17 add get Hm 17 1
336+end
337+fn hmsaid to void
338+put Hm 19 0
339+if eq get Hmask 0 1
340+put Hm 19 1
341+put Hmask 0 0
342+end
343+put Hm 20 0
344+put Hm 21 get Hm 15
345+put Hm 17 add get Hm 17 1
346+end
347+note ---- the frame ----
348+fn hmnotes t long to void
349+if ne get Hm 15 get Hm 16
350+put Hm 16 get Hm 15
351+if gt get Hminn 0 ulong get Hm 14
352+mdkey t
353+end
354+put Hm 14 long get Hminn 0
355+put Hm 3 t
356+put Hm 2 t
357+put Hm 4 1
358+end
359+if eq get Hm 17 get Hm 18
360+ret
361+end
362+put Hm 18 get Hm 17
363+if ne get Hmw 0 0
364+if eq get Hmw 2 0
365+put Hmw 2 t
366+end
367+end
368+put Hm 13 0
369+if ne get Hm 20 0
370+put Hm 5 0
371+put Hm 6 1
372+else
373+n = pkmin long get Hmsayn 0 159
374+for i ulong ulong n
375+put Hmnext i get Hmsay i
376+end
377+put Hm 13 n
378+think = long 500
379+if ne get Hm 6 0
380+think = 400
381+else
382+if ne get Hm 19 0
383+think = add 900 pkmin mul n 6 700
384+end
385+end
386+put Hm 5 pkmax add t think 15600
387+put Hm 6 0
388+end
389+put Hm 14 0
390+if ne get Hm 15 get Hm 21
391+put Hm 14 long get Hminn 0
392+end
393+put Hm 4 1
394+put Hm 2 t
395+mdmode 2 t
396+end
397+note the flash radius (16ths) and alpha at t (0: none)
398+fn hmfrad t long to long
399+tm = sub t 12000
400+ret mul add hms 40 shr mul hms 220 long pkeaseout pkprog ulong tm 0 1200 8 16
401+end
402+fn hmfa t long to long
403+if lt t 12000
404+ret 0
405+end
406+if ge t 13600
407+ret 0
408+end
409+tm = sub t 12000
410+rise = long pksmooth pkprog ulong tm 0 120
411+e = long 0
412+if gt tm 120
413+e = div mul sub tm 120 256 450
414+end
415+ret shr mul mul rise shr long pkexpneg ulong e 8 230 16
416+end
417+note one wrapped line of Hmnow from start: returns its end (face Hm 23 = 0)
418+fn hmwline from0 long n long to long
419+j = from0
420+w = long 0
421+go = true
422+put Hm 57 0
423+while go
424+if lt j n
425+aw = long div add hmadv get Hmnow j 255 256
426+take = true
427+if gt add w aw hms 900
428+if gt j from0
429+take = false
430+end
431+end
432+if take
433+if eq get Hmnow j 32
434+put Hm 57 j
435+end
436+w = add w aw
437+j = add j 1
438+else
439+go = false
440+end
441+else
442+go = false
443+end
444+end
445+if lt j n
446+if gt get Hm 57 from0
447+j = get Hm 57
448+end
449+end
450+ret j
451+end
452+fn hmwrap to void
453+n = get Hmw 0
454+lines = long 0
455+i = long 0
456+put Hm 23 0
457+put Hm 51 2
458+while lt i n
459+if ge lines 5
460+i = n
461+else
462+while lt i n
463+if eq get Hmnow i 32
464+i = add i 1
465+else
466+n = i
467+end
468+end
469+n = get Hmw 0
470+j = hmwline i n
471+put Hmw add 5 lines i
472+put Hmw add 10 lines sub j i
473+lines = add lines 1
474+i = j
475+end
476+end
477+put Hmw 4 lines
478+end
479+note one line's x (centred), updating the box edges Hm 58 (min x) and Hm 62 (max x1)
480+fn hmlinex li ulong to void
481+lw = hmmeas ulong get Hmw add 5 li ulong get Hmw add 10 li
482+x = div sub get Lg 0 lw 2
483+put Hmw add 15 li x
484+put Hm 58 pkmin get Hm 58 x
485+put Hm 62 pkmax get Hm 62 add x lw
486+end
487+fn hmlayout to void
488+hmwrap
489+put Hm 58 get Lg 0
490+put Hm 62 0
491+for li ulong ulong get Hmw 4
492+hmlinex li
493+end
494+x0 = get Hm 58
495+x1 = get Hm 62
496+lines = get Hmw 4
497+if eq lines 0
498+put Hm 58 0
499+put Hm 59 0
500+put Hm 60 0
501+put Hm 61 0
502+put Hmw 3 add get Hmw 1 700
503+ret
504+end
505+put Hm 58 sub x0 hms 8
506+put Hm 59 sub add get Lg 4 hms 250 hms 34
507+put Hm 60 add sub x1 x0 hms 16
508+put Hm 61 add mul lines hms 40 hms 30
509+last = add get Hmw add 4 lines get Hmw add 9 lines
510+put Hmw 3 add add get Hmw 1 mul last 35 700
511+end
512+fn hmwalpha t long to long
513+if eq get Hmw 0 0
514+ret 0
515+end
516+out = get Hmw 2
517+if eq out 0
518+out = add add get Hmw 3 6000 mul get Hmw 0 70
519+end
520+ret sub 256 long pksmooth pkprog ulong t ulong out ulong add out 450
521+end
522+fn hmspeak t long to void
523+if eq get Hm 5 0
524+ret
525+end
526+if lt t get Hm 5
527+ret
528+end
529+for i ulong ulong get Hm 13
530+put Hmnow i get Hmnext i
531+end
532+put Hmw 0 get Hm 13
533+put Hmw 1 get Hm 5
534+put Hmw 2 0
535+hmlayout
536+put Hm 5 0
537+mdmode 3 t
538+end
539+fn hmpulse t long prev long to void
540+n = get Hmw 0
541+if eq n 0
542+ret
543+end
544+if lt t get Hmw 1
545+ret
546+end
547+if ge prev get Hmw 3
548+ret
549+end
550+for i ulong ulong n
551+at = add get Hmw 1 mul long i 35
552+if gt at prev
553+if le at t
554+if ne get Hmnow i 32
555+first = eq i 0
556+if not first
557+first = eq get Hmnow sub i 1 32
558+end
559+if first
560+mdword t
561+put Hm 7 t
562+end
563+end
564+end
565+end
566+end
567+end
568+note the mind's mode from the words' state (speaking in Hm 56)
569+fn hmwmode t long to void
570+n = get Hmw 0
571+mode = get Mdv 9
572+if eq get Hm 56 0
573+if eq get Hm 5 0
574+if ne n 0
575+if ge t get Hmw 1
576+if or eq mode 3 eq mode 2
577+mdmode 0 t
578+put Hm 2 t
579+mode = 0
580+end
581+end
582+end
583+end
584+end
585+if ne mode 2
586+if ne mode 3
587+lis = long 0
588+if ne get Hm 14 0
589+if lt sub t get Hm 3 4000
590+lis = 1
591+end
592+end
593+mdmode lis t
594+end
595+end
596+end
597+note marks the words box when it changes, remembers it in Hm 32..35, forgets faded words
598+fn hmwbox t long prev long to void
599+n = get Hmw 0
600+if ne n 0
601+if lt t add get Hmw 3 40
602+hmmarkat 58
603+else
604+if ne hmwalpha t hmwalpha prev
605+hmmarkat 58
606+end
607+end
608+end
609+if ne get Hm 34 0
610+moved = ne get Hm 32 get Hm 58
611+if ne get Hm 34 get Hm 60
612+moved = true
613+end
614+if ne get Hm 35 get Hm 61
615+moved = true
616+end
617+if moved
618+hmmarkat 32
619+end
620+end
621+for i ulong 4
622+put Hm add 32 i get Hm add 58 i
623+end
624+if ne n 0
625+if eq hmwalpha t 0
626+if gt t get Hmw 1
627+for i ulong 20
628+put Hmw i 0
629+end
630+for i ulong 4
631+put Hm add 58 i 0
632+end
633+end
634+end
635+end
636+end
637+fn hmwords t long prev long to void
638+hmspeak t
639+hmpulse t prev
640+n = get Hmw 0
641+speaking = false
642+if ne n 0
643+if ge t get Hmw 1
644+speaking = lt t add add get Hmw 1 mul n 35 300
645+end
646+end
647+put Hm 56 0
648+if speaking
649+put Hm 56 1
650+mdvoice shr long pkexpneg ulong div mul sub t get Hm 7 256 200 8
651+else
652+mdvoice 0
653+end
654+hmwmode t
655+hmwbox t prev
656+end
657+note A stable bar only changes at its breathing caret. Background dirty regions already repaint intersecting overlays.
658+fn hmmarkcaret to void
659+put Hm 23 1
660+x = add get Hm 24 hms 30
661+if ne get Hm 14 0
662+x = hmbartyped x 0 false
663+end
664+y = add get Hm 25 div get Hm 27 2
665+y = sub y hms 12
666+hmmark add x hms 3 y pkmax hms 2 2 hms 24
667+end
668+fn hmbarstep t long dt long to void
669+want = false
670+if ne get Hm 0 0
671+if ge t 15300
672+want = ne get Hm 14 0
673+if lt sub t get Hm 2 9000
674+want = true
675+end
676+if ne get Hm 56 0
677+want = true
678+end
679+if ne get Hm 5 0
680+want = true
681+end
682+end
683+end
684+full = long 1400
685+goal = long 0
686+if want
687+goal = 256
688+full = 900
689+if lt sub t get Hm 3 300
690+full = 250
691+end
692+end
693+put Hm 8 hmtoward get Hm 8 goal dt full
694+mark = ne get Hm 8 get Hm 9
695+if ne get Hm 4 0
696+mark = true
697+end
698+if mark
699+hmmarkat 28
700+else
701+if ne get Hm 8 0
702+hmmarkcaret
703+end
704+end
705+put Hm 9 get Hm 8
706+put Hm 4 0
707+end
708+fn hmstep t long to void
709+if ne get Hm 11 0
710+if lt sub t get Hm 10 16
711+ret
712+end
713+else
714+note the first frame takes the setup panel (seen_panel = panel_gen - 1 in start): quiet_t = t, after the wake's FORMED_MS
715+put Hm 2 t
716+end
717+put Hm 11 1
718+put Hm 12 t
719+prev = get Hm 10
720+dt = sub t prev
721+hmnotes t
722+if gt dt 100
723+dt = 100
724+end
725+put Hmdirty 2 0
726+hmmarkat 36
727+put Hm 38 0
728+if ne hmfa t 0
729+r = add shr hmfrad t 4 2
730+put Hm 36 sub get Lg 3 r
731+put Hm 37 sub get Lg 4 r
732+put Hm 38 add mul 2 r 1
733+put Hm 39 add mul 2 r 1
734+hmmarkat 36
735+end
736+hmwords t prev
737+hmbarstep t dt
738+put Hm 10 t
739+end
740+note ---- drawing: hmflash before the mind, hmtext after it, both inside band x y w h ----
741+note one pixel of the shadow taking its black back (unflash in the C): hole 0, keep 0..256
742+fn hmunpx x long y long keep long to void
743+dx = sub add mul x 16 8 get Nthole 0
744+dy = sub add mul y 16 8 get Nthole 1
745+dx = long pkisqrt ulong add mul dx dx mul dy dy
746+dy = sub get Nthole 3 dx
747+if le dy 0
748+ret
749+end
750+if ge dy 16
751+dy = 256
752+else
753+dy = mul dy 16
754+end
755+dy = sub 256 shr mul dy sub 256 keep 8
756+at = add mul ulong y ulong get Lg 0 ulong x
757+put Nfrm at uint pkscale ulong get Nfrm at ulong dy
758+end
759+fn hmunrow y long keep long to void
760+for i ulong ulong get Lg 7
761+hmunpx add get Lg 5 long i y keep
762+end
763+end
764+note clips hole 0's box; false when nothing to do
765+fn hmunbox to bool
766+rs = get Nthole 3
767+if le rs 16
768+ret false
769+end
770+bx = shr sub get Nthole 0 rs 4
771+by = shr sub get Nthole 1 rs 4
772+bw = add shr mul 2 rs 4 2
773+ret hmcut bx by bw bw
774+end
775+fn hmunflash t long to void
776+tm = sub t 12000
777+if ne get Nthol 0 1
778+ret
779+end
780+if lt tm 100
781+ret
782+end
783+keep = sub 256 long pksmooth pkprog ulong tm 100 400
784+if not hmunbox
785+ret
786+end
787+for j ulong ulong get Lg 8
788+hmunrow add get Lg 6 long j keep
789+end
790+end
791+fn hmflash x long y long w long h long to void
792+put Hm 52 x
793+put Hm 53 y
794+put Hm 54 w
795+put Hm 55 h
796+t = get Hm 12
797+a = hmfa t
798+if eq a 0
799+ret
800+end
801+if not hmcut x y w h
802+ret
803+end
804+rad = hmfrad t
805+cx = add mul get Lg 3 16 8
806+cy = add mul get Lg 4 16 8
807+pkglow cx cy rad hmrgb 200 210 255 ulong div a 3
808+pkglow cx cy div rad 3 hmrgb 255 240 224 ulong a
809+hmunflash t
810+end
811+note one of Allen's letters (Hmnow i) age ms after its moment: alpha, colour and rise as draw_words in the C
812+fn hmwletter pen ulong y long i long age long all long to ulong
813+put Hm 49 shr mul long pksmooth pkprog ulong age 0 260 all 8
814+c = pkmix hmrgb 255 212 150 hmrgb 234 238 252 pksmooth pkprog ulong age 0 900
815+rise = shr mul hms 6 sub 256 long pkeaseout pkprog ulong age 0 360 8
816+ret hmblit pen add y rise get Hmnow ulong i c
817+end
818+fn hmwline2 li ulong t long all long to void
819+pen = mul ulong get Hmw add 15 li 256
820+y = add add get Lg 4 hms 250 mul long li hms 40
821+j = get Hmw add 5 li
822+e = add j get Hmw add 10 li
823+while lt j e
824+at = add get Hmw 1 mul j 35
825+if le t at
826+j = e
827+else
828+pen = hmwletter pen y j sub t at all
829+j = add j 1
830+end
831+end
832+end
833+fn hmwdraw t long to void
834+all = hmwalpha t
835+if eq all 0
836+ret
837+end
838+if not hmmeets get Hm 58 get Hm 59 get Hm 60 get Hm 61
839+ret
840+end
841+if not hmcut get Hm 52 get Hm 53 get Hm 54 get Hm 55
842+ret
843+end
844+put Hm 23 0
845+put Hm 51 2
846+put Hm 50 0
847+for li ulong ulong get Hmw 4
848+hmwline2 li t all
849+end
850+end
851+note the bar's rim and, while typing, the soft blue glow round it (draw_bar in the C)
852+fn hmbaredge px ulong sd long a ulong to ulong
853+edge = pkabs add sd 8
854+if lt edge 16
855+e = ulong mul sub 16 edge 3
856+if ne get Hm 14 0
857+e = ulong mul sub 16 edge 4
858+end
859+px = pkadd px hmrgb 255 255 255 shr mul e a 8
860+end
861+if ne get Hm 14 0
862+if gt sd 0
863+if lt sd mul hms 14 16
864+g = ulong sub 256 div mul sd 256 mul hms 14 16
865+g = shr mul g g 8
866+g = shr mul g 34 8
867+px = pkadd px hmrgb 110 130 255 shr mul g a 8
868+end
869+end
870+end
871+ret px
872+end
873+fn hmbarpx x long y long sd long to void
874+a = ulong get Hm 8
875+at = add mul ulong y ulong get Lg 0 ulong x
876+px = ulong get Nfrm at
877+in = pkcover sd
878+if ne in 0
879+px = pkmix px hmrgb 6 8 18 shr mul shr mul in 150 8 a 8
880+end
881+put Nfrm at uint hmbaredge px sd a
882+end
883+fn hmbarsd x long y long to long
884+ret pksdrrect x y get Hm 24 get Hm 25 get Hm 26 get Hm 27
885+end
886+fn hmbarrow y long to void
887+for i ulong ulong get Lg 7
888+x = add get Lg 5 long i
889+hmbarpx x y hmbarsd x y
890+end
891+end
892+fn hmbarbody to void
893+g = hms 14
894+x = sub get Hm 24 g
895+y = sub get Hm 25 g
896+w = add get Hm 26 mul 2 g
897+h = add get Hm 27 mul 2 g
898+if not hmcut x y w h
899+ret
900+end
901+put Lg 9 div get Hm 27 2
902+for j ulong ulong get Lg 8
903+hmbarrow add get Lg 6 long j
904+end
905+end
906+note the caret's light at t: it breathes (ck_sin over 1100 ms) rather than blinks
907+fn hmcaretlvl t long to long
908+d = and mul and sub t get Hm 3 4294967295 65536 4294967295
909+ca = shr mul add 16384 pksin ulong add div d 1100 16384 200 15
910+if lt sub t get Hm 3 500
911+ca = 200
912+end
913+ret shr mul add 40 ca get Hm 8 8
914+end
915+fn hmcaretrow y long a long to void
916+at = add mul ulong y ulong get Lg 0 ulong get Lg 5
917+for i ulong ulong get Lg 7
918+put Nfrm at uint pkadd ulong get Nfrm at hmrgb 150 170 255 ulong a
919+at = add at 1
920+end
921+end
922+fn hmcaret x long t long to void
923+a = hmcaretlvl t
924+cy = sub add get Hm 25 div get Hm 27 2 hms 12
925+if not hmcut add x hms 3 cy pkmax hms 2 2 hms 24
926+ret
927+end
928+for j ulong ulong get Lg 8
929+hmcaretrow add get Lg 6 long j a
930+end
931+end
932+note the first typed letter that fits in avail px (the line scrolls from the left)
933+fn hmbarfrom avail long to long
934+n = get Hm 14
935+from = long 0
936+while lt from n
937+if gt hmmeas ulong from ulong sub n from avail
938+from = add from 1
939+else
940+n = from
941+end
942+end
943+ret from
944+end
945+note the typed line in the bar: returns the pen end in px (Hm 51 = 1, face Hm 23 = 1)
946+fn hmbartyped x long base long tcw bool to long
947+put Hm 51 1
948+avail = sub sub get Hm 26 mul 2 hms 30 hms 12
949+from = hmbarfrom avail
950+n = sub get Hm 14 from
951+if tcw
952+put Hm 49 get Hm 8
953+ret hmwrite ulong from ulong n x base hmrgb 236 240 252
954+end
955+ret add x hmmeas ulong from ulong n
956+end
957+fn hmbarline t long to void
958+pad = hms 30
959+base = add add get Hm 25 div get Hm 27 2 hms 7
960+x = add get Hm 24 pad
961+pad = sub get Hm 26 mul 2 pad
962+tcw = hmcut x get Hm 25 pad get Hm 27
963+put Hm 23 1
964+put Hm 50 0
965+if eq get Hm 14 0
966+if tcw
967+put Hm 51 0
968+put Hm 49 shr mul 192 get Hm 8 8
969+dd = hmwrite 0 ulong get Hm 22 x base hmrgb 150 160 196
970+end
971+else
972+x = hmbartyped x base tcw
973+end
974+hmcaret x t
975+end
976+fn hmfooter to void
977+if eq get Hmfootn 0 0
978+ret
979+end
980+if ne get Hm 14 0
981+ret
982+end
983+if not hmcut get Hm 52 get Hm 53 get Hm 54 get Hm 55
984+ret
985+end
986+put Hm 23 2
987+put Hm 51 3
988+put Hm 50 0
989+put Hm 49 shr mul 222 get Hm 8 8
990+n = get Hmfootn 0
991+fw = hmmeas 0 n
992+fw = div sub get Lg 0 fw 2
993+fy = add add get Hm 25 get Hm 27 hms 34
994+dd = hmwrite 0 n fw fy hmrgb 130 140 176
995+end
996+fn hmbar t long to void
997+if eq get Hm 8 0
998+ret
999+end
1000+if not hmmeets get Hm 28 get Hm 29 get Hm 30 get Hm 31
1001+ret
1002+end
1003+hmbarbody
1004+hmbarline t
1005+hmfooter
1006+end
1007+fn hmtext x long y long w long h long to void
1008+put Hm 52 x
1009+put Hm 53 y
1010+put Hm 54 w
1011+put Hm 55 h
1012+hmwdraw get Hm 12
1013+hmbar get Hm 12
1014+end
1015+fn hmdraw x long y long w long h long to void
1016+hmflash x y w h
1017+hmtext x y w h
1018+end

aienux/allen/look-install.om

new file mode 100644
@@ -0,0 +1,158 @@
1+note SPDX-License-Identifier: MIT
2+note Install: the typed line `install allen on this computer` copies the running firmware image
3+note from the stick's volume to the one other volume that already holds \EFI\BOOT\BOOTX64.EFI
4+note (the internal EFI System Partition the C kernel made), through the compiler's file word
5+note (efi 11: sub 0 counts volumes and finds the boot one, 1 reads that file, 2 writes it).
6+note Nothing happens at boot; only the typed line installs. Needs look-home.om (Hmsay, hmsaid)
7+note and base.om (In, Inlen) before it in the unit; look-show.om calls inmatch and ininstall.
8+note Ins: 0 last attempt (ms), 1 bytes written, 2 failing step (0 none), 3 status low 16 bits.
9+global Inimg uchar 4194304
10+global Ins ulong 4
11+text Incmd "install allen on this computer"
12+text Inok "Installed on this computer: "
13+text Inok2 " bytes. Shut down, take the stick out, start me again."
14+text Inno "Not installed: "
15+text Inno2 " status "
16+text Insteps "count|boot volume|no other volume holds Allen|more than one volume holds Allen|read|write|size"
17+fn inmatch to bool
18+note The typed line, letters in either case, equals the command.
19+n = get Inlen 0
20+if ne n len Incmd
21+ret false
22+end
23+for i ulong n
24+c = get In i
25+if and ge c 65 le c 90
26+c = add c 32
27+end
28+if ne c get Incmd i
29+ret false
30+end
31+end
32+ret true
33+end
34+fn inchar at ulong c uchar to ulong
35+if lt at len Hmsay
36+put Hmsay at c
37+end
38+ret add at 1
39+end
40+fn innum at ulong v ulong to ulong
41+note Decimal digits of v at position at; returns the position after them.
42+d = ulong 1
43+t = v
44+while ge t 10
45+t = div t 10
46+d = add d 1
47+end
48+e = add at d
49+p = e
50+for i ulong d
51+p = sub p 1
52+q = inchar p uchar add 48 rem v 10
53+v = div v 10
54+end
55+ret e
56+end
57+fn instep at ulong k ulong to ulong
58+note Field k of Insteps (fields separated by |) at position at.
59+f = ulong 0
60+for i ulong len Insteps
61+c = get Insteps i
62+if eq c 124
63+f = add f 1
64+else
65+if eq f k
66+at = inchar at c
67+end
68+end
69+end
70+ret at
71+end
72+fn infail step ulong st ulong to void
73+put Ins 2 add step 1
74+put Ins 3 and st 65535
75+at = ulong 0
76+for i ulong len Inno
77+at = inchar at get Inno i
78+end
79+at = instep at step
80+for i ulong len Inno2
81+at = inchar at get Inno2 i
82+end
83+at = innum at and st 65535
84+at = inchar at 46
85+put Hmsayn 0 at
86+hmsaid
87+end
88+fn insaid bytes ulong to void
89+put Ins 1 bytes
90+put Ins 2 0
91+put Ins 3 0
92+at = ulong 0
93+for i ulong len Inok
94+at = inchar at get Inok i
95+end
96+at = innum at bytes
97+for i ulong len Inok2
98+at = inchar at get Inok2 i
99+end
100+put Hmsayn 0 at
101+hmsaid
102+end
103+fn inholds k ulong to bool
104+note True when volume k holds \EFI\BOOT\BOOTX64.EFI: a read succeeds, or fails only
105+note because the file is larger than Inimg (file word code 24).
106+rd = efi 11 or 1 shl k 8 Inimg 0 len Inimg
107+if eq shr rd 63 0
108+ret true
109+end
110+ret eq and rd 255 24
111+end
112+fn ininstall now ulong to void
113+put Ins 0 now
114+r = efi 11 0 Inimg 0 0
115+if eq shr r 63 1
116+infail 0 r
117+ret
118+end
119+n = and r 255
120+boot = and shr r 8 255
121+if eq boot 255
122+infail 1 n
123+ret
124+end
125+found = ulong 0
126+tgt = ulong 0
127+for k ulong n
128+if ne k boot
129+if inholds k
130+found = add found 1
131+tgt = k
132+end
133+end
134+end
135+if eq found 0
136+infail 2 n
137+ret
138+end
139+if gt found 1
140+infail 3 found
141+ret
142+end
143+rd = efi 11 or 1 shl boot 8 Inimg 0 len Inimg
144+if eq shr rd 63 1
145+infail 4 rd
146+ret
147+end
148+wr = efi 11 or 2 shl tgt 8 Inimg 0 rd
149+if eq shr wr 63 1
150+infail 5 wr
151+ret
152+end
153+if ne wr rd
154+infail 6 wr
155+ret
156+end
157+insaid wr
158+end

aienux/allen/look-mind.om

new file mode 100644
@@ -0,0 +1,1088 @@
1+note SPDX-License-Identifier: MIT
2+note Allen's look, part 4: Allen's presence, the mind of light. Handwritten Omega port of
3+note native/kernel/ui/mind.h and mind.c (aienux 4b24df65), integer for integer: about a hundred
4+note sharp points on and inside a sphere joined by fine threads, turning round a compact heart,
5+note with sparks running along the threads. mdat moves it to a time; mddraw only reads.
6+note Needs look-paint.om (pkmin pkmax pkabs pkclamp pksin pkcos pkisqrt pkhash pkexpneg pkprog
7+note pkeaseout pksmooth pkcover pkmix, Lg, Nfrm). The mind's own thread and point mix coverage
8+note (never add light), so they are private here (mdthread, mdpoint), as in mind.c.
9+note Statements are short on purpose: every literal and operator of a statement holds one of the
10+note function's 16 value slots until the statement ends.
11+note Mdv state slots: 0 cx 1 cy 2 R (px) 3 k 4 ne 5 born 6 t 7 rng (32-bit xorshift) 8 spawn
12+note 9 mode (0 idle 1 listen 2 think 3 speak) 10 angle (32-bit wrap, 1/256 of a 65536th)
13+note 11 spin 12 squeeze 13 heart 14 voice 15 nspark 16 alpha 17 hx 18 hy 19 hr (16ths)
14+note 20 form (0..256 this frame) 21 ca 22 sa 23 ct 24 st 25 scale 26 R16 27 x0 28 x1 29 y0 30 y1
15+note (the frame's bounding box in 16ths) 31 ta (thread alpha this draw).
16+note Mdhome: home[i][c] at 3*i+c (unit sphere, Q14). Mdea/Mdeb: the edges. Mdact: how lit each
17+note point is. Sparks as parallel arrays Mdse (edge) Mdsdur (ms) Mdsback (runs eb to ea) Mdst0.
18+note Mdpx Mdpy (16ths) Mdlum Mdnear: the frame for mddraw. Mdwords/Mdkeys: when the last four
19+note pulses began (ms, 0 none). Mdnow/Mdwas: the box now and the frame before; mddirty writes
20+note their union to Mdbox. Mdclip: the draw rect. Mdp: draw scratch. Mdtab: the mode tables
21+note (0..3 spins, 4..7 squeezes, 8..11 hearts, 12..15 spark rates, by mode).
22+global Mdv long 32
23+global Mdhome long 360
24+global Mdea long 300
25+global Mdeb long 300
26+global Mdact long 120
27+global Mdse long 64
28+global Mdsdur long 64
29+global Mdsback long 64
30+global Mdst0 long 64
31+global Mdpx long 120
32+global Mdpy long 120
33+global Mdlum long 120
34+global Mdnear long 120
35+global Mdwords long 4
36+global Mdkeys long 4
37+global Mdnow long 4
38+global Mdwas long 4
39+global Mdbox long 4
40+global Mdclip long 4
41+global Mdp long 16
42+global Mdtab long 16
43+fn mdrnd to long
44+r = get Mdv 7
45+s = shl r 13
46+s = and s 4294967295
47+r = xor r s
48+s = shr r 17
49+r = xor r s
50+s = shl r 5
51+s = and s 4294967295
52+r = xor r s
53+put Mdv 7 r
54+ret r
55+end
56+fn mdhome i long c long to long
57+j = mul i 3
58+j = add j c
59+ret get Mdhome j
60+end
61+fn mddist2 i long j long to long
62+dx = sub mdhome i 0 mdhome j 0
63+dy = sub mdhome i 1 mdhome j 1
64+dz = sub mdhome i 2 mdhome j 2
65+dx = mul dx dx
66+dy = mul dy dy
67+dz = mul dz dz
68+ret add add dx dy dz
69+end
70+fn mdhasedge a long b long to bool
71+nedge = get Mdv 4
72+for i ulong ulong nedge
73+ea = get Mdea i
74+eb = get Mdeb i
75+if eq ea a
76+if eq eb b
77+ret true
78+end
79+end
80+if eq ea b
81+if eq eb a
82+ret true
83+end
84+end
85+end
86+ret false
87+end
88+fn mdput i long c long v long to void
89+j = mul i 3
90+j = add j c
91+put Mdhome j v
92+end
93+note one home point: the first 96 on a Fibonacci lattice over the sphere, the last 24 inside
94+fn mdnode i long to void
95+y = long 0
96+th = ulong 0
97+ln = long 0
98+if lt i 96
99+y = mul 2 i
100+y = add y 1
101+y = mul y 16384
102+y = div y 96
103+y = sub 16384 y
104+th = mul ulong i 25033
105+ln = long rem pkhash i 1 31 5900
106+ln = add ln 13434
107+else
108+h1 = pkhash i 2 31
109+th = pkhash i 3 31
110+y = long rem h1 32768
111+y = sub 16384 y
112+ln = long rem pkhash i 4 31 5734
113+ln = add ln 4915
114+end
115+rr = mul y y
116+rr = sub 268435456 rr
117+rr = long pkisqrt ulong rr
118+x = mul rr pkcos th
119+x = shr x 14
120+z = mul rr pksin th
121+z = shr z 14
122+x = mul x ln
123+mdput i 0 shr x 14
124+y = mul y ln
125+mdput i 1 shr y 14
126+z = mul z ln
127+mdput i 2 shr z 14
128+end
129+note the nearest point to i not yet joined to it, or -1
130+fn mdnearest i long to long
131+best = long -1
132+bd = long 0
133+for j ulong 120
134+jj = long j
135+if ne jj i
136+if not mdhasedge i jj
137+d = mddist2 i jj
138+if lt best 0
139+best = jj
140+bd = d
141+else
142+if lt d bd
143+best = jj
144+bd = d
145+end
146+end
147+end
148+end
149+end
150+ret best
151+end
152+fn mdedges to void
153+for i ulong 120
154+ii = long i
155+want = long 3
156+if lt ii 96
157+want = 2
158+end
159+for w ulong ulong want
160+best = mdnearest ii
161+if ge best 0
162+nedge = get Mdv 4
163+if lt nedge 300
164+put Mdea nedge ii
165+put Mdeb nedge best
166+put Mdv 4 add nedge 1
167+end
168+end
169+end
170+end
171+end
172+fn mdtables to void
173+put Mdtab 0 349
174+put Mdtab 1 520
175+put Mdtab 2 1400
176+put Mdtab 3 600
177+put Mdtab 4 0
178+put Mdtab 5 4
179+put Mdtab 6 16
180+put Mdtab 7 0
181+put Mdtab 8 50
182+put Mdtab 9 70
183+put Mdtab 10 120
184+put Mdtab 11 80
185+put Mdtab 12 2
186+put Mdtab 13 6
187+put Mdtab 14 25
188+put Mdtab 15 12
189+end
190+note (cx, cy) its centre and k the scale from Lg; born the time it starts to gather (ms)
191+fn mdinit born long to void
192+for i ulong 32
193+put Mdv i 0
194+end
195+for i ulong 120
196+put Mdact i 0
197+end
198+for i ulong 4
199+put Mdwords i 0
200+put Mdkeys i 0
201+put Mdnow i 0
202+put Mdwas i 0
203+put Mdbox i 0
204+end
205+k = get Lg 2
206+put Mdv 0 get Lg 3
207+put Mdv 1 get Lg 4
208+r = mul 118 k
209+r = add r 128
210+put Mdv 2 div r 256
211+put Mdv 3 k
212+put Mdv 5 born
213+put Mdv 7 2654435769
214+put Mdv 11 349
215+mdtables
216+for i ulong 120
217+mdnode long i
218+end
219+mdedges
220+end
221+fn mdmode m long t long to void
222+put Mdv 9 m
223+end
224+fn mdword t long to void
225+put Mdwords 3 get Mdwords 2
226+put Mdwords 2 get Mdwords 1
227+put Mdwords 1 get Mdwords 0
228+if eq t 0
229+put Mdwords 0 1
230+else
231+put Mdwords 0 t
232+end
233+end
234+fn mdkey t long to void
235+put Mdkeys 3 get Mdkeys 2
236+put Mdkeys 2 get Mdkeys 1
237+put Mdkeys 1 get Mdkeys 0
238+if eq t 0
239+put Mdkeys 0 1
240+else
241+put Mdkeys 0 t
242+end
243+end
244+fn mdvoice lvl long to void
245+if gt lvl 256
246+lvl = 256
247+end
248+put Mdv 14 lvl
249+end
250+note the thread leaving from that the spark takes: e or the next one round that touches from
251+fn mdsedge e long from long to long
252+nedge = get Mdv 4
253+tries = long 0
254+note at most ne + 1 passes: tries reaches ne or an edge of from is found
255+while true bound 400
256+if eq get Mdea e from
257+break
258+end
259+if eq get Mdeb e from
260+break
261+end
262+if ge tries nedge
263+break
264+end
265+tries = add tries 1
266+e = add e 1
267+e = rem e nedge
268+end
269+ret e
270+end
271+note a spark on a thread leaving from, or on any thread when from is out of range
272+fn mdspark from long to void
273+ns = get Mdv 15
274+nedge = get Mdv 4
275+if ge ns 64
276+ret
277+end
278+if eq nedge 0
279+ret
280+end
281+e = rem mdrnd nedge
282+back = long 0
283+if lt from 120
284+e = mdsedge e from
285+if eq get Mdeb e from
286+back = 1
287+end
288+else
289+back = and mdrnd 1
290+end
291+put Mdse ns e
292+put Mdsback ns back
293+put Mdst0 ns get Mdv 6
294+if eq get Mdv 9 2
295+e = rem mdrnd 260
296+put Mdsdur ns add e 240
297+else
298+e = rem mdrnd 480
299+put Mdsdur ns add e 420
300+end
301+put Mdv 15 add ns 1
302+end
303+fn mdtoward cur long want long dt long ms long to long
304+d = sub want cur
305+step = pkmin dt ms
306+step = mul d step
307+step = div step ms
308+if eq step 0
309+if ne d 0
310+if ne dt 0
311+step = 1
312+if lt d 0
313+step = -1
314+end
315+end
316+end
317+end
318+ret add cur step
319+end
320+note (1 - (off/width)^2)^2, 0..256
321+fn mdpulse off long width long to long
322+if le off neg width
323+ret 0
324+end
325+if ge off width
326+ret 0
327+end
328+q = mul off off
329+q = mul q 256
330+w2 = mul width width
331+q = div q w2
332+q = sub 256 q
333+q = mul q q
334+ret shr q 8
335+end
336+note ulong (t * 65536 as uint32) / period
337+fn mdphase t long period long to ulong
338+p = mul t 65536
339+p = and p 4294967295
340+ret ulong div p period
341+end
342+note spin, squeeze and heart eased toward the mode's
343+fn mdease md long dt long t long to void
344+put Mdv 11 mdtoward get Mdv 11 get Mdtab md dt 700
345+w = add md 4
346+put Mdv 12 mdtoward get Mdv 12 get Mdtab w dt 500
347+w = add md 8
348+wh = get Mdtab w
349+ms = long 400
350+if eq md 3
351+w = mul get Mdv 14 120
352+w = div w 256
353+wh = add wh w
354+ms = 80
355+end
356+if eq md 2
357+w = pksin mdphase t 900
358+w = add w 16384
359+w = mul w 30
360+w = shr w 15
361+wh = add wh w
362+end
363+put Mdv 13 mdtoward get Mdv 13 wh dt ms
364+end
365+note copy spark slot a over slot b
366+fn mdscopy a long b long to void
367+put Mdse b get Mdse a
368+put Mdsdur b get Mdsdur a
369+put Mdsback b get Mdsback a
370+put Mdst0 b get Mdst0 a
371+end
372+note spark i arrives: its point lights, and the spark may go on
373+fn mdarrived md long i long to void
374+e = get Mdse i
375+dest = get Mdeb e
376+if ne get Mdsback i 0
377+dest = get Mdea e
378+end
379+put Mdact dest 256
380+ns = sub get Mdv 15 1
381+put Mdv 15 ns
382+mdscopy ns i
383+r = rem mdrnd 100
384+go = false
385+if eq md 2
386+if lt r 70
387+go = true
388+end
389+else
390+if lt r 18
391+go = true
392+end
393+end
394+if go
395+mdspark dest
396+end
397+end
398+fn mdarrive md long t long to void
399+i = long 0
400+note each pass moves i on or removes one of the at most 64 sparks that were there
401+while lt i get Mdv 15 bound 200
402+age = sub t get Mdst0 i
403+if lt age get Mdsdur i
404+i = add i 1
405+else
406+mdarrived md i
407+end
408+end
409+end
410+fn mddecay dt long to void
411+f = mul dt 256
412+f = div f 260
413+f = long pkexpneg ulong f
414+for i ulong 120
415+a = mul get Mdact i f
416+put Mdact i shr a 16
417+end
418+end
419+note the shape this frame: breathing, drawn in while thinking, gathered in while being born
420+fn mdshape t long form long to void
421+b = pksin mdphase t 5500
422+b = mul b 1966
423+b = shr b 14
424+sq = mul get Mdv 12 65536
425+sq = div sq 256
426+scale = add 65536 b
427+scale = sub scale sq
428+gather = long pkeaseout form
429+gather = sub 256 gather
430+b = mul gather 560
431+b = div b 256
432+b = add b 256
433+scale = mul scale b
434+put Mdv 25 shr scale 8
435+sw = mul gather gather
436+sw = shr sw 8
437+sw = mul sw 256
438+b = shr get Mdv 10 8
439+b = add b sw
440+b = and b 4294967295
441+put Mdv 16 long pksmooth mul form 3
442+put Mdv 21 pkcos ulong b
443+put Mdv 22 pksin ulong b
444+put Mdv 23 pkcos 3641
445+put Mdv 24 pksin 3641
446+put Mdv 26 mul get Mdv 2 16
447+put Mdv 27 mul get Mdv 0 16
448+put Mdv 28 get Mdv 27
449+put Mdv 29 mul get Mdv 1 16
450+put Mdv 30 get Mdv 29
451+end
452+note turn about the upright axis: rz
453+fn mdrz i long to long
454+x = mul mdhome i 0 get Mdv 22
455+z = mul mdhome i 2 get Mdv 21
456+x = add x z
457+ret shr x 14
458+end
459+fn mdrx i long to long
460+x = mul mdhome i 0 get Mdv 21
461+z = mul mdhome i 2 get Mdv 22
462+x = sub x z
463+ret shr x 14
464+end
465+note c*16 + 8 + (v * persp >> 14) * R16 / 16384 * scale / 65536
466+fn mdscreen c long v long persp long to long
467+v = mul v persp
468+v = shr v 14
469+v = mul v get Mdv 26
470+v = div v 16384
471+v = mul v get Mdv 25
472+v = div v 65536
473+c = mul c 16
474+c = add c 8
475+ret add c v
476+end
477+note (uint32_t) of the nearness then capped at 256: a negative value wraps past 256
478+fn mdnear32 v long to long
479+if lt v 0
480+ret 256
481+end
482+if gt v 256
483+ret 256
484+end
485+ret v
486+end
487+fn mdproj i long to void
488+rz = mdrz i
489+y = mdhome i 1
490+ry = mul y get Mdv 23
491+fz = mul rz get Mdv 24
492+ry = sub ry fz
493+ry = shr ry 14
494+fz = mul y get Mdv 24
495+y = mul rz get Mdv 23
496+fz = add fz y
497+fz = shr fz 14
498+persp = mul fz 3
499+persp = div persp 16
500+persp = add persp 16384
501+put Mdpx i mdscreen get Mdv 0 mdrx i persp
502+put Mdpy i mdscreen get Mdv 1 ry persp
503+fz = add fz 16384
504+fz = mul fz 256
505+put Mdnear i mdnear32 div fz 32768
506+end
507+fn mdrad i long to long
508+x = mdhome i 0
509+x = mul x x
510+y = mdhome i 1
511+y = mul y y
512+z = mdhome i 2
513+z = mul z z
514+x = add add x y z
515+x = long pkisqrt ulong x
516+x = mul x 256
517+ret div x 16384
518+end
519+note the light a word pulse of this age gives a point at rad
520+fn mdwpulse rad long age long to long
521+o = mul age 300
522+o = div o 600
523+o = sub rad o
524+p = mdpulse o 70
525+o = sub 900 age
526+p = mul p o
527+p = div p 900
528+p = mul p 150
529+ret shr p 8
530+end
531+note the light a key pulse of this age gives a point at ny
532+fn mdkpulse ny long age long to long
533+o = mul age 600
534+o = div o 500
535+o = sub 300 o
536+o = sub ny o
537+p = mdpulse o 60
538+o = sub 600 age
539+p = mul p o
540+p = div p 600
541+p = mul p 90
542+ret shr p 8
543+end
544+note light from the pulses: words outward from the heart, keys upward from below
545+fn mdpulses rad long ny long t long to long
546+extra = long 0
547+for w ulong 4
548+wt = get Mdwords w
549+if ne wt 0
550+if le wt t
551+age = sub t wt
552+if lt age 900
553+extra = add extra mdwpulse rad age
554+end
555+end
556+end
557+wt = get Mdkeys w
558+if ne wt 0
559+if le wt t
560+age = sub t wt
561+if lt age 600
562+extra = add extra mdkpulse ny age
563+end
564+end
565+end
566+end
567+ret extra
568+end
569+fn mdlight i long t long to void
570+rad = mdrad i
571+ny = mdhome i 1
572+ny = mul ny 256
573+ny = div ny 16384
574+l = mdpulses rad ny t
575+nr = get Mdnear i
576+nr = mul nr nr
577+nr = div nr 256
578+nr = mul nr 180
579+nr = div nr 256
580+l = add l nr
581+l = add l 34
582+nr = mul get Mdact i 120
583+nr = div nr 256
584+l = add l nr
585+if gt l 256
586+l = 256
587+end
588+put Mdlum i l
589+end
590+fn mdgrow i long to void
591+put Mdv 27 pkmin get Mdv 27 get Mdpx i
592+put Mdv 28 pkmax get Mdv 28 get Mdpx i
593+put Mdv 29 pkmin get Mdv 29 get Mdpy i
594+put Mdv 30 pkmax get Mdv 30 get Mdpy i
595+end
596+note the native-pixel heart and the box round everything
597+fn mdboxup to void
598+hx = mul get Mdv 0 16
599+hx = add hx 8
600+hy = mul get Mdv 1 16
601+hy = add hy 8
602+put Mdv 17 hx
603+put Mdv 18 hy
604+put Mdv 19 24
605+x0 = sub get Mdv 27 48
606+x0 = pkmin x0 sub hx 40
607+x1 = add get Mdv 28 48
608+x1 = pkmax x1 add hx 40
609+y0 = sub get Mdv 29 48
610+y0 = pkmin y0 sub hy 40
611+y1 = add get Mdv 30 48
612+y1 = pkmax y1 add hy 40
613+put Mdnow 0 sub shr x0 4 1
614+put Mdnow 1 sub shr y0 4 1
615+x1 = sub x1 x0
616+x1 = shr x1 4
617+put Mdnow 2 add x1 3
618+y1 = sub y1 y0
619+y1 = shr y1 4
620+put Mdnow 3 add y1 3
621+end
622+note sparks are born at the mode's rate
623+fn mdspawn md long dt long to void
624+w = add md 12
625+w = mul get Mdtab w dt
626+spawn = add get Mdv 8 w
627+note spawn grows by at most 25*250 per frame
628+while ge spawn 1000 bound 999999
629+spawn = sub spawn 1000
630+mdspark 120
631+end
632+put Mdv 8 spawn
633+end
634+fn mdat t long to void
635+dt = long 0
636+if gt t get Mdv 6
637+dt = sub t get Mdv 6
638+end
639+if gt dt 250
640+dt = 250
641+end
642+put Mdv 6 t
643+for i ulong 4
644+put Mdwas i get Mdnow i
645+end
646+if lt t get Mdv 5
647+put Mdv 16 0
648+for i ulong 4
649+put Mdnow i 0
650+end
651+ret
652+end
653+md = and get Mdv 9 3
654+mdease md dt t
655+dt2 = mul get Mdv 11 dt
656+dt2 = add dt2 get Mdv 10
657+put Mdv 10 and dt2 4294967295
658+born = get Mdv 5
659+dt2 = add born 3000
660+form = pkprog ulong t ulong born ulong dt2
661+put Mdv 20 form
662+if ge form 192
663+mdspawn md dt
664+end
665+mdarrive md t
666+mddecay dt
667+mdshape t form
668+for i ulong 120
669+mdproj long i
670+mdlight long i t
671+mdgrow long i
672+end
673+mdboxup
674+end
675+fn mdcopy4 which long to void
676+for i ulong 4
677+if eq which 0
678+put Mdbox i get Mdnow i
679+else
680+put Mdbox i get Mdwas i
681+end
682+end
683+end
684+note what needs redrawing: the union of where it was and where it is, into Mdbox
685+fn mddirty to void
686+if le get Mdwas 2 0
687+mdcopy4 0
688+ret
689+end
690+if le get Mdwas 3 0
691+mdcopy4 0
692+ret
693+end
694+if le get Mdnow 2 0
695+mdcopy4 1
696+ret
697+end
698+if le get Mdnow 3 0
699+mdcopy4 1
700+ret
701+end
702+x0 = pkmin get Mdwas 0 get Mdnow 0
703+y0 = pkmin get Mdwas 1 get Mdnow 1
704+put Mdbox 0 x0
705+put Mdbox 1 y0
706+x1 = add get Mdwas 0 get Mdwas 2
707+x1 = pkmax x1 add get Mdnow 0 get Mdnow 2
708+put Mdbox 2 sub x1 x0
709+x1 = add get Mdwas 1 get Mdwas 3
710+x1 = pkmax x1 add get Mdnow 1 get Mdnow 3
711+put Mdbox 3 sub x1 y0
712+end
713+note ---- drawing: coverage-mixed points and threads inside Mdclip and the screen ----
714+note Mdp 1 cx 2 cy 3 radius 4 color 5 alpha 6 inner2 7 outer2 9 x0 10 y0 11 x1 12 y1 (the pixel box)
715+fn mdpbox bx long by long bw long bh long to bool
716+x0 = pkmax bx get Mdclip 0
717+x0 = pkmax x0 0
718+y0 = pkmax by get Mdclip 1
719+y0 = pkmax y0 0
720+x1 = add get Mdclip 0 get Mdclip 2
721+x1 = pkmin x1 add bx bw
722+x1 = pkmin x1 get Lg 0
723+y1 = add get Mdclip 1 get Mdclip 3
724+y1 = pkmin y1 add by bh
725+y1 = pkmin y1 get Lg 1
726+if le x1 x0
727+ret false
728+end
729+if le y1 y0
730+ret false
731+end
732+put Mdp 9 x0
733+put Mdp 10 y0
734+put Mdp 11 x1
735+put Mdp 12 y1
736+ret true
737+end
738+note mix the point's colour into frame word idx with this coverage
739+fn mdpmix idx ulong cov ulong to void
740+a = mul cov ulong get Mdp 5
741+a = shr a 8
742+put Nfrm idx uint pkmix ulong get Nfrm idx ulong get Mdp 4 a
743+end
744+fn mdprow y long to void
745+dy = mul y 16
746+dy = add dy 8
747+dy = sub dy get Mdp 2
748+dy = mul dy dy
749+x = get Mdp 9
750+xe = get Mdp 11
751+idx = mul ulong y ulong get Lg 0
752+idx = add idx ulong x
753+note xe - x pixels, at most the screen width
754+while lt x xe bound 4096
755+dx = mul x 16
756+dx = add dx 8
757+dx = sub dx get Mdp 1
758+dx = mul dx dx
759+dx = add dx dy
760+if lt dx get Mdp 7
761+cov = ulong 256
762+full = false
763+if ge get Mdp 3 8
764+if le dx get Mdp 6
765+full = true
766+end
767+end
768+if not full
769+dx = long pkisqrt ulong dx
770+cov = pkcover sub dx get Mdp 3
771+end
772+if ne cov 0
773+mdpmix idx cov
774+end
775+end
776+x = add x 1
777+idx = add idx 1
778+end
779+end
780+note a filled geometric point: constant light inside, one-pixel coverage at its boundary
781+fn mdpoint cx long cy long radius long color long alpha long to void
782+if le radius 0
783+ret
784+end
785+if eq alpha 0
786+ret
787+end
788+bx = sub cx radius
789+bx = sub bx 8
790+bx = shr bx 4
791+by = sub cy radius
792+by = sub by 8
793+by = shr by 4
794+bw = add cx radius
795+bw = add bw 8
796+bw = shr bw 4
797+bw = sub bw bx
798+bw = add bw 1
799+bh = add cy radius
800+bh = add bh 8
801+bh = shr bh 4
802+bh = sub bh by
803+bh = add bh 1
804+if not mdpbox bx by bw bh
805+ret
806+end
807+put Mdp 1 cx
808+put Mdp 2 cy
809+put Mdp 3 radius
810+put Mdp 4 color
811+put Mdp 5 alpha
812+bx = sub radius 8
813+bx = pkmax bx 0
814+put Mdp 6 mul bx bx
815+bx = add radius 8
816+put Mdp 7 mul bx bx
817+by = get Mdp 10
818+note at most the screen height rows
819+while lt by get Mdp 12 bound 4096
820+mdprow by
821+by = add by 1
822+end
823+end
824+note Mdp 0 width 1 x0 2 y0 3 len 4 grad 5 radius 6 a0 7 a1 8 steep (after the swaps)
825+fn mdtin x long y long to bool
826+if lt x get Mdclip 0
827+ret false
828+end
829+if lt y get Mdclip 1
830+ret false
831+end
832+if ge x add get Mdclip 0 get Mdclip 2
833+ret false
834+end
835+if ge y add get Mdclip 1 get Mdclip 3
836+ret false
837+end
838+if lt x 0
839+ret false
840+end
841+if lt y 0
842+ret false
843+end
844+if ge x get Lg 0
845+ret false
846+end
847+if ge y get Lg 1
848+ret false
849+end
850+ret true
851+end
852+fn mdtpx X long Y long yc long a long to void
853+x = X
854+y = Y
855+if ne get Mdp 8 0
856+x = Y
857+y = X
858+end
859+if not mdtin x y
860+ret
861+end
862+yc = mul Y 16
863+yc = add yc 8
864+yc = sub yc get Mdp 2
865+yc = pkabs yc
866+yc = sub yc get Mdp 5
867+a = mul a long pkcover yc
868+a = shr a 8
869+x = add mul y get Lg 0 x
870+put Nfrm x uint pkmix ulong get Nfrm x 7900415 ulong a
871+end
872+fn mdtcol X long to void
873+along = mul X 16
874+along = add along 8
875+along = sub along get Mdp 1
876+yc = mul along get Mdp 4
877+yc = shr yc 16
878+yc = add yc get Mdp 2
879+a = sub get Mdp 7 get Mdp 6
880+a = mul a along
881+a = div a get Mdp 3
882+a = add a get Mdp 6
883+y = sub yc get Mdp 5
884+y = sub y 8
885+y = shr y 4
886+ye = add yc get Mdp 5
887+ye = add ye 8
888+ye = shr ye 4
889+put Mdp 2 yc
890+note radius/8 + 2 rows
891+while le y ye bound 4096
892+mdtpx X y yc a
893+y = add y 1
894+end
895+put Mdp 2 get Mdp 9
896+end
897+fn mdtrun x0 long y0 long x1 long y1 long a0 long a1 long to void
898+ln = sub x1 x0
899+ln = pkmax ln 1
900+grad = sub y1 y0
901+grad = mul grad 65536
902+grad = div grad ln
903+put Mdp 1 x0
904+put Mdp 2 y0
905+put Mdp 9 y0
906+put Mdp 3 ln
907+put Mdp 4 grad
908+put Mdp 6 a0
909+put Mdp 7 a1
910+grad = mul grad grad
911+grad = add grad 4294967296
912+grad = long pkisqrt ulong grad
913+grad = shr grad 8
914+grad = mul grad get Mdp 0
915+put Mdp 5 shr grad 9
916+x0 = add x0 7
917+x0 = shr x0 4
918+x1 = sub x1 8
919+x1 = shr x1 4
920+if ne get Mdp 8 0
921+x0 = pkmax x0 get Mdclip 1
922+ln = add get Mdclip 1 get Mdclip 3
923+else
924+x0 = pkmax x0 get Mdclip 0
925+ln = add get Mdclip 0 get Mdclip 2
926+end
927+x1 = pkmin x1 sub ln 1
928+note at most the screen's major extent of columns
929+while le x0 x1 bound 4096
930+mdtcol x0
931+x0 = add x0 1
932+end
933+end
934+note a thread whose light runs from a0 to a1, coverage mixed (crossings never add up)
935+fn mdthread x0 long y0 long x1 long y1 long a0 long a1 long to void
936+if le get Mdp 0 0
937+ret
938+end
939+if eq a0 0
940+if eq a1 0
941+ret
942+end
943+end
944+put Mdp 8 0
945+t = pkabs sub y1 y0
946+if gt t pkabs sub x1 x0
947+put Mdp 8 1
948+t = x0
949+x0 = y0
950+y0 = t
951+t = x1
952+x1 = y1
953+y1 = t
954+end
955+if gt x0 x1
956+t = x0
957+x0 = x1
958+x1 = t
959+t = y0
960+y0 = y1
961+y1 = t
962+t = a0
963+a0 = a1
964+a1 = t
965+end
966+mdtrun x0 y0 x1 y1 a0 a1
967+end
968+fn mdtalpha n long to long
969+l = mul get Mdnear n 60
970+l = div l 256
971+l = add l 16
972+l = mul l get Mdlum n
973+l = shr l 8
974+l = mul l get Mdv 31
975+ret shr l 8
976+end
977+fn mdthreads to void
978+put Mdp 0 div get Mdv 3 16
979+nedge = get Mdv 4
980+for i ulong ulong nedge
981+a = get Mdea i
982+b = get Mdeb i
983+mdthread get Mdpx a get Mdpy a get Mdpx b get Mdpy b mdtalpha a mdtalpha b
984+end
985+end
986+fn mdpoints to void
987+al = get Mdv 16
988+for i ulong 120
989+c = long pkmix 2115728 3174592 ulong get Mdact i
990+a = mul get Mdlum i al
991+mdpoint get Mdpx i get Mdpy i 16 c shr a 8
992+end
993+end
994+note the k-th of a spark's three fading points
995+fn mdsparkpt a long b long g long k long to void
996+x = sub get Mdpx b get Mdpx a
997+x = mul x g
998+x = shr x 8
999+x = add x get Mdpx a
1000+y = sub get Mdpy b get Mdpy a
1001+y = mul y g
1002+y = shr y 8
1003+y = add y get Mdpy a
1004+g = shr 200 k
1005+g = mul g get Mdv 16
1006+g = shr g 8
1007+k = mul k 4
1008+mdpoint x y sub 16 k 3174592 g
1009+end
1010+fn mdsparkdraw i long to void
1011+e = get Mdse i
1012+a = get Mdea e
1013+b = get Mdeb e
1014+if ne get Mdsback i 0
1015+a = get Mdeb e
1016+b = get Mdea e
1017+end
1018+f = sub get Mdv 6 get Mdst0 i
1019+f = mul f 256
1020+f = div f get Mdsdur i
1021+for k long 3
1022+g = mul k 22
1023+g = sub f g
1024+g = pkclamp g 0 256
1025+mdsparkpt a b g k
1026+end
1027+end
1028+fn mdheart to void
1029+h = get Mdv 13
1030+c = long pkmix 2115728 3174592 ulong h
1031+a = add 90 h
1032+a = pkmin a 256
1033+a = mul a get Mdv 16
1034+mdpoint get Mdv 17 get Mdv 18 get Mdv 19 c shr a 8
1035+end
1036+note does the mind's box meet the draw rect
1037+fn mdmeets to bool
1038+x1 = add get Mdnow 0 get Mdnow 2
1039+x1 = pkmin x1 add get Mdclip 0 get Mdclip 2
1040+if le x1 pkmax get Mdnow 0 get Mdclip 0
1041+ret false
1042+end
1043+x1 = add get Mdnow 1 get Mdnow 3
1044+x1 = pkmin x1 add get Mdclip 1 get Mdclip 3
1045+if le x1 pkmax get Mdnow 1 get Mdclip 1
1046+ret false
1047+end
1048+ret true
1049+end
1050+note the figure into the part (x, y, w, h) of the frame, held inside the clip Lg[5..8]
1051+fn mddraw x long y long w long h long to void
1052+if eq get Mdv 16 0
1053+ret
1054+end
1055+x0 = pkmax x get Lg 5
1056+y0 = pkmax y get Lg 6
1057+w = add x w
1058+w = pkmin w add get Lg 5 get Lg 7
1059+h = add y h
1060+h = pkmin h add get Lg 6 get Lg 8
1061+if le w x0
1062+ret
1063+end
1064+if le h y0
1065+ret
1066+end
1067+put Mdclip 0 x0
1068+put Mdclip 1 y0
1069+put Mdclip 2 sub w x0
1070+put Mdclip 3 sub h y0
1071+if not mdmeets
1072+ret
1073+end
1074+x0 = sub get Mdv 20 128
1075+x0 = mul x0 2
1076+x0 = long pksmooth x0
1077+x0 = mul x0 get Mdv 16
1078+put Mdv 31 shr x0 8
1079+if ne get Mdv 31 0
1080+mdthreads
1081+end
1082+mdpoints
1083+w = get Mdv 15
1084+for i ulong ulong w
1085+mdsparkdraw long i
1086+end
1087+mdheart
1088+end

aienux/allen/look-night.om

new file mode 100644
@@ -0,0 +1,965 @@
1+note look-night.om: the night, ported from native/kernel/ui/night.c at aienux 4b24df65 (integer for integer).
2+note Needs look-paint.om (pk*, Lg, Nfrm, Nsky, Slin, Ssrgb) and look-sky.om (skmake, sktwink, Sktw*, Skg*) before it;
3+note pkinit must have run (the integrator does that once; ntinit does not).
4+note API: ntinit; ntat t; ntbase x y w h; ntlights x y w h shim voice; ntfaded x y l; ntstarbox i (into Pa 0..3);
5+note ntholes; ntcount. Readable state after ntat: Nthol (count), Nthole (x y e rs per hole, 16ths; hole 0 at 0..3, hole 1 at
6+note 4..7), Ntlens (x y w h px, w=0 none), Ntrip (0 ripple_r px, 1 ripple_w px (0 none), 2 ripple_c2, 3 ripple_s2 Q14).
7+note Milliseconds: FADE_END 6800, HOLES 2600, SPIRAL 6000, MERGE 12000, RIPPLE 3600, GONE 15200, ORBIT 5200.
8+global Ntapp uchar 519901
9+global Ntaw long 1
10+global Ntt ulong 1
11+global Nthol ulong 1
12+global Nthole long 8
13+global Ntlens long 4
14+global Ntrip long 4
15+global Ntdisp long 1024
16+global Ntlit uchar 1024
17+global Ntband uchar 256
18+global Ntpow2 ulong 257
19+global Ntsep long 1
20+global Ntsxy long 2
21+global Ntwarp long 3
22+global Ntcor long 12
23+global Ntwt long 4
24+global Ntlr long 8
25+global Ntlit0 ulong 257
26+global Ntsz long 5
27+global Ntcoarse ulong 1
28+global Ntdone uint 131072
29+global Ntstamp uint 1
30+global Ntbw long 1
31+global Ntb long 4
32+global Ntd long 4
33+global Ntg long 5
34+note nts: S(v) = (v * k + 128) / 256, the 1920 x 1080 design unit scaled to this screen.
35+fn nts v long to long
36+ret div add mul v get Lg 2 128 256
37+end
38+note ntpow2: 2^(x / 65536) in Q16 (night.c pow2_q16).
39+fn ntpow2 x ulong to ulong
40+n = shr x 16
41+f = and x 65535
42+k = shr f 8
43+g = and f 255
44+m = add get Ntpow2 k shr mul sub get Ntpow2 add k 1 get Ntpow2 k g 8
45+ret shl m n
46+end
47+note ntgauss: exp(-(v / width)^2) in Q16 (night.c gauss).
48+fn ntgauss v long width long to ulong
49+if eq width 0
50+width = 1
51+end
52+q = div mul v 256 width
53+if or gt q 4095 lt q -4095
54+ret 0
55+end
56+ret pkexpneg ulong shr mul q q 8
57+end
58+note ntfar: the farthest screen corner from the centre, pixels.
59+fn ntfar to long
60+far = long 0
61+for i ulong 4
62+px = long 0
63+if eq and i 1 1
64+px = get Lg 0
65+end
66+py = long 0
67+if eq shr i 1 1
68+py = get Lg 1
69+end
70+dx = sub px get Lg 3
71+dy = sub py get Lg 4
72+far = pkmax far long pkisqrt ulong add mul dx dx mul dy dy
73+end
74+ret far
75+end
76+fn ntappx x long y long h long far long to uchar
77+x = mul x 4
78+y = mul y 4
79+dx = sub x get Lg 3
80+dy = sub y get Lg 4
81+dx = long pkisqrt ulong add mul dx dx mul dy dy
82+dx = div mul dx 255 far
83+x = div mul x 640 h
84+y = div mul y 640 h
85+dy = long shr pkfbm x y 909 4 8
86+ret uchar div add mul dy 6 mul dx 4 10
87+end
88+note ntappear: the appearance map, one byte per 4 x 4 cell (night.c appear_map).
89+fn ntappear to void
90+aw = ulong get Ntaw 0
91+ah = ulong add div get Lg 1 4 1
92+h = get Lg 1
93+far = ntfar
94+if eq far 0
95+far = 1
96+end
97+for y ulong ah
98+for x ulong aw
99+put Ntapp add mul y aw x ntappx long x long y h far
100+end
101+end
102+end
103+note ntfaded: how far pixel (x, y) with luma l has faded in, 0..256 (ck_night_faded).
104+fn ntfaded x long y long l ulong to ulong
105+if ge get Ntt 0 6800
106+ret 256
107+end
108+x = pkclamp x 0 sub get Lg 0 1
109+y = pkclamp y 0 sub get Lg 1 1
110+y = add mul shr y 2 get Ntaw 0 shr x 2
111+x = mul long get Ntapp y 12
112+x = add add 300 x mul sub 255 long l 8
113+dt = sub long get Ntt 0 x
114+if le dt 0
115+ret 0
116+end
117+if ge dt 1365
118+ret 256
119+end
120+ret pksmooth shr mul dt 48 8
121+end
122+fn ntfadepx c ulong x long y long to ulong
123+if eq c 0
124+note pkscale 0 f is 0 for every f: one black fades to itself.
125+ret 0
126+end
127+l = pkmax pkmax long and shr c 16 255 long and shr c 8 255 long and c 255
128+f = ntfaded x y ulong l
129+if ge f 256
130+ret c
131+end
132+ret pkscale c f
133+end
134+note ntfrow / ntcrow: one row of the base, pixels x0..x1-1, fading / plain copy.
135+fn ntfrow y long x0 long x1 long to void
136+base = mul y get Lg 0
137+for i ulong ulong sub x1 x0
138+x = add x0 long i
139+p = add base x
140+c = ulong get Nsky p
141+if ne c 0
142+c = ntfadepx c x y
143+end
144+put Nfrm p uint c
145+end
146+end
147+fn ntcrow y long x0 long x1 long to void
148+base = mul y get Lg 0
149+for i ulong ulong sub x1 x0
150+p = add base add x0 long i
151+put Nfrm p get Nsky p
152+end
153+end
154+note ntinit: tables, the sky (skmake), the appearance map, state at t = 0 (ck_night_init).
155+fn ntinit to void
156+note The ripple's light over one black: pkadd for every light value, computed once (most of
157+note the sky is one black, so the per-pixel add becomes a table read; same bytes).
158+for a ulong 257
159+put Ntlit0 a pkadd 0 5663920 a
160+end
161+put Ntsz 0 mul sub get Lg 0 1 16
162+put Ntsz 1 mul sub get Lg 1 1 16
163+put Ntsz 2 sub get Lg 0 1
164+put Ntsz 3 sub get Lg 1 1
165+put Ntsz 4 mul sub get Lg 1 1 get Lg 0
166+put Ntcoarse 0 0
167+put Ntbw 0 div add get Lg 0 7 8
168+put Ntstamp 0 0
169+for i ulong 131072
170+put Ntdone i 0
171+end
172+for i ulong 256
173+c = shr ulong add 16384 pkcos mul i 256 1
174+c2 = shr mul c c 14
175+c6 = shr mul shr mul c2 c2 14 c2 14
176+put Ntband i uchar shr mul c6 255 14
177+end
178+e2 = ulong 1073741824
179+for i ulong 256
180+put Ntpow2 i shr add e2 8192 14
181+e2 = shr mul e2 1076652777 30
182+end
183+put Ntpow2 256 131072
184+put Ntaw 0 add div get Lg 0 4 1
185+skmake
186+ntappear
187+ntat 0
188+end
189+fn ntroot8 l ulong to ulong
190+for i ulong 3
191+l = pkisqrt shl l 30
192+end
193+ret l
194+end
195+note ntorbit: the orbit angle (turns / 65536) at t; the separation (16ths) goes to Ntsep (night.c orbit_angle).
196+fn ntorbit t ulong a0 long to ulong
197+if lt t 6000
198+put Ntsep 0 a0
199+ret div mul sub t 2600 65536 5200
200+end
201+left = div shl sub 12000 t 30 6000
202+r = ntroot8 left
203+r2 = shr mul r r 30
204+r5 = shr mul shr mul r2 r2 30 r 30
205+put Ntsep 0 long shr mul ulong a0 r2 30
206+ret add 42850 shr mul 120989 sub 1073741824 r5 30
207+end
208+fn ntat2 t ulong ef long rf long a0 long cx long cy long to void
209+ang = ntorbit t a0
210+v = shr mul ef long pksmooth pkprog t 2600 5200 8
211+put Nthole 2 v
212+put Nthole 6 v
213+v = shr mul rf long pksmooth pkprog t 4000 6000 8
214+put Nthole 3 v
215+put Nthole 7 v
216+v = div get Ntsep 0 2
217+hx = shr mul v pkcos ang 14
218+hy = shr mul v pksin ang 15
219+put Nthole 0 add cx hx
220+put Nthole 1 add cy hy
221+put Nthole 4 sub cx hx
222+put Nthole 5 sub cy hy
223+put Nthol 0 2
224+end
225+fn ntat1 t ulong ef long rf long cx long cy long to void
226+tm = sub t 12000
227+rs0 = div mul rf 323 256
228+rs = long pksmooth pkprog tm 0 180
229+rs = add rs0 shr mul sub mul rf 2 rs0 rs 8
230+wob = long pkexpneg div mul tm 256 260
231+wob = shr mul pksin div mul tm 65536 95 wob 16
232+wob = div mul mul rs wob 7 100
233+rs = add rs shr wob 14
234+keep = sub 256 long pksmooth pkprog t 12900 15200
235+put Nthole 0 cx
236+put Nthole 1 cy
237+ef = div mul ef 362 256
238+put Nthole 2 shr mul ef keep 8
239+keep = shr mul keep keep 8
240+put Nthole 3 shr mul rs keep 8
241+put Nthol 0 1
242+end
243+note ntunion: Ntlens = Ntlens U (x y w h), the lens rect in pixels.
244+fn ntunion x long y long w long h long to void
245+if or le get Ntlens 2 0 le get Ntlens 3 0
246+put Ntlens 0 x
247+put Ntlens 1 y
248+put Ntlens 2 w
249+put Ntlens 3 h
250+ret
251+end
252+x0 = pkmin get Ntlens 0 x
253+y0 = pkmin get Ntlens 1 y
254+x1 = pkmax add get Ntlens 0 get Ntlens 2 add x w
255+y1 = pkmax add get Ntlens 1 get Ntlens 3 add y h
256+put Ntlens 0 x0
257+put Ntlens 1 y0
258+put Ntlens 2 sub x1 x0
259+put Ntlens 3 sub y1 y0
260+end
261+note ntholebox: hole i's own lens box (x y w h, unclipped) into Pa 0..3; false when it has none.
262+fn ntholebox i ulong to bool
263+b = mul i 4
264+e = get Nthole add b 2
265+rs = get Nthole add b 3
266+if and le e 0 le rs 0
267+ret false
268+end
269+reach = add shr div mul e 44 10 4 2
270+rs = add shr div mul rs 16 10 4 2
271+reach = pkmax reach rs
272+put Pa 0 sub shr get Nthole b 4 reach
273+put Pa 1 sub shr get Nthole add b 1 4 reach
274+put Pa 2 add mul 2 reach 1
275+put Pa 3 add mul 2 reach 1
276+ret true
277+end
278+fn ntlensbox to void
279+for i ulong get Nthol 0
280+if ntholebox i
281+x = get Pa 0
282+y = get Pa 1
283+w = get Pa 2
284+ntunion x y w get Pa 3
285+end
286+end
287+if ne get Ntlens 2 0
288+x0 = pkmax get Ntlens 0 0
289+y0 = pkmax get Ntlens 1 0
290+x1 = pkmin add get Ntlens 0 get Ntlens 2 get Lg 0
291+y1 = pkmin add get Ntlens 1 get Ntlens 3 get Lg 1
292+if or le x1 x0 le y1 y0
293+put Ntlens 0 0
294+put Ntlens 1 0
295+put Ntlens 2 0
296+put Ntlens 3 0
297+else
298+put Ntlens 0 x0
299+put Ntlens 1 y0
300+put Ntlens 2 sub x1 x0
301+put Ntlens 3 sub y1 y0
302+end
303+end
304+end
305+note ntriptab: Ntdisp / Ntlit over the ripple width; amp in Ntsxy 0, env in Ntsxy 1.
306+fn ntriptab reach long w long lambda long to void
307+n = ulong add mul 2 reach 1
308+for i ulong n
309+o = sub long i reach
310+s = and div mul o 65536 lambda 65535
311+s = shr mul get Ntsxy 0 pksin ulong s 14
312+put Ntdisp i shr mul s long ntgauss o w 16
313+s = long ntgauss o div mul w 6 10
314+s = mul mul s get Ntsxy 1 46
315+put Ntlit i uchar shr s 24
316+end
317+end
318+fn ntripple t ulong last ulong to void
319+if or lt t 12000 ge t 15600
320+ret
321+end
322+tr = sub t 12000
323+w = pkclamp nts 60 4 200
324+reach = div mul w 22 10
325+far = add ntfar reach
326+rr = div mul far long tr 3600
327+put Ntrip 0 rr
328+put Ntrip 1 w
329+env = sub 256 pksmooth pkprog tr 2160 3600
330+env = shr mul pksmooth pkprog tr 0 220 env 8
331+amp = sub 256 div mul 150 rr far
332+amp = shr mul mul nts 6 16 amp 8
333+put Ntsxy 0 shr mul amp long env 8
334+put Ntsxy 1 long env
335+ntriptab reach w pkmax nts 110 8
336+put Ntrip 2 pkcos mul 2 last
337+put Ntrip 3 pksin mul 2 last
338+end
339+note ntat: the state at t ms (ck_night_at): holes, lens rect, ripple tables.
340+fn ntat t ulong to void
341+put Ntt 0 t
342+put Ntstamp 0 add get Ntstamp 0 1
343+put Nthol 0 0
344+put Ntlens 0 0
345+put Ntlens 1 0
346+put Ntlens 2 0
347+put Ntlens 3 0
348+put Ntrip 0 0
349+put Ntrip 1 0
350+put Ntrip 2 0
351+put Ntrip 3 0
352+ef = mul nts 60 16
353+rf = mul nts 20 16
354+a0 = mul nts 270 16
355+cx = add mul get Lg 3 16 8
356+cy = add mul get Lg 4 16 8
357+last = ntorbit 11999 a0
358+if and ge t 2600 lt t 12000
359+ntat2 t ef rf a0 cx cy
360+else
361+if and ge t 12000 lt t 15200
362+ntat1 t ef rf cx cy
363+end
364+end
365+ntlensbox
366+ntripple t last
367+end
368+note ntsample: the sky at (sx, sy) in 16ths, bilinear (night.c sample). The four taps are
369+note read in place; when they agree (most of the sky is one black) no mix is needed, as pkmix
370+note itself would answer: it returns d when d equals c.
371+fn ntsample sx long sy long to ulong
372+sx = pkclamp sub sx 8 0 mul sub get Lg 0 1 16
373+sy = pkclamp sub sy 8 0 mul sub get Lg 1 1 16
374+ix = shr sx 4
375+iy = mul shr sy 4 get Lg 0
376+ix1 = pkmin add ix 1 sub get Lg 0 1
377+iy1 = iy
378+if lt shr sy 4 sub get Lg 1 1
379+iy1 = add iy get Lg 0
380+end
381+a = ulong get Nsky add iy ix
382+b = ulong get Nsky add iy ix1
383+c = ulong get Nsky add iy1 ix
384+d = ulong get Nsky add iy1 ix1
385+if and eq a b and eq c d eq a c
386+ret a
387+end
388+fx = mul ulong and sx 15 16
389+a = pkmix a b fx
390+c = pkmix c d fx
391+ret pkmix a c mul ulong and sy 15 16
392+end
393+fn ntlens1 e long dx long dy long d2 long out long to void
394+in = div mul mul e e 484 100
395+if lt d2 64
396+d2 = 64
397+end
398+f = div mul mul e e 65536 d2
399+if gt d2 in
400+w = div mul sub out d2 65536 sub out in
401+f = shr mul f shr mul w w 16 16
402+end
403+put Ntsxy 0 sub get Ntsxy 0 shr mul dx f 16
404+put Ntsxy 1 sub get Ntsxy 1 shr mul dy f 16
405+end
406+fn ntlens0 X long Y long b ulong to void
407+e = get Nthole add b 2
408+if le e 0
409+ret
410+end
411+dx = sub X get Nthole b
412+dy = sub Y get Nthole add b 1
413+d2 = add mul dx dx mul dy dy
414+out = div mul mul e e 1936 100
415+if lt d2 out
416+ntlens1 e dx dy d2 out
417+end
418+end
419+fn ntlensat X long Y long to void
420+for i ulong get Nthol 0
421+ntlens0 X Y mul i 4
422+end
423+end
424+fn ntwrip2 dx long dy long d2 long r16 long i long to void
425+q = mul sub mul dx dx mul dy dy get Ntrip 2
426+q = add q mul mul 2 mul dx dy get Ntrip 3
427+q = div q d2
428+m = add 5734 shr mul q 10650 14
429+m = shr mul get Ntdisp i m 14
430+put Ntsxy 0 sub get Ntsxy 0 div mul m dx r16
431+put Ntsxy 1 sub get Ntsxy 1 div mul m dy r16
432+put Ntwarp 2 long get Ntlit i
433+end
434+fn ntwripple X long Y long to void
435+dx = sub X add mul get Lg 3 16 8
436+dy = sub Y add mul get Lg 4 16 8
437+d2 = add mul dx dx mul dy dy
438+r16 = long pkisqrt ulong d2
439+reach = div mul get Ntrip 1 22 10
440+i = add sub shr r16 4 get Ntrip 0 reach
441+if gt r16 0
442+if and ge i 0 le i mul 2 reach
443+if lt i 1024
444+ntwrip2 dx dy d2 r16 i
445+end
446+end
447+end
448+end
449+note ntwarp: where (X, Y) in 16ths samples from: offset in Ntwarp 0 1, ripple light in Ntwarp 2 (night.c warp).
450+fn ntwarp X long Y long to void
451+put Ntsxy 0 0
452+put Ntsxy 1 0
453+put Ntwarp 2 0
454+ntlensat X Y
455+if ne get Ntrip 1 0
456+ntwripple X Y
457+end
458+put Ntwarp 0 get Ntsxy 0
459+put Ntwarp 1 get Ntsxy 1
460+end
461+fn ntfinal c ulong x long y long light ulong to ulong
462+if lt get Ntt 0 6800
463+c = ntfadepx c x y
464+end
465+if ne light 0
466+if and eq c 0 le light 256
467+ret get Ntlit0 light
468+end
469+ret pkadd c 5663920 light
470+end
471+ret c
472+end
473+note ntring: the shadow disc and the ring of a hole of radius rs at distance r (16ths) over c.
474+fn ntring c ulong r long rs long to ulong
475+c = pkmix c 0 pkcover sub r rs
476+ring = pkabs sub r div mul rs 104 100
477+a = ulong 0
478+if lt ring 22
479+a = ulong mul sub 22 ring 6
480+end
481+if gt r rs
482+if lt r div mul rs 3 2
483+ring = sub div mul rs 3 2 r
484+a = add a ulong div mul ring 46 add div rs 2 1
485+end
486+end
487+ret pkadd c 16770244 a
488+end
489+fn ntshadow c ulong X long Y long b ulong to ulong
490+rs = get Nthole add b 3
491+if le rs 0
492+ret c
493+end
494+dx = sub X get Nthole b
495+dy = sub Y get Nthole add b 1
496+dx = add mul dx dx mul dy dy
497+if ge dx div mul mul rs rs 9 4
498+ret c
499+end
500+ret ntring c long pkisqrt ulong dx rs
501+end
502+note ntnearpx: one pixel next to a hole, exact warp plus the shadow disc and ring (night.c near_px).
503+fn ntnearpx x long y long to ulong
504+X = add mul x 16 8
505+Y = add mul y 16 8
506+note ntwarp in place: the lens of every hole, then the ripple, into Ntsxy and Ntwarp 2.
507+put Ntsxy 0 0
508+put Ntsxy 1 0
509+put Ntwarp 2 0
510+for i ulong get Nthol 0
511+ntlens0 X Y mul i 4
512+end
513+if ne get Ntrip 1 0
514+ntwripple X Y
515+end
516+c = ntsample add X get Ntsxy 0 add Y get Ntsxy 1
517+c = ntfinal c x y ulong get Ntwarp 2
518+for i ulong get Nthol 0
519+c = ntshadow c X Y mul i 4
520+end
521+ret c
522+end
523+fn ntnear1 X long Y long b ulong to bool
524+reach = div mul get Nthole add b 3 3 2
525+reach = add pkmax get Nthole add b 2 reach 128
526+dx = sub X get Nthole b
527+dy = sub Y get Nthole add b 1
528+ret lt add mul dx dx mul dy dy mul reach reach
529+end
530+fn ntnearhole x long y long to bool
531+x = add mul x 16 8
532+y = add mul y 16 8
533+for i ulong get Nthol 0
534+if ntnear1 x y mul i 4
535+ret true
536+end
537+end
538+ret false
539+end
540+fn ntinrip bx long by long to bool
541+if eq get Ntrip 1 0
542+ret false
543+end
544+reach = add div mul get Ntrip 1 22 10 1
545+lo = pkmax 0 sub get Ntrip 0 reach
546+hi = add get Ntrip 0 reach
547+cx = get Lg 3
548+cy = get Lg 4
549+nx = sub pkclamp cx bx add bx 8 cx
550+ny = sub pkclamp cy by add by 8 cy
551+if gt add mul nx nx mul ny ny mul hi hi
552+ret false
553+end
554+nx = pkmax pkabs sub bx cx pkabs sub add bx 8 cx
555+ny = pkmax pkabs sub by cy pkabs sub add by 8 cy
556+ret ge add mul nx nx mul ny ny mul lo lo
557+end
558+note ntmeetl: does the s x s box at (x, y) meet the lens rect.
559+fn ntmeetl x long y long s long to bool
560+if ge x add get Ntlens 0 get Ntlens 2
561+ret false
562+end
563+if ge y add get Ntlens 1 get Ntlens 3
564+ret false
565+end
566+if le add x s get Ntlens 0
567+ret false
568+end
569+if le add y s get Ntlens 1
570+ret false
571+end
572+ret true
573+end
574+note ntdrect: Ntd = (x y w h) ∩ clip ∩ screen as x0 y0 x1 y1; false if empty.
575+fn ntdrect x long y long w long h long to bool
576+put Ntd 0 pkmax x pkmax 0 get Lg 5
577+put Ntd 1 pkmax y pkmax 0 get Lg 6
578+x = pkmin get Lg 0 add get Lg 5 get Lg 7
579+put Ntd 2 pkmin add x w x
580+y = pkmin get Lg 1 add get Lg 6 get Lg 8
581+put Ntd 3 pkmin add y h y
582+if le get Ntd 2 get Ntd 0
583+ret false
584+end
585+if le get Ntd 3 get Ntd 1
586+ret false
587+end
588+ret true
589+end
590+note ntbclip: Ntb = (bx by 8 8) clipped to Ntd, as x0 y0 x1 y1; false if empty.
591+fn ntbclip bx long by long to bool
592+put Ntb 0 pkmax bx get Ntd 0
593+put Ntb 1 pkmax by get Ntd 1
594+put Ntb 2 pkmin add bx 8 get Ntd 2
595+put Ntb 3 pkmin add by 8 get Ntd 3
596+if le get Ntb 2 get Ntb 0
597+ret false
598+end
599+if le get Ntb 3 get Ntb 1
600+ret false
601+end
602+ret true
603+end
604+fn ntnearrow y long to void
605+p = mul y get Lg 0
606+n = ulong sub get Ntb 2 get Ntb 0
607+for i ulong n
608+x = add get Ntb 0 long i
609+put Nfrm add p x uint ntnearpx x y
610+end
611+end
612+fn ntnearblk to void
613+n = ulong sub get Ntb 3 get Ntb 1
614+for j ulong n
615+ntnearrow add get Ntb 1 long j
616+end
617+end
618+fn ntcorners bx long by long to void
619+for c ulong 4
620+X = mul add bx mul long and c 1 8 16
621+Y = mul add by mul long shr c 1 8 16
622+ntwarp X Y
623+put Ntcor c get Ntwarp 0
624+put Ntcor add c 4 get Ntwarp 1
625+put Ntcor add c 8 get Ntwarp 2
626+end
627+end
628+note ntmix4: the bilinear mix of four taps at fractions sx, sy (sixteenths), as ntsample.
629+fn ntmix4 a ulong b ulong c ulong d ulong sx long sy long to ulong
630+a = pkmix a b mul ulong and sx 15 16
631+c = pkmix c d mul ulong and sx 15 16
632+ret pkmix a c mul ulong and sy 15 16
633+end
634+note ntgpx: one pixel of a grid block at wx (odd sixteenths across the block): the warp and
635+note light interpolated between the row's left and right edge values Ntlr (ntgridrow), then the
636+note sky sample (ntsample in place: clamp, four taps, bilinear only when the taps differ) and
637+note the fade or the ripple light (ntfinal in place). The edge form equals the four-corner dot
638+note of night.c exactly: (16-wx)(c0(16-wy) + c2 wy) + wx(c1(16-wy) + c3 wy).
639+fn ntgpx x long y long wx long to ulong
640+wi = sub 16 wx
641+sx = mul get Ntlr 0 wi
642+sx = add sx mul get Ntlr 3 wx
643+sy = mul get Ntlr 1 wi
644+sy = add sy mul get Ntlr 4 wx
645+sx = add mul x 16 shr sx 8
646+sy = add mul y 16 shr sy 8
647+if lt sx 0
648+sx = 0
649+end
650+if gt sx get Ntsz 0
651+sx = get Ntsz 0
652+end
653+if lt sy 0
654+sy = 0
655+end
656+if gt sy get Ntsz 1
657+sy = get Ntsz 1
658+end
659+ix = shr sx 4
660+wi = mul shr sy 4 get Lg 0
661+wi = add wi ix
662+note ix becomes the step to the right tap: 1, or 0 on the last column (pkmin ix+1 w-1).
663+if lt ix get Ntsz 2
664+ix = 1
665+else
666+ix = 0
667+end
668+a = ulong get Nsky wi
669+b = ulong get Nsky add wi ix
670+note The row below exists while the tap lies above the last row (pkmin iy+1 h-1).
671+if lt wi get Ntsz 4
672+wi = add wi get Lg 0
673+end
674+c = ulong get Nsky wi
675+d = ulong get Nsky add wi ix
676+if ne a b
677+a = ntmix4 a b c d sx sy
678+else
679+if ne c d
680+a = ntmix4 a b c d sx sy
681+else
682+if ne a c
683+a = ntmix4 a b c d sx sy
684+end
685+end
686+end
687+if lt get Ntt 0 6800
688+a = ntfadepx a x y
689+end
690+note The light, interpolated like the warp; sx is free now and holds it.
691+wi = sub 16 wx
692+sx = mul get Ntlr 2 wi
693+sx = add sx mul get Ntlr 5 wx
694+sx = shr sx 8
695+if ne sx 0
696+if and eq a 0 le sx 256
697+ret get Ntlit0 ulong sx
698+end
699+ret pkadd a 5663920 ulong sx
700+end
701+ret a
702+end
703+fn ntgridrow y long bx long wy long to void
704+p = mul y get Lg 0
705+wi = sub 16 wy
706+for k ulong 3
707+b = mul k 4
708+v = mul get Ntcor b wi
709+v = add v mul get Ntcor add b 2 wy
710+put Ntlr k v
711+v = mul get Ntcor add b 1 wi
712+v = add v mul get Ntcor add b 3 wy
713+put Ntlr add k 3 v
714+end
715+n = ulong sub get Ntb 2 get Ntb 0
716+for i ulong n
717+x = add get Ntb 0 long i
718+put Nfrm add p x uint ntgpx x y add mul 2 sub x bx 1
719+end
720+end
721+fn ntgridblk bx long by long to void
722+n = ulong sub get Ntb 3 get Ntb 1
723+for j ulong n
724+y = add get Ntb 1 long j
725+ntgridrow y bx add mul 2 sub y by 1
726+end
727+end
728+note ntcoarse: the ripple's band drawn at 2 x 2 (one sample for four pixels): same warp, same
729+note light, a quarter of the samples. Ntcoarse 0 keeps every pixel (the C look exactly);
730+note look-show.om turns it on while the ripple runs on a large screen.
731+fn ntgridrow2 y long bx long wy long to void
732+p = mul y get Lg 0
733+wi = sub 16 wy
734+for k ulong 3
735+b = mul k 4
736+v = mul get Ntcor b wi
737+v = add v mul get Ntcor add b 2 wy
738+put Ntlr k v
739+v = mul get Ntcor add b 1 wi
740+v = add v mul get Ntcor add b 3 wy
741+put Ntlr add k 3 v
742+end
743+x = get Ntb 0
744+while lt x get Ntb 2 bound 8
745+c = ntgpx x y add mul 2 sub x bx 1
746+put Nfrm add p x uint c
747+if lt add x 1 get Ntb 2
748+put Nfrm add p add x 1 uint c
749+end
750+x = add x 2
751+end
752+end
753+fn ntrowdup y long to void
754+note Row y of the block's columns copied onto row y + 1.
755+w = get Lg 0
756+p = add mul y w get Ntb 0
757+n = ulong sub get Ntb 2 get Ntb 0
758+for i ulong n
759+x = add p long i
760+put Nfrm add x w get Nfrm x
761+end
762+end
763+fn ntgridblk2 bx long by long to void
764+y = get Ntb 1
765+while lt y get Ntb 3 bound 8
766+ntgridrow2 y bx add mul 2 sub y by 1
767+if lt add y 1 get Ntb 3
768+ntrowdup y
769+end
770+y = add y 2
771+end
772+end
773+note ntblock: one 8 x 8 block of the warped base (night.c ck_night_base block loop).
774+note ntwhole: is the 8 x 8 block at (bx, by) entirely inside the draw rect Ntd.
775+fn ntwhole bx long by long to bool
776+if or lt bx get Ntd 0 lt by get Ntd 1
777+ret false
778+end
779+ret and le add bx 8 get Ntd 2 le add by 8 get Ntd 3
780+end
781+fn ntblock bx long by long to void
782+lens = false
783+if ne get Ntlens 2 0
784+lens = ntmeetl bx by 8
785+end
786+if not lens
787+if not ntinrip bx by
788+ret
789+end
790+end
791+if not ntbclip bx by
792+ret
793+end
794+note Rectangles composed in one frame overlap (the ripple's bands meet the lens box); a block
795+note drawn whole earlier this frame is the same block again, so it is left alone. Only whole
796+note blocks are stamped: a clipped one may be covered further by a later rectangle.
797+whole = ntwhole bx by
798+idx = ulong add mul shr by 3 get Ntbw 0 shr bx 3
799+if whole
800+if eq get Ntdone idx get Ntstamp 0
801+ret
802+end
803+put Ntdone idx get Ntstamp 0
804+end
805+if lens
806+if ntnearhole add bx 4 add by 4
807+ntnearblk
808+ret
809+end
810+end
811+ntcorners bx by
812+if and not lens ne get Ntcoarse 0 0
813+ntgridblk2 bx by
814+else
815+ntgridblk bx by
816+end
817+end
818+fn ntblocks to void
819+by = sub get Ntd 1 rem get Ntd 1 8
820+while lt by get Ntd 3 bound 1024
821+bx = sub get Ntd 0 rem get Ntd 0 8
822+while lt bx get Ntd 2 bound 1024
823+ntblock bx by
824+bx = add bx 8
825+end
826+by = add by 8
827+end
828+end
829+note ntbase: Nsky as seen now into Nfrm, inside (x y w h) ∩ clip (ck_night_base).
830+fn ntbase x long y long w long h long to void
831+if not ntdrect x y w h
832+ret
833+end
834+fading = lt get Ntt 0 6800
835+n = ulong sub get Ntd 3 get Ntd 1
836+for i ulong n
837+y = add get Ntd 1 long i
838+if fading
839+ntfrow y get Ntd 0 get Ntd 2
840+else
841+ntcrow y get Ntd 0 get Ntd 2
842+end
843+end
844+if and eq get Ntlens 2 0 eq get Ntrip 1 0
845+ret
846+end
847+ntblocks
848+end
849+note ntstarbox: the 2 x 2 pixel box of twinkle star i into Pa 0..3 (x y w h) (ck_night_star_box).
850+fn ntstarbox i ulong to void
851+put Pa 0 shr sub get Sktw mul i 8 8 4
852+put Pa 1 shr sub get Sktw add mul i 8 1 8 4
853+put Pa 2 2
854+put Pa 3 2
855+end
856+fn ntholes to ulong
857+ret get Nthol 0
858+end
859+note ntcount: the number of twinkle stars.
860+fn ntcount to ulong
861+ret get Sktwn 0
862+end
863+fn ntmeetd x long y long s long to bool
864+if ge x get Ntd 2
865+ret false
866+end
867+if ge y get Ntd 3
868+ret false
869+end
870+if le add x s get Ntd 0
871+ret false
872+end
873+if le add y s get Ntd 1
874+ret false
875+end
876+ret true
877+end
878+fn nttw1 i ulong to void
879+ntstarbox i
880+if not ntmeetd get Pa 0 get Pa 1 2
881+ret
882+end
883+if ne get Ntlens 2 0
884+if ntmeetl get Pa 0 get Pa 1 2
885+ret
886+end
887+end
888+b = mul i 8
889+per = ulong get Sktw add b 6
890+tw = rem add get Ntt 0 ulong get Sktw add b 7 per
891+tw = shr ulong add 16384 pksin div mul tw 65536 per 7
892+a = shr mul shr mul tw tw 8 120 8
893+tw = ntfaded shr get Sktw b 4 shr get Sktw add b 1 4 255
894+a = shr mul a tw 8
895+sktwink i a
896+end
897+note ntglpx: one galaxy pixel: Ntg 0 sweep, 1 map base, 2 shimmer, 3 voice, 4 tint.
898+fn ntglpx x long row long to void
899+p = add get Ntg 1 x
900+l = ulong get Skglit p
901+if eq l 0
902+ret
903+end
904+a = ulong sub 256 get Ntg 0
905+a = and add a ulong get Skgpha p 255
906+a = shr mul l ulong get Ntband a 8
907+a = shr mul a ulong get Ntg 2 8
908+a = add a shr mul shr mul l l 8 ulong get Ntg 3 9
909+if ne a 0
910+p = add row x
911+put Nfrm p uint pkadd ulong get Nfrm p ulong get Ntg 4 a
912+end
913+end
914+fn ntgrow g ulong y long x0 long x1 long to void
915+b = mul g 4
916+n = ulong sub y get Skgbox add b 1
917+n = mul n ulong get Skgbox add b 2
918+put Ntg 1 sub long add get Skgoff g n get Skgbox b
919+base = mul y get Lg 0
920+n = ulong sub x1 x0
921+for i ulong n
922+ntglpx add x0 long i base
923+end
924+end
925+fn ntgset g ulong shim ulong voice ulong to void
926+per = get Skgper g
927+put Ntg 0 long div mul rem get Ntt 0 per 256 per
928+put Ntg 2 long shim
929+put Ntg 3 long voice
930+put Ntg 4 long get Skgtint g
931+end
932+fn ntgal g ulong shim ulong voice ulong to void
933+b = mul g 4
934+if eq get Skgbox add b 2 0
935+ret
936+end
937+ntgset g shim voice
938+x0 = pkmax get Skgbox b get Ntd 0
939+y0 = pkmax get Skgbox add b 1 get Ntd 1
940+x1 = add get Skgbox b get Skgbox add b 2
941+x1 = pkmin x1 get Ntd 2
942+y1 = add get Skgbox add b 1 get Skgbox add b 3
943+y1 = pkmin y1 get Ntd 3
944+if or le x1 x0 le y1 y0
945+ret
946+end
947+for j ulong ulong sub y1 y0
948+ntgrow g add y0 long j x0 x1
949+end
950+end
951+note ntlights: twinkles and galaxy glow over the base inside (x y w h) ∩ clip (ck_night_lights).
952+fn ntlights x long y long w long h long shim ulong voice ulong to void
953+if not ntdrect x y w h
954+ret
955+end
956+for i ulong get Sktwn 0
957+nttw1 i
958+end
959+if and eq shim 0 eq voice 0
960+ret
961+end
962+for g ulong 6
963+ntgal g shim voice
964+end
965+end

aienux/allen/look-paint.om

new file mode 100644
@@ -0,0 +1,755 @@
1+note SPDX-License-Identifier: MIT
2+note Allen's look, part 1: the drawing kit. Handwritten Omega port of native/kernel/ui/paint.h and
3+note paint.c (aienux 4b24df65): integer sine, arctangent, exp(-x), log2, hash noise, light-weighted
4+note colour blending through the sky's transfer tables, and the glow, thread, rounded-rectangle and
5+note letter shapes. Every function gives the same integers as the C kit; tests/look-paint.om compares
6+note them value for value against the C harness. Needs font-data.om and font.om before it (afsqrt,
7+note afglyph) and pkinit once before any other call.
8+note Shared memory (declared here, used by every look-* module):
9+note Lg: 0 screen width, 1 height, 2 k (1/256 px per design px of a 1920x1080 design), 3 sky centre x,
10+note 4 sky centre y, 5..8 the clip rectangle x,y,w,h every shape is held inside (pkclip sets it),
11+note 9 the rounded rectangle's radius for pksdrrect, 10..15 PAINT scratch (unused so far).
12+note Nfrm: the frame being drawn, one packed RGB word (R<<16|G<<8|B) per pixel, rows Lg[0] apart.
13+note Nsky: the sky as it was made at startup, the same layout.
14+note Slin: ck_sky_lin, sRGB byte -> linear light Q15. Ssrgb: ck_sky_srgb16, light>>3 -> sRGB x16.
15+note Both are filled by pkinit from Plin/Psrgb, the exact values of sky_data.c.
16+note Pa: the argument block for calls with more than six values. pkthread reads Pa[0] = width in
17+note 16ths of a pixel, Pa[1] = a0, Pa[2] = a1 (its sixth value a01 is ignored; pass 0). pkletter's
18+note face is the font's own state (afinit before use). Ps is PAINT's private scratch.
19+note Signatures (same integers as the C): pksin/pkcos a (turns/65536) -> Q14; pkatan2 y x -> 0..65535;
20+note pkexpneg x -> exp(-x/256)*65536; pklog2q16 v -> log2(v)*65536; pkisqrt v; pkhash x y seed;
21+note pknoise x256 y256 seed; pkfbm x256 y256 seed octaves; pklenc light; pkscale c f; pkadd d c a;
22+note pkmix d c a; pksmooth t; pkeaseout t; pkprog now from upto; pkclip x y w h; pkglow cx cy r color a
23+note (16ths); pkthread x0 y0 x1 y1 color a01 (16ths, Pa as above); pksdrrect x y rx ry rw rh (Lg[9]);
24+note pkcover d16; pkletter pen y c color a plus -> pen after (pen in 1/256 px, plus true = additive).
25+const LOOKPX ulong 8294400
26+global Lg long 16
27+global Nfrm uint LOOKPX
28+global Nsky uint LOOKPX
29+global Slin ushort 256
30+global Ssrgb ushort 4096
31+global Pa long 8
32+global Psin long 4097
33+global Pexp ulong 4096
34+global Plog ulong 257
35+global Patan ulong 14
36+note Ps: 0 glow cx, 1 cy, 2 r2, 3 inv, 4 color, 5 a, 6 x0, 7 x1-1; 8..18 thread x0 y0 x1 y1 color a0 a1
37+note len grad radius steep yc, 27 a; 20..26 letter gx gy color a plus x0 x1; 28..31 pkfit x0 y0 x1 y1
38+global Ps long 32
39+global Pgc ulong 3
40+global Pgt ulong 514
41+text Plin "0 10 20 30 40 50 60 70 80 90 99 110 120 132 144 157 170 184 198 213 229 246 263 281 299 319 338 359 381 403 425 449 473 498 524 551 578 606 635 665 695 727 759 792 825 860 895 931 969 1006 1045 1085 1125 1167 1209 1252 1296 1341 1386 1433 1481 1529 1578 1629 1680 1732 1785 1839 1894 1950 2007 2065 2123 2183 2244 2306 2368 2432 2496 2562 2629 2696 2765 2834 2905 2977 3049 3123 3198 3273 3350 3428 3507 3587 3668 3750 3833 3917 4002 4089 4176 4264 4354 4444 4536 4629 4723 4818 4914 5011 5109 5209 5309 5411 5514 5618 5723 5829 5936 6045 6155 6265 6377 6490 6605 6720 6837 6954 7073 7193 7315 7437 7561 7686 7812 7939 8068 8197 8328 8460 8593 8728 8864 9001 9139 9278 9419 9561 9704 9848 9994 10141 10289 10438 10589 10741 10894 11048 11204 11361 11519 11679 11839 12001 12165 12329 12495 12663 12831 13001 13172 13344 13518 13693 13870 14047 14226 14407 14588 14771 14956 15141 15328 15517 15706 15897 16090 16284 16479 16675 16873 17072 17273 17474 17678 17882 18088 18296 18504 18715 18926 19139 19353 19569 19786 20005 20225 20446 20669 20893 21118 21345 21574 21803 22035 22267 22501 22737 22974 23212 23452 23693 23936 24180 24425 24672 24921 25171 25422 25675 25929 26185 26442 26701 26961 27223 27486 27750 28016 28284 28553 28823 29095 29369 29644 29920 30198 30478 30759 31041 31325 31611 31898 32186 32476 32768 "
42+text Psrgb "0 13 26 39 51 64 77 90 103 116 129 142 154 167 180 191 203 214 224 234 244 254 263 272 281 290 298 307 315 323 331 338 346 353 360 367 374 381 388 395 401 408 414 420 427 433 439 445 451 456 462 468 474 479 485 490 495 501 506 511 516 522 527 532 537 542 546 551 556 561 566 570 575 579 584 589 593 598 602 606 611 615 619 624 628 632 636 640 645 649 653 657 661 665 669 673 677 681 684 688 692 696 700 703 707 711 715 718 722 726 729 733 736 740 744 747 751 754 758 761 764 768 771 775 778 781 785 788 791 795 798 801 805 808 811 814 817 821 824 827 830 833 836 839 843 846 849 852 855 858 861 864 867 870 873 876 879 882 885 887 890 893 896 899 902 905 908 910 913 916 919 922 924 927 930 933 936 938 941 944 946 949 952 955 957 960 963 965 968 971 973 976 978 981 984 986 989 991 994 996 999 1002 1004 1007 1009 1012 1014 1017 1019 1022 1024 1027 1029 1032 1034 1036 1039 1041 1044 1046 1049 1051 1053 1056 1058 1061 1063 1065 1068 1070 1072 1075 1077 1079 1082 1084 1086 1089 1091 1093 1096 1098 1100 1102 1105 1107 1109 1111 1114 1116 1118 1120 1123 1125 1127 1129 1132 1134 1136 1138 1140 1143 1145 1147 1149 1151 1153 1156 1158 1160 1162 1164 1166 1168 1170 1173 1175 1177 1179 1181 1183 1185 1187 1189 1191 1194 1196 1198 1200 1202 1204 1206 1208 1210 1212 1214 1216 1218 1220 1222 1224 1226 1228 1230 1232 1234 1236 1238 1240 1242 1244 1246 1248 1250 1252 1254 1256 1258 1260 1262 1264 1266 1268 1269 1271 1273 1275 1277 1279 1281 1283 1285 1287 1289 1290 1292 1294 1296 1298 1300 1302 1304 1305 1307 1309 1311 1313 1315 1317 1318 1320 1322 1324 1326 1328 1329 1331 1333 1335 1337 1339 1340 1342 1344 1346 1348 1349 1351 1353 1355 1356 1358 1360 1362 1364 1365 1367 1369 1371 1372 1374 1376 1378 1379 1381 1383 1385 1386 1388 1390 1392 1393 1395 1397 1398 1400 1402 1404 1405 1407 1409 1410 1412 1414 1415 1417 1419 1420 1422 1424 1426 1427 1429 1431 1432 1434 1436 1437 1439 1441 1442 1444 1445 1447 1449 1450 1452 1454 1455 1457 1459 1460 1462 1463 1465 1467 1468 1470 1472 1473 1475 1476 1478 1480 1481 1483 1484 1486 1488 1489 1491 1492 1494 1496 1497 1499 1500 1502 1503 1505 1507 1508 1510 1511 1513 1514 1516 1517 1519 1521 1522 1524 1525 1527 1528 1530 1531 1533 1534 1536 1538 1539 1541 1542 1544 1545 1547 1548 1550 1551 1553 1554 1556 1557 1559 1560 1562 1563 1565 1566 1568 1569 1571 1572 1574 1575 1577 1578 1580 1581 1583 1584 1586 1587 1589 1590 1591 1593 1594 1596 1597 1599 1600 1602 1603 1605 1606 1607 1609 1610 1612 1613 1615 1616 1618 1619 1620 1622 1623 1625 1626 1628 1629 1630 1632 1633 1635 1636 1638 1639 1640 1642 1643 1645 1646 1647 1649 1650 1652 1653 1654 1656 1657 1659 1660 1661 1663 1664 1666 1667 1668 1670 1671 1672 1674 1675 1677 1678 1679 1681 1682 1683 1685 1686 1688 1689 1690 1692 1693 1694 1696 1697 1698 1700 1701 1702 1704 1705 1707 1708 1709 1711 1712 1713 1715 1716 1717 1719 1720 1721 1723 1724 1725 1727 1728 1729 1731 1732 1733 1734 1736 1737 1738 1740 1741 1742 1744 1745 1746 1748 1749 1750 1752 1753 1754 1755 1757 1758 1759 1761 1762 1763 1765 1766 1767 1768 1770 1771 1772 1774 1775 1776 1777 1779 1780 1781 1782 1784 1785 1786 1788 1789 1790 1791 1793 1794 1795 1796 1798 1799 1800 1801 1803 1804 1805 1806 1808 1809 1810 1811 1813 1814 1815 1816 1818 1819 1820 1821 1823 1824 1825 1826 1828 1829 1830 1831 1833 1834 1835 1836 1837 1839 1840 1841 1842 1844 1845 1846 1847 1848 1850 1851 1852 1853 1855 1856 1857 1858 1859 1861 1862 1863 1864 1865 1867 1868 1869 1870 1871 1873 1874 1875 1876 1877 1879 1880 1881 1882 1883 1885 1886 1887 1888 1889 1891 1892 1893 1894 1895 1896 1898 1899 1900 1901 1902 1904 1905 1906 1907 1908 1909 1911 1912 1913 1914 1915 1916 1918 1919 1920 1921 1922 1923 1924 1926 1927 1928 1929 1930 1931 1933 1934 1935 1936 1937 1938 1939 1941 1942 1943 1944 1945 1946 1947 1949 1950 1951 1952 1953 1954 1955 1957 1958 1959 1960 1961 1962 1963 1965 1966 1967 1968 1969 1970 1971 1972 1974 1975 1976 1977 1978 1979 1980 1981 1982 1984 1985 1986 1987 1988 1989 1990 1991 1992 1994 1995 1996 1997 1998 1999 2000 2001 2002 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2358 2359 2360 2361 2362 2363 2364 2365 2366 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2375 2376 2377 2378 2379 2380 2381 2382 2382 2383 2384 2385 2386 2387 2388 2389 2390 2390 2391 2392 2393 2394 2395 2396 2397 2397 2398 2399 2400 2401 2402 2403 2404 2404 2405 2406 2407 2408 2409 2410 2411 2411 2412 2413 2414 2415 2416 2417 2417 2418 2419 2420 2421 2422 2423 2424 2424 2425 2426 2427 2428 2429 2430 2430 2431 2432 2433 2434 2435 2436 2436 2437 2438 2439 2440 2441 2442 2442 2443 2444 2445 2446 2447 2448 2448 2449 2450 2451 2452 2453 2454 2454 2455 2456 2457 2458 2459 2460 2460 2461 2462 2463 2464 2465 2465 2466 2467 2468 2469 2470 2471 2471 2472 2473 2474 2475 2476 2476 2477 2478 2479 2480 2481 2481 2482 2483 2484 2485 2486 2486 2487 2488 2489 2490 2491 2492 2492 2493 2494 2495 2496 2497 2497 2498 2499 2500 2501 2501 2502 2503 2504 2505 2506 2506 2507 2508 2509 2510 2511 2511 2512 2513 2514 2515 2516 2516 2517 2518 2519 2520 2520 2521 2522 2523 2524 2525 2525 2526 2527 2528 2529 2530 2530 2531 2532 2533 2534 2534 2535 2536 2537 2538 2539 2539 2540 2541 2542 2543 2543 2544 2545 2546 2547 2547 2548 2549 2550 2551 2551 2552 2553 2554 2555 2556 2556 2557 2558 2559 2560 2560 2561 2562 2563 2564 2564 2565 2566 2567 2568 2568 2569 2570 2571 2572 2572 2573 2574 2575 2576 2576 2577 2578 2579 2580 2580 2581 2582 2583 2584 2584 2585 2586 2587 2588 2588 2589 2590 2591 2592 2592 2593 2594 2595 2596 2596 2597 2598 2599 2599 2600 2601 2602 2603 2603 2604 2605 2606 2607 2607 2608 2609 2610 2611 2611 2612 2613 2614 2614 2615 2616 2617 2618 2618 2619 2620 2621 2621 2622 2623 2624 2625 2625 2626 2627 2628 2629 2629 2630 2631 2632 2632 2633 2634 2635 2636 2636 2637 2638 2639 2639 2640 2641 2642 2642 2643 2644 2645 2646 2646 2647 2648 2649 2649 2650 2651 2652 2653 2653 2654 2655 2656 2656 2657 2658 2659 2659 2660 2661 2662 2662 2663 2664 2665 2666 2666 2667 2668 2669 2669 2670 2671 2672 2672 2673 2674 2675 2675 2676 2677 2678 2679 2679 2680 2681 2682 2682 2683 2684 2685 2685 2686 2687 2688 2688 2689 2690 2691 2691 2692 2693 2694 2694 2695 2696 2697 2697 2698 2699 2700 2700 2701 2702 2703 2703 2704 2705 2706 2706 2707 2708 2709 2709 2710 2711 2712 2712 2713 2714 2715 2715 2716 2717 2718 2718 2719 2720 2721 2721 2722 2723 2724 2724 2725 2726 2727 2727 2728 2729 2730 2730 2731 2732 2733 2733 2734 2735 2736 2736 2737 2738 2738 2739 2740 2741 2741 2742 2743 2744 2744 2745 2746 2747 2747 2748 2749 2750 2750 2751 2752 2752 2753 2754 2755 2755 2756 2757 2758 2758 2759 2760 2761 2761 2762 2763 2763 2764 2765 2766 2766 2767 2768 2769 2769 2770 2771 2771 2772 2773 2774 2774 2775 2776 2777 2777 2778 2779 2779 2780 2781 2782 2782 2783 2784 2785 2785 2786 2787 2787 2788 2789 2790 2790 2791 2792 2792 2793 2794 2795 2795 2796 2797 2797 2798 2799 2800 2800 2801 2802 2803 2803 2804 2805 2805 2806 2807 2808 2808 2809 2810 2810 2811 2812 2813 2813 2814 2815 2815 2816 2817 2818 2818 2819 2820 2820 2821 2822 2823 2823 2824 2825 2825 2826 2827 2827 2828 2829 2830 2830 2831 2832 2832 2833 2834 2835 2835 2836 2837 2837 2838 2839 2839 2840 2841 2842 2842 2843 2844 2844 2845 2846 2847 2847 2848 2849 2849 2850 2851 2851 2852 2853 2854 2854 2855 2856 2856 2857 2858 2858 2859 2860 2861 2861 2862 2863 2863 2864 2865 2865 2866 2867 2868 2868 2869 2870 2870 2871 2872 2872 2873 2874 2874 2875 2876 2877 2877 2878 2879 2879 2880 2881 2881 2882 2883 2883 2884 2885 2886 2886 2887 2888 2888 2889 2890 2890 2891 2892 2892 2893 2894 2894 2895 2896 2897 2897 2898 2899 2899 2900 2901 2901 2902 2903 2903 2904 2905 2905 2906 2907 2908 2908 2909 2910 2910 2911 2912 2912 2913 2914 2914 2915 2916 2916 2917 2918 2918 2919 2920 2920 2921 2922 2922 2923 2924 2925 2925 2926 2927 2927 2928 2929 2929 2930 2931 2931 2932 2933 2933 2934 2935 2935 2936 2937 2937 2938 2939 2939 2940 2941 2941 2942 2943 2943 2944 2945 2945 2946 2947 2947 2948 2949 2949 2950 2951 2952 2952 2953 2954 2954 2955 2956 2956 2957 2958 2958 2959 2960 2960 2961 2962 2962 2963 2964 2964 2965 2966 2966 2967 2968 2968 2969 2970 2970 2971 2972 2972 2973 2974 2974 2975 2976 2976 2977 2978 2978 2979 2979 2980 2981 2981 2982 2983 2983 2984 2985 2985 2986 2987 2987 2988 2989 2989 2990 2991 2991 2992 2993 2993 2994 2995 2995 2996 2997 2997 2998 2999 2999 3000 3001 3001 3002 3003 3003 3004 3005 3005 3006 3006 3007 3008 3008 3009 3010 3010 3011 3012 3012 3013 3014 3014 3015 3016 3016 3017 3018 3018 3019 3020 3020 3021 3021 3022 3023 3023 3024 3025 3025 3026 3027 3027 3028 3029 3029 3030 3031 3031 3032 3033 3033 3034 3034 3035 3036 3036 3037 3038 3038 3039 3040 3040 3041 3042 3042 3043 3043 3044 3045 3045 3046 3047 3047 3048 3049 3049 3050 3051 3051 3052 3052 3053 3054 3054 3055 3056 3056 3057 3058 3058 3059 3060 3060 3061 3061 3062 3063 3063 3064 3065 3065 3066 3067 3067 3068 3068 3069 3070 3070 3071 3072 3072 3073 3074 3074 3075 3075 3076 3077 3077 3078 3079 3079 3080 3081 3081 3082 3082 3083 3084 3084 3085 3086 3086 3087 3088 3088 3089 3089 3090 3091 3091 3092 3093 3093 3094 3094 3095 3096 3096 3097 3098 3098 3099 3099 3100 3101 3101 3102 3103 3103 3104 3105 3105 3106 3106 3107 3108 3108 3109 3110 3110 3111 3111 3112 3113 3113 3114 3115 3115 3116 3116 3117 3118 3118 3119 3120 3120 3121 3121 3122 3123 3123 3124 3125 3125 3126 3126 3127 3128 3128 3129 3129 3130 3131 3131 3132 3133 3133 3134 3134 3135 3136 3136 3137 3138 3138 3139 3139 3140 3141 3141 3142 3143 3143 3144 3144 3145 3146 3146 3147 3147 3148 3149 3149 3150 3151 3151 3152 3152 3153 3154 3154 3155 3155 3156 3157 3157 3158 3159 3159 3160 3160 3161 3162 3162 3163 3163 3164 3165 3165 3166 3166 3167 3168 3168 3169 3170 3170 3171 3171 3172 3173 3173 3174 3174 3175 3176 3176 3177 3177 3178 3179 3179 3180 3181 3181 3182 3182 3183 3184 3184 3185 3185 3186 3187 3187 3188 3188 3189 3190 3190 3191 3191 3192 3193 3193 3194 3194 3195 3196 3196 3197 3197 3198 3199 3199 3200 3200 3201 3202 3202 3203 3204 3204 3205 3205 3206 3207 3207 3208 3208 3209 3210 3210 3211 3211 3212 3213 3213 3214 3214 3215 3216 3216 3217 3217 3218 3219 3219 3220 3220 3221 3222 3222 3223 3223 3224 3224 3225 3226 3226 3227 3227 3228 3229 3229 3230 3230 3231 3232 3232 3233 3233 3234 3235 3235 3236 3236 3237 3238 3238 3239 3239 3240 3241 3241 3242 3242 3243 3244 3244 3245 3245 3246 3246 3247 3248 3248 3249 3249 3250 3251 3251 3252 3252 3253 3254 3254 3255 3255 3256 3257 3257 3258 3258 3259 3259 3260 3261 3261 3262 3262 3263 3264 3264 3265 3265 3266 3267 3267 3268 3268 3269 3269 3270 3271 3271 3272 3272 3273 3274 3274 3275 3275 3276 3277 3277 3278 3278 3279 3279 3280 3281 3281 3282 3282 3283 3284 3284 3285 3285 3286 3286 3287 3288 3288 3289 3289 3290 3291 3291 3292 3292 3293 3293 3294 3295 3295 3296 3296 3297 3297 3298 3299 3299 3300 3300 3301 3302 3302 3303 3303 3304 3304 3305 3306 3306 3307 3307 3308 3308 3309 3310 3310 3311 3311 3312 3313 3313 3314 3314 3315 3315 3316 3317 3317 3318 3318 3319 3319 3320 3321 3321 3322 3322 3323 3323 3324 3325 3325 3326 3326 3327 3327 3328 3329 3329 3330 3330 3331 3331 3332 3333 3333 3334 3334 3335 3335 3336 3337 3337 3338 3338 3339 3339 3340 3341 3341 3342 3342 3343 3343 3344 3345 3345 3346 3346 3347 3347 3348 3349 3349 3350 3350 3351 3351 3352 3353 3353 3354 3354 3355 3355 3356 3357 3357 3358 3358 3359 3359 3360 3360 3361 3362 3362 3363 3363 3364 3364 3365 3366 3366 3367 3367 3368 3368 3369 3370 3370 3371 3371 3372 3372 3373 3373 3374 3375 3375 3376 3376 3377 3377 3378 3379 3379 3380 3380 3381 3381 3382 3382 3383 3384 3384 3385 3385 3386 3386 3387 3387 3388 3389 3389 3390 3390 3391 3391 3392 3393 3393 3394 3394 3395 3395 3396 3396 3397 3398 3398 3399 3399 3400 3400 3401 3401 3402 3403 3403 3404 3404 3405 3405 3406 3406 3407 3408 3408 3409 3409 3410 3410 3411 3411 3412 3413 3413 3414 3414 3415 3415 3416 3416 3417 3418 3418 3419 3419 3420 3420 3421 3421 3422 3423 3423 3424 3424 3425 3425 3426 3426 3427 3428 3428 3429 3429 3430 3430 3431 3431 3432 3432 3433 3434 3434 3435 3435 3436 3436 3437 3437 3438 3439 3439 3440 3440 3441 3441 3442 3442 3443 3443 3444 3445 3445 3446 3446 3447 3447 3448 3448 3449 3449 3450 3451 3451 3452 3452 3453 3453 3454 3454 3455 3455 3456 3457 3457 3458 3458 3459 3459 3460 3460 3461 3461 3462 3463 3463 3464 3464 3465 3465 3466 3466 3467 3467 3468 3469 3469 3470 3470 3471 3471 3472 3472 3473 3473 3474 3474 3475 3476 3476 3477 3477 3478 3478 3479 3479 3480 3480 3481 3482 3482 3483 3483 3484 3484 3485 3485 3486 3486 3487 3487 3488 3489 3489 3490 3490 3491 3491 3492 3492 3493 3493 3494 3494 3495 3496 3496 3497 3497 3498 3498 3499 3499 3500 3500 3501 3501 3502 3503 3503 3504 3504 3505 3505 3506 3506 3507 3507 3508 3508 3509 3509 3510 3511 3511 3512 3512 3513 3513 3514 3514 3515 3515 3516 3516 3517 3517 3518 3519 3519 3520 3520 3521 3521 3522 3522 3523 3523 3524 3524 3525 3525 3526 3527 3527 3528 3528 3529 3529 3530 3530 3531 3531 3532 3532 3533 3533 3534 3534 3535 3536 3536 3537 3537 3538 3538 3539 3539 3540 3540 3541 3541 3542 3542 3543 3543 3544 3545 3545 3546 3546 3547 3547 3548 3548 3549 3549 3550 3550 3551 3551 3552 3552 3553 3553 3554 3555 3555 3556 3556 3557 3557 3558 3558 3559 3559 3560 3560 3561 3561 3562 3562 3563 3563 3564 3564 3565 3566 3566 3567 3567 3568 3568 3569 3569 3570 3570 3571 3571 3572 3572 3573 3573 3574 3574 3575 3575 3576 3576 3577 3578 3578 3579 3579 3580 3580 3581 3581 3582 3582 3583 3583 3584 3584 3585 3585 3586 3586 3587 3587 3588 3588 3589 3589 3590 3591 3591 3592 3592 3593 3593 3594 3594 3595 3595 3596 3596 3597 3597 3598 3598 3599 3599 3600 3600 3601 3601 3602 3602 3603 3603 3604 3604 3605 3606 3606 3607 3607 3608 3608 3609 3609 3610 3610 3611 3611 3612 3612 3613 3613 3614 3614 3615 3615 3616 3616 3617 3617 3618 3618 3619 3619 3620 3620 3621 3621 3622 3622 3623 3624 3624 3625 3625 3626 3626 3627 3627 3628 3628 3629 3629 3630 3630 3631 3631 3632 3632 3633 3633 3634 3634 3635 3635 3636 3636 3637 3637 3638 3638 3639 3639 3640 3640 3641 3641 3642 3642 3643 3643 3644 3644 3645 3645 3646 3646 3647 3647 3648 3649 3649 3650 3650 3651 3651 3652 3652 3653 3653 3654 3654 3655 3655 3656 3656 3657 3657 3658 3658 3659 3659 3660 3660 3661 3661 3662 3662 3663 3663 3664 3664 3665 3665 3666 3666 3667 3667 3668 3668 3669 3669 3670 3670 3671 3671 3672 3672 3673 3673 3674 3674 3675 3675 3676 3676 3677 3677 3678 3678 3679 3679 3680 3680 3681 3681 3682 3682 3683 3683 3684 3684 3685 3685 3686 3686 3687 3687 3688 3688 3689 3689 3690 3690 3691 3691 3692 3692 3693 3693 3694 3694 3695 3695 3696 3696 3697 3697 3698 3698 3699 3699 3700 3700 3701 3701 3702 3702 3703 3703 3704 3704 3705 3705 3706 3706 3707 3707 3708 3708 3709 3709 3710 3710 3711 3711 3712 3712 3713 3713 3714 3714 3715 3715 3716 3716 3717 3717 3718 3718 3719 3719 3720 3720 3721 3721 3722 3722 3723 3723 3724 3724 3725 3725 3726 3726 3727 3727 3728 3728 3729 3729 3730 3730 3731 3731 3732 3732 3733 3733 3734 3734 3735 3735 3735 3736 3736 3737 3737 3738 3738 3739 3739 3740 3740 3741 3741 3742 3742 3743 3743 3744 3744 3745 3745 3746 3746 3747 3747 3748 3748 3749 3749 3750 3750 3751 3751 3752 3752 3753 3753 3754 3754 3755 3755 3756 3756 3757 3757 3758 3758 3759 3759 3760 3760 3760 3761 3761 3762 3762 3763 3763 3764 3764 3765 3765 3766 3766 3767 3767 3768 3768 3769 3769 3770 3770 3771 3771 3772 3772 3773 3773 3774 3774 3775 3775 3776 3776 3777 3777 3778 3778 3778 3779 3779 3780 3780 3781 3781 3782 3782 3783 3783 3784 3784 3785 3785 3786 3786 3787 3787 3788 3788 3789 3789 3790 3790 3791 3791 3792 3792 3793 3793 3793 3794 3794 3795 3795 3796 3796 3797 3797 3798 3798 3799 3799 3800 3800 3801 3801 3802 3802 3803 3803 3804 3804 3805 3805 3806 3806 3806 3807 3807 3808 3808 3809 3809 3810 3810 3811 3811 3812 3812 3813 3813 3814 3814 3815 3815 3816 3816 3817 3817 3817 3818 3818 3819 3819 3820 3820 3821 3821 3822 3822 3823 3823 3824 3824 3825 3825 3826 3826 3827 3827 3828 3828 3828 3829 3829 3830 3830 3831 3831 3832 3832 3833 3833 3834 3834 3835 3835 3836 3836 3837 3837 3838 3838 3838 3839 3839 3840 3840 3841 3841 3842 3842 3843 3843 3844 3844 3845 3845 3846 3846 3847 3847 3847 3848 3848 3849 3849 3850 3850 3851 3851 3852 3852 3853 3853 3854 3854 3855 3855 3856 3856 3856 3857 3857 3858 3858 3859 3859 3860 3860 3861 3861 3862 3862 3863 3863 3864 3864 3864 3865 3865 3866 3866 3867 3867 3868 3868 3869 3869 3870 3870 3871 3871 3872 3872 3872 3873 3873 3874 3874 3875 3875 3876 3876 3877 3877 3878 3878 3879 3879 3879 3880 3880 3881 3881 3882 3882 3883 3883 3884 3884 3885 3885 3886 3886 3886 3887 3887 3888 3888 3889 3889 3890 3890 3891 3891 3892 3892 3893 3893 3893 3894 3894 3895 3895 3896 3896 3897 3897 3898 3898 3899 3899 3900 3900 3900 3901 3901 3902 3902 3903 3903 3904 3904 3905 3905 3906 3906 3907 3907 3907 3908 3908 3909 3909 3910 3910 3911 3911 3912 3912 3913 3913 3913 3914 3914 3915 3915 3916 3916 3917 3917 3918 3918 3919 3919 3919 3920 3920 3921 3921 3922 3922 3923 3923 3924 3924 3925 3925 3925 3926 3926 3927 3927 3928 3928 3929 3929 3930 3930 3931 3931 3931 3932 3932 3933 3933 3934 3934 3935 3935 3936 3936 3937 3937 3937 3938 3938 3939 3939 3940 3940 3941 3941 3942 3942 3942 3943 3943 3944 3944 3945 3945 3946 3946 3947 3947 3948 3948 3948 3949 3949 3950 3950 3951 3951 3952 3952 3953 3953 3953 3954 3954 3955 3955 3956 3956 3957 3957 3958 3958 3958 3959 3959 3960 3960 3961 3961 3962 3962 3963 3963 3963 3964 3964 3965 3965 3966 3966 3967 3967 3968 3968 3968 3969 3969 3970 3970 3971 3971 3972 3972 3973 3973 3973 3974 3974 3975 3975 3976 3976 3977 3977 3978 3978 3978 3979 3979 3980 3980 3981 3981 3982 3982 3983 3983 3983 3984 3984 3985 3985 3986 3986 3987 3987 3988 3988 3988 3989 3989 3990 3990 3991 3991 3992 3992 3992 3993 3993 3994 3994 3995 3995 3996 3996 3997 3997 3997 3998 3998 3999 3999 4000 4000 4001 4001 4001 4002 4002 4003 4003 4004 4004 4005 4005 4006 4006 4006 4007 4007 4008 4008 4009 4009 4010 4010 4010 4011 4011 4012 4012 4013 4013 4014 4014 4014 4015 4015 4016 4016 4017 4017 4018 4018 4019 4019 4019 4020 4020 4021 4021 4022 4022 4023 4023 4023 4024 4024 4025 4025 4026 4026 4027 4027 4027 4028 4028 4029 4029 4030 4030 4031 4031 4031 4032 4032 4033 4033 4034 4034 4035 4035 4035 4036 4036 4037 4037 4038 4038 4039 4039 4039 4040 4040 4041 4041 4042 4042 4043 4043 4043 4044 4044 4045 4045 4046 4046 4047 4047 4047 4048 4048 4049 4049 4050 4050 4051 4051 4051 4052 4052 4053 4053 4054 4054 4054 4055 4055 4056 4056 4057 4057 4058 4058 4058 4059 4059 4060 4060 4061 4061 4062 4062 4062 4063 4063 4064 4064 4065 4065 4066 4066 4066 4067 4067 4068 4068 4069 4069 4069 4070 4070 4071 4071 4072 4072 4073 4073 4073 4074 4074 4075 4075 4076 4076 4076 4077 4077 4078 4078 4079 4079 4080 4080 "
43+fn pkmin a long b long to long
44+if lt a b
45+ret a
46+end
47+ret b
48+end
49+fn pkmax a long b long to long
50+if gt a b
51+ret a
52+end
53+ret b
54+end
55+fn pkabs a long to long
56+if lt a 0
57+ret neg a
58+end
59+ret a
60+end
61+fn pkclamp v long lo long hi long to long
62+if lt v lo
63+ret lo
64+end
65+if gt v hi
66+ret hi
67+end
68+ret v
69+end
70+fn pkinitsin to void
71+note sine: a rotation by a 4096th of a turn, applied over and over (Q30)
72+c = long 1073741824
73+s = long 0
74+for k ulong 1025
75+v = shr add s 32768 16
76+if eq k 1024
77+v = 16384
78+end
79+put Psin k v
80+put Psin sub 2048 k v
81+put Psin and add 2048 k 4095 neg v
82+put Psin and sub 4096 k 4095 neg v
83+nc = shr sub mul c 1073740561 mul s 1647099 30
84+ns = shr add mul s 1073740561 mul c 1647099 30
85+c = nc
86+s = ns
87+end
88+put Psin 4096 get Psin 0
89+end
90+fn pkinitexp to void
91+note exp(-k/256): one factor of exp(-1/256) (Q30) per step
92+e = ulong 1073741824
93+for k ulong 4096
94+put Pexp k shr add e 8192 14
95+e = shr mul e 1069555701 30
96+end
97+end
98+fn pkinitlog to void
99+note log2(1 + k/256): square the value 16 times, taking a bit each time it passes 2
100+for k ulong 257
101+if eq k 256
102+put Plog k 65536
103+else
104+y = shl add ulong 256 k 8
105+r = ulong 0
106+for i ulong 16
107+b = sub ulong 15 i
108+y = shr mul y y 16
109+if ge y 131072
110+y = shr y 1
111+r = or r shl ulong 1 b
112+end
113+end
114+put Plog k r
115+end
116+end
117+end
118+fn pkinitatan to void
119+put Patan 0 8192
120+put Patan 1 4836
121+put Patan 2 2555
122+put Patan 3 1297
123+put Patan 4 651
124+put Patan 5 326
125+put Patan 6 163
126+put Patan 7 81
127+put Patan 8 41
128+put Patan 9 20
129+put Patan 10 10
130+put Patan 11 5
131+put Patan 12 3
132+put Patan 13 1
133+end
134+fn pkinitlin to void
135+v = ulong 0
136+slot = ulong 0
137+for i ulong len Plin
138+c = get Plin i
139+if eq c 32
140+put Slin slot ushort v
141+slot = add slot 1
142+v = 0
143+else
144+v = add mul v 10 sub ulong c 48
145+end
146+end
147+end
148+fn pkinitsrgb to void
149+v = ulong 0
150+slot = ulong 0
151+for i ulong len Psrgb
152+c = get Psrgb i
153+if eq c 32
154+put Ssrgb slot ushort v
155+slot = add slot 1
156+v = 0
157+else
158+v = add mul v 10 sub ulong c 48
159+end
160+end
161+end
162+fn pkinit to void
163+for i ulong 3
164+put Pgc i 0
165+end
166+for i ulong 514
167+put Pgt i 0
168+end
169+pkinitsin
170+pkinitexp
171+pkinitlog
172+pkinitatan
173+pkinitlin
174+pkinitsrgb
175+end
176+fn pksin a ulong to long
177+a = and a 65535
178+i = shr a 4
179+f = long and a 15
180+s0 = get Psin i
181+ret add s0 shr mul sub get Psin add i 1 s0 f 4
182+end
183+fn pkcos a ulong to long
184+ret pksin add a 16384
185+end
186+fn pkatan2 y long x long to ulong
187+if and eq x 0 eq y 0
188+ret 0
189+end
190+xx = x
191+yy = y
192+ang = ulong 0
193+if lt xx 0
194+xx = neg xx
195+yy = neg yy
196+ang = 32768
197+end
198+m = pkmax xx pkabs yy
199+while lt m 1048576
200+xx = mul xx 2
201+yy = mul yy 2
202+m = mul m 2
203+end
204+while ge m 4194304
205+xx = shr xx 1
206+yy = shr yy 1
207+m = shr m 1
208+end
209+z = long 0
210+for i ulong 14
211+st = long get Patan i
212+nx = xx
213+if gt yy 0
214+nx = add xx shr yy i
215+yy = sub yy shr xx i
216+z = add z st
217+else
218+nx = sub xx shr yy i
219+yy = add yy shr xx i
220+z = sub z st
221+end
222+xx = nx
223+end
224+ret and add ang bitcast ulong z 65535
225+end
226+fn pkexpneg x ulong to ulong
227+if lt x 4096
228+ret get Pexp x
229+end
230+ret 0
231+end
232+fn pklog2q16 v ulong to ulong
233+if eq v 0
234+ret 0
235+end
236+n = ulong 0
237+t = v
238+while ge t 2 bound 64
239+t = shr t 1
240+n = add n 1
241+end
242+m = v
243+if ge n 16
244+m = shr v sub n 16
245+else
246+m = shl v sub 16 n
247+end
248+k = and shr m 8 255
249+f = and m 255
250+lk = get Plog k
251+ret add add mul n 65536 lk shr mul sub get Plog add k 1 lk f 8
252+end
253+fn pkisqrt v ulong to ulong
254+ret afsqrt v
255+end
256+fn pkbits32 v long to ulong
257+ret and bitcast ulong v 4294967295
258+end
259+fn pkhash x long y long seed ulong to ulong
260+m = ulong 4294967295
261+a = and mul pkbits32 x 2376512323 m
262+b = and mul pkbits32 y 3625334849 m
263+c = and mul and seed m 3407524639 m
264+h = xor xor a b c
265+h = xor h shr h 13
266+h = and mul h 1540483477 m
267+h = xor h shr h 15
268+h = and mul h 668265261 m
269+h = xor h shr h 16
270+ret h
271+end
272+fn pksmooth t long to ulong
273+t = pkclamp t 0 256
274+ret ulong shr mul mul t t sub 768 mul 2 t 16
275+end
276+fn pkeaseout t long to ulong
277+u = sub 256 pkclamp t 0 256
278+ret sub ulong 256 ulong shr mul mul u u u 16
279+end
280+fn pkprog now ulong from ulong upto ulong to long
281+if le now from
282+ret 0
283+end
284+if ge now upto
285+ret 256
286+end
287+ret long div mul sub now from 256 sub upto from
288+end
289+fn pknrow ix long iy long seed ulong fx ulong to ulong
290+a = mul shr pkhash ix iy seed 16 sub 256 fx
291+ret add a mul shr pkhash add ix 1 iy seed 16 fx
292+end
293+fn pknoise x long y long seed ulong to ulong
294+fx = pksmooth long and pkbits32 x 255
295+fy = pksmooth long and pkbits32 y 255
296+ix = shr x 8
297+iy = shr y 8
298+a = pknrow ix iy seed fx
299+b = pknrow ix add iy 1 seed fx
300+ret shr add mul a sub 256 fy mul b fy 16
301+end
302+fn pkfbm x long y long seed ulong octaves ulong to ulong
303+sum = ulong 0
304+total = ulong 0
305+for o ulong octaves
306+w = shl ulong 1 sub sub octaves 1 o
307+sd = and add seed mul o 7919 4294967295
308+sum = add sum mul pknoise shl x o shl y o sd w
309+total = add total w
310+end
311+ret div sum total
312+end
313+fn pklenc light ulong to ulong
314+i = shr light 3
315+if ge light 32767
316+i = 4095
317+end
318+ret shr add ulong get Ssrgb i 8 4
319+end
320+fn pkscale c ulong f ulong to ulong
321+if eq f 0
322+ret 0
323+end
324+if ge f 256
325+ret c
326+end
327+out = ulong 0
328+s = ulong 16
329+for k ulong 3
330+x = and shr c s 255
331+x = pklenc shr mul ulong get Slin x f 8
332+out = or out shl x s
333+s = sub s 8
334+end
335+ret out
336+end
337+fn pkadd d ulong c ulong a ulong to ulong
338+if or eq a 0 eq c 0
339+ret d
340+end
341+if and eq d 0 eq a 256
342+ret c
343+end
344+out = ulong 0
345+s = ulong 16
346+for k ulong 3
347+x = and shr d s 255
348+y = and shr c s 255
349+v = shr mul ulong get Slin y a 8
350+if ne v 0
351+v = add ulong get Slin x v
352+i = shr v 3
353+if ge v 32767
354+i = 4095
355+end
356+x = shr add ulong get Ssrgb i 8 4
357+end
358+out = or out shl x s
359+s = sub s 8
360+end
361+ret out
362+end
363+fn pkmix d ulong c ulong a ulong to ulong
364+if or eq a 0 eq d c
365+ret d
366+end
367+if ge a 256
368+ret c
369+end
370+out = ulong 0
371+s = ulong 16
372+for k ulong 3
373+x = and shr d s 255
374+y = and shr c s 255
375+if ne x y
376+v = mul ulong get Slin x sub 256 a
377+v = shr add v mul ulong get Slin y a 8
378+i = shr v 3
379+if ge v 32767
380+i = 4095
381+end
382+x = shr add ulong get Ssrgb i 8 4
383+end
384+out = or out shl x s
385+s = sub s 8
386+end
387+ret out
388+end
389+fn pkcover d16 long to ulong
390+v = sub 8 d16
391+if le v 0
392+ret 0
393+end
394+if ge v 16
395+ret 256
396+end
397+ret ulong mul v 16
398+end
399+fn pkclip x long y long w long h long to void
400+x0 = pkmax x 0
401+y0 = pkmax y 0
402+x1 = pkmin add x w get Lg 0
403+y1 = pkmin add y h get Lg 1
404+put Lg 5 x0
405+put Lg 6 y0
406+put Lg 7 pkmax sub x1 x0 0
407+put Lg 8 pkmax sub y1 y0 0
408+end
409+fn pkfit x long y long w long h long to bool
410+note Ps[28..31] = the part of (x,y,w,h) inside the clip and the screen, as x0 y0 x1 y1; false when empty
411+x0 = pkmax x pkmax get Lg 5 0
412+y0 = pkmax y pkmax get Lg 6 0
413+x1 = add get Lg 5 get Lg 7
414+x1 = pkmin x1 get Lg 0
415+x1 = pkmin add x w x1
416+y1 = add get Lg 6 get Lg 8
417+y1 = pkmin y1 get Lg 1
418+y1 = pkmin add y h y1
419+put Ps 28 x0
420+put Ps 29 y0
421+put Ps 30 x1
422+put Ps 31 y1
423+if or le x1 x0 le y1 y0
424+ret false
425+end
426+ret true
427+end
428+fn pkmeets x long y long w long h long to bool
429+x0 = pkmax x get Lg 5
430+y0 = pkmax y get Lg 6
431+x1 = pkmin add x w add get Lg 5 get Lg 7
432+y1 = pkmin add y h add get Lg 6 get Lg 8
433+if or le x1 x0 le y1 y0
434+ret false
435+end
436+ret true
437+end
438+fn pkplot x long y long color ulong a ulong to void
439+if eq a 0
440+ret
441+end
442+lx = get Lg 5
443+ly = get Lg 6
444+if or lt x lx lt y ly
445+ret
446+end
447+if ge x add lx get Lg 7
448+ret
449+end
450+if ge y add ly get Lg 8
451+ret
452+end
453+if or lt x 0 lt y 0
454+ret
455+end
456+if ge x get Lg 0
457+ret
458+end
459+if ge y get Lg 1
460+ret
461+end
462+i = ulong add mul y get Lg 0 x
463+put Nfrm i uint pkadd ulong get Nfrm i color a
464+end
465+fn pkblend i ulong color ulong w ulong to void
466+note frame pixel i gets color's light times w/256 added (no clip test: callers fit first)
467+put Nfrm i uint pkadd ulong get Nfrm i color w
468+end
469+fn pkglowrow xa long xb long to void
470+note Ps: 0 cx, 2 r2, 3 inv, 4 color, 5 a, 10 y * width, 11 dy*dy
471+for i ulong ulong add sub xb xa 1
472+x = add xa long i
473+dx = add mul x 16 8
474+dx = sub dx get Ps 0
475+dx = add mul dx dx get Ps 11
476+if lt dx get Ps 2
477+f = shr mul dx get Ps 3 32
478+f = sub 256 f
479+f = shr mul shr mul f f 8 f 8
480+f = shr mul f get Ps 5 8
481+x = add get Ps 10 x
482+if eq get Nfrm x 0
483+f = add f long get Pgc 2
484+put Nfrm x uint get Pgt ulong f
485+else
486+dx = get Ps 4
487+pkblend ulong x ulong dx ulong f
488+end
489+end
490+end
491+end
492+note pkglowtab: the glow's colour over one black for every weight, kept for the last two
493+note colours (two alternate at the merger): most of the sky is one black, so the row's add
494+note becomes a table read; the bytes are pkadd's. Pgc: colour of table 0, of table 1, current.
495+fn pkglowtab color ulong to void
496+if eq get Pgc 0 color
497+put Pgc 2 0
498+ret
499+end
500+if eq get Pgc 1 color
501+put Pgc 2 257
502+ret
503+end
504+k = ulong 257
505+if eq get Pgc 2 257
506+k = 0
507+end
508+put Pgc 2 k
509+put Pgc div k 257 color
510+for i ulong 257
511+put Pgt add k i pkadd 0 color i
512+end
513+end
514+fn pkglowy y long to void
515+dy = add mul y 16 8
516+dy = sub dy get Ps 1
517+dy = mul dy dy
518+if lt dy get Ps 2
519+put Ps 11 dy
520+put Ps 10 mul y get Lg 0
521+dy = sub get Ps 2 dy
522+half = long pkisqrt ulong dy
523+xa = sub get Ps 0 half
524+xa = pkmax get Ps 6 shr xa 4
525+xb = add get Ps 0 half
526+xb = pkmin get Ps 7 shr xb 4
527+if le xa xb
528+pkglowrow xa xb
529+end
530+end
531+end
532+fn pkglow cx long cy long r long color ulong a ulong to void
533+if or le r 0 eq a 0
534+ret
535+end
536+x0 = shr sub cx r 4
537+y0 = shr sub cy r 4
538+if not pkfit x0 y0 add sub shr add cx r 4 x0 1 add sub shr add cy r 4 y0 1
539+ret
540+end
541+put Ps 0 cx
542+put Ps 1 cy
543+put Ps 2 mul r r
544+put Ps 3 div 1099511627776 mul r r
545+put Ps 4 long color
546+put Ps 5 long a
547+put Ps 6 get Ps 28
548+put Ps 7 sub get Ps 30 1
549+pkglowtab color
550+y0 = get Ps 29
551+for j ulong ulong sub get Ps 31 y0
552+pkglowy add y0 long j
553+end
554+end
555+fn pkthreadpx xc long yy long to void
556+note Ps: 12 color, 17 radius, 18 steep, 19 yc (16ths), 27 a
557+d = add mul yy 16 8
558+d = sub d get Ps 19
559+d = sub pkabs d get Ps 17
560+cov = pkcover d
561+cov = shr mul ulong get Ps 27 cov 8
562+color = ulong get Ps 12
563+if eq get Ps 18 1
564+pkplot yy xc color cov
565+else
566+pkplot xc yy color cov
567+end
568+end
569+fn pkthreadcol xc long to void
570+note one column (row when steep) at major coordinate xc; Ps: 8 x0, 9 y0, 13 a0, 14 a1, 15 len, 16 grad
571+along = add mul xc 16 8
572+along = sub along get Ps 8
573+yc = shr mul along get Ps 16 16
574+yc = add yc get Ps 9
575+put Ps 19 yc
576+a = sub get Ps 14 get Ps 13
577+a = div mul a along get Ps 15
578+put Ps 27 add a get Ps 13
579+ya = sub yc get Ps 17
580+ya = shr sub ya 8 4
581+yb = add yc get Ps 17
582+yb = shr add yb 8 4
583+for j ulong ulong add sub yb ya 1
584+pkthreadpx xc add ya long j
585+end
586+end
587+fn pkthreadgo to void
588+x0 = get Ps 8
589+x1 = get Ps 10
590+ln = sub x1 x0
591+if lt ln 1
592+ln = 1
593+end
594+put Ps 15 ln
595+grad = div mul sub get Ps 11 get Ps 9 65536 ln
596+put Ps 16 grad
597+note slant: the native-scaled width projected onto the minor axis (256 = flat)
598+grad = long shr pkisqrt ulong add 4294967296 mul grad grad 8
599+put Ps 17 shr mul get Pa 0 grad 9
600+first = shr add x0 7 4
601+last = shr sub x1 8 4
602+x0 = get Lg 5
603+x1 = get Lg 7
604+if eq get Ps 18 1
605+x0 = get Lg 6
606+x1 = get Lg 8
607+end
608+first = pkmax first x0
609+last = pkmin last sub add x0 x1 1
610+if gt first last
611+ret
612+end
613+for i ulong ulong add sub last first 1
614+pkthreadcol add first long i
615+end
616+end
617+fn pkthreadbox x0 long y0 long x1 long y1 long pad long to bool
618+bx = sub shr pkmin x0 x1 4 pad
619+by = sub shr pkmin y0 y1 4 pad
620+bw = add add sub shr pkmax x0 x1 4 bx pad 1
621+bh = add add sub shr pkmax y0 y1 4 by pad 1
622+ret pkmeets bx by bw bh
623+end
624+fn pkthread x0 long y0 long x1 long y1 long color ulong a01 ulong to void
625+note width, a0 and a1 ride in Pa[0..2] (Omega takes at most six values); a01 is ignored
626+w = get Pa 0
627+if le w 0
628+ret
629+end
630+if and eq get Pa 1 0 eq get Pa 2 0
631+ret
632+end
633+if not pkthreadbox x0 y0 x1 y1 add shr w 4 1
634+ret
635+end
636+put Ps 18 0
637+if gt pkabs sub y1 y0 pkabs sub x1 x0
638+put Ps 18 1
639+t = x0
640+x0 = y0
641+y0 = t
642+t = x1
643+x1 = y1
644+y1 = t
645+end
646+put Ps 13 get Pa 1
647+put Ps 14 get Pa 2
648+if gt x0 x1
649+t = x0
650+x0 = x1
651+x1 = t
652+t = y0
653+y0 = y1
654+y1 = t
655+put Ps 13 get Pa 2
656+put Ps 14 get Pa 1
657+end
658+put Ps 8 x0
659+put Ps 9 y0
660+put Ps 10 x1
661+put Ps 11 y1
662+put Ps 12 long color
663+pkthreadgo
664+end
665+fn pksdrrect x long y long rx long ry long rw long rh long to long
666+note The rounded rectangle's radius rides in Lg[9] (Omega takes at most six values).
667+rad = mul get Lg 9 16
668+x = add mul x 16 8
669+x = sub x mul rx 16
670+x = sub x mul rw 8
671+rw = sub mul rw 8 rad
672+x = sub pkabs x rw
673+y = add mul y 16 8
674+y = sub y mul ry 16
675+y = sub y mul rh 8
676+rh = sub mul rh 8 rad
677+y = sub pkabs y rh
678+out = pkmax x y
679+if and gt x 0 gt y 0
680+x = add mul x x mul y y
681+out = long pkisqrt ulong x
682+end
683+ret sub out rad
684+end
685+fn pkadvance c uchar to ulong
686+note the advance of c, 1/256 px: the number after 'w' at the start of its glyph, times the scale
687+if not afpick c
688+ret 0
689+end
690+put Afpos 0 add get Afpos 0 1
691+ret mul ulong afnum get Af 0
692+end
693+fn pkletterpx xx long to void
694+note Ps: 10 alpha row offset (row*w - gx), 11 y * width, 22 color, 23 a, 24 plus
695+cov = ulong get Alpha ulong add xx get Ps 10
696+if ne cov 0
697+cov = add cov shr cov 7
698+cov = shr mul cov ulong get Ps 23 8
699+i = ulong add xx get Ps 11
700+color = ulong get Ps 22
701+if eq get Ps 24 1
702+put Nfrm i uint pkadd ulong get Nfrm i color cov
703+else
704+put Nfrm i uint pkmix ulong get Nfrm i color cov
705+end
706+end
707+end
708+fn pkletterrow yy long to void
709+m = sub yy get Ps 21
710+m = mul m long get Af 3
711+put Ps 10 sub m get Ps 20
712+put Ps 11 mul yy get Lg 0
713+x0 = get Ps 25
714+n = ulong sub get Ps 26 x0
715+for i ulong n
716+pkletterpx add x0 long i
717+end
718+end
719+fn pkletterrows to void
720+note every row of the fitted glyph box Ps[28..31]
721+put Ps 25 get Ps 28
722+put Ps 26 get Ps 30
723+y0 = get Ps 29
724+n = ulong sub get Ps 31 y0
725+for j ulong n
726+pkletterrow add y0 long j
727+end
728+end
729+fn pkletter pen ulong y long c uchar color ulong a ulong plus bool to ulong
730+note ck_letter: the glyph c of the face afinit made, its pen at pen (1/256 px) on baseline y, mixed in
731+note with weight a (added light when plus); returns the pen after it
732+if eq a 0
733+ret add pen pkadvance c
734+end
735+if not afglyph c
736+ret add pen pkadvance c
737+end
738+if eq get Af 2 0
739+ret add pen get Af 5
740+end
741+gx = add long div add pen 128 256 get Ab 0
742+gy = add y get Ab 1
743+if pkfit gx gy long get Af 3 long get Af 4
744+put Ps 20 gx
745+put Ps 21 gy
746+put Ps 22 long color
747+put Ps 23 long a
748+put Ps 24 0
749+if plus
750+put Ps 24 1
751+end
752+pkletterrows
753+end
754+ret add pen get Af 5
755+end

aienux/allen/look-show.om

new file mode 100644
@@ -0,0 +1,592 @@
1+note SPDX-License-Identifier: MIT
2+note Allen's look, the show: what the firmware loop draws each frame and where. Native resolution
3+note (Lg[0] x Lg[1], the GOP mode), the frame Nfrm (look-paint.om) composed in allen_ui.c's order:
4+note night base, lights, the merger flash, Allen's being, his words and the bar; in repository mode
5+note the repository screen (repository-screen.om, drawn through surface.om at native scale) on top.
6+note Only rectangles that changed are composed; their rows are blitted from two persistent BGRA
7+note halves (Efa rows 0..hh-1, Efb rows hh..h-1; each at most 16 MiB, the compiler's array limit).
8+note Sh: 0 ms at start, 1 last t, 2 rows per half (hh), 3 full redraw pending, 4 frames drawn,
9+note 5 repository screen dirty, 6 last full-screen compose ms, 7 fade strip, 8 the request is
10+note with the Spark (thinking), 9 the fade's last full pass is done, 10 the ripple radius last
11+note drawn, 11 now (ms), 12 the ripple was on screen last frame, 13 pixels composed this frame,
12+note 14 rectangles composed this frame, 15 this frame redrew the whole screen (look-stat.om).
13+global Sh long 16
14+global Efa uchar 16777216
15+global Efb uchar 16777216
16+global Shrow uchar 2176
17+global Shd long 1280
18+global Shdn ulong 1
19+global Shr long 4
20+global Shl long 10
21+global Shb long 20
22+global Shbn ulong 1
23+const SHRECTS ulong 320
24+const SHBORN ulong 12300
25+const SHFADE ulong 6800
26+const SHMERGE ulong 12000
27+const SHGONE ulong 15600
28+const SHCOARSE ulong 0
29+text Shnet "Spark is not connected yet. Your message is still here."
30+fn shfits w ulong h ulong to bool
31+if or lt w 640 lt h 400
32+ret false
33+end
34+if or gt w 3840 gt h 2176
35+ret false
36+end
37+hh = div add h 1 2
38+ret le mul mul hh w 4 len Efa
39+end
40+fn shclipr x long y long w long h long to bool
41+note Shr becomes (x,y,w,h) held inside the screen; false when nothing is left.
42+x1 = add x w
43+y1 = add y h
44+if lt x 0
45+x = 0
46+end
47+if lt y 0
48+y = 0
49+end
50+if gt x1 get Lg 0
51+x1 = get Lg 0
52+end
53+if gt y1 get Lg 1
54+y1 = get Lg 1
55+end
56+put Shr 0 x
57+put Shr 1 y
58+put Shr 2 sub x1 x
59+put Shr 3 sub y1 y
60+if or le sub x1 x 0 le sub y1 y 0
61+ret false
62+end
63+ret true
64+end
65+fn shmark x long y long w long h long to void
66+note Remember a rectangle to compose this frame. Past the list's room, the whole screen is marked.
67+if not shclipr x y w h
68+ret
69+end
70+n = get Shdn 0
71+if ge n SHRECTS
72+put Sh 3 1
73+ret
74+end
75+at = mul n 4
76+put Shd at get Shr 0
77+put Shd add at 1 get Shr 1
78+put Shd add at 2 get Shr 2
79+put Shd add at 3 get Shr 3
80+put Shdn 0 add n 1
81+end
82+fn shmarkall to void
83+put Sh 3 1
84+end
85+fn shrowa i ulong at ulong n ulong to void
86+note n pixels from Nfrm[i..] as BGRA into Efa[at..] (rows of the upper half).
87+for k ulong n
88+c = get Nfrm add i k
89+put Efa at uchar and c 255
90+put Efa add at 1 uchar and shr c 8 255
91+put Efa add at 2 uchar and shr c 16 255
92+put Efa add at 3 0
93+at = add at 4
94+end
95+end
96+fn shrowb i ulong at ulong n ulong to void
97+note The same into Efb (rows of the lower half).
98+for k ulong n
99+c = get Nfrm add i k
100+put Efb at uchar and c 255
101+put Efb add at 1 uchar and shr c 8 255
102+put Efb add at 2 uchar and shr c 16 255
103+put Efb add at 3 0
104+at = add at 4
105+end
106+end
107+fn shrow y ulong x0 ulong n ulong to void
108+note One row's pixels x0..x0+n-1 from Nfrm into the BGRA half that holds row y.
109+w = ulong get Lg 0
110+hh = ulong get Sh 2
111+i = add mul y w x0
112+if lt y hh
113+shrowa i mul i 4 n
114+else
115+shrowb i mul add mul sub y hh w x0 4 n
116+end
117+put Shrow y 1
118+end
119+fn shconvert x long y long w long h long to void
120+note Nfrm -> BGRA for the rectangle, and its rows are remembered for the blit.
121+for r ulong ulong h
122+shrow add ulong y r ulong x ulong w
123+end
124+end
125+fn shblit y0 ulong rows ulong to bool
126+note Rows y0..y0+rows-1 (whole width) to the screen from the half that holds them; a run that
127+note crosses the halves is sent as two.
128+w = ulong get Lg 0
129+hh = ulong get Sh 2
130+if and lt y0 hh gt add y0 rows hh
131+if not shblit y0 sub hh y0
132+ret false
133+end
134+ret shblit hh sub add y0 rows hh
135+end
136+arg = or or w shl rows 32 shl y0 48
137+n = mul mul w rows 4
138+put Stw 10 add get Stw 10 n
139+st = ulong 0
140+if lt y0 hh
141+st = efi 3 arg Efa mul mul y0 w 4 n
142+else
143+st = efi 3 arg Efb mul mul sub y0 hh w 4 n
144+end
145+ret eq st 0
146+end
147+fn shflush to bool
148+note Blit every run of rows marked by shrow, then clear the marks.
149+h = ulong get Lg 1
150+y = ulong 0
151+ok = true
152+while lt y h bound 2176
153+if eq get Shrow y 0
154+y = add y 1
155+else
156+n = ulong 0
157+while and lt add y n h ne get Shrow add y n 0 bound 2176
158+put Shrow add y n 0
159+n = add n 1
160+end
161+if not shblit y n
162+ok = false
163+end
164+y = add y n
165+end
166+end
167+ret ok
168+end
169+fn shrepo to void
170+note The repository screen, through surface.om at native scale, over the composed sky.
171+if ne get Dmo 0 1
172+ret
173+end
174+ok = ghrender
175+end
176+fn shcompose x long y long w long h long to void
177+note allen_ui.c compose: night base, lights, flash, the being, words and bar.
178+pkclip x y w h
179+ntbase x y w h
180+ntlights x y w h 0 0
181+hmflash x y w h
182+mddraw x y w h
183+hmtext x y w h
184+end
185+fn shfull to void
186+note The whole screen, then the repository screen if it is up, then BGRA.
187+w = get Lg 0
188+h = get Lg 1
189+shcompose 0 0 w h
190+shrepo
191+shconvert 0 0 w h
192+put Sh 13 mul w h
193+put Sh 14 1
194+put Sh 15 1
195+put Shdn 0 0
196+put Sh 3 0
197+end
198+fn shrects to void
199+note Every marked rectangle: compose and convert. Rectangles may overlap; drawing twice is harmless
200+note because every layer is a pure function of position and time.
201+n = get Shdn 0
202+px = long 0
203+for i ulong n
204+at = mul i 4
205+x = get Shd at
206+y = get Shd add at 1
207+w = get Shd add at 2
208+h = get Shd add at 3
209+shcompose x y w h
210+shconvert x y w h
211+px = add px mul w h
212+end
213+put Sh 13 px
214+put Sh 14 long n
215+put Sh 15 0
216+put Shdn 0 0
217+end
218+fn shtwinkles to void
219+note The twinkling stars' boxes (ck_night_star_box) as in allen_ui.c: every star, every frame.
220+n = ntcount
221+for i ulong n
222+ntstarbox i
223+shmark get Pa 0 get Pa 1 get Pa 2 get Pa 3
224+end
225+end
226+fn shstrip to void
227+note The eyes adjust over 6.8 s in slow patches: the screen is composed a sixth at a time, so a
228+note frame stays cheap and every part of the sky is refreshed about twice a second.
229+h = get Lg 1
230+k = rem get Sh 7 6
231+y0 = div mul h k 6
232+y1 = div mul h add k 1 6
233+shmark 0 y0 get Lg 0 sub y1 y0
234+put Sh 7 add get Sh 7 1
235+end
236+fn shchord r long dy long to long
237+note Half the width of a circle of radius r at dy from its centre (0 outside).
238+if ge dy r
239+ret 0
240+end
241+ret long pkisqrt ulong sub mul r r mul dy dy
242+end
243+fn shringband hi long lo long ya long yb long to void
244+note The ring between radii lo and hi within rows ya..yb-1: one rectangle, or two when the band
245+note misses the ring's hollow middle. Distances are from (cx, cy).
246+cy = get Lg 4
247+cx = get Lg 3
248+near = long 0
249+if gt ya cy
250+near = sub ya cy
251+end
252+if lt yb cy
253+near = sub cy yb
254+end
255+far = pkmax pkabs sub ya cy pkabs sub yb cy
256+xo = shchord hi near
257+xi = shchord lo far
258+if eq xo 0
259+ret
260+end
261+if eq xi 0
262+shmark sub cx xo ya mul xo 2 sub yb ya
263+else
264+shmark sub cx xo ya sub xo xi sub yb ya
265+shmark add cx xi ya sub xo xi sub yb ya
266+end
267+end
268+fn shring to void
269+note The ripple bends the sky only within reach of its crest (night.c in_ripple); since the last
270+note frame the crest moved out, so the band from the old inner edge to the new outer edge changes.
271+r = get Ntrip 0
272+w = get Ntrip 1
273+if eq w 0
274+ret
275+end
276+reach = add div mul w 22 10 9
277+hi = add r reach
278+lo = sub get Sh 10 reach
279+if or lt lo 0 eq get Sh 10 0
280+lo = 0
281+end
282+put Sh 10 r
283+cy = get Lg 4
284+ya = sub cy hi
285+if lt ya 0
286+ya = 0
287+end
288+yend = add cy hi
289+if gt yend get Lg 1
290+yend = get Lg 1
291+end
292+while lt ya yend bound 64
293+yb = add ya 64
294+if gt yb yend
295+yb = yend
296+end
297+shringband hi lo ya yb
298+ya = yb
299+end
300+end
301+fn shbadd x long y long w long h long to void
302+note A box onto the list Shb (at most 5: two holes now, two before, one spare).
303+n = get Shbn 0
304+if ge n 5
305+ret
306+end
307+at = mul n 4
308+put Shb at x
309+put Shb add at 1 y
310+put Shb add at 2 w
311+put Shb add at 3 h
312+put Shbn 0 add n 1
313+end
314+fn shbmeet a ulong b ulong to bool
315+note Do boxes a and b of Shb overlap (share at least one pixel column and row).
316+a = mul a 4
317+b = mul b 4
318+if ge get Shb a add get Shb b get Shb add b 2
319+ret false
320+end
321+if ge get Shb b add get Shb a get Shb add a 2
322+ret false
323+end
324+if ge get Shb add a 1 add get Shb add b 1 get Shb add b 3
325+ret false
326+end
327+if ge get Shb add b 1 add get Shb add a 1 get Shb add a 3
328+ret false
329+end
330+ret true
331+end
332+fn shbjoin a ulong b ulong to void
333+note Box a becomes the union of a and b; the last box moves into b's place.
334+n = get Shbn 0
335+a = mul a 4
336+b = mul b 4
337+x1 = add get Shb a get Shb add a 2
338+y1 = add get Shb b get Shb add b 2
339+x1 = pkmax x1 y1
340+y1 = add get Shb add a 1 get Shb add a 3
341+x0 = add get Shb add b 1 get Shb add b 3
342+y1 = pkmax y1 x0
343+x0 = pkmin get Shb a get Shb b
344+put Shb a x0
345+x0 = pkmin get Shb add a 1 get Shb add b 1
346+put Shb add a 1 x0
347+put Shb add a 2 sub x1 get Shb a
348+put Shb add a 3 sub y1 get Shb add a 1
349+n = sub n 1
350+put Shbn 0 n
351+n = mul n 4
352+for i ulong 4
353+put Shb add b i get Shb add n i
354+end
355+end
356+fn shbmerge to void
357+note Join overlapping boxes until none overlap: every layer is a pure function of position and
358+note time, so one union costs less than two boxes composed twice where they meet.
359+for pass ulong 8
360+joined = false
361+n = get Shbn 0
362+for a ulong n
363+for b ulong n
364+if and lt a b not joined
365+if shbmeet a b
366+shbjoin a b
367+joined = true
368+end
369+end
370+end
371+end
372+if not joined
373+ret
374+end
375+end
376+end
377+fn shlens to void
378+note The holes' lens boxes now (Shl remembers them for the next frame) and the boxes of the
379+note frame before, merged where they meet, then marked.
380+put Shbn 0 0
381+n = ulong get Shl 8
382+for i ulong n
383+at = mul i 4
384+shbadd get Shl at get Shl add at 1 get Shl add at 2 get Shl add at 3
385+end
386+put Shl 8 0
387+for i ulong ntholes
388+if ntholebox i
389+shbadd get Pa 0 get Pa 1 get Pa 2 get Pa 3
390+k = ulong get Shl 8
391+at = mul k 4
392+for j ulong 4
393+put Shl add at j get Pa j
394+end
395+put Shl 8 add long k 1
396+end
397+end
398+shbmerge
399+n = get Shbn 0
400+for i ulong n
401+at = mul i 4
402+shmark get Shb at get Shb add at 1 get Shb add at 2 get Shb add at 3
403+end
404+end
405+fn shdecide t ulong to void
406+note Which parts of the screen change at t (ms since the sky started). Sh[9]: the fade's last
407+note full pass is done; Sh[12]: the ripple was on screen last frame; Shl: the lens rect last frame.
408+if lt t add SHFADE 400
409+shstrip
410+else
411+if eq get Sh 9 0
412+put Sh 9 1
413+shmarkall
414+end
415+end
416+if ne get Ntrip 1 0
417+shring
418+put Sh 12 1
419+put Ntcoarse 0 SHCOARSE
420+else
421+put Ntcoarse 0 0
422+if ne get Sh 12 0
423+put Sh 12 0
424+shmarkall
425+end
426+end
427+note The holes' lens regions now and where they were, Allen, his words and bar, the twinkles.
428+shlens
429+mddirty
430+shmark get Mdbox 0 get Mdbox 1 get Mdbox 2 get Mdbox 3
431+shmark get Hmdirty 0 get Hmdirty 1 get Hmdirty 2 get Hmdirty 3
432+shtwinkles
433+end
434+fn shstep now ulong to bool
435+note Move the show on to now and draw what changed. False when the screen refused a blit.
436+if eq get Sh 0 0
437+put Sh 0 long now
438+end
439+put Sh 11 long now
440+t = sub now ulong get Sh 0
441+ntat t
442+hmstep long t
443+mdat long t
444+if eq get Dmo 0 1
445+note Repository mode: a still picture, redrawn only when the screen says it changed.
446+if or ne get Sh 5 0 ne get Sh 3 0
447+shfull
448+put Sh 5 0
449+ret shflush
450+end
451+ret true
452+end
453+shdecide t
454+if ne get Sh 3 0
455+shfull
456+else
457+shrects
458+end
459+put Sh 1 long t
460+put Sh 4 add get Sh 4 1
461+t1 = efms
462+ok = shflush
463+shstat now t1 efms t
464+ret ok
465+end
466+fn shstat t0 ulong t1 ulong t2 ulong t ulong to void
467+note The frame's clocks and what it composed, for the stopwatch (look-stat.om).
468+rf = ulong add mul get Sh 14 2 get Sh 15
469+stframe t0 t1 t2 t ulong get Sh 13 rf
470+end
471+fn shsubmit to void
472+note Enter in the bar: a recognised repository request opens the repository screen; anything else
473+note goes to the Spark through the courier (look-chat.om) and Allen thinks until the answer comes.
474+n = get Hminn 0
475+if or eq n 0 gt n 159
476+ret
477+end
478+for i ulong n
479+put In i get Hmin i
480+put Dprm i get Hmin i
481+end
482+put Inlen 0 n
483+put Dprmn 0 n
484+if stasked
485+hmkey 13
486+ret
487+end
488+if inmatch
489+hmkey 13
490+ininstall ulong get Sh 11
491+ret
492+end
493+if ghask
494+put Dmo 0 1
495+put Sh 5 1
496+hmkey 13
497+ret
498+end
499+if eq get Es 6 0
500+note A disconnected firmware network must not make Enter silently do nothing.
501+note Keep the unsent input for retry and give a local answer without claiming it was delivered.
502+for i ulong len Shnet
503+put Hmsay i get Shnet i
504+end
505+put Hmsayn 0 len Shnet
506+hmsaid
507+note The local notice did not consume input; the next frame must still draw that line.
508+put Hm 15 add get Hm 15 1
509+ret
510+end
511+if chask ulong get Sh 11
512+put Sh 8 1
513+hmthink 1
514+end
515+hmkey 13
516+end
517+fn shkey key ulong to bool
518+note Keys: the repository screen takes them while it is up (Escape closes it); otherwise the bar.
519+if eq get Dmo 0 1
520+if eq key 27
521+put Dmo 0 0
522+ghinit
523+shmarkall
524+ret true
525+end
526+ghkey key
527+put Sh 5 1
528+ret true
529+end
530+if or eq key 10 eq key 13
531+shsubmit
532+ret true
533+end
534+hmkey key
535+ret true
536+end
537+fn shanswer to void
538+note The courier's visible text becomes what Allen says.
539+if ne get Chevent 0 1
540+if or eq get Chevent 0 5 eq get Chevent 0 6
541+if eq get Chevent 0 6
542+hmthink 0
543+put Sh 8 0
544+end
545+put Chevent 0 0
546+end
547+ret
548+end
549+n = get Chsayn 0
550+if gt n len Hmsay
551+n = len Hmsay
552+end
553+for i ulong n
554+put Hmsay i get Chsay i
555+end
556+put Hmsayn 0 n
557+hmsaid
558+hmthink 0
559+put Sh 8 0
560+put Chevent 0 0
561+end
562+fn shinit now ulong to bool
563+note Sizes from the screen (Es), then every module of the look.
564+w = get Es 0
565+h = get Es 1
566+if not shfits w h
567+ret false
568+end
569+put Lg 0 long w
570+put Lg 1 long h
571+kw = div mul w 256 1920
572+kh = div mul h 256 1080
573+if lt kh kw
574+kw = kh
575+end
576+put Lg 2 long kw
577+put Lg 3 long div w 2
578+put Lg 4 long div mul h 40 100
579+put Sh 2 long div add h 1 2
580+for i ulong 2176
581+put Shrow i 0
582+end
583+put Shdn 0 0
584+put Shl 8 0
585+pkinit
586+ntinit
587+mdinit long SHBORN
588+hminit
589+put Sh 0 long now
590+put Sh 3 1
591+ret true
592+end

aienux/allen/look-sky.om

new file mode 100644
@@ -0,0 +1,360 @@
1+note SPDX-License-Identifier: MIT
2+note Allen's look: the real sky. Handwritten Omega port of native/kernel/ui/sky_real.c (aienux 4b24df65):
3+note the gnomonic projection of the catalogue's stars (look-skydata.om) into Nsky, the list of the bright
4+note ones that twinkle, the twinkle itself (into Nfrm, inside the clip), and the two Magellanic Clouds'
5+note light and phase maps for the sweeping light. Same integers as the C; tests/look-sky.om compares the
6+note sky byte for byte with the C oracle.
7+note Ported: ck_sky_project (skproj), ck_sky_draw_stars (skstars), ck_sky_twinkle (sktwink),
8+note ck_sky_galaxy_bound/in_view/box/maps (skgbound skginview skgbox skgmaps), and ck_night_init's sky
9+note construction (skmake, night.c:120-133). Not ported, never reached by the default iMac build (sky_mode 0,
10+note allen_ui.c:1226): ck_sky_draw_milkyway and its helpers, ck_sky_gmst, ck_sky_zenith, ck_sky_view_at.
11+note Interface (NIGHT reads these; the names were agreed with LookNight):
12+note skmake: reads Lg 0..4 (w h k cx cy), runs skinit, clears Nsky w*h, draws the stars into Nsky, fills
13+note Sktwn/Sktw, then every galaxy's box, offset and maps. Never touches Nfrm or the clip.
14+note Sktwn: how many stars twinkle (<= 256). Sktw: 8 longs per star i at 8*i: 0 x16, 1 y16 (16ths of a
15+note pixel), 2 peak (catalogue flux, linear Q16), 3 4 5 col (linear, brightest channel 4096), 6 period
16+note (ms), 7 phase (ms).
17+note sktwink i amount: ck_sky_twinkle of star i with amount (1/256 of its flux) into Nfrm, clipped by Lg 5..8.
18+note Skgbox: x y w h per galaxy (w 0: empty; only galaxies 0 and 1 exist). Skgtint: its sRGB tint.
19+note Skgper: ms for the sweep to come round. Skgoff: where its maps start in Skglit (light 0..255) and
20+note Skgpha (phase 0..255), row-major box w*h each. The pools hold every box a 3840-wide screen can need:
21+note sum of (2a+1)^2 over ck_sky_galaxy_bound = 445^2 + 231^2 = 251386 (Wolfram).
22+const SKGPOOL ulong 251386
23+global Sktwn ulong 1
24+global Sktw long 2048
25+global Skgbox long 24
26+global Skgtint uint 6
27+global Skgper ulong 6
28+global Skgoff ulong 6
29+global Skglit uchar SKGPOOL
30+global Skgpha uchar SKGPOOL
31+note scratch: Skpx 0 x16 1 y16 (skproj's result), Skgp 0 gx 1 gy (skginview's result);
32+note Skpk 0 peak 1 2 3 colour, Skclip x y w h, Sktgt 0 Nsky 1 Nfrm (skpoint's arguments);
33+note Skgw 0 gx 1 gy 2 a 3 b 4 cos 5 sin 6 box x 7 box y 8 a^2 9 b^2 (skgmaps' per-galaxy values for skgpx)
34+global Skpx long 2
35+global Skgp long 2
36+global Skpk ulong 4
37+global Skclip long 4
38+global Sktgt ulong 1
39+global Skgw long 10
40+note ck_sky_project: where direction (dx dy dz) (Q15) lands on the Lg 0 wide screen whose view centre is
41+note (Lg 3, Lg 4): Skpx 0 1 in 16ths of a pixel; 0 when behind the camera (more than 88 degrees away).
42+fn skproj dx long dy long dz long to long
43+a2 = add mul get Skview 11 dx mul get Skview 12 dy
44+a2 = add a2 mul get Skview 13 dz
45+if lt a2 1099511627776
46+ret 0
47+end
48+a2 = shr a2 16
49+u = add mul get Skview 5 dx mul get Skview 6 dy
50+u = add u mul get Skview 7 dz
51+u = div mul u 16384 a2
52+t = add mul get Skview 8 dx mul get Skview 9 dy
53+t = add t mul get Skview 10 dz
54+t = div mul t 16384 a2
55+s = mul get Lg 0 8
56+u = div mul u s get Skview 4
57+t = div mul t s get Skview 4
58+put Skpx 0 add mul get Lg 3 16 u
59+put Skpx 1 sub mul get Lg 4 16 t
60+ret 1
61+end
62+note one native pixel of point_add: pixel (x, y) of the target gets weight/256 of the light Skpk
63+fn skdep x long y long wt ulong to void
64+i = ulong add mul y get Lg 0 x
65+c = ulong 0
66+if eq get Sktgt 0 0
67+c = ulong get Nsky i
68+else
69+c = ulong get Nfrm i
70+end
71+out = ulong 0
72+for k ulong 3
73+lv = and shr c sub 16 mul 8 k 255
74+a = mul get Skpk 0 get Skpk add k 1
75+a = shr mul shr a 13 wt 8
76+if ne a 0
77+l = add ulong get Slin lv a
78+if ge l 32767
79+l = 4095
80+else
81+l = shr l 3
82+end
83+lv = shr add ulong get Ssrgb l 8 4
84+if gt lv 255
85+lv = 255
86+end
87+end
88+out = or shl out 8 lv
89+end
90+c = or and c 4278190080 out
91+if eq get Sktgt 0 0
92+put Nsky i uint c
93+else
94+put Nfrm i uint c
95+end
96+end
97+note the clip for skpoint: (x, y, w, h) cut to the screen, kept as x0 y0 x1 y1 (ends exclusive) in Skclip
98+fn skclip x long y long w long h long to void
99+put Skclip 0 pkmax x 0
100+put Skclip 1 pkmax y 0
101+put Skclip 2 pkmin add x w get Lg 0
102+put Skclip 3 pkmin add y h get Lg 1
103+end
104+note point_add: a point source at (x16, y16) deposits the light Skpk on the 2 x 2 native pixels round it,
105+note inside Skclip (already cut to the screen), into Nsky (Sktgt 0) or Nfrm (Sktgt 1). Weights sum to 256.
106+fn skpoint x16 long y16 long to void
107+x0 = shr sub x16 8 4
108+y0 = shr sub y16 8 4
109+fx = ulong and sub x16 8 15
110+fy = ulong and sub y16 8 15
111+for j ulong 2
112+y = add y0 long j
113+if ge y get Skclip 1
114+if lt y get Skclip 3
115+for i ulong 2
116+x = add x0 long i
117+if ge x get Skclip 0
118+if lt x get Skclip 2
119+wt = sub 16 fx
120+if eq i 1
121+wt = fx
122+end
123+if eq j 1
124+wt = mul wt fy
125+else
126+wt = mul wt sub 16 fy
127+end
128+if ne wt 0
129+skdep x y wt
130+end
131+end
132+end
133+end
134+end
135+end
136+end
137+end
138+note ck_sky_draw_stars for star i: project it, add its light to Nsky, list it to twinkle when V <= 1.0
139+fn skstar1 i ulong to void
140+j = mul i 3
141+if eq skproj get Skstar j get Skstar add j 1 get Skstar add j 2 0
142+ret
143+end
144+x = get Skpx 0
145+y = get Skpx 1
146+if lt x -32
147+ret
148+end
149+if lt y -32
150+ret
151+end
152+if gt x add mul get Lg 0 16 32
153+ret
154+end
155+if gt y add mul get Lg 1 16 32
156+ret
157+end
158+bv = get Skbv i
159+if ge bv 128
160+bv = 127
161+end
162+bv = mul bv 3
163+put Skpk 0 get Skflux get Skmag i
164+put Skpk 1 get Skpal bv
165+put Skpk 2 get Skpal add bv 1
166+put Skpk 3 get Skpal add bv 2
167+skpoint x y
168+if le get Skmag i 59
169+n = get Sktwn 0
170+if lt n 256
171+n = mul n 8
172+put Sktw n x
173+put Sktw add n 1 y
174+put Sktw add n 2 long get Skpk 0
175+put Sktw add n 3 long get Skpk 1
176+put Sktw add n 4 long get Skpk 2
177+put Sktw add n 5 long get Skpk 3
178+put Sktw add n 6 long add 1200 rem mul i 137 2400
179+put Sktw add n 7 long rem mul i 919 65536
180+put Sktwn 0 add get Sktwn 0 1
181+end
182+end
183+end
184+note ck_sky_draw_stars: every catalogue star in the view into Nsky (clip: the whole screen), the bright
185+note ones listed in Sktw
186+fn skstars to void
187+put Sktwn 0 0
188+put Sktgt 0 0
189+skclip 0 0 get Lg 0 get Lg 1
190+for i ulong SKNST
191+skstar1 i
192+end
193+end
194+note ck_sky_twinkle: star i of Sktw with amount/256 more of its light, into Nfrm inside the clip Lg 5..8
195+fn sktwink i ulong amount ulong to void
196+n = mul i 8
197+put Skpk 0 shr mul ulong get Sktw add n 2 amount 8
198+put Skpk 1 ulong get Sktw add n 3
199+put Skpk 2 ulong get Sktw add n 4
200+put Skpk 3 ulong get Sktw add n 5
201+put Sktgt 0 1
202+skclip get Lg 5 get Lg 6 get Lg 7 get Lg 8
203+skpoint get Sktw n get Sktw add n 1
204+end
205+note ck_sky_galaxy_bound: the side of the largest box galaxy i can need on a w-wide screen (0: no galaxy i)
206+fn skgbound w long i ulong to long
207+if ge i SKNGAL
208+ret 0
209+end
210+a = add shr mul get Skgal add mul i 7 3 w 16 4
211+ret add mul a 2 1
212+end
213+note ck_sky_galaxy_in_view: galaxy i's centre pixel into Skgp 0 1; 1 when it is on the Lg 0 x h screen
214+fn skginview i ulong h long to long
215+if ge i SKNGAL
216+ret 0
217+end
218+j = mul i 7
219+if eq skproj get Skgal j get Skgal add j 1 get Skgal add j 2 0
220+ret 0
221+end
222+x = shr add get Skpx 0 8 4
223+y = shr add get Skpx 1 8 4
224+put Skgp 0 x
225+put Skgp 1 y
226+if lt x 0
227+ret 0
228+end
229+if ge x get Lg 0
230+ret 0
231+end
232+if lt y 0
233+ret 0
234+end
235+if ge y h
236+ret 0
237+end
238+ret 1
239+end
240+note ck_sky_galaxy_box: galaxy i's box on the screen into Skgbox (clipped; empty when out of view or none)
241+fn skgbox i ulong to void
242+b = mul i 4
243+put Skgbox b 0
244+put Skgbox add b 1 0
245+put Skgbox add b 2 0
246+put Skgbox add b 3 0
247+if eq skginview i get Lg 1 0
248+ret
249+end
250+a = add shr mul get Skgal add mul i 7 3 get Lg 0 16 4
251+x0 = pkmax 0 sub get Skgp 0 a
252+y0 = pkmax 0 sub get Skgp 1 a
253+x1 = pkmin sub get Lg 0 1 add get Skgp 0 a
254+y1 = pkmin sub get Lg 1 1 add get Skgp 1 a
255+if ge x0 x1
256+ret
257+end
258+if ge y0 y1
259+ret
260+end
261+put Skgbox b x0
262+put Skgbox add b 1 y0
263+put Skgbox add b 2 sub x1 x0
264+put Skgbox add b 3 sub y1 y0
265+end
266+note one map pixel (px, py) of the galaxy Skgw describes, at pool offset off: its light and phase
267+fn skgpx px long py long off ulong to void
268+px = sub add get Skgw 6 px get Skgw 0
269+py = sub add get Skgw 7 py get Skgw 1
270+u = mul px get Skgw 4
271+u = shr add u mul py get Skgw 5 14
272+v = mul neg px get Skgw 5
273+v = shr add v mul py get Skgw 4 14
274+a = get Skgw 2
275+note f < 0: no galaxy there (a or b 0, or outside the ellipse u^2 b^2 + v^2 a^2 > a^2 b^2);
276+note Skgw 8 is a^2, Skgw 9 is b^2
277+f = long -1
278+if ne a 0
279+if ne get Skgw 3 0
280+f = mul mul u u get Skgw 9
281+f = add f mul mul v v get Skgw 8
282+f = sub mul get Skgw 8 get Skgw 9 f
283+end
284+end
285+if lt f 0
286+put Skglit off 0
287+put Skgpha off 128
288+ret
289+end
290+note light falls off as (1 - (u/a)^2 - (v/b)^2)^2
291+f = mul mul u u 65536
292+f = sub 65536 div f get Skgw 8
293+v = mul mul v v 65536
294+f = sub f div v get Skgw 9
295+if lt f 0
296+f = 0
297+end
298+f = shr mul f f 16
299+f = shr mul f 255 16
300+put Skglit off uchar f
301+f = mul add u a 255
302+f = div f add mul a 2 1
303+put Skgpha off uchar f
304+end
305+note ck_sky_galaxy_maps: galaxy i's light and phase over its box into Skglit / Skgpha at Skgoff i
306+fn skgmaps i ulong to void
307+if ge i SKNGAL
308+ret
309+end
310+b = mul i 4
311+if eq get Skgbox add b 2 0
312+ret
313+end
314+if eq skginview i 2147483647 0
315+ret
316+end
317+j = mul i 7
318+put Skgw 0 get Skgp 0
319+put Skgw 1 get Skgp 1
320+put Skgw 2 shr mul get Skgal add j 3 get Lg 0 16
321+put Skgw 3 add shr mul get Skgal add j 4 get Lg 0 16 1
322+put Skgw 4 pkcos ulong get Skgal add j 5
323+put Skgw 5 pksin ulong get Skgal add j 5
324+put Skgw 6 get Skgbox b
325+put Skgw 7 get Skgbox add b 1
326+put Skgw 8 mul get Skgw 2 get Skgw 2
327+put Skgw 9 mul get Skgw 3 get Skgw 3
328+put Skgtint i uint get Skgal add j 6
329+put Skgper i add 2400 mul i 400
330+w = ulong get Skgbox add b 2
331+h = ulong get Skgbox add b 3
332+off = get Skgoff i
333+for py ulong h
334+for px ulong w
335+skgpx long px long py off
336+off = add off 1
337+end
338+end
339+end
340+note the sky as ck_night_init makes it (night.c:120-133): black, the stars, the galaxies
341+fn skmake to void
342+skinit
343+w = ulong get Lg 0
344+h = ulong get Lg 1
345+for y ulong h
346+r = mul y w
347+for x ulong w
348+put Nsky add r x 0
349+end
350+end
351+skstars
352+off = ulong 0
353+for i ulong 6
354+skgbox i
355+put Skgoff i off
356+b = mul i 4
357+off = add off mul ulong get Skgbox add b 2 ulong get Skgbox add b 3
358+skgmaps i
359+end
360+end

aienux/allen/look-skydata.om

new file mode 100644
@@ -0,0 +1,124 @@
1+note SPDX-License-Identifier: MIT
2+note Allen's look: the sky's tables. GENERATED by ~/work/IMacLook/sky/gen_skydata.py from
3+note native/kernel/ui/sky_data.c (aienux 4b24df65, itself generated by native/kernel/tools/ck_sky_gen.c
4+note from the Yale Bright Star Catalogue); do not edit the text lines. Decimal numbers, one space between,
5+note a trailing space. skinit decodes them once into the Sk* pools below; skmake (look-sky.om) calls it.
6+note Left out on purpose: ck_sky_milkyway, ck_sky_luma, ck_sky_chroma (ck_night_init at 4b24df65 clears the
7+note sky to black and never calls ck_sky_draw_milkyway: night.c:122-125) and ck_sky_checks (host test only).
8+note Sdview: ra_mdeg dec_mdeg fov_mdeg roll_mdeg tan_half_q30, then rot_q30 row-major (rows: screen right,
9+note screen up, the view centre). Sdstars: x y z (Q15, J2000) mag ((V+2)*20) bv (palette index) per star.
10+note Sdflux: light at the middle of a star of magnitude code m, linear Q16. Sdpal: linear sRGB r g b per
11+note B-V step, brightest channel 4096. ck_sky_lin / ck_sky_srgb16 (Slin / Ssrgb) are PAINT's: pkinit fills
12+note them. Sdgal: dir x y z (Q15), a_q16, b_q16, angle
13+note (turns/65536 from screen right towards down), tint (sRGB packed) per galaxy.
14+text Sdview "113697 -72757 80000 0 900976368 983207820 431536659 0 -412141747 939018691 318283808 -127918209 291447275 -1025483750 "
15+text Sdstars "-2072 19750 -26064 26 28 -12262 -10232 -28611 40 55 16145 7334 -27554 49 12 -13891 -8332 -28483 52 8 -16180 -3418 -28288 65 8 -14726 -1717 -29221 67 8 -12262 -10232 -28611 67 64 -17627 -2412 -27517 73 100 -8481 7557 -30735 74 20 -14725 -1717 -29221 75 7 -9685 13514 -28236 77 84 -3592 -11164 -30596 78 92 -12463 14249 -26745 79 22 -21163 -3875 -24714 83 20 -12687 10923 -28168 85 29 -17683 -8235 -26329 86 9 -14504 11944 -26845 90 11 -20730 -756 -25365 92 14 -20236 6695 -24887 94 65 -11517 -1885 -30618 94 10 -13368 4671 -29549 95 9 7184 820 -31959 96 51 -16962 -1122 -28013 96 8 -7595 -12533 -29307 97 34 13551 7728 -28815 97 34 -7701 -9090 -30525 98 20 -4495 20300 -25326 99 80 -11553 7567 -29714 100 34 -11969 -2450 -30404 101 11 -14203 10779 -27491 103 98 -14783 1568 -29201 103 18 -10520 -9024 -29691 104 32 4872 7449 -31535 105 101 6880 17467 -26856 105 15 -3217 15074 -28915 105 30 -10005 5003 -30798 106 16 -14411 5821 -28847 106 16 6732 13565 -29058 107 66 -14161 6824 -28750 108 97 -12502 11360 -28077 109 10 -9623 17222 -26163 109 11 -16320 9722 -26699 111 16 16880 11441 -25648 111 14 -16115 -1506 -28491 112 91 -12718 15117 -26142 112 11 -9990 -2784 -31083 112 79 -12920 813 -30101 113 28 -12586 8390 -29067 114 81 17799 9865 -25682 114 62 -16056 15484 -24002 115 80 1738 15035 -29062 115 61 5885 -4065 -31977 115 70 -7872 10665 -29966 115 76 -3232 10450 -30887 116 72 -16240 4849 -28043 116 68 -15649 6652 -28010 116 36 -4630 -4164 -32170 117 92 -11110 11601 -28560 117 15 -20423 7708 -24437 117 35 7789 11571 -29650 117 76 1142 20560 -25488 117 29 -21785 10775 -21977 117 22 10814 21691 -22051 117 75 -21402 -3552 -24557 117 22 -9952 -1419 -31187 117 12 -18757 3223 -26673 118 12 -2327 -5865 -32154 118 66 -16465 3757 -28079 118 82 -20804 -2558 -25186 118 10 17854 5491 -26921 118 16 -4210 8844 -31269 119 72 -19981 -1017 -25950 119 12 -11280 10222 -29016 119 11 -4046 11613 -30372 120 59 15320 14524 -25061 120 125 -9376 9178 -30026 120 27 -8241 3652 -31503 120 38 -17259 -4191 -27536 121 12 -14316 -1154 -29452 121 12 -4215 6102 -31917 121 40 -11051 -12883 -28028 121 24 -13495 9945 -28154 122 20 9715 6914 -30520 122 22 9308 7783 -30438 122 17 -6037 2334 -32121 122 99 -15769 929 -28708 122 65 -12259 -941 -30373 122 99 -7703 -10672 -30008 122 78 -14041 -422 -29603 123 37 4657 -1557 -32397 123 30 13863 1225 -29665 125 49 -2333 -6685 -31993 125 73 8942 18341 -25638 125 35 -6057 -486 -32199 125 14 -20210 -6074 -25066 125 10 -17375 6384 -27038 126 72 -14458 651 -29398 126 12 -2897 -2161 -32567 126 86 -10641 12612 -28308 127 15 -14715 -194 -29276 127 34 -20946 -4943 -24708 127 88 -14844 -10425 -27288 127 26 -13282 11526 -27648 127 101 894 13436 -29872 127 30 -6328 10133 -30511 127 15 -4089 5806 -31988 127 78 -17312 12483 -24862 127 29 17309 3314 -27624 127 20 14756 2044 -29185 127 16 -3000 19502 -26160 128 19 -23442 6264 -22021 128 26 -4194 18976 -26381 128 66 -10553 18607 -24821 128 12 7301 15050 -28176 129 74 8290 22951 -21868 129 37 -16399 6329 -27653 129 101 -5105 1714 -32321 129 10 -23082 893 -23240 129 85 -20758 -733 -25342 129 12 -7081 6770 -31268 130 50 -11940 13412 -27409 130 12 -16619 7669 -27179 130 14 13548 -5 -29835 130 16 7599 13282 -28974 130 102 809 18226 -27218 130 75 -10557 -12964 -28181 130 30 -12853 9054 -28749 130 16 -14870 -5606 -28655 131 14 -13152 -5049 -29584 131 62 14752 2045 -29187 131 28 7917 13541 -28769 131 101 -17008 7966 -26851 131 101 -15214 5273 -28538 131 105 -19094 11969 -23787 132 80 -25132 7121 -19783 132 72 -15880 3332 -28467 132 48 -15612 -5094 -28354 132 16 -14758 3506 -29045 132 72 -19022 2103 -26598 132 16 -16329 -3969 -28130 132 12 -10054 18700 -24958 133 8 381 14827 -29218 133 73 -17721 -3636 -27320 133 12 -18255 -9167 -25620 133 68 -16127 6895 -27678 133 46 -15743 5827 -28141 133 94 -21206 -3986 -24659 133 75 -2706 -5825 -32131 134 104 10927 5991 -30305 134 68 -13806 14256 -26073 134 14 -15581 -3144 -28654 134 73 -7907 7527 -30895 134 12 -12653 -7133 -29372 134 76 9107 11805 -29179 134 40 4150 17124 -27627 134 46 -12884 662 -30121 134 97 -14789 -279 -29238 134 16 -9364 3862 -31162 135 22 6214 5717 -31660 135 86 -16466 -10480 -26320 135 67 -8396 13306 -28743 135 42 7333 51 -31936 136 84 -11672 -3976 -30358 136 16 -845 18790 -26831 136 8 -11668 9708 -29039 136 67 -7311 12621 -29341 136 12 -12651 17651 -24537 136 12 -13319 4701 -29567 136 13 -13603 4676 -29441 136 14 -20283 -2358 -25626 136 13 2546 12448 -30203 137 84 -22294 10122 -21776 137 76 9362 8250 -30298 137 23 -13451 4445 -29546 137 12 -20456 -5822 -24926 137 21 11169 3835 -30565 137 44 -10885 13523 -27791 137 70 -12801 14932 -26208 137 12 -17926 9437 -25754 137 14 -14714 -1710 -29227 137 14 -9476 -11060 -29352 137 82 -12191 -4270 -30114 137 95 -17959 7316 -26413 138 45 -13732 489 -29747 138 15 -6688 11 -32077 138 17 -4218 -2905 -32364 138 32 -4340 -10284 -30807 138 48 -11696 12009 -28154 138 10 -15950 -5355 -28118 138 44 -13928 -9991 -27926 138 63 11165 21643 -21922 139 36 -3662 21522 -24435 139 64 -5846 20424 -24947 139 26 -8755 3580 -31372 139 104 -16263 -3010 -28287 139 18 -8080 18221 -26008 139 90 -15284 1277 -28956 139 77 -5254 20969 -24625 139 104 7845 13769 -28680 139 91 -11075 486 -30835 139 90 10184 10078 -29469 140 26 -11720 5281 -30140 140 14 -18663 -1550 -26888 140 100 14210 -149 -29525 140 23 7491 5386 -31441 140 75 -664 13526 -29838 140 101 -13179 16461 -25080 140 86 -16493 12188 -25556 140 11 -17158 -8160 -26696 140 18 -20753 8285 -23966 140 72 5053 20637 -24945 141 94 -15096 1087 -29062 141 60 17430 8701 -26347 141 22 -7637 -159 -31864 141 94 -471 15297 -28973 141 82 -7960 -3100 -31634 141 76 -450 11818 -30558 141 16 -19003 -7815 -25524 141 24 -4577 -3276 -32280 141 15 8332 1794 -31639 141 88 8796 21455 -23151 141 10 -7679 11139 -29843 141 77 -14807 -9889 -27507 141 16 -19287 12293 -23464 142 15 -19511 10573 -24108 142 64 -15505 5926 -28252 142 79 -23865 3292 -22210 142 18 14709 2115 -29204 142 22 -385 8608 -31614 142 56 -11816 15737 -26199 142 32 -10386 -12048 -28647 142 17 -6180 -10233 -30509 142 76 -7585 19166 -25471 142 73 4932 -2299 -32312 142 94 11491 11859 -28302 142 37 567 12843 -30140 142 13 -15313 12148 -26299 142 15 -4145 3071 -32358 142 13 -13694 2208 -29686 142 16 -10748 -10446 -29138 142 20 4547 -157 -32450 142 66 -17264 12805 -24731 142 14 -15023 3429 -28917 143 31 -16533 2047 -28216 143 74 2477 16737 -28061 143 70 -5365 19725 -25609 143 101 -6544 20508 -24704 143 82 -23470 5497 -22195 143 22 -16497 2039 -28238 143 44 -15665 1578 -28737 143 76 -15400 1475 -28885 143 19 -12469 -1207 -30278 143 30 5308 -5093 -31931 143 44 -8303 12395 -29174 143 24 -13846 15974 -25036 143 10 -11873 11937 -28111 143 41 -11740 5885 -30020 143 30 -19899 -5060 -25536 143 17 800 20108 -25859 143 70 -3180 11903 -30363 143 90 -4975 17263 -27403 143 18 -8023 13949 -28543 143 107 -12038 16340 -25725 143 12 -14217 2144 -29444 143 45 -13587 1219 -29792 143 60 -17263 -4193 -27533 143 14 -9930 -10356 -29459 143 66 -15654 15810 -24055 144 32 -8273 -282 -31704 144 85 947 7681 -31840 144 76 -12657 15089 -26188 144 13 3327 14289 -29299 144 102 -7036 8453 -30866 144 20 -11766 -11319 -28410 144 78 14523 12258 -26693 144 40 -14920 -13319 -25955 144 69 -2298 17769 -27435 144 75 -14312 14096 -25887 145 14 -13503 4486 -29516 145 16 -17058 5628 -27405 145 16 -13974 2923 -29493 145 17 -12907 -9024 -28734 145 34 9811 11517 -29065 145 50 6094 13355 -29295 145 68 -16968 5146 -27555 145 28 -21955 2315 -24213 145 32 -17484 -9304 -26104 145 16 11083 10070 -29145 145 25 -10815 13445 -27856 145 13 -15669 13371 -25483 145 16 5353 15624 -28300 145 30 -2719 20780 -25189 145 40 -13892 12258 -27027 145 70 -2710 -5841 -32128 145 90 4429 194 -32466 146 73 4883 3805 -32177 146 69 -11872 6266 -29891 146 69 -18336 9204 -25549 146 32 324 -1329 -32738 146 84 448 19882 -26042 146 36 -5438 7620 -31401 146 20 -6479 5562 -31635 146 21 -13162 5528 -29494 146 113 -22845 1424 -23447 146 14 3511 -2217 -32503 146 57 9134 -4031 -31209 146 52 -15660 2299 -28691 146 16 15409 12636 -26011 146 34 6894 19678 -25277 146 69 2597 10172 -31040 146 70 1330 22476 -23807 146 72 -14587 -2759 -29211 146 34 -13149 -5128 -29571 146 40 -14261 9920 -27783 146 30 -17393 -4332 -27430 146 20 -13295 17472 -24324 147 13 -15221 16062 -24166 147 33 9983 21234 -22872 147 74 1675 14148 -29508 147 72 -13376 4458 -29579 147 15 -21615 -778 -24614 147 20 -5394 -5295 -31883 147 92 13092 9590 -28466 147 40 -8748 9498 -30116 147 41 -12097 -245 -30451 147 20 5363 -1681 -32281 147 12 -4079 3300 -32344 147 43 -20995 4410 -24767 147 29 -11219 -9864 -29163 147 34 14833 4487 -28871 147 64 -5952 8515 -31076 147 17 5293 20768 -24786 148 41 -1262 11304 -30730 148 68 -23552 9134 -20870 148 127 -15825 5551 -28150 148 33 -15326 -7311 -28024 148 18 -14230 -13777 -26103 148 26 13372 2507 -29809 148 45 -6940 18901 -25851 148 16 -9031 7762 -30527 148 41 -17434 -1742 -27689 148 15 5451 14343 -28952 148 99 -4165 20075 -25560 148 87 -2379 10420 -30975 148 15 15715 13490 -25392 148 48 -17484 969 -27696 148 103 -1726 1778 -32673 148 36 -21927 2154 -24254 149 82 -18172 139 -27266 149 16 11132 2724 -30697 149 75 6772 13705 -28983 149 75 3668 20470 -25322 149 46 -1470 5834 -32210 149 22 -16181 12407 -25650 149 15 -15765 11328 -26397 149 28 -6257 4127 -31898 149 64 -15915 5994 -28008 149 45 2897 22125 -23995 149 51 -2706 -662 -32648 149 71 -10437 -12308 -28518 149 15 2376 8178 -31641 149 96 257 6044 -32204 149 16 -9475 11565 -29158 149 71 -4060 4782 -32161 149 15 -8124 6399 -31092 149 74 -7606 5752 -31349 149 98 -5139 1738 -32315 149 68 869 -8412 -31657 149 21 438 -405 -32762 149 34 -12507 14985 -26319 150 12 -16509 -2296 -28211 150 52 -18620 -6835 -26082 150 14 18523 9245 -25399 150 100 -5653 -7469 -31400 150 14 1426 -200 -32735 150 84 -4576 16153 -28139 150 15 -21311 2340 -24780 150 72 -16759 -2019 -28084 150 92 -6393 -3891 -31901 150 98 -3898 -9937 -30980 150 81 11362 1026 -30717 150 18 -11545 17513 -25173 150 101 -14231 16624 -24389 150 11 -13089 -4009 -29771 150 19 6393 -3055 -31992 150 36 17474 8381 -26422 150 46 4694 5399 -31976 150 42 -12798 14943 -26203 150 12 -3851 2207 -32465 150 22 -12968 4708 -29721 150 12 11498 -2820 -30554 150 38 7126 7268 -31146 151 13 -2263 5772 -32175 151 84 -10209 16813 -26206 151 87 -6686 8931 -30809 151 18 9810 11472 -29083 151 52 3527 10108 -30969 151 14 -12435 11106 -28208 151 62 -12511 -13806 -26954 151 77 10298 6832 -30347 151 98 -19432 12800 -23070 151 11 -23847 1947 -22387 151 50 -9895 -2182 -31161 151 78 -1106 11161 -30788 151 96 -15995 10819 -26473 151 18 -16223 -10664 -26396 151 92 19779 2998 -25951 151 44 4277 4569 -32164 151 35 -12688 8011 -29129 151 86 -10446 2468 -30959 151 18 -17842 610 -27477 151 24 -15155 154 -29051 151 12 -1775 -2615 -32614 151 26 -17315 7455 -26801 152 98 -2178 -1026 -32678 152 29 -8308 16112 -27296 152 76 -11941 12849 -27676 152 15 -9864 1554 -31208 152 23 10429 213 -31062 152 14 -2758 20063 -25759 152 47 -7982 14135 -28463 152 48 -13827 7247 -28809 152 100 -21478 10530 -22394 152 96 -6896 -6500 -31367 152 61 5792 18629 -26327 152 36 -1812 18056 -27283 152 32 -3800 18147 -27017 152 96 -12690 15085 -26174 152 13 -14189 75 -29535 152 29 -9812 -7201 -30423 152 44 -19200 12076 -23647 152 78 -8506 15523 -27575 153 85 -14307 11812 -27009 153 30 -14161 -6395 -28849 153 45 -909 5152 -32347 153 30 539 5403 -32314 153 50 -5962 8514 -31075 153 15 -19998 9296 -24235 153 103 -7945 791 -31779 153 38 -2710 -2754 -32538 153 68 -2749 -2866 -32525 153 85 -5343 -7655 -31409 153 18 -9794 15438 -27192 153 30 -73 20525 -25542 153 30 -12678 5974 -29618 153 22 -21418 5289 -24227 153 32 -10116 -3976 -30912 153 18 -10150 -12442 -28563 153 44 12533 16720 -25239 154 75 6976 -6425 -31364 154 50 14684 -1997 -29224 154 12 2721 1233 -32631 154 67 10303 6916 -30326 154 85 2398 5027 -32290 154 62 -3231 10452 -30887 154 40 -12086 15459 -26242 154 49 -3047 4183 -32356 154 71 17785 3278 -27324 154 30 14534 3465 -29162 154 98 4028 5248 -32092 154 66 -2364 16831 -28014 154 17 -8998 16836 -26632 154 12 -11556 18288 -24611 154 14 -15041 627 -29104 154 33 -4730 -8705 -31233 154 78 14439 6872 -28600 154 84 13010 21312 -21218 154 50 -357 13302 -29943 154 18 -13019 13576 -26830 154 44 -19673 12021 -23284 154 15 -22061 2395 -24109 154 103 -18666 -5674 -26326 154 16 -10928 -5984 -30306 154 94 -17614 -9684 -25877 154 16 -8697 -11086 -29583 154 102 -8836 19677 -24666 154 17 -17908 10882 -25190 154 20 -15437 7885 -27806 154 16 -15815 -3600 -28471 154 39 14122 -975 -29551 154 90 12310 18469 -24104 155 68 -18907 11964 -23939 155 74 -19329 -4370 -26096 155 26 -10422 -12053 -28632 155 16 4464 -48 -32462 155 73 10894 9593 -29376 155 66 11806 13176 -27580 155 127 -7835 14090 -28526 155 98 -21456 8673 -23197 155 12 -16232 3338 -28268 155 15 -12055 -1171 -30447 155 72 5922 13912 -29070 155 70 -17574 14435 -23589 155 66 -10184 -5403 -30672 155 106 -10773 -7311 -30069 155 17 -6968 -11944 -29706 155 17 -5342 -11086 -30369 155 28 6355 -425 -32142 155 76 16529 7691 -27227 155 64 -2448 21712 -24418 155 17 -19214 3939 -26248 155 86 -15783 -3743 -28471 155 36 -8640 -9388 -30181 155 54 2854 166 -32642 155 106 -12035 9621 -28918 155 28 -13457 4643 -29513 155 20 3191 -4037 -32360 155 77 2135 -867 -32686 155 71 14682 19119 -22194 156 31 1009 9118 -31457 156 105 -7451 14434 -28457 156 41 -11147 11766 -28478 156 16 -18131 9093 -25735 156 27 10049 -4412 -30875 156 39 2010 4357 -32414 156 38 5512 13914 -29150 156 72 -6090 11739 -29980 156 18 -3954 4472 -32219 156 100 -11283 11208 -28649 156 80 -16707 15102 -23801 156 10 -14104 8881 -28212 156 88 -17720 2875 -27412 156 20 -12744 -5955 -29594 156 40 -1714 16154 -28457 156 20 -3976 19589 -25964 156 96 -12976 16043 -25454 156 14 -14562 10098 -27561 156 75 -22937 4745 -22915 156 103 -17920 -2351 -27332 156 98 15035 10519 -27147 156 98 -7917 13874 -28610 156 16 -10554 5523 -30525 156 21 -16512 7822 -27200 156 44 -22841 6122 -22682 156 16 -19441 2837 -26224 156 46 -7386 -8372 -30806 156 127 7108 -831 -31976 156 54 15606 16010 -23955 156 85 -2046 17242 -27789 156 84 -11769 18265 -24527 156 12 7918 10400 -30047 157 17 -15775 1632 -28673 157 16 -18810 -7058 -25885 157 26 -9815 -7618 -30320 157 70 14349 16718 -24255 157 82 1132 4142 -32484 157 66 -11748 16331 -25864 157 20 -6221 -2090 -32103 157 74 -10749 -8035 -29893 157 95 505 -9197 -31446 157 43 2817 22618 -23541 157 88 -6547 5619 -31611 157 19 392 -7976 -31779 157 82 16528 7690 -27228 157 65 3647 1661 -32521 157 50 6367 13300 -29262 157 16 -7607 18366 -26048 157 70 -9655 16584 -26560 157 13 -15191 15468 -24569 157 74 -15531 13182 -25665 157 47 -14733 -11670 -26841 157 44 -15574 -12332 -26058 157 75 -10552 -9890 -29403 157 56 -8464 8380 -30525 158 101 -13654 10440 -27897 158 105 -9485 -1340 -31336 158 76 -647 -5165 -32351 158 103 16395 2927 -28219 158 48 -11639 -133 -30630 158 16 -19699 -6533 -25356 158 19 -16146 -5418 -27993 158 74 -17191 -9307 -26297 158 20 -7529 -9486 -30447 158 71 1296 -8957 -31492 158 69 -13918 16427 -24700 158 10 -12730 1544 -30154 158 76 -15752 -3769 -28484 158 30 -12548 -4127 -29987 158 23 -9654 18467 -25287 158 75 -14893 15882 -24488 158 12 -10230 7956 -30095 158 20 -21646 8684 -23015 158 66 -16602 6204 -27560 158 13 -15930 5069 -28182 158 20 -19950 5614 -25380 158 29 -14730 322 -29268 158 30 -10690 -3466 -30780 158 41 -9645 -8741 -30071 158 16 -2000 -2205 -32631 158 17 3162 -3825 -32389 158 105 16707 12017 -25498 158 31 -16603 14744 -24096 158 18 -12045 9345 -29004 158 75 -15917 5873 -28033 158 102 -15488 4494 -28524 158 74 -14879 -804 -29183 158 34 -18062 -1736 -27284 158 99 -15642 -9346 -27233 158 81 13208 5142 -29543 159 98 15627 17422 -22934 159 42 11736 19069 -23923 159 82 -17519 10753 -25518 159 12 -14843 4362 -28885 159 108 -18315 -4317 -26826 159 86 -9721 -2447 -31196 159 76 -5144 -5153 -31948 159 73 18564 9757 -25177 159 27 6344 14434 -28724 159 97 594 17761 -27529 159 53 -14078 7965 -28497 159 33 -10769 17798 -25317 159 80 -15636 6881 -27961 159 36 -14476 -2030 -29326 159 34 -3661 -2022 -32499 159 93 -4467 -6493 -31805 159 18 709 -5513 -32292 159 78 6860 -3839 -31810 159 40 7214 9037 -30659 159 41 -5837 19326 -25809 159 70 -7339 17606 -26643 159 98 -22114 10492 -21784 159 17 -12417 1207 -30299 159 71 -19206 1620 -26499 159 103 -15897 -343 -28650 159 103 7102 667 -31981 159 90 -6441 18879 -25995 159 75 -10041 14182 -27780 159 16 -8353 11303 -29600 159 68 -5477 1944 -32247 159 16 -11395 -6636 -29996 159 38 14897 -173 -29184 159 26 15972 3012 -28452 160 86 -2068 19985 -25884 160 72 -21727 11234 -21804 160 82 13461 17641 -24110 160 26 -12096 9787 -28837 160 73 -10369 3086 -30929 160 19 -13842 2487 -29595 160 43 -15746 -4769 -28337 160 44 -15397 10602 -26911 160 14 -15820 6328 -27988 160 36 -15622 5069 -28354 160 34 -14369 -1727 -29398 160 24 -17917 -3414 -27221 160 16 -16176 -7797 -27408 160 16 -16536 -9218 -26744 160 59 -17222 -10927 -25645 160 17 -15898 -11530 -26230 160 75 5085 -5950 -31819 160 42 7410 -700 -31910 160 65 15823 6985 -27830 160 39 -12397 5299 -29865 160 24 -15940 -7333 -27673 160 77 -6477 -7229 -31297 160 20 -4453 16309 -28069 160 35 -4569 14055 -29245 160 19 -10773 18612 -24722 160 22 -12927 11308 -27905 160 15 -16573 3942 -27991 160 82 -17285 -6360 -27101 160 34 -7254 -4552 -31628 160 49 10899 10192 -29172 161 82 1714 11820 -30513 161 37 -12347 13118 -27371 161 19 -10018 -2829 -31069 161 22 -14080 -1748 -29536 161 21 -9507 -3428 -31170 161 88 -9507 -7819 -30367 161 45 -529 -2009 -32701 161 22 7767 -3383 -31653 161 52 8340 9764 -30146 161 26 8985 15363 -27513 161 42 2443 6565 -32010 161 75 4029 19753 -25832 161 90 675 6317 -32145 161 19 -6881 18814 -25930 161 41 -11811 15901 -26102 161 23 -8826 10108 -29893 161 30 -4060 4703 -32173 161 32 -10894 8609 -29680 161 28 -18725 11062 -24509 161 13 -20310 73 -25714 161 84 -2496 -25 -32672 161 84 -9396 -3554 -31189 161 24 -9300 -5954 -30850 161 107 10717 -3141 -30805 161 53 18651 2917 -26783 161 70 4983 2533 -32287 161 37 13962 7721 -28620 161 38 -8204 17795 -26263 161 15 -15231 9829 -27296 161 67 -12154 2290 -30343 161 108 -17643 447 -27608 161 22 -13474 -375 -29866 161 52 -13450 -1005 -29862 161 22 -18969 -6070 -26019 161 16 -9551 -6145 -30736 161 29 14846 2923 -29064 161 42 7372 23479 -21635 161 38 -8222 3022 -31574 161 105 -13011 -4527 -29730 161 42 -5975 -4569 -31892 161 79 -14969 -13385 -25893 161 24 -79 -7828 -31818 161 80 10918 -742 -30886 161 66 3579 23206 -22855 162 80 -15769 12770 -25728 162 48 -22098 8574 -22623 162 67 -15728 -761 -28735 162 40 -18029 -3409 -27148 162 18 8465 17881 -26120 162 44 -21454 8674 -23198 162 15 -9773 1360 -31246 162 28 -5606 -3254 -32119 162 22 -9642 -9207 -29932 162 17 17693 9910 -25738 162 44 11521 6631 -29950 162 78 8820 20556 -23945 162 43 492 21220 -24963 162 14 -9610 16415 -26681 162 18 -11976 9005 -29141 162 92 -14667 7391 -28354 162 16 -19628 8328 -24881 162 96 -14901 1050 -29164 162 23 -9965 -4581 -30877 162 91 -13908 -12216 -27037 162 17 17195 4771 -27481 162 67 5992 2594 -32110 162 68 2985 18014 -27208 162 15 2318 22094 -24086 162 78 -2138 10763 -30875 162 86 -3521 15875 -28448 162 43 -6633 7249 -31259 162 30 -13390 12644 -27102 162 12 -9710 8303 -30174 162 83 -22567 8344 -22244 162 53 -23286 6786 -22032 162 16 -15912 4427 -28300 162 75 -20733 4317 -25004 162 73 -12969 -5314 -29618 162 26 -15833 -10447 -26718 162 22 -12884 -11291 -27932 162 71 17433 11163 -25400 162 61 14569 15963 -24630 162 76 4792 16413 -27952 162 42 -7994 16104 -27394 162 40 -10815 18642 -24681 162 15 -8265 11681 -29477 162 66 -5801 7378 -31394 162 68 -17097 10153 -26044 162 14 -19646 10964 -23822 162 21 -22999 3809 -23026 162 66 -23802 3731 -22208 162 11 5831 -1335 -32216 162 27 10412 1528 -31031 163 32 -22076 9581 -22238 163 76 -8112 2278 -31665 163 96 -20718 5063 -24876 163 19 12348 -2270 -30266 163 88 7536 12551 -29315 163 75 -7206 12841 -29272 163 15 -5622 5052 -31883 163 75 -13492 7512 -28900 163 18 -16054 6371 -27846 163 38 -16778 -9332 -26553 163 24 19019 3784 -26413 163 46 15020 13077 -26020 163 24 7918 8478 -30645 163 71 7178 8867 -30717 163 44 -2094 15301 -28899 163 12 -16984 11514 -25547 163 15 -19568 5230 -25756 163 29 -17988 -2252 -27295 163 66 7004 -3572 -31810 163 70 5951 -2301 -32140 163 89 9027 -2059 -31432 163 91 5790 3205 -32092 163 42 8690 20808 -23774 163 73 -17924 9095 -25878 163 78 -16877 8298 -26833 163 12 -15176 4121 -28747 163 17 -17604 -114 -27637 163 20 -11605 -2310 -30556 163 54 -15647 -5155 -28325 163 50 -17501 12666 -24636 163 34 -11108 -620 -30821 163 62 -16166 -9885 -26732 163 32 -9349 -10021 -29763 163 94 2256 -3079 -32544 163 30 15720 7060 -27870 164 101 1064 19063 -26630 164 90 -2578 15404 -28805 164 51 -2856 6410 -32007 164 106 -4964 10154 -30756 164 17 -22136 9707 -22124 164 70 -15486 -5681 -28312 164 42 -14878 -5607 -28651 164 20 -3951 -5606 -32041 164 80 -7422 -11418 -29803 164 31 4902 -3466 -32212 164 43 1863 14280 -29433 164 31 -2911 19812 -25936 164 75 -16013 11553 -26149 164 73 -14217 7962 -28428 164 29 -8277 3653 -31493 164 24 -11839 4895 -30159 164 20 -2979 809 -32621 164 26 -19301 -6889 -25567 164 20 386 2953 -32631 164 19 -10045 5976 -30611 164 15 -17004 9652 -26294 164 14 -15385 8708 -27589 164 76 -10561 -4308 -30718 164 21 -11675 -6640 -29888 164 73 -5986 -5982 -31655 164 18 7286 -6598 -31258 164 74 13105 3678 -29806 164 102 14993 14241 -25418 164 99 -7487 15543 -27857 164 73 -11221 12785 -28006 164 16 -15663 5312 -28286 164 50 -23219 4629 -22652 164 101 -13356 -1196 -29897 164 18 11174 2600 -30693 164 48 -14154 9376 -28026 164 43 -14770 7200 -28349 164 30 -15951 -586 -28616 164 107 -14126 -881 -29552 164 26 -9766 -699 -31270 164 20 -15367 -1916 -28876 164 83 -15278 -2383 -28889 164 56 -12979 -11078 -27973 164 43 -2234 -10585 -30930 164 73 15520 4041 -28574 165 25 -14792 5810 -28655 165 90 -11924 -329 -30518 165 82 -20435 -1027 -25594 165 61 -13322 -12112 -27377 165 76 12385 4329 -30026 165 22 16110 12805 -25498 165 46 -21208 -4733 -24526 165 22 -18835 -4384 -26452 165 76 8070 23350 -21525 165 93 -8206 14676 -28124 165 124 -15259 5085 -28548 165 22 -12519 -2144 -30205 165 23 -1645 -8582 -31580 165 20 9796 8474 -30098 165 46 -4857 20218 -25324 165 70 -11553 7567 -29714 165 24 -10163 3484 -30956 165 30 -21422 1385 -24756 165 78 -22314 319 -23992 165 40 -21387 -2510 -24697 165 54 -12862 -2263 -30052 165 18 4532 18525 -26645 165 97 2225 9297 -31341 165 20 3067 19794 -25932 165 24 -1457 14454 -29371 165 100 -1569 14367 -29407 165 14 -4671 17850 -27078 165 78 -10327 7814 -30099 165 88 -22247 9944 -21906 165 64 -9351 3201 -31241 165 44 -8272 1473 -31671 165 18 856 -4590 -32433 165 14 2851 9486 -31234 166 46 -8192 18693 -25635 166 24 -9397 16029 -26990 166 12 -7688 12254 -29401 166 17 -14306 12053 -26902 166 15 -9855 -10701 -29361 166 23 -8038 -9637 -30269 166 16 3886 5374 -32089 166 77 7231 16278 -27503 166 53 1714 6420 -32086 166 96 -1772 13437 -29833 166 36 -11991 13996 -27093 166 79 10660 15888 -26601 166 72 -7745 12799 -29153 166 15 -13241 14705 -26117 166 15 -12591 10246 -28463 166 94 -18478 8946 -25538 166 97 -7233 2798 -31836 166 80 -19961 4783 -25541 166 68 -13365 -1480 -29881 166 68 -13848 -11676 -27305 166 79 -10552 -11590 -28775 166 52 1311 12968 -30063 166 16 -22401 4308 -23523 166 40 1723 15703 -28707 166 62 -10473 18286 -25092 166 50 -7976 9182 -30426 166 95 -13238 11550 -27659 166 72 -20079 4779 -25449 166 78 -10329 -11574 -28863 166 115 19244 760 -26510 167 57 5575 2640 -32181 167 67 -8239 16115 -27315 167 70 -8120 14111 -28436 167 17 -14455 12378 -26675 167 90 -5682 1725 -32224 167 93 -3923 326 -32530 167 74 -13559 -348 -29828 167 31 -2186 -245 -32693 167 74 -11331 -2104 -30673 167 59 -14003 -4542 -29274 167 42 5892 -1062 -32215 167 66 -10475 18286 -25091 167 50 -4697 8196 -31376 167 27 -11712 15059 -26641 167 86 -11345 13434 -27649 167 30 -7355 -3398 -31749 167 20 -14160 -8929 -28168 167 22 10500 -3346 -30858 167 24 824 19809 -26089 167 58 -8967 5380 -31054 167 16 -15878 7082 -27774 167 96 -10199 2192 -31062 167 88 -5781 1056 -32236 167 33 -6479 -394 -32118 167 82 115 -4849 -32406 167 95 539 14337 -29459 167 63 -11361 14859 -26904 167 60 -10388 12466 -28467 167 20 -16750 5471 -27626 167 101 -12407 -1259 -30301 167 64 -10652 -7857 -29974 167 26 11864 6705 -29799 167 65 11346 8555 -29526 167 18 11181 22326 -21218 167 93 6953 14312 -28644 167 24 -1800 9343 -31355 167 68 -10238 9705 -29575 167 88 -17564 10515 -25585 167 12 -20713 -730 -25379 167 18 -10768 -3677 -30728 167 80 -12408 -5369 -29848 167 19 6725 12564 -29506 168 52 -5864 11926 -29951 168 68 -9577 17455 -26025 168 20 -11921 12464 -27860 168 15 -15623 1970 -28735 168 46 -20870 -3117 -25068 168 43 3354 -2484 -32500 168 26 14039 16964 -24265 168 70 9437 21529 -22828 168 42 1624 22773 -23504 168 34 -5331 13055 -29578 168 98 -7476 16787 -27129 168 79 -13471 17370 -24300 168 12 -13762 14671 -25866 168 20 -6063 452 -32198 168 65 -16185 -10851 -26343 168 99 -13595 -9219 -28352 168 122 -7422 -11418 -29803 168 32 1427 -6738 -32035 168 50 2390 -4310 -32394 168 90 -13950 13579 -26357 168 16 -15098 7727 -28036 168 103 -16620 -3190 -28058 168 75 -12517 -7840 -29249 168 71 -12758 -10266 -28382 168 83 18825 3092 -26641 168 70 16698 5275 -27695 168 64 10524 7748 -30048 168 97 9507 12716 -28663 168 72 1528 2234 -32655 168 20 3711 12432 -30089 168 101 -1545 19781 -26077 168 93 -3812 16268 -28187 168 29 -13901 6980 -28839 168 15 -13552 3228 -29658 168 26 -9975 1756 -31162 168 22 -18660 -8992 -25389 168 103 6092 -3451 -32010 168 31 5063 -1072 -32356 168 95 13608 2193 -29727 168 83 5791 18630 -26326 168 50 -4862 21252 -24462 168 80 -9508 13844 -28136 168 40 -13347 7488 -28973 168 106 -15577 5570 -28284 168 24 -10403 -112 -31072 168 78 -17642 -2423 -27506 168 28 -15613 -7126 -27913 168 76 -14073 -8660 -28295 168 26 -3296 -2403 -32512 168 21 2154 18717 -26809 169 48 -1192 16728 -28150 169 50 -7355 15390 -27977 169 15 -14529 5970 -28757 169 108 -6935 1162 -32004 169 30 -19305 -5674 -25861 169 105 9505 22435 -21908 169 102 7027 19067 -25705 169 86 -10083 17758 -25625 169 32 -11621 17329 -25265 169 94 -12584 12068 -27743 169 32 -8913 -145 -31531 169 82 -6350 -9085 -30835 169 24 13890 20613 -21350 169 73 235 19523 -26315 169 94 -154 16335 -28405 169 99 -4587 17546 -27291 169 40 -13368 -10140 -28145 169 27 19 -2733 -32653 169 42 2368 -1783 -32633 169 90 12889 -1862 -30068 169 94 10335 16960 -26062 169 28 4746 13975 -29255 169 74 -1560 14573 -29306 169 53 -3831 18546 -26741 169 63 -5874 20062 -25233 169 50 -14793 9822 -27538 169 15 -10169 3475 -30955 169 32 -3371 11339 -30557 169 72 -346 1665 -32723 169 41 -12566 15143 -26200 169 15 -18518 -9058 -25470 169 14 -5788 -3938 -32010 169 91 4546 -3384 -32273 169 22 12575 -2776 -30130 169 68 -1771 17007 -27952 170 26 -15698 14416 -24888 170 29 -15833 9798 -26963 170 13 -6478 -2790 -31999 170 44 -656 -842 -32750 170 35 7957 554 -31781 170 70 12179 18200 -24374 170 71 3864 19716 -25885 170 80 -870 21236 -24939 170 46 -8156 -1410 -31704 170 24 -13539 -7839 -28791 170 36 -684 -9982 -31202 170 44 "
16+text Sdflux "9877139 9432595 9008058 8602629 8215447 7845691 7492576 7155355 6833311 6525761 6232054 5951565 5683700 5427892 5183596 4950296 4727496 4514724 4311528 4117477 3932160 3755184 3586173 3424768 3270628 3123426 2982848 2848598 2720390 2597952 2481025 2369361 2262722 2160883 2063627 1970748 1882050 1797344 1716450 1639197 1565421 1494966 1427681 1363425 1302061 1243458 1187493 1134047 1083007 1034263 987714 943259 900806 860263 821545 784569 749258 715535 683331 652576 623205 595156 568370 542789 518360 495030 472750 451472 431153 411748 393216 375518 358617 342477 327063 312343 298285 284860 272039 259795 248103 236936 226272 216088 206363 197075 188205 179734 171645 163920 156542 149497 142768 136342 130206 124346 118749 113405 108301 103426 98771 94326 90081 86026 82154 78457 74926 71554 68333 65258 62321 59516 56837 54279 51836 49503 47275 45147 43115 41175 39322 37552 35862 34248 32706 31234 29828 28486 27204 25980 24810 23694 22627 21609 20636 19707 18821 17973 17165 16392 15654 14950 14277 13634 13021 12435 11875 11340 10830 10343 9877 9433 9008 8603 8215 7846 7493 7155 6833 6526 6232 5952 5684 5428 5184 4950 4727 4515 4312 4117 3932 3755 3586 3425 3271 3123 2983 2849 2720 2598 2481 2369 2263 2161 2064 1971 1882 1797 1716 1639 1565 1495 1428 1363 1302 1243 1187 1134 1083 1034 988 943 901 860 822 785 749 716 683 653 623 595 568 543 518 495 473 451 431 412 393 376 359 342 327 312 298 285 272 260 248 237 226 216 206 197 188 180 172 164 157 149 143 136 130 124 119 113 108 103 99 94 90 86 82 78 "
17+text Sdpal "1623 2156 4096 1657 2185 4096 1691 2215 4096 1727 2245 4096 1763 2276 4096 1801 2307 4096 1839 2339 4096 1878 2371 4096 1918 2403 4096 1959 2436 4096 2000 2469 4096 2043 2503 4096 2087 2537 4096 2131 2572 4096 2177 2607 4096 2224 2643 4096 2272 2679 4096 2321 2715 4096 2371 2752 4096 2422 2790 4096 2474 2828 4096 2528 2867 4096 2582 2906 4096 2638 2945 4096 2695 2985 4096 2754 3026 4096 2813 3067 4096 2874 3109 4096 2937 3151 4096 3001 3194 4096 3066 3237 4096 3132 3281 4096 3201 3325 4096 3270 3371 4096 3341 3416 4096 3414 3462 4096 3488 3509 4096 3564 3557 4096 3642 3605 4096 3721 3654 4096 3802 3703 4096 3885 3753 4096 3970 3804 4096 4056 3855 4096 4096 3861 4048 4096 3830 3962 4096 3799 3877 4096 3768 3795 4096 3738 3714 4096 3708 3635 4096 3677 3557 4096 3648 3482 4096 3618 3408 4096 3589 3335 4096 3560 3264 4096 3531 3194 4096 3502 3126 4096 3474 3060 4096 3446 2995 4096 3418 2931 4096 3390 2869 4096 3363 2808 4096 3336 2748 4096 3309 2689 4096 3282 2632 4096 3256 2576 4096 3230 2521 4096 3204 2468 4096 3178 2415 4096 3153 2364 4096 3127 2313 4096 3102 2264 4096 3078 2216 4096 3053 2169 4096 3029 2123 4096 3004 2077 4096 2981 2033 4096 2957 1990 4096 2933 1947 4096 2910 1906 4096 2887 1865 4096 2864 1825 4096 2841 1786 4096 2819 1748 4096 2797 1711 4096 2775 1674 4096 2753 1638 4096 2731 1603 4096 2710 1569 4096 2689 1535 4096 2667 1502 4096 2647 1470 4096 2626 1438 4096 2605 1407 4096 2585 1377 4096 2565 1347 4096 2545 1318 4096 2525 1290 4096 2506 1262 4096 2486 1234 4096 2467 1208 4096 2448 1181 4096 2429 1156 4096 2410 1131 4096 2392 1106 4096 2373 1082 4096 2355 1058 4096 2337 1035 4096 2319 1012 4096 2301 990 4096 2284 968 4096 2266 947 4096 2249 926 4096 2232 905 4096 2215 885 4096 2198 865 4096 2181 846 4096 2165 827 4096 2148 809 4096 2132 790 4096 2116 773 4096 2100 755 4096 2084 738 4096 2068 721 4096 2053 705 4096 2037 689 4096 2022 673 4096 2007 658 "
18+text Sdgal "1794 11195 -30743 3732 3257 23970 16775162 9419 2207 -31306 1905 1255 58867 16644351 "
19+const SKNST ulong 1035
20+const SKNGAL ulong 2
21+global Skview long 14
22+global Skstar long 3105
23+global Skmag ulong 1035
24+global Skbv ulong 1035
25+global Skflux ulong 256
26+global Skpal ulong 384
27+global Skgal long 14
28+global Skrdy ulong 1
29+global Sdbuf uchar 65536
30+global Sdpos ulong 1
31+fn sdnext to long
32+p = get Sdpos 0
33+while eq get Sdbuf p 32 bound 64
34+p = add p 1
35+end
36+m = false
37+if eq get Sdbuf p 45
38+m = true
39+p = add p 1
40+end
41+v = long 0
42+b = ulong get Sdbuf p
43+while and ge b 48 le b 57 bound 20
44+v = add mul v 10 long sub b 48
45+p = add p 1
46+b = ulong get Sdbuf p
47+end
48+put Sdpos 0 p
49+if m
50+ret neg v
51+end
52+ret v
53+end
54+fn skdview to void
55+n = len Sdview
56+for i ulong n
57+put Sdbuf i get Sdview i
58+end
59+put Sdbuf n 0
60+put Sdpos 0 0
61+for i ulong 14
62+put Skview i sdnext
63+end
64+end
65+fn skdstars to void
66+n = len Sdstars
67+for i ulong n
68+put Sdbuf i get Sdstars i
69+end
70+put Sdbuf n 0
71+put Sdpos 0 0
72+for i ulong SKNST
73+j = mul i 3
74+put Skstar j sdnext
75+put Skstar add j 1 sdnext
76+put Skstar add j 2 sdnext
77+put Skmag i ulong sdnext
78+put Skbv i ulong sdnext
79+end
80+end
81+fn skdflux to void
82+n = len Sdflux
83+for i ulong n
84+put Sdbuf i get Sdflux i
85+end
86+put Sdbuf n 0
87+put Sdpos 0 0
88+for i ulong 256
89+put Skflux i ulong sdnext
90+end
91+end
92+fn skdpal to void
93+n = len Sdpal
94+for i ulong n
95+put Sdbuf i get Sdpal i
96+end
97+put Sdbuf n 0
98+put Sdpos 0 0
99+for i ulong 384
100+put Skpal i ulong sdnext
101+end
102+end
103+fn skdgal to void
104+n = len Sdgal
105+for i ulong n
106+put Sdbuf i get Sdgal i
107+end
108+put Sdbuf n 0
109+put Sdpos 0 0
110+for i ulong 14
111+put Skgal i sdnext
112+end
113+end
114+fn skinit to void
115+if ne get Skrdy 0 0
116+ret
117+end
118+put Skrdy 0 1
119+skdview
120+skdstars
121+skdflux
122+skdpal
123+skdgal
124+end

aienux/allen/look-stat.om

new file mode 100644
@@ -0,0 +1,215 @@
1+note SPDX-License-Identifier: MIT
2+note Allen's look, the stopwatch: what a second of frames costs on the machine that runs the show.
3+note look-show.om stamps three clocks a frame (before the decision, after compose and conversion,
4+note after the blit); once a second the sums become one line
5+note STAT net=<network ready> e=<last firmware error> h=<SNP handles> l=<locate status>
6+note c=<efi 8 scans> p=<probe step per handle, hex> m=<adapter MAC, hex> s=<second>
7+note t=<ms into the show> f=<frames> cc=<compose+convert ms> bl=<blit ms>
8+note r=<rectangles> px=<pixels composed> full=<full redraws> max=<slowest frame ms>
9+note lens=<w>x<h> rip=<ripple radius> kb=<KiB blitted>
10+note The network fields come first so the 159-byte answer view never cuts them off.
11+note sent as one datagram to the courier's port (the relay drops anything that is not courier
12+note wire; tcpdump on the Spark reads it) and kept as Allen's answer to the typed line `stats`.
13+note Stw: 0 second start ms, 1 frames, 2 compose+convert ms, 3 blit ms, 4 rectangles, 5 pixels,
14+note 6 full redraws, 7 slowest frame ms, 8 seconds counted, 9 a line waits in Stt for the wire,
15+note 10 bytes blitted.
16+global Stw ulong 16
17+global Stv ulong 16
18+global Stt uchar 256
19+global Sttn ulong 1
20+global Stdig uchar 24
21+global Stn ulong 8
22+text Stfmt "STAT % s=# t=# f=# cc=# bl=# r=# px=# full=# max=# lens=#x# rip=# kb=#"
23+text Stnetf "net=# e=# h=# l=# c=# p=% m=%"
24+text Stkey "stats"
25+fn stput c uchar to void
26+n = get Sttn 0
27+if lt n len Stt
28+put Stt n c
29+put Sttn 0 add n 1
30+end
31+end
32+fn stnum v ulong to void
33+n = ulong 0
34+while gt v 9 bound 24
35+put Stdig n uchar rem v 10
36+v = div v 10
37+n = add n 1
38+end
39+put Stdig n uchar v
40+n = add n 1
41+for i ulong n
42+stput add uchar 48 get Stdig sub sub n 1 i
43+end
44+end
45+fn stdiff a ulong b ulong to ulong
46+note b - a, 0 when the clock failed or went backwards.
47+if or lt b a eq b 18446744073709551615
48+ret 0
49+end
50+ret sub b a
51+end
52+fn sthex v ulong to void
53+note One lowercase hex digit of v (0..15).
54+if lt v 10
55+stput add uchar 48 uchar v
56+else
57+stput add uchar 87 uchar v
58+end
59+end
60+fn stprobe h ulong to void
61+note One efi 8 probe step per SNP handle (Es 15), handle 0 first; at most 16, at least one digit.
62+note 0 not reached, 1 no Mode, 2 MAC size, 3 IfType, 4 Start, 5 Initialize, 6 GetStatus, 7 state,
63+note 8 no link (kept initialized), 9 filter mask, a ReceiveFilters, b not opened, e chosen without
64+note link detection, f chosen with a link.
65+n = h
66+if gt n 16
67+n = ulong 16
68+end
69+if eq n 0
70+n = ulong 1
71+end
72+v = get Es 15
73+for i ulong n
74+sthex and shr v mul i 4 15
75+end
76+end
77+fn stnet to void
78+note Stnetf from Es (efi-main.om efnetup): network ready, last firmware error, then efi 8's
79+note handles, LocateHandleBuffer status, scans, probe steps and the adapter's MAC (Nmac).
80+d = get Es 14
81+put Stn 0 get Es 6
82+put Stn 1 get Es 12
83+put Stn 2 and d 255
84+put Stn 3 and shr d 8 255
85+put Stn 4 and shr d 16 65535
86+k = ulong 0
87+for i ulong len Stnetf
88+c = get Stnetf i
89+if eq c 35
90+stnum get Stn k
91+k = add k 1
92+else
93+if eq c 37
94+if eq k 5
95+stprobe get Stn 2
96+else
97+for j ulong 6
98+b = ulong get Nmac j
99+sthex shr b 4
100+sthex and b 15
101+end
102+end
103+k = add k 1
104+else
105+stput c
106+end
107+end
108+end
109+end
110+fn stline to void
111+note Stfmt with every # replaced by the next value of Stv and % by the network fields.
112+put Sttn 0 0
113+k = ulong 0
114+for i ulong len Stfmt
115+c = get Stfmt i
116+if eq c 35
117+stnum get Stv k
118+k = add k 1
119+else
120+if eq c 37
121+stnet
122+else
123+stput c
124+end
125+end
126+end
127+end
128+fn stsecond now ulong t ulong to void
129+put Stw 8 add get Stw 8 1
130+put Stv 0 get Stw 8
131+put Stv 1 t
132+put Stv 2 get Stw 1
133+put Stv 3 get Stw 2
134+put Stv 4 get Stw 3
135+put Stv 5 get Stw 4
136+put Stv 6 get Stw 5
137+put Stv 7 get Stw 6
138+put Stv 8 get Stw 7
139+put Stv 9 ulong pkmax get Ntlens 2 0
140+put Stv 10 ulong pkmax get Ntlens 3 0
141+put Stv 11 ulong pkmax get Ntrip 0 0
142+put Stv 12 div get Stw 10 1024
143+stline
144+put Stw 9 1
145+for i ulong 8
146+put Stw i 0
147+end
148+put Stw 0 now
149+put Stw 10 0
150+end
151+fn stframe t0 ulong t1 ulong t2 ulong t ulong px ulong rf ulong to void
152+note One frame: t0 before the decision, t1 after compose and conversion, t2 after the blit;
153+note t is the show's clock, px the pixels composed, rf twice the rectangles plus 1 for a
154+note whole-screen redraw (six parameters is the language's limit).
155+if eq get Stw 0 0
156+put Stw 0 t0
157+end
158+put Stw 1 add get Stw 1 1
159+put Stw 2 add get Stw 2 stdiff t0 t1
160+put Stw 3 add get Stw 3 stdiff t1 t2
161+put Stw 4 add get Stw 4 shr rf 1
162+put Stw 5 add get Stw 5 px
163+put Stw 6 add get Stw 6 and rf 1
164+d = stdiff t0 t2
165+if gt d get Stw 7
166+put Stw 7 d
167+end
168+if ge t2 add get Stw 0 1000
169+stsecond t2 t
170+end
171+end
172+fn ststep up bool to void
173+note Offer the waiting line to the wire when the network is up and nothing is in flight; the
174+note courier's own datagrams are offered again on their clock, so one frame of delay is harmless.
175+if or eq get Stw 9 0 not up
176+ret
177+end
178+if ne get Ntxlen 0 0
179+ret
180+end
181+n = get Sttn 0
182+if or eq n 0 gt n 1472
183+put Stw 9 0
184+ret
185+end
186+ntxzero
187+for i ulong n
188+put Ntx add 42 i get Stt i
189+end
190+nudp 4294967295 47033 47033 n true
191+nqueue 7 add 42 n
192+put Stw 9 0
193+end
194+fn stasked to bool
195+note True when the typed line is `stats`: the last line becomes what Allen says.
196+n = get Hminn 0
197+if ne n len Stkey
198+ret false
199+end
200+for i ulong n
201+if ne get Hmin i get Stkey i
202+ret false
203+end
204+end
205+n = get Sttn 0
206+if gt n len Hmsay
207+n = len Hmsay
208+end
209+for i ulong n
210+put Hmsay i get Stt i
211+end
212+put Hmsayn 0 n
213+hmsaid
214+ret true
215+end

aienux/allen/main.om

new file mode 100644
@@ -0,0 +1,146 @@
1+note Development stdio boundary. Lines ASK, SAY, WAIT, CODE, CANCEL, RESET,
2+note and TIME milliseconds. stdout courier jobs; stderr actual visible text.
3+note No socket, clock, model, framebuffer, keyboard, filesystem or EFI provider.
4+global Input uchar 8192
5+global Lstate ulong 3
6+fn sendout fd int to bool
7+p = ulong 0
8+while lt p get Outlen 0
9+w = write fd Outb p sub get Outlen 0 p
10+if le w 0
11+ret false
12+end
13+p = add p ulong w
14+end
15+ret true
16+end
17+fn display to bool
18+outreset
19+for i ulong get R 8
20+emitb get Answer i
21+end
22+emitb 10
23+ret sendout 2
24+end
25+text Cmds "CANCELRESET"
26+fn isword off ulong size ulong to bool
27+if ne get Inlen 0 size
28+ret false
29+end
30+for i ulong size
31+if ne get In i get Cmds add off i
32+ret false
33+end
34+end
35+ret true
36+end
37+fn dispatch to bool
38+if isword 0 6
39+cancel
40+ret true
41+end
42+if isword 6 5
43+reset
44+ret true
45+end
46+if and ineq 0 84 ineq 1 73
47+put P 0 5
48+put P 2 0
49+number
50+if or ne get P 2 0 ne get P 0 get Inlen 0
51+ret false
52+end
53+if lt get P 1 get Lstate 2
54+ret false
55+end
56+put Lstate 2 get P 1
57+v = tick get Lstate 2
58+ret true
59+end
60+if ineq 0 67
61+if codetake
62+b = heard get C 0 get Lstate 2
63+ret true
64+end
65+ret false
66+end
67+if or ineq 0 83 ineq 0 87
68+v = saytake get Lstate 2
69+if eq v 1
70+if ne get S 1 0
71+ret display
72+end
73+ret true
74+end
75+if eq v 2
76+emitb 10
77+ret sendout 1
78+end
79+ret false
80+end
81+if and ineq 0 65 ineq 1 83
82+if not and ineq 2 75 ineq 3 32
83+ret false
84+end
85+n = sub get Inlen 0 4
86+for i ulong n
87+put In i get In add i 4
88+end
89+put Inlen 0 n
90+kind = classify
91+if not start kind get Lstate 2
92+ret false
93+end
94+if gt kind 1
95+codebeg get R 0
96+b = display
97+end
98+if not jobbuild kind get R 0
99+cancel
100+ret false
101+end
102+emitb 10
103+ret sendout 1
104+end
105+ret false
106+end
107+fn main to int
108+constants
109+while true
110+n = read 0 Input 0 len Input
111+if lt n 0
112+ret 2
113+end
114+if eq n 0
115+if ne get Lstate 0 0
116+ret 65
117+end
118+ret 0
119+end
120+for i ulong ulong n
121+c = get Input i
122+if eq c 10
123+if eq get Lstate 1 0
124+put Inlen 0 get Lstate 0
125+b = dispatch
126+if not b
127+put Lstate 0 0
128+ret 65
129+end
130+else
131+put Lstate 1 0
132+end
133+put Lstate 0 0
134+else
135+if lt get Lstate 0 8192
136+put In get Lstate 0 c
137+put Lstate 0 add get Lstate 0 1
138+else
139+note Refuse immediately: no silent discard and no later command execution.
140+ret 65
141+end
142+end
143+end
144+end
145+ret 0
146+end

aienux/allen/memory.om

new file mode 100644
@@ -0,0 +1,451 @@
1+note Legacy application record codec; SHA is unkeyed integrity ONLY.
2+global Unit uchar 4096
3+global Enc uchar 4096
4+global Mem uchar 3692
5+global Md ulong 3
6+global Note uchar 128
7+global Ns ulong 4
8+text Magic "AIENALM1"
9+text Nmagic "AIENNOT1"
10+fn get32 off ulong to ulong
11+v = ulong 0
12+for i ulong 4
13+v = or v shl ulong get Unit add off i mul i 8
14+end
15+ret v
16+end
17+fn get64 off ulong to ulong
18+ret or get32 off shl get32 add off 4 32
19+end
20+fn put32 off ulong v ulong to void
21+for i ulong 4
22+put Unit add off i uchar and shr v mul i 8 255
23+end
24+end
25+fn put64 off ulong v ulong to void
26+put32 off and v 4294967295
27+put32 add off 4 shr v 32
28+end
29+fn mem32 off ulong to ulong
30+v = ulong 0
31+for i ulong 4
32+v = or v shl ulong get Mem add off i mul i 8
33+end
34+ret v
35+end
36+fn mset32 off ulong v ulong to void
37+for i ulong 4
38+put Mem add off i uchar and shr v mul i 8 255
39+end
40+end
41+fn zeroend off ulong to bool
42+for i ulong sub ulong 4096 off
43+if ne get Unit add off i 0
44+ret false
45+end
46+end
47+ret true
48+end
49+fn fieldok off ulong cap ulong name bool to bool
50+n = ulong 0
51+while lt n cap
52+if eq get Unit add off n 0
53+for j ulong sub cap n
54+if ne get Unit add add off n j 0
55+ret false
56+end
57+end
58+ret true
59+end
60+c = get Unit add off n
61+lower = and ge c 97 le c 122
62+digit = isdigit c
63+if name
64+if eq n 0
65+if not or and ge c 65 le c 90 digit
66+ret false
67+end
68+else
69+if not or lower digit
70+ret false
71+end
72+end
73+else
74+if eq c 32
75+if or eq n 0 eq n sub cap 1
76+ret false
77+end
78+if eq get Unit add off add n 1 0
79+ret false
80+end
81+if eq get Unit add off sub n 1 32
82+ret false
83+end
84+else
85+if not or lower digit
86+ret false
87+end
88+end
89+end
90+n = add n 1
91+end
92+ret false
93+end
94+fn digest count ulong to void
95+hinit
96+for i ulong 32
97+hbyte get Unit i
98+end
99+for i ulong count
100+hbyte get Unit add i 64
101+end
102+finish
103+end
104+fn hashok count ulong to bool
105+digest count
106+d = uchar 0
107+for i ulong 32
108+d = or d xor get Hash i get Unit add i 32
109+end
110+ret eq d 0
111+end
112+fn seal count ulong to void
113+digest count
114+for i ulong 32
115+put Unit add i 32 get Hash i
116+end
117+end
118+fn memvalid to bool
119+for i ulong 8
120+if ne get Unit i get Magic i
121+ret false
122+end
123+end
124+ver = get32 8
125+if or lt ver 2 gt ver 4
126+ret false
127+end
128+n = get32 96
129+if or gt n 32 gt get32 100 512
130+ret false
131+end
132+size = add 40 mul n 113
133+if ge ver 3
134+size = add size 24
135+end
136+if eq ver 4
137+size = add size 12
138+end
139+if or ne size get32 12 eq get64 16 0
140+ret false
141+end
142+for i ulong 8
143+if ne get Unit add i 24 0
144+ret false
145+end
146+end
147+if not zeroend add 64 size
148+ret false
149+end
150+if not hashok size
151+ret false
152+end
153+if not fieldok 72 24 true
154+ret false
155+end
156+for i ulong n
157+off = add 104 mul i 113
158+if or eq get Unit off 0 eq get Unit add off 48 0
159+ret false
160+end
161+if not fieldok off 48 false
162+ret false
163+end
164+if not fieldok add off 48 64 false
165+ret false
166+end
167+if gt get Unit add off 112 1
168+ret false
169+end
170+end
171+off = add 104 mul n 113
172+if ge ver 3
173+if not fieldok off 24 true
174+ret false
175+end
176+end
177+if eq ver 4
178+if ne get Unit add off 27 0
179+ret false
180+end
181+end
182+ret true
183+end
184+fn memdec to bool
185+if not memvalid
186+ret false
187+end
188+size = get32 12
189+for i ulong 3692
190+put Mem i 0
191+end
192+for i ulong size
193+put Mem i get Unit add i 64
194+end
195+put Md 0 get64 16
196+put Md 1 get32 8
197+put Md 2 size
198+ret true
199+end
200+fn memenc gen ulong to bool
201+n = mem32 32
202+if or gt n 32 eq gen 0
203+ret false
204+end
205+size = add 76 mul n 113
206+for i ulong 4096
207+put Unit i 0
208+end
209+for i ulong 8
210+put Unit i get Magic i
211+end
212+put32 8 4
213+put32 12 size
214+put64 16 gen
215+for i ulong size
216+put Unit add i 64 get Mem i
217+end
218+seal size
219+if not memvalid
220+ret false
221+end
222+for i ulong 4096
223+put Enc i get Unit i
224+end
225+ret true
226+end
227+fn noteval index ulong to bool
228+for i ulong 8
229+if ne get Unit i get Nmagic i
230+ret false
231+end
232+end
233+n = get32 12
234+if or eq n 0 ge n 128
235+ret false
236+end
237+if or ne get32 8 1 ne get32 16 index
238+ret false
239+end
240+if or gt get32 24 1 ne get32 28 0
241+ret false
242+end
243+if not zeroend add n 64
244+ret false
245+end
246+for i ulong n
247+c = get Unit add i 64
248+if or lt c 32 gt c 126
249+ret false
250+end
251+end
252+ret hashok n
253+end
254+fn notedec index ulong to bool
255+if not noteval index
256+ret false
257+end
258+n = get32 12
259+for i ulong 128
260+put Note i 0
261+end
262+for i ulong n
263+put Note i get Unit add i 64
264+end
265+put Ns 0 n
266+put Ns 1 index
267+put Ns 2 get32 20
268+put Ns 3 get32 24
269+ret true
270+end
271+fn noteenc to bool
272+n = get Ns 0
273+if or eq n 0 ge n 128
274+ret false
275+end
276+if or gt get Ns 1 511 gt get Ns 2 4294967295
277+ret false
278+end
279+if gt get Ns 3 1
280+ret false
281+end
282+for i ulong n
283+c = get Note i
284+if or lt c 32 gt c 126
285+ret false
286+end
287+end
288+for i ulong 4096
289+put Unit i 0
290+end
291+for i ulong 8
292+put Unit i get Nmagic i
293+end
294+put32 8 1
295+put32 12 n
296+put32 16 get Ns 1
297+put32 20 get Ns 2
298+put32 24 get Ns 3
299+for i ulong n
300+put Unit add i 64 get Note i
301+end
302+seal n
303+for i ulong 4096
304+put Enc i get Unit i
305+end
306+ret true
307+end
308+note Store St gen,newest,valid. Tx phase,target,newgen. Provider owns actual I/O.
309+global St ulong 3
310+global Nt ulong 2
311+global Load ulong 1
312+global Tx ulong 3
313+fn txbegin to bool
314+if ne get Nt 0 0
315+ret false
316+end
317+if or ne get Tx 0 0 eq get St 0 18446744073709551615
318+ret false
319+end
320+if not memenc add get St 0 1
321+ret false
322+end
323+put Tx 1 0
324+if ne get St 0 0
325+put Tx 1 sub ulong 1 get St 1
326+end
327+put Tx 2 add get St 0 1
328+put Tx 0 1
329+ret true
330+end
331+fn txwrite ok bool to bool
332+if ne get Tx 0 1
333+ret false
334+end
335+if not ok
336+put Tx 0 0
337+ret false
338+end
339+put Tx 0 2
340+ret true
341+end
342+fn txflush ok bool to bool
343+if ne get Tx 0 2
344+ret false
345+end
346+if not ok
347+put Tx 0 0
348+ret false
349+end
350+put Tx 0 3
351+ret true
352+end
353+fn txread ok bool to bool
354+if ne get Tx 0 3
355+ret false
356+end
357+put Tx 0 0
358+if not ok
359+ret false
360+end
361+d = uchar 0
362+for i ulong 4096
363+d = or d xor get Unit i get Enc i
364+end
365+if ne d 0
366+ret false
367+end
368+put St 0 get Tx 2
369+put St 1 get Tx 1
370+if lt get St 2 2
371+put St 2 add get St 2 1
372+end
373+ret true
374+end
375+note Load each copy once into Unit. Caller resets St and calls loadcopy0,1.
376+fn loadbeg to void
377+for i ulong 3
378+put St i 0
379+end
380+put Load 0 0
381+end
382+fn loadcopy slot ulong to bool
383+if gt slot 1
384+ret false
385+end
386+if ne and get Load 0 shl ulong 1 slot 0
387+ret false
388+end
389+if not memvalid
390+ret false
391+end
392+put Load 0 or get Load 0 shl ulong 1 slot
393+put St 2 add get St 2 1
394+if gt get64 16 get St 0
395+b = memdec
396+put St 0 get Md 0
397+put St 1 slot
398+end
399+ret true
400+end
401+note Note transaction completes before the parent copy may publish its count.
402+fn nbegin to bool
403+if or ne get Nt 0 0 ne get Tx 0 0
404+ret false
405+end
406+if not noteenc
407+ret false
408+end
409+put Nt 1 get Ns 1
410+put Nt 0 1
411+ret true
412+end
413+fn nwrite ok bool to bool
414+if ne get Nt 0 1
415+ret false
416+end
417+if not ok
418+put Nt 0 0
419+ret false
420+end
421+put Nt 0 2
422+ret true
423+end
424+fn nflush ok bool to bool
425+if ne get Nt 0 2
426+ret false
427+end
428+if not ok
429+put Nt 0 0
430+ret false
431+end
432+put Nt 0 3
433+ret true
434+end
435+fn nread ok bool to bool
436+if ne get Nt 0 3
437+ret false
438+end
439+put Nt 0 0
440+if not ok
441+ret false
442+end
443+d = uchar 0
444+for i ulong 4096
445+d = or d xor get Enc i get Unit i
446+end
447+if ne d 0
448+ret false
449+end
450+ret noteval get Nt 1
451+end

aienux/allen/net.om

new file mode 100644
@@ -0,0 +1,1845 @@
1+note Native bounded single HTTPS client. RFC826/791/768/2131/2132/1035/9293/6298.
2+note Caller provides Ethernet frames without FCS, checked monotonic milliseconds,
3+note six-byte unicast Nmac before netinit, and 32 fresh EFI entropy bytes in
4+note Nrand before every netconnect. netconnect consumes and wipes Nrand: DHCP xid,
5+note IPv4 id, DNS id/port, TCP port and ISN are never reused across connections.
6+note netwrite true transfers a copy, not a peer ACK. netsent is firmware acceptance.
7+note Public state 0idle 1DHCP 2DNS 3SYN 4open 5EOF/closed 6error.
8+note Errors: 1clock 2MAC/entropy 3DHCPtimeout 4DHCPnak 5config 6conflict
9+note 7ARPtimeout 8DNStimeout 9DNSrefused/truncated 10DNSinvalid/empty
10+note 11TCPtimeout 12peerreset 13unsupportedTCP 14leaseexpired 15transmit
11+note 16establishdeadline 17callerbounds. Invalid unrelated packets are ignored.
12+note Limits: untagged Ethernet MTU1500, IPv4 without options/fragments,
13+note DHCP lease without renewal, 120s establishment, DNS A/CNAME <=8 links,
14+note 64 DNS records/UDP message, one stop-and-wait TCP segment, receive64KiB.
15+note No DNS-over-TCP or EDNS: truncation fails; lease expiry fails explicitly.
16+note A bound lease is reused by later netconnect calls; anything else restarts DHCP.
17+note Internal Ncfg slots: now,dhcp,ip,mask,router,dns,server,offer,xid,leaseMS,
18+note leaseAt,initAt,dhcpDue,dhcpTries,probeCount,want,connectAt,generation,
19+note ipid,dnsid,dnsport,tcpport,dnsDue,dnsTries,cnameHops,qnameLen,
20+note arpWanted,arpCached,arpDue,arpTries,arpAt,initialized.
21+global Nrx uchar 2048
22+global Ntx uchar 2048
23+global Ntxlen ulong 1
24+global Nmac uchar 6
25+global Nrand uchar 32
26+global Tcpin uchar 65536
27+global Tcpout uchar 65536
28+global Tcpn ulong 1
29+global Tcpstate ulong 8
30+global Ncfg ulong 32
31+note Nct: una,next,rcvnxt,ringHead,peerwin,wl1,wl2,mss,ackPending,
32+note flightLen,flightKind(1syn2data3fin),flightSent,flightSeq,sentAt,rto,
33+note retries,sendTotal,sendOffset,closeWanted,finAcked,peerFin,finPending,
34+note finSeq,activity,timewaitAt,iss,srtt,rttvar,rttValid,zeroAt,synRetried.
35+global Nct ulong 32
36+global Nsbuf uchar 65536
37+global Nrbuf uchar 65536
38+global Nrmap uchar 65536
39+global Nhop uchar 6
40+global Narp uchar 6
41+global Napip ulong 1
42+note Queue kind 1DHCP 2ARPquery 3ARPreply 4DNS 5TCPflight 6TCPack 7courierUDP.
43+note Kind 7 (look-chat.om, netudpsend) is fire-and-forget: netsent only clears it,
44+note no retry bookkeeping; the courier scheduler resends on its own clock.
45+note Q1 failures Q2 queuedAt Q3 DHCP/ARP phase Q4 seq Q5 ack Q6 window Q7 generation.
46+global Nq ulong 8
47+note Parsed packet: frameLen,ipHlen,ipLen,src,dst,l4off,l4len,seq,ack,
48+note flags,dataOff,dataLen,window,tcpHlen.
49+global Npk ulong 16
50+note Ndrop: reason code of the last segment refused before the payload path. Diagnosis only.
51+global Ndrop ulong 1
52+note Ndropt/Ndropd/Ndropw: length, start offset and window of the last accepted segment.
53+global Ndropt ulong 1
54+global Ndropd ulong 1
55+global Ndropw ulong 1
56+global Nopt ulong 8
57+note DNS decoder base,end,next,nameLen,answerStart,answerCount,rrNext,rrData.
58+global Nd ulong 8
59+global Nname uchar 256
60+global Nwant uchar 256
61+global Nrr ulong 4
62+note Courier UDP hooks (look-chat.om): one datagram body out in Chtx, one in
63+note Chrx/Chrxn (0 = empty slot); a second arrival before chstep consumed the
64+note slot is dropped and counted in Chdrop. Port 47033 both ways, like the C
65+note kernel (x86/courier_udp.h CK_COURIER_PORT); source 0.0.0.0 before a lease.
66+global Chtx uchar 1600
67+global Chrx uchar 1600
68+global Chrxn ulong 1
69+global Chdrop ulong 1
70+text Nhost "api.github.com"
71+fn nr16 p ulong to ulong
72+ret add shl ulong get Nrx p 8 ulong get Nrx add p 1
73+end
74+fn nr32 p ulong to ulong
75+ret add shl nr16 p 16 nr16 add p 2
76+end
77+fn nt16 p ulong v ulong to void
78+put Ntx p uchar and shr v 8 255
79+put Ntx add p 1 uchar and v 255
80+end
81+fn nt32 p ulong v ulong to void
82+nt16 p shr v 16
83+nt16 add p 2 and v 65535
84+end
85+fn nadd a ulong b ulong to ulong
86+ret and add a b 4294967295
87+end
88+fn ndiff a ulong b ulong to ulong
89+ret and sub add a 4294967296 b 4294967295
90+end
91+fn nlt a ulong b ulong to bool
92+ret gt ndiff a b 2147483647
93+end
94+fn nfold s ulong to ulong
95+while gt s 65535 bound 8
96+s = add and s 65535 shr s 16
97+end
98+ret xor s 65535
99+end
100+fn nrsum p ulong n ulong to ulong
101+s = ulong 0
102+while ge n 2 bound 1024
103+s = add s nr16 p
104+p = add p 2
105+n = sub n 2
106+end
107+if eq n 1
108+s = add s shl ulong get Nrx p 8
109+end
110+ret s
111+end
112+fn ntsum p ulong n ulong to ulong
113+s = ulong 0
114+while ge n 2 bound 1024
115+s = add s shl ulong get Ntx p 8
116+s = add s ulong get Ntx add p 1
117+p = add p 2
118+n = sub n 2
119+end
120+if eq n 1
121+s = add s shl ulong get Ntx p 8
122+end
123+ret s
124+end
125+fn npssum a ulong b ulong proto ulong n ulong to ulong
126+s = add shr a 16 and a 65535
127+s = add s shr b 16
128+s = add s and b 65535
129+ret add add s proto n
130+end
131+fn nipok ip ulong to bool
132+if or eq ip 0 eq ip 4294967295
133+ret false
134+end
135+x = shr ip 24
136+ret and ne x 0 and ne x 127 lt x 224
137+end
138+fn nmacrx p ulong to bool
139+v = uchar 0
140+for i ulong 6
141+v = or v get Nrx add p i
142+end
143+ret and ne v 0 eq and get Nrx p 1 0
144+end
145+fn nmaceq p ulong to bool
146+for i ulong 6
147+if ne get Nrx add p i get Nmac i
148+ret false
149+end
150+end
151+ret true
152+end
153+fn nwipe to void
154+for i ulong 65536
155+put Tcpin i uchar 0
156+put Tcpout i uchar 0
157+put Nsbuf i uchar 0
158+put Nrbuf i uchar 0
159+put Nrmap i uchar 0
160+end
161+put Tcpn 0 0
162+end
163+fn nfail code ulong to void
164+put Tcpstate 0 6
165+put Tcpstate 1 code
166+put Ntxlen 0 0
167+for i ulong 2048
168+put Ntx i uchar 0
169+end
170+for i ulong 32
171+put Nrand i uchar 0
172+put Nct i 0
173+end
174+nwipe
175+end
176+fn nclock now ulong to bool
177+if or lt now get Ncfg 0 gt now 1000000000000000000
178+nfail 1
179+ret false
180+end
181+put Ncfg 0 now
182+ret true
183+end
184+fn ntxzero to void
185+for i ulong 1514
186+put Ntx i uchar 0
187+end
188+end
189+fn neth typ ulong broad bool to void
190+for i ulong 6
191+if broad
192+put Ntx i uchar 255
193+else
194+put Ntx i get Nhop i
195+end
196+put Ntx add i 6 get Nmac i
197+end
198+nt16 12 typ
199+end
200+fn nqueue kind ulong n ulong to void
201+if lt n 60
202+n = 60
203+end
204+put Ntxlen 0 n
205+put Nq 0 kind
206+put Nq 1 0
207+put Nq 2 get Ncfg 0
208+put Nq 7 get Ncfg 17
209+end
210+fn nipbuild dest ulong proto ulong n ulong broad bool to void
211+neth 2048 broad
212+put Ntx 14 uchar 69
213+nt16 16 add n 20
214+nt16 18 get Ncfg 18
215+put Ncfg 18 and add get Ncfg 18 1 65535
216+nt16 20 16384
217+put Ntx 22 uchar 64
218+put Ntx 23 uchar proto
219+nt32 26 get Ncfg 2
220+nt32 30 dest
221+nt16 24 nfold ntsum 14 20
222+end
223+fn nudp dest ulong srcp ulong dstp ulong n ulong broad bool to void
224+nt16 34 srcp
225+nt16 36 dstp
226+nt16 38 add n 8
227+s = npssum get Ncfg 2 dest 17 add n 8
228+s = nfold add s ntsum 34 add n 8
229+if eq s 0
230+s = 65535
231+end
232+nt16 40 s
233+nipbuild dest 17 add n 8 broad
234+end
235+note Courier datagram out: Chtx[0..n) to 255.255.255.255:47033 from Ncfg2:47033
236+note in a broadcast frame, queued as kind 7 only when nothing else is in flight.
237+note Error state 6 does not refuse it: the courier has no TCP, DHCP or DNS
238+note dependency, so Allen keeps answering after a failed repository session.
239+note false: not queued, the courier scheduler offers the same datagram again on
240+note its own clock.
241+fn netudpsend n ulong to bool
242+if ne get Ntxlen 0 0
243+ret false
244+end
245+if or eq n 0 gt n 1472
246+ret false
247+end
248+ntxzero
249+for i ulong n
250+put Ntx add 42 i get Chtx i
251+end
252+nudp 4294967295 47033 47033 n true
253+nqueue 7 add 42 n
254+ret true
255+end
256+fn narpout target ulong probe bool to void
257+ntxzero
258+neth 2054 true
259+nt16 14 1
260+nt16 16 2048
261+put Ntx 18 uchar 6
262+put Ntx 19 uchar 4
263+nt16 20 1
264+for i ulong 6
265+put Ntx add i 22 get Nmac i
266+end
267+if not probe
268+nt32 28 get Ncfg 2
269+end
270+nt32 38 target
271+put Nq 3 get Ncfg 1
272+nqueue 2 42
273+end
274+fn narprepl to void
275+ntxzero
276+neth 2054 false
277+for i ulong 6
278+put Ntx i get Narp i
279+put Ntx add i 32 get Narp i
280+put Ntx add i 22 get Nmac i
281+end
282+nt16 14 1
283+nt16 16 2048
284+put Ntx 18 uchar 6
285+put Ntx 19 uchar 4
286+nt16 20 2
287+nt32 28 get Ncfg 2
288+nt32 38 get Napip 0
289+put Napip 0 0
290+nqueue 3 42
291+end
292+fn nroute dest ulong to bool
293+if ne and dest get Ncfg 3 and get Ncfg 2 get Ncfg 3
294+dest = get Ncfg 4
295+end
296+if eq dest 0
297+nfail 5
298+ret false
299+end
300+if eq get Ncfg 27 dest
301+if lt sub get Ncfg 0 get Ncfg 30 60000
302+ret true
303+end
304+put Ncfg 27 0
305+end
306+if ne get Ncfg 26 dest
307+put Ncfg 26 dest
308+put Ncfg 29 0
309+put Ncfg 28 get Ncfg 0
310+end
311+if ge get Ncfg 0 get Ncfg 28
312+if ge get Ncfg 29 5
313+nfail 7
314+ret false
315+end
316+narpout dest false
317+end
318+ret false
319+end
320+fn ndhcpout to void
321+ntxzero
322+put Ntx 42 uchar 1
323+put Ntx 43 uchar 1
324+put Ntx 44 uchar 6
325+nt32 46 get Ncfg 8
326+nt16 50 div sub get Ncfg 0 get Ncfg 11 1000
327+nt16 52 32768
328+for i ulong 6
329+put Ntx add i 70 get Nmac i
330+end
331+nt32 278 1669485411
332+put Ntx 282 uchar 53
333+put Ntx 283 uchar 1
334+mt = uchar 1
335+if eq get Ncfg 1 2
336+mt = 3
337+end
338+if eq get Ncfg 1 5
339+mt = 4
340+end
341+put Ntx 284 mt
342+p = ulong 285
343+if ne mt 1
344+put Ntx p uchar 50
345+put Ntx add p 1 uchar 4
346+nt32 add p 2 get Ncfg 7
347+put Ntx add p 6 uchar 54
348+put Ntx add p 7 uchar 4
349+nt32 add p 8 get Ncfg 6
350+p = add p 12
351+end
352+put Ntx p uchar 61
353+put Ntx add p 1 uchar 7
354+put Ntx add p 2 uchar 1
355+for i ulong 6
356+put Ntx add add p 3 i get Nmac i
357+end
358+p = add p 9
359+note RFC2131 table 5: DHCPDECLINE carries no parameter list or size option.
360+if ne mt 4
361+put Ntx p uchar 55
362+put Ntx add p 1 uchar 6
363+put Ntx add p 2 uchar 1
364+put Ntx add p 3 uchar 3
365+put Ntx add p 4 uchar 6
366+put Ntx add p 5 uchar 51
367+put Ntx add p 6 uchar 58
368+put Ntx add p 7 uchar 59
369+put Ntx add p 8 uchar 57
370+put Ntx add p 9 uchar 2
371+nt16 add p 10 1472
372+p = add p 12
373+end
374+put Ntx p uchar 255
375+p = add p 1
376+if lt p 342
377+p = 342
378+end
379+nudp 4294967295 68 67 sub p 42 true
380+put Nq 3 get Ncfg 1
381+nqueue 1 p
382+end
383+fn ndnsout to void
384+ntxzero
385+nt16 42 get Ncfg 19
386+nt16 44 256
387+nt16 46 1
388+for i ulong get Ncfg 25
389+put Ntx add i 54 get Nwant i
390+end
391+p = add 54 get Ncfg 25
392+nt16 p 1
393+nt16 add p 2 1
394+nudp get Ncfg 5 get Ncfg 20 53 sub add p 4 42 false
395+nqueue 4 add p 4
396+end
397+fn nwindow to ulong
398+ret sub 65535 get Tcpn 0
399+end
400+fn ntcpout flight bool to void
401+ntxzero
402+nt16 34 get Ncfg 21
403+nt16 36 443
404+nt32 38 get Nct 1
405+nt32 42 get Nct 2
406+put Ntx 46 uchar 80
407+put Ntx 47 uchar 16
408+nt16 48 nwindow
409+n = ulong 20
410+if flight
411+nt32 38 get Nct 12
412+if eq get Nct 10 1
413+put Ntx 46 uchar 96
414+put Ntx 47 uchar 2
415+nt32 42 0
416+put Ntx 54 uchar 2
417+put Ntx 55 uchar 4
418+nt16 56 1460
419+n = 24
420+else
421+if eq get Nct 10 3
422+put Ntx 47 uchar 17
423+else
424+put Ntx 47 uchar 24
425+n = add n get Nct 9
426+for i ulong get Nct 9
427+put Ntx add i 54 get Nsbuf add get Nct 17 i
428+end
429+end
430+end
431+end
432+s = npssum get Ncfg 2 get Tcpstate 2 6 n
433+nt16 50 nfold add s ntsum 34 n
434+nipbuild get Tcpstate 2 6 n false
435+put Nq 4 get Nct 12
436+put Nq 5 get Nct 2
437+put Nq 6 nwindow
438+if flight
439+nqueue 5 add n 34
440+else
441+nqueue 6 add n 34
442+end
443+end
444+note DHCP option fields are parsed atomically before changing lease state.
445+fn ndopt code ulong p ulong n ulong to bool
446+slot = ulong 8
447+if eq code 53
448+slot = 0
449+end
450+if eq code 54
451+slot = 1
452+end
453+if eq code 1
454+slot = 2
455+end
456+if eq code 3
457+slot = 3
458+end
459+if eq code 6
460+slot = 4
461+end
462+if eq code 51
463+slot = 5
464+end
465+if eq code 52
466+slot = 7
467+end
468+if eq slot 8
469+ret true
470+end
471+if ne and get Nopt 6 shl ulong 1 slot 0
472+ret false
473+end
474+put Nopt 6 or get Nopt 6 shl ulong 1 slot
475+if or eq slot 0 eq slot 7
476+if ne n 1
477+ret false
478+end
479+put Nopt slot ulong get Nrx p
480+ret true
481+end
482+if or eq slot 3 eq slot 4
483+if or lt n 4 ne rem n 4 0
484+ret false
485+end
486+else
487+if ne n 4
488+ret false
489+end
490+end
491+put Nopt slot nr32 p
492+ret true
493+end
494+fn ndopts p ulong stop ulong to bool
495+while lt p stop bound 2048
496+code = ulong get Nrx p
497+p = add p 1
498+if eq code 255
499+ret true
500+end
501+if ne code 0
502+if ge p stop
503+ret false
504+end
505+n = ulong get Nrx p
506+p = add p 1
507+if gt n sub stop p
508+ret false
509+end
510+if not ndopt code p n
511+ret false
512+end
513+p = add p n
514+end
515+end
516+ret false
517+end
518+fn ndconf to bool
519+m = get Ncfg 3
520+if or eq m 0 eq m 4294967295
521+ret false
522+end
523+v = xor m 4294967295
524+if ne and v add v 1 0
525+ret false
526+end
527+v = and get Ncfg 7 xor m 4294967295
528+if or eq v 0 eq v xor m 4294967295
529+ret false
530+end
531+if not nipok get Ncfg 4
532+ret false
533+end
534+if ne and get Ncfg 4 m and get Ncfg 7 m
535+ret false
536+end
537+if not nipok get Ncfg 5
538+ret false
539+end
540+ret ge get Ncfg 9 10000
541+end
542+fn ndcopy to void
543+if ne get Nopt 2 0
544+put Ncfg 3 get Nopt 2
545+end
546+if ne get Nopt 3 0
547+put Ncfg 4 get Nopt 3
548+end
549+if ne get Nopt 4 0
550+put Ncfg 5 get Nopt 4
551+end
552+if ne get Nopt 5 0
553+put Ncfg 9 mul get Nopt 5 1000
554+end
555+end
556+fn ndhcpin to void
557+p = add get Npk 5 8
558+n = sub get Npk 6 8
559+if lt n 240
560+ret
561+end
562+if or ne get Nrx p 2 ne get Nrx add p 1 1
563+ret
564+end
565+if ne get Nrx add p 2 6
566+ret
567+end
568+if ne nr32 add p 4 get Ncfg 8
569+ret
570+end
571+if not nmaceq add p 28
572+ret
573+end
574+if ne nr32 add p 236 1669485411
575+ret
576+end
577+for i ulong 8
578+put Nopt i 0
579+end
580+if not ndopts add p 240 add p n
581+ret
582+end
583+if gt get Nopt 7 3
584+ret
585+end
586+if ne and get Nopt 7 1 0
587+if not ndopts add p 108 add p 236
588+ret
589+end
590+end
591+if ne and get Nopt 7 2 0
592+if not ndopts add p 44 add p 108
593+ret
594+end
595+end
596+if not nipok get Nopt 1
597+ret
598+end
599+if eq get Ncfg 1 1
600+if ne get Nopt 0 2
601+ret
602+end
603+if not nipok nr32 add p 16
604+ret
605+end
606+put Ncfg 7 nr32 add p 16
607+put Ncfg 6 get Nopt 1
608+ndcopy
609+put Ncfg 1 2
610+put Ncfg 13 0
611+put Ncfg 12 get Ncfg 0
612+ret
613+end
614+if ne get Ncfg 1 2
615+ret
616+end
617+if ne get Nopt 1 get Ncfg 6
618+ret
619+end
620+if eq get Nopt 0 6
621+nfail 4
622+ret
623+end
624+if ne get Nopt 0 5
625+ret
626+end
627+if ne nr32 add p 16 get Ncfg 7
628+ret
629+end
630+ndcopy
631+if not ndconf
632+nfail 5
633+ret
634+end
635+put Ncfg 10 get Ncfg 0
636+put Ncfg 1 3
637+put Ncfg 14 0
638+put Ncfg 12 add get Ncfg 0 rem get Ncfg 8 1000
639+end
640+fn narpin to void
641+if lt get Npk 0 42
642+ret
643+end
644+if or ne nr16 14 1 ne nr16 16 2048
645+ret
646+end
647+if or ne get Nrx 18 6 ne get Nrx 19 4
648+ret
649+end
650+if or lt nr16 20 1 gt nr16 20 2
651+ret
652+end
653+if not nmacrx 22
654+ret
655+end
656+for i ulong 6
657+if ne get Nrx add i 6 get Nrx add i 22
658+ret
659+end
660+end
661+if nmaceq 22
662+ret
663+end
664+if eq get Ncfg 1 3
665+if or eq nr32 28 get Ncfg 7 and eq nr32 28 0 eq nr32 38 get Ncfg 7
666+put Ncfg 1 5
667+put Ncfg 12 get Ncfg 0
668+end
669+ret
670+end
671+if ne get Ncfg 1 4
672+ret
673+end
674+if eq nr32 28 get Ncfg 2
675+nfail 6
676+ret
677+end
678+if ne nr32 38 get Ncfg 2
679+ret
680+end
681+if eq nr16 20 2
682+if not nmaceq 32
683+ret
684+end
685+if or eq get Ncfg 26 0 ne nr32 28 get Ncfg 26
686+ret
687+end
688+for i ulong 6
689+put Nhop i get Nrx add i 22
690+end
691+put Ncfg 27 get Ncfg 26
692+put Ncfg 26 0
693+put Ncfg 30 get Ncfg 0
694+ret
695+end
696+if nipok nr32 28
697+if eq get Napip 0 0
698+for i ulong 6
699+put Narp i get Nrx add i 22
700+end
701+put Napip 0 nr32 28
702+end
703+end
704+end
705+note DNS names expand to lowercase wire labels, never textual pointer arithmetic.
706+note Compression pointers must point backward into this message, with <=128 hops.
707+fn ndname p ulong to bool
708+used = ulong 0
709+next = ulong 0
710+for hop ulong 256
711+if ge p get Nd 1
712+ret false
713+end
714+c = ulong get Nrx p
715+if eq and c 192 192
716+if ge add p 1 get Nd 1
717+ret false
718+end
719+q = add get Nd 0 and nr16 p 16383
720+if or ge q p lt q add get Nd 0 12
721+ret false
722+end
723+if eq next 0
724+next = add p 2
725+end
726+p = q
727+else
728+if ne and c 192 0
729+ret false
730+end
731+p = add p 1
732+if or gt add used add c 1 255 gt c sub get Nd 1 p
733+ret false
734+end
735+put Nname used uchar c
736+used = add used 1
737+if eq c 0
738+if eq next 0
739+next = p
740+end
741+put Nd 2 next
742+put Nd 3 used
743+ret true
744+end
745+for i ulong c
746+v = get Nrx add p i
747+if and ge v 65 le v 90
748+v = add v 32
749+end
750+put Nname used v
751+used = add used 1
752+end
753+p = add p c
754+end
755+end
756+ret false
757+end
758+fn ndmatch to bool
759+if ne get Nd 3 get Ncfg 25
760+ret false
761+end
762+for i ulong get Nd 3
763+if ne get Nname i get Nwant i
764+ret false
765+end
766+end
767+ret true
768+end
769+fn ndrr p ulong to bool
770+if not ndname p
771+ret false
772+end
773+p = get Nd 2
774+if gt add p 10 get Nd 1
775+ret false
776+end
777+put Nrr 0 nr16 p
778+put Nrr 1 nr16 add p 2
779+put Nrr 2 nr16 add p 8
780+put Nrr 3 nr32 add p 4
781+p = add p 10
782+if gt get Nrr 2 sub get Nd 1 p
783+ret false
784+end
785+put Nd 7 p
786+put Nd 6 add p get Nrr 2
787+ret true
788+end
789+fn ndtarget to void
790+for i ulong get Nd 3
791+put Nwant i get Nname i
792+end
793+put Ncfg 25 get Nd 3
794+put Ncfg 24 add get Ncfg 24 1
795+end
796+fn ndanswer to void
797+for pass ulong 9
798+p = get Nd 4
799+changed = false
800+for i ulong get Nd 5
801+if not ndrr p
802+nfail 10
803+ret
804+end
805+p = get Nd 6
806+if and eq get Nrr 1 1 ndmatch
807+if eq get Nrr 0 1
808+if ne get Nrr 2 4
809+nfail 10
810+ret
811+end
812+if not nipok nr32 get Nd 7
813+nfail 10
814+ret
815+end
816+put Tcpstate 2 nr32 get Nd 7
817+put Tcpstate 0 3
818+put Nct 9 1
819+put Nct 10 1
820+put Nct 11 0
821+put Nct 12 get Nct 25
822+put Nct 0 get Nct 25
823+put Nct 1 get Nct 25
824+put Nct 14 1000
825+put Nct 15 0
826+ret
827+end
828+if eq get Nrr 0 5
829+if ge get Ncfg 24 8
830+nfail 10
831+ret
832+end
833+if not ndname get Nd 7
834+nfail 10
835+ret
836+end
837+if ne get Nd 2 p
838+nfail 10
839+ret
840+end
841+if ndmatch
842+nfail 10
843+ret
844+end
845+ndtarget
846+changed = true
847+break
848+end
849+end
850+end
851+if not changed
852+if eq pass 0
853+nfail 10
854+ret
855+end
856+put Ncfg 19 and add get Ncfg 19 1 65535
857+put Ncfg 22 get Ncfg 0
858+put Ncfg 23 0
859+ret
860+end
861+end
862+nfail 10
863+end
864+fn ndnsin to void
865+p = add get Npk 5 8
866+if lt get Npk 6 20
867+ret
868+end
869+if ne nr16 p get Ncfg 19
870+ret
871+end
872+if ne and nr16 add p 2 63488 32768
873+ret
874+end
875+if ne nr16 add p 4 1
876+ret
877+end
878+put Nd 0 p
879+put Nd 1 add get Npk 5 get Npk 6
880+if not ndname add p 12
881+ret
882+end
883+if not ndmatch
884+ret
885+end
886+q = get Nd 2
887+if gt add q 4 get Nd 1
888+ret
889+end
890+if or ne nr16 q 1 ne nr16 add q 2 1
891+ret
892+end
893+if ne and nr16 add p 2 527 0
894+nfail 9
895+ret
896+end
897+put Nd 4 add q 4
898+put Nd 5 nr16 add p 6
899+n = add get Nd 5 nr16 add p 8
900+n = add n nr16 add p 10
901+if gt n 64
902+nfail 10
903+ret
904+end
905+q = get Nd 4
906+for i ulong n
907+if not ndrr q
908+nfail 10
909+ret
910+end
911+q = get Nd 6
912+end
913+if ne q get Nd 1
914+nfail 10
915+ret
916+end
917+ndanswer
918+end
919+fn nrtt to void
920+if ne get Nct 15 0
921+ret
922+end
923+r = sub get Ncfg 0 get Nct 13
924+if eq r 0
925+r = 1
926+end
927+if eq get Nct 28 0
928+put Nct 26 r
929+put Nct 27 div r 2
930+put Nct 28 1
931+else
932+d = get Nct 26
933+if ge d r
934+d = sub d r
935+else
936+d = sub r d
937+end
938+put Nct 27 div add mul get Nct 27 3 d 4
939+put Nct 26 div add mul get Nct 26 7 r 8
940+end
941+r = add get Nct 26 mul get Nct 27 4
942+if lt r 1000
943+r = 1000
944+end
945+if gt r 60000
946+r = 60000
947+end
948+if and ne get Nct 30 0 lt r 3000
949+r = 3000
950+end
951+put Nct 14 r
952+end
953+fn ntopts p ulong stop ulong to bool
954+while lt p stop bound 40
955+kind = ulong get Nrx p
956+if eq kind 0
957+ret true
958+end
959+if eq kind 1
960+p = add p 1
961+else
962+if ge add p 1 stop
963+ret false
964+end
965+n = ulong get Nrx add p 1
966+if or lt n 2 gt n sub stop p
967+ret false
968+end
969+if eq kind 2
970+if ne n 4
971+ret false
972+end
973+n = nr16 add p 2
974+if eq n 0
975+ret false
976+end
977+if gt n 1460
978+n = 1460
979+end
980+put Nct 7 n
981+n = 4
982+end
983+p = add p n
984+end
985+end
986+ret true
987+end
988+fn ntaccept to bool
989+n = get Npk 11
990+if ne and get Npk 9 1 0
991+n = add n 1
992+end
993+w = nwindow
994+if eq n 0
995+if eq w 0
996+ret eq get Npk 7 get Nct 2
997+end
998+ret lt ndiff get Npk 7 get Nct 2 w
999+end
1000+if eq w 0
1001+ret false
1002+end
1003+if lt ndiff get Npk 7 get Nct 2 w
1004+ret true
1005+end
1006+ret lt ndiff nadd get Npk 7 sub n 1 get Nct 2 w
1007+end
1008+fn ntack to bool
1009+a = get Npk 8
1010+if nlt get Nct 1 a
1011+put Nct 8 1
1012+ret false
1013+end
1014+if nlt a get Nct 0
1015+ret true
1016+end
1017+if or nlt get Nct 5 get Npk 7 and eq get Nct 5 get Npk 7 not nlt a get Nct 6
1018+put Nct 4 get Npk 12
1019+put Nct 5 get Npk 7
1020+put Nct 6 a
1021+end
1022+if eq a get Nct 0
1023+ret true
1024+end
1025+if or eq get Nct 9 0 eq get Nct 11 0
1026+ret false
1027+end
1028+n = ndiff a get Nct 0
1029+if gt n get Nct 9
1030+ret false
1031+end
1032+if eq n get Nct 9
1033+nrtt
1034+end
1035+if eq get Nct 10 2
1036+for i ulong n
1037+put Nsbuf add get Nct 17 i uchar 0
1038+end
1039+put Nct 17 add get Nct 17 n
1040+end
1041+put Nct 0 a
1042+put Nct 12 a
1043+put Nct 9 sub get Nct 9 n
1044+put Nct 13 get Ncfg 0
1045+if ne get Nct 9 0
1046+note Partial ACK retains Karn ambiguity for the remaining bytes.
1047+put Nct 15 1
1048+ret true
1049+end
1050+if eq get Nct 10 3
1051+put Nct 19 1
1052+end
1053+put Nct 10 0
1054+put Nct 11 0
1055+put Nct 15 0
1056+if eq get Nct 17 get Nct 16
1057+put Nct 17 0
1058+put Nct 16 0
1059+end
1060+ret true
1061+end
1062+fn ntfinish to void
1063+if and ne get Nct 19 0 ne get Nct 20 0
1064+if eq get Nct 24 0
1065+put Nct 24 add get Ncfg 0 1
1066+end
1067+put Tcpstate 0 5
1068+end
1069+end
1070+fn ntdrain to void
1071+while ne get Nrmap get Nct 3 0 bound 65536
1072+if ge get Tcpn 0 65535
1073+break
1074+end
1075+if ne get Nct 20 0
1076+break
1077+end
1078+if and ne get Nct 21 0 eq get Nct 22 get Nct 2
1079+break
1080+end
1081+put Tcpin get Tcpn 0 get Nrbuf get Nct 3
1082+put Tcpn 0 add get Tcpn 0 1
1083+put Nrmap get Nct 3 uchar 0
1084+put Nrbuf get Nct 3 uchar 0
1085+put Nct 3 and add get Nct 3 1 65535
1086+put Nct 2 nadd get Nct 2 1
1087+end
1088+if and ne get Nct 21 0 eq get Nct 22 get Nct 2
1089+put Nct 2 nadd get Nct 2 1
1090+put Nct 21 0
1091+put Nct 20 1
1092+put Nct 18 1
1093+put Nct 8 1
1094+put Tcpstate 0 5
1095+end
1096+ntfinish
1097+end
1098+fn ntdata to void
1099+if ne get Nct 20 0
1100+put Nct 8 1
1101+ret
1102+end
1103+note Out-of-order bytes are stored directly in the ring and drained once the gap fills.
1104+note This deliberately does not borrow Nct 21/22, which hold the peer FIN state: doing so
1105+note made a retransmitted in-order segment look like a FIN and stalled the stream.
1106+for i ulong get Npk 11
1107+s = nadd get Npk 7 i
1108+d = ndiff s get Nct 2
1109+if lt d nwindow
1110+p = and add get Nct 3 d 65535
1111+v = get Nrx add get Npk 10 i
1112+if eq get Nrmap p 0
1113+put Nrbuf p v
1114+put Nrmap p uchar 1
1115+else
1116+if ne get Nrbuf p v
1117+nfail 13
1118+ret
1119+end
1120+end
1121+end
1122+end
1123+if or ne get Npk 11 0 ne and get Npk 9 1 0
1124+put Nct 8 1
1125+end
1126+ntdrain
1127+end
1128+fn ntsynin to void
1129+if eq get Nct 11 0
1130+ret
1131+end
1132+if ne get Npk 8 nadd get Nct 25 1
1133+ret
1134+end
1135+if eq and get Npk 9 20 20
1136+nfail 12
1137+ret
1138+end
1139+if ne and get Npk 9 23 18
1140+ret
1141+end
1142+if ne get Npk 11 0
1143+nfail 13
1144+ret
1145+end
1146+if not ntopts add get Npk 5 20 get Npk 10
1147+ret
1148+end
1149+nrtt
1150+put Nct 0 get Npk 8
1151+put Nct 1 get Npk 8
1152+put Nct 2 nadd get Npk 7 1
1153+put Nct 4 get Npk 12
1154+put Nct 5 get Npk 7
1155+put Nct 6 get Npk 8
1156+put Nct 9 0
1157+put Nct 10 0
1158+put Nct 11 0
1159+put Nct 15 0
1160+put Nct 8 1
1161+put Nct 23 get Ncfg 0
1162+put Tcpstate 0 4
1163+end
1164+fn ntcpin to void
1165+p = get Npk 5
1166+if lt get Npk 6 20
1167+ret
1168+end
1169+if or ne nr16 p 443 ne nr16 add p 2 get Ncfg 21
1170+ret
1171+end
1172+if ne get Npk 3 get Tcpstate 2
1173+put Ndrop 0 12
1174+ret
1175+end
1176+s = npssum get Npk 3 get Npk 4 6 get Npk 6
1177+if ne nfold add s nrsum p get Npk 6 0
1178+put Ndrop 0 13
1179+ret
1180+end
1181+put Npk 13 mul ulong shr get Nrx add p 12 4 4
1182+if or lt get Npk 13 20 gt get Npk 13 get Npk 6
1183+put Ndrop 0 14
1184+ret
1185+end
1186+note RFC9293: the four reserved header bits are ignored on receipt.
1187+put Npk 7 nr32 add p 4
1188+put Npk 8 nr32 add p 8
1189+put Npk 9 ulong get Nrx add p 13
1190+put Npk 10 add p get Npk 13
1191+put Npk 11 sub get Npk 6 get Npk 13
1192+put Npk 12 nr16 add p 14
1193+if eq get Tcpstate 0 3
1194+ntsynin
1195+ret
1196+end
1197+if or lt get Tcpstate 0 4 gt get Tcpstate 0 5
1198+put Ndrop 0 15
1199+ret
1200+end
1201+if ne get Nct 31 0
1202+put Ndrop 0 16
1203+ret
1204+end
1205+if ne and get Npk 9 4 0
1206+if eq get Npk 7 get Nct 2
1207+nfail 12
1208+else
1209+if ntaccept
1210+put Nct 8 1
1211+end
1212+end
1213+ret
1214+end
1215+if not ntaccept
1216+put Nct 8 1
1217+if and ne get Nct 24 0 ne and get Npk 9 1 0
1218+if eq nadd get Npk 7 add get Npk 11 1 get Nct 2
1219+put Nct 24 add get Ncfg 0 1
1220+end
1221+end
1222+ret
1223+end
1224+if ne and get Npk 9 2 0
1225+put Nct 8 1
1226+ret
1227+end
1228+if eq and get Npk 9 16 0
1229+ret
1230+end
1231+note CWR/ECE are ignored (ECN was not offered); urgent data is refused.
1232+if ne and get Npk 9 32 0
1233+nfail 13
1234+ret
1235+end
1236+if not ntack
1237+put Ndrop 0 1
1238+ret
1239+end
1240+put Ndropt 0 get Npk 11
1241+put Ndropd 0 ndiff get Npk 7 get Nct 2
1242+put Ndropw 0 nwindow
1243+put Nct 23 get Ncfg 0
1244+ntdata
1245+if ne and get Npk 9 1 0
1246+note FIN occupies one sequence number after the payload. Latch it; ntdrain completes it when
1247+note the stream reaches it, in order or after the gap fills.
1248+put Nct 21 1
1249+put Nct 22 nadd get Npk 7 get Npk 11
1250+ntdrain
1251+end
1252+end
1253+note Courier datagram in (UDP to port 47033, checksum already verified). Like
1254+note the C kernel (courier_udp_x86.c pump) the frame is ours by its Ethernet
1255+note destination (netinput: our MAC or ff:ff:ff:ff:ff:ff) and the port alone:
1256+note any IPv4 destination is taken, so the relay's --udp-answer 192.168.1.255
1257+note reaches a kernel that has no lease yet. Copied into Chrx when the slot is
1258+note free, else dropped and counted. Any source port.
1259+fn netudpin p ulong to void
1260+n = sub get Npk 6 8
1261+if or eq n 0 gt n len Chrx
1262+ret
1263+end
1264+if ne get Chrxn 0 0
1265+put Chdrop 0 add get Chdrop 0 1
1266+ret
1267+end
1268+for i ulong n
1269+put Chrx i get Nrx add add p 8 i
1270+end
1271+put Chrxn 0 n
1272+end
1273+fn nipin to void
1274+if lt get Npk 0 34
1275+ret
1276+end
1277+if ne shr get Nrx 14 4 4
1278+ret
1279+end
1280+put Npk 1 mul ulong and get Nrx 14 15 4
1281+if lt get Npk 1 20
1282+ret
1283+end
1284+put Npk 2 nr16 16
1285+if or lt get Npk 2 get Npk 1 gt add get Npk 2 14 get Npk 0
1286+ret
1287+end
1288+if ne and nr16 20 49151 0
1289+ret
1290+end
1291+if eq get Nrx 22 0
1292+ret
1293+end
1294+if ne nfold nrsum 14 get Npk 1 0
1295+ret
1296+end
1297+note All IPv4 options are refused; no source-route or hidden forwarding path.
1298+if ne get Npk 1 20
1299+ret
1300+end
1301+put Npk 3 nr32 26
1302+put Npk 4 nr32 30
1303+if not nipok get Npk 3
1304+ret
1305+end
1306+put Npk 5 add 14 get Npk 1
1307+put Npk 6 sub get Npk 2 get Npk 1
1308+if eq get Nrx 23 6
1309+if ne get Tcpstate 0 6
1310+if and eq get Ncfg 1 4 eq get Npk 4 get Ncfg 2
1311+ntcpin
1312+end
1313+end
1314+ret
1315+end
1316+if ne get Nrx 23 17
1317+ret
1318+end
1319+p = get Npk 5
1320+if lt get Npk 6 8
1321+ret
1322+end
1323+if ne nr16 add p 4 get Npk 6
1324+ret
1325+end
1326+if ne nr16 add p 6 0
1327+s = npssum get Npk 3 get Npk 4 17 get Npk 6
1328+if ne nfold add s nrsum p get Npk 6 0
1329+ret
1330+end
1331+end
1332+if and eq nr16 p 67 eq nr16 add p 2 68
1333+if ne get Tcpstate 0 6
1334+if or eq get Ncfg 1 1 eq get Ncfg 1 2
1335+note Any destination: chaddr, random xid and server-id gate acceptance.
1336+ndhcpin
1337+end
1338+end
1339+ret
1340+end
1341+if eq nr16 add p 2 47033
1342+netudpin p
1343+ret
1344+end
1345+if ne get Tcpstate 0 2
1346+ret
1347+end
1348+if or ne get Npk 4 get Ncfg 2 ne get Npk 3 get Ncfg 5
1349+ret
1350+end
1351+if or ne nr16 p 53 ne nr16 add p 2 get Ncfg 20
1352+ret
1353+end
1354+ndnsin
1355+end
1356+fn nrnd32 p ulong to ulong
1357+v = ulong 0
1358+for i ulong 4
1359+v = add shl v 8 ulong get Nrand add p i
1360+end
1361+ret v
1362+end
1363+fn nqhost to void
1364+put Nwant 0 uchar 3
1365+put Nwant 4 uchar 6
1366+put Nwant 11 uchar 3
1367+put Nwant 15 uchar 0
1368+for i ulong 3
1369+put Nwant add i 1 get Nhost i
1370+put Nwant add i 12 get Nhost add i 11
1371+end
1372+for i ulong 6
1373+put Nwant add i 5 get Nhost add i 4
1374+end
1375+put Ncfg 25 16
1376+end
1377+fn netinit now ulong to void
1378+put Ntxlen 0 0
1379+nwipe
1380+for i ulong 32
1381+put Ncfg i 0
1382+put Nct i 0
1383+put Nrand i uchar 0
1384+end
1385+for i ulong 8
1386+put Tcpstate i 0
1387+put Nq i 0
1388+end
1389+put Napip 0 0
1390+for i ulong 6
1391+put Nhop i uchar 0
1392+put Narp i uchar 0
1393+end
1394+if not nclock now
1395+ret
1396+end
1397+v = uchar 0
1398+for i ulong 6
1399+v = or v get Nmac i
1400+end
1401+if or eq v 0 ne and get Nmac 0 1 0
1402+nfail 2
1403+ret
1404+end
1405+put Ncfg 31 1
1406+end
1407+fn nbound to bool
1408+if or ne get Ncfg 1 4 lt get Ncfg 14 5
1409+ret false
1410+end
1411+ret lt sub get Ncfg 0 get Ncfg 10 get Ncfg 9
1412+end
1413+fn ndhcpnew to void
1414+for i ulong 14
1415+put Ncfg add i 1 0
1416+end
1417+for i ulong 5
1418+put Ncfg add i 26 0
1419+end
1420+put Ncfg 8 nrnd32 0
1421+put Ncfg 1 1
1422+put Ncfg 11 get Ncfg 0
1423+put Ncfg 12 get Ncfg 0
1424+end
1425+fn netconnect now ulong to void
1426+if not nclock now
1427+ret
1428+end
1429+if eq get Ncfg 31 0
1430+nfail 17
1431+ret
1432+end
1433+if and ge get Tcpstate 0 1 le get Tcpstate 0 4
1434+ret
1435+end
1436+v = uchar 0
1437+for i ulong 32
1438+v = or v get Nrand i
1439+end
1440+if eq v 0
1441+nfail 2
1442+ret
1443+end
1444+note A queued frame from an older generation is completed, never reinterpreted.
1445+g = add get Ncfg 17 1
1446+nwipe
1447+for i ulong 32
1448+put Nct i 0
1449+end
1450+for i ulong 8
1451+put Tcpstate i 0
1452+end
1453+for i ulong 10
1454+put Ncfg add i 15 0
1455+end
1456+put Napip 0 0
1457+put Ncfg 17 g
1458+put Ncfg 18 and nrnd32 20 65535
1459+put Ncfg 19 and nrnd32 4 65535
1460+put Ncfg 20 add 49152 rem nrnd32 8 16384
1461+put Ncfg 21 add 49152 rem nrnd32 16 16384
1462+put Nct 25 nrnd32 12
1463+put Nct 7 536
1464+put Nct 14 1000
1465+if nbound
1466+put Tcpstate 0 2
1467+put Ncfg 22 now
1468+else
1469+ndhcpnew
1470+put Tcpstate 0 1
1471+end
1472+for i ulong 32
1473+put Nrand i uchar 0
1474+end
1475+put Ncfg 15 1
1476+put Ncfg 16 now
1477+nqhost
1478+end
1479+note Error state 6 freezes DHCP, DNS and TCP until the next netconnect. Courier
1480+note datagrams on port 47033 still arrive, and ARP for a bound lease is still
1481+note answered so a relay's unicast answer to the leased address can reach us.
1482+fn netinput n ulong now ulong to void
1483+if not nclock now
1484+ret
1485+end
1486+if or lt n 14 gt n 1514
1487+ret
1488+end
1489+if not nmacrx 6
1490+ret
1491+end
1492+if nmaceq 6
1493+ret
1494+end
1495+note Any frame for us counts as activity: the mode-3 idle check in netstep must not be a
1496+note connection-lifetime cap, or a long transfer dies mid-body with failure 14.
1497+put Ncfg 10 now
1498+if not nmaceq 0
1499+for i ulong 6
1500+if ne get Nrx i 255
1501+ret
1502+end
1503+end
1504+end
1505+put Npk 0 n
1506+if eq nr16 12 2054
1507+if or ne get Tcpstate 0 6 eq get Ncfg 1 4
1508+narpin
1509+end
1510+end
1511+if eq nr16 12 2048
1512+nipin
1513+end
1514+end
1515+fn netwrite n ulong now ulong to bool
1516+if not nclock now
1517+ret false
1518+end
1519+if gt n 65536
1520+nfail 17
1521+ret false
1522+end
1523+if or ne get Tcpstate 0 4 ne get Nct 18 0
1524+ret false
1525+end
1526+if ne get Nct 16 0
1527+ret false
1528+end
1529+if eq n 0
1530+ret true
1531+end
1532+for i ulong n
1533+put Nsbuf i get Tcpout i
1534+end
1535+put Nct 16 n
1536+put Nct 17 0
1537+put Nct 29 now
1538+ret true
1539+end
1540+fn netconsume n ulong to void
1541+if gt n get Tcpn 0
1542+nfail 17
1543+ret
1544+end
1545+if eq n 0
1546+ret
1547+end
1548+left = sub get Tcpn 0 n
1549+for i ulong left
1550+put Tcpin i get Tcpin add i n
1551+end
1552+for i ulong n
1553+put Tcpin add left i uchar 0
1554+end
1555+put Tcpn 0 left
1556+put Nct 8 1
1557+ntdrain
1558+end
1559+fn netclose now ulong to void
1560+if not nclock now
1561+ret
1562+end
1563+if eq get Tcpstate 0 6
1564+ret
1565+end
1566+if lt get Tcpstate 0 4
1567+put Tcpstate 0 5
1568+put Nct 31 1
1569+nwipe
1570+ret
1571+end
1572+put Nct 18 1
1573+put Tcpstate 0 5
1574+end
1575+fn nstepset to void
1576+if eq get Ncfg 1 5
1577+ndhcpout
1578+ret
1579+end
1580+if or eq get Ncfg 1 1 eq get Ncfg 1 2
1581+if ge sub get Ncfg 0 get Ncfg 11 60000
1582+nfail 3
1583+ret
1584+end
1585+if ge get Ncfg 0 get Ncfg 12
1586+if ge get Ncfg 13 5
1587+nfail 3
1588+else
1589+ndhcpout
1590+end
1591+end
1592+ret
1593+end
1594+if eq get Ncfg 1 3
1595+if lt get Ncfg 0 get Ncfg 12
1596+ret
1597+end
1598+if lt get Ncfg 14 3
1599+narpout get Ncfg 7 true
1600+ret
1601+end
1602+put Ncfg 2 get Ncfg 7
1603+put Ncfg 1 4
1604+end
1605+if ne get Ncfg 1 4
1606+ret
1607+end
1608+if lt get Ncfg 14 5
1609+if ge get Ncfg 0 get Ncfg 12
1610+narpout get Ncfg 2 false
1611+put Nq 3 6
1612+end
1613+ret
1614+end
1615+if eq get Tcpstate 0 1
1616+put Tcpstate 0 2
1617+put Ncfg 22 get Ncfg 0
1618+end
1619+end
1620+fn nstepdns to void
1621+if lt get Ncfg 0 get Ncfg 22
1622+ret
1623+end
1624+if ge get Ncfg 23 4
1625+nfail 8
1626+ret
1627+end
1628+if nroute get Ncfg 5
1629+ndnsout
1630+end
1631+end
1632+fn nflight kind ulong n ulong to void
1633+put Nct 9 n
1634+put Nct 10 kind
1635+put Nct 11 0
1636+put Nct 12 get Nct 1
1637+put Nct 15 0
1638+end
1639+fn nsteptcp to void
1640+if ne get Nct 24 0
1641+if ge sub add get Ncfg 0 1 get Nct 24 120000
1642+put Nct 31 1
1643+put Nct 8 0
1644+ret
1645+end
1646+end
1647+if ne get Nct 31 0
1648+ret
1649+end
1650+note FIN-WAIT-2 is bounded: our FIN is acknowledged, the peer stays silent.
1651+if and ne get Nct 19 0 eq get Nct 20 0
1652+if ge sub get Ncfg 0 get Nct 23 60000
1653+put Nct 31 1
1654+ret
1655+end
1656+end
1657+if ne get Nct 8 0
1658+if nroute get Tcpstate 2
1659+ntcpout false
1660+end
1661+ret
1662+end
1663+if ne get Nct 9 0
1664+if ne get Nct 11 0
1665+if lt sub get Ncfg 0 get Nct 13 get Nct 14
1666+ret
1667+end
1668+if ge get Nct 15 6
1669+nfail 11
1670+ret
1671+end
1672+end
1673+if nroute get Tcpstate 2
1674+ntcpout true
1675+end
1676+ret
1677+end
1678+if eq get Tcpstate 0 3
1679+ret
1680+end
1681+if ne get Nct 16 0
1682+n = sub get Nct 16 get Nct 17
1683+if gt n get Nct 7
1684+n = get Nct 7
1685+end
1686+if gt n get Nct 4
1687+n = get Nct 4
1688+end
1689+if eq n 0
1690+if lt sub get Ncfg 0 get Nct 29 1000
1691+ret
1692+end
1693+note A one-byte persist probe is retained and retransmitted, never discarded.
1694+n = 1
1695+end
1696+nflight 2 n
1697+else
1698+if and ne get Nct 18 0 eq get Nct 19 0
1699+nflight 3 1
1700+else
1701+ret
1702+end
1703+end
1704+if nroute get Tcpstate 2
1705+ntcpout true
1706+end
1707+end
1708+fn netstep now ulong to void
1709+if not nclock now
1710+ret
1711+end
1712+if or eq get Tcpstate 0 6 ne get Nct 31 0
1713+ret
1714+end
1715+if ge get Ncfg 1 3
1716+if and ne get Ncfg 9 0 ge sub now get Ncfg 10 get Ncfg 9
1717+nfail 14
1718+ret
1719+end
1720+end
1721+if and ne get Ncfg 15 0 lt get Tcpstate 0 4
1722+if ge sub now get Ncfg 16 120000
1723+nfail 16
1724+ret
1725+end
1726+end
1727+if ne get Ntxlen 0 0
1728+if ge sub now get Nq 2 10000
1729+nfail 15
1730+end
1731+ret
1732+end
1733+nstepset
1734+if or eq get Tcpstate 0 6 ne get Ntxlen 0 0
1735+ret
1736+end
1737+if lt get Ncfg 14 5
1738+ret
1739+end
1740+if ne get Napip 0 0
1741+narprepl
1742+ret
1743+end
1744+if eq get Tcpstate 0 2
1745+nstepdns
1746+end
1747+if and ge get Tcpstate 0 3 le get Tcpstate 0 5
1748+nsteptcp
1749+end
1750+end
1751+fn nqdhcp to void
1752+if ne get Nq 3 get Ncfg 1
1753+ret
1754+end
1755+if eq get Ncfg 1 5
1756+nfail 6
1757+ret
1758+end
1759+d = add 3000 rem get Ncfg 8 2001
1760+d = mul d shl ulong 1 get Ncfg 13
1761+if gt d 16000
1762+d = 16000
1763+end
1764+put Ncfg 13 add get Ncfg 13 1
1765+put Ncfg 12 add get Ncfg 0 d
1766+end
1767+fn nqarp to void
1768+if eq get Nq 3 3
1769+if ne get Ncfg 1 3
1770+ret
1771+end
1772+put Ncfg 14 add get Ncfg 14 1
1773+d = add 1000 rem get Ncfg 8 1001
1774+if eq get Ncfg 14 3
1775+d = 2000
1776+end
1777+put Ncfg 12 add get Ncfg 0 d
1778+ret
1779+end
1780+if eq get Nq 3 6
1781+put Ncfg 14 add get Ncfg 14 1
1782+put Ncfg 12 add get Ncfg 0 2000
1783+ret
1784+end
1785+put Ncfg 28 add get Ncfg 0 mul 1000 shl ulong 1 get Ncfg 29
1786+put Ncfg 29 add get Ncfg 29 1
1787+end
1788+fn nqflight to void
1789+if or eq get Nct 9 0 ne get Nq 4 get Nct 12
1790+ret
1791+end
1792+if ne get Nct 11 0
1793+put Nct 15 add get Nct 15 1
1794+r = mul get Nct 14 2
1795+if gt r 60000
1796+r = 60000
1797+end
1798+put Nct 14 r
1799+if eq get Nct 10 1
1800+put Nct 30 1
1801+end
1802+end
1803+put Nct 11 1
1804+put Nct 13 get Ncfg 0
1805+put Nct 1 nadd get Nct 12 get Nct 9
1806+end
1807+fn netsent ok bool now ulong to void
1808+if not nclock now
1809+ret
1810+end
1811+if eq get Ntxlen 0 0
1812+ret
1813+end
1814+if not ok
1815+put Nq 1 add get Nq 1 1
1816+if ge get Nq 1 8
1817+nfail 15
1818+end
1819+ret
1820+end
1821+put Ntxlen 0 0
1822+note Kind 7 (courier UDP) ends here: nothing to retry or acknowledge.
1823+if ne get Nq 7 get Ncfg 17
1824+ret
1825+end
1826+if eq get Nq 0 1
1827+nqdhcp
1828+end
1829+if eq get Nq 0 2
1830+nqarp
1831+end
1832+if eq get Nq 0 4
1833+d = mul 2000 shl ulong 1 get Ncfg 23
1834+put Ncfg 23 add get Ncfg 23 1
1835+put Ncfg 22 add now d
1836+end
1837+if eq get Nq 0 5
1838+nqflight
1839+end
1840+if or eq get Nq 0 5 eq get Nq 0 6
1841+if and eq get Nq 5 get Nct 2 eq get Nq 6 nwindow
1842+put Nct 8 0
1843+end
1844+end
1845+end

aienux/allen/paint.om

new file mode 100644
@@ -0,0 +1,100 @@
1+note Handwritten Omega port of paint.h ck_add, ck_scale, ck_mix and paint.c ck_glow.
2+note Bounded192x128 RAM canvas. This is rendering core, not full sky/font/device UI.
3+global Frame uint 24576
4+global G ulong 6
5+global Fb uchar 73728
6+fn channel c uint shift uint to uint
7+ret and shr c shift 255
8+end
9+fn addcolor d uint c uint a uint to uint
10+v = uint 0
11+for i uint 3
12+s = mul i 8
13+n = add channel d s shr mul channel c s a 8
14+if gt n 255
15+n = 255
16+end
17+v = or v shl n s
18+end
19+ret v
20+end
21+fn scale c uint f uint to uint
22+ret or and shr mul and c 16711935 f 8 16711935 and shr mul and c 65280 f 8 65280
23+end
24+fn mix d uint c uint a uint to uint
25+if ge a 256
26+ret c
27+end
28+ret add scale d sub uint 256 a scale c a
29+end
30+fn distance x ulong y ulong to ulong
31+dx = sub add mul long x 16 8 long get G 0
32+dy = sub add mul long y 16 8 long get G 1
33+ret ulong add mul dx dx mul dy dy
34+end
35+fn weight d2 ulong r2 ulong to ulong
36+inv = div ulong 1099511627776 r2
37+f = sub ulong 256 shr mul d2 inv 32
38+w = shr mul shr mul f f 8 f 8
39+ret shr mul w get G 4 8
40+end
41+fn glowpix x ulong y ulong to void
42+d2 = distance x y
43+r2 = mul get G 2 get G 2
44+if ge d2 r2
45+ret
46+end
47+a = uint weight d2 r2
48+at = add mul y 192 x
49+put Frame at addcolor get Frame at uint get G 3 a
50+end
51+fn glow cx ulong cy ulong radius ulong color ulong alpha ulong to bool
52+if or eq radius 0 gt radius 8192
53+ret false
54+end
55+if or gt cx 8192 gt cy 8192
56+ret false
57+end
58+if or gt color 16777215 gt alpha 512
59+ret false
60+end
61+put G 0 cx
62+put G 1 cy
63+put G 2 radius
64+put G 3 color
65+put G 4 alpha
66+for y ulong 128
67+for x ulong 192
68+glowpix x y
69+end
70+end
71+ret true
72+end
73+fn render to void
74+for i ulong 24576
75+put Frame i 0
76+end
77+note Frozen component pose; same halo and heart colors/weights as ck_mind_draw.
78+b = glow 1536 1024 1088 3951314 68
79+b = glow 1536 1024 640 7363839 46
80+b = glow 1536 1024 400 16765610 89
81+b = glow 1536 1024 160 16772310 218
82+b = glow 1536 1024 50 16775920 230
83+end
84+fn frameout to bool
85+for i ulong 24576
86+c = get Frame i
87+put Fb mul i 3 uchar channel c 16
88+put Fb add mul i 3 1 uchar channel c 8
89+put Fb add mul i 3 2 uchar channel c 0
90+end
91+n = ulong 0
92+while lt n len Fb
93+w = write 1 Fb n sub len Fb n
94+if le w 0
95+ret false
96+end
97+n = add n ulong w
98+end
99+ret true
100+end

aienux/allen/platform.om

new file mode 100644
@@ -0,0 +1,11 @@
1+note SPDX-License-Identifier: MIT
2+note State shared between the firmware platform loop and the on-screen workflow.
3+note Declared once, before both, because Omega globals must precede their use.
4+note Es: width,height,scale,left,top,MAC ready,network ready,dirty,epoch base,ms base,
5+note pointer drag rows,last firmware error,last network retry, efi 8 handles | locate status << 8 |
6+note scans << 16, efi 8 probe step per handle (one hex digit each, handle 0 lowest).
7+global Es ulong 16
8+global Dmo ulong 4
9+global Dprm uchar 160
10+global Dprmn ulong 1
11+global Dstat ulong 1

aienux/allen/presentation.om

new file mode 100644
@@ -0,0 +1,156 @@
1+note Stable application presentation; see PRESENTATION.md for scope and ownership.
2+global Ds ulong 8
3+global Dt ulong 64
4+global Dtext uchar 2304
5+global Dsay ulong 1
6+global Dm ulong 3
7+global Dcode uchar 32768
8+global Dstart ulong 4096
9+global Dlen ulong 4096
10+global Dline ulong 4096
11+global Dview ulong 3
12+global Din uchar 8192
13+fn dscene to bool
14+n = get Inlen 0
15+for i ulong 8192
16+put Din i get In i
17+end
18+for i ulong get R 8
19+put In i get Answer i
20+end
21+put Inlen 0 get R 8
22+ok = scdecode
23+for i ulong 8192
24+put In i get Din i
25+end
26+put Inlen 0 n
27+if not ok
28+ret false
29+end
30+for i ulong 8
31+put Ds i get Sc i
32+end
33+for i ulong 64
34+put Dt i get Things i
35+end
36+for i ulong 2304
37+put Dtext i 0
38+end
39+for i ulong get Sc 4
40+put Dtext i get Stext i
41+end
42+put Dsay 0 get Sw 3
43+put Dm 0 1
44+ret true
45+end
46+fn dcode to bool
47+if or le get R 2 1 ne get R 1 0
48+ret false
49+end
50+if or eq get R 6 0 ne get C 0 get R 0
51+ret false
52+end
53+if not rows 80 4096
54+ret false
55+end
56+for i ulong 32768
57+put Dcode i 0
58+end
59+for i ulong get C 2
60+put Dcode i get Code i
61+end
62+for i ulong 4096
63+put Dstart i 0
64+put Dlen i 0
65+put Dline i 0
66+end
67+for i ulong get View 0
68+put Dstart i get Rowst i
69+put Dlen i get Rowlen i
70+put Dline i get Rowline i
71+end
72+put Dview 0 get View 0
73+put Dview 1 0
74+put Dview 2 get C 2
75+put Dm 1 1
76+ret true
77+end
78+fn dpresent to bool
79+if or eq get A 0 0 ne get A 2 1
80+ret false
81+end
82+if or gt get R 8 159 gt get Inlen 0 8192
83+ret false
84+end
85+shown = dscene
86+coded = dcode
87+if or shown coded
88+put Dm 2 get R 0
89+ret true
90+end
91+ret false
92+end
93+fn dask now ulong to bool
94+if not appask now
95+ret false
96+end
97+b = dpresent
98+ret true
99+end
100+fn drecv now ulong to bool
101+if not appreceive now
102+ret false
103+end
104+b = dpresent
105+ret true
106+end
107+fn dreset to void
108+appreset
109+for i ulong 8
110+put Ds i 0
111+end
112+for i ulong 64
113+put Dt i 0
114+end
115+for i ulong 2304
116+put Dtext i 0
117+end
118+put Dsay 0 0
119+for i ulong 3
120+put Dm i 0
121+put Dview i 0
122+end
123+for i ulong 32768
124+put Dcode i 0
125+end
126+for i ulong 4096
127+put Dstart i 0
128+put Dlen i 0
129+put Dline i 0
130+end
131+for i ulong 8192
132+put Din i 0
133+end
134+end
135+fn cvspan beg ulong size ulong x long y long color ulong to bool
136+if not cvargs x y color
137+ret false
138+end
139+if gt beg len Dtext
140+ret false
141+end
142+if gt size sub len Dtext beg
143+ret false
144+end
145+pen = mul x 256
146+origin = pen
147+for i ulong size
148+if not afglyph get Dtext add beg i
149+ret false
150+end
151+cvblit affloor pen y color
152+pen = add pen long get Af 5
153+end
154+put Cv 7 ulong sub pen origin
155+ret true
156+end

aienux/allen/provider-core.om

new file mode 100644
@@ -0,0 +1,256 @@
1+note Host provider stream core. PROVIDER.md is the framing/state contract.
2+global Ph uchar 40
3+global Pb uchar 4096
4+global Pv ulong 4
5+global Pc ulong 2
6+global Pe ulong 2
7+global Pout uchar 65536
8+global Pn ulong 1
9+text Prmagic "ALNPRV01"
10+fn prshape to bool
11+op = get Pv 0
12+now = get Pv 1
13+arg = get Pv 2
14+n = get Pv 3
15+if eq op 1
16+ret and gt arg 0 eq n 0
17+end
18+if eq op 2
19+if ne arg 0
20+ret false
21+end
22+ret and gt n 0 le n 159
23+end
24+if or eq op 3 eq op 4
25+ret and le arg 1 eq n 0
26+end
27+if eq op 5
28+if ne arg 0
29+ret false
30+end
31+ret and ge n 65 le n 1200
32+end
33+if ne now 0
34+ret false
35+end
36+if or eq op 6 eq op 7
37+ret and eq arg 0 eq n 0
38+end
39+if eq op 8
40+ret and le arg 1 eq n 4096
41+end
42+if eq op 9
43+ret and le arg 511 eq n 4096
44+end
45+if eq op 10
46+ret and eq arg 0 eq n 0
47+end
48+ret false
49+end
50+fn prparse to bool
51+for i ulong 8
52+if ne get Ph i get Prmagic i
53+ret false
54+end
55+end
56+for k ulong 4
57+v = ulong 0
58+for i ulong 8
59+off = add add 8 mul k 8 i
60+v = or v shl ulong get Ph off mul i 8
61+end
62+put Pv k v
63+end
64+ret prshape
65+end
66+fn prbyte c uchar to void
67+put Pout get Pn 0 c
68+put Pn 0 add get Pn 0 1
69+end
70+fn prword v ulong to void
71+for i ulong 8
72+prbyte uchar and shr v mul i 8 255
73+end
74+end
75+fn prhead op ulong status ulong event ulong size ulong to void
76+for i ulong 8
77+prbyte get Prmagic i
78+end
79+prword op
80+prword status
81+prword event
82+prword size
83+end
84+fn prreply status ulong to void
85+put Pn 0 0
86+kind = get Pe 1
87+size = ulong 0
88+if eq kind 1
89+size = get Outlen 0
90+end
91+if eq kind 2
92+size = get R 8
93+end
94+prhead get Pv 0 status get Pe 0 size
95+for i ulong size
96+if eq kind 1
97+prbyte get Outb i
98+else
99+prbyte get Answer i
100+end
101+end
102+if eq kind 2
103+if and gt get R 2 1 eq get R 1 0
104+if and ne get R 6 0 eq codestat 2
105+prhead 11 1 1 get C 2
106+for i ulong get C 2
107+prbyte get Code i
108+end
109+end
110+end
111+end
112+end
113+fn prevent to void
114+put Pe 0 get A 2
115+if eq get A 2 1
116+put Pe 1 2
117+end
118+end
119+fn prload to ulong
120+if or ne get A 0 0 not ctxidle
121+ret 0
122+end
123+constants
124+for i ulong 3692
125+put Mem i 0
126+end
127+loadbeg
128+b = ctxbegin
129+put Pc 0 1
130+put Pc 1 0
131+ret 1
132+end
133+fn prcopy to ulong
134+if or ne get A 0 0 ne get Pc 0 1
135+ret 0
136+end
137+if not ctxidle
138+ret 0
139+end
140+slot = get Pv 2
141+bit = shl ulong 1 slot
142+if ne and get Pc 1 bit 0
143+ret 0
144+end
145+for i ulong 4096
146+put Unit i get Pb i
147+end
148+status = ulong 2
149+if loadcopy slot
150+status = 1
151+end
152+put Pc 1 or get Pc 1 bit
153+if eq get Pc 1 3
154+if not ctxbegin
155+ret 0
156+end
157+put Pc 0 2
158+if ne get Cx 2 0
159+put Pc 0 3
160+end
161+end
162+ret status
163+end
164+fn prnote to ulong
165+if or ne get A 0 0 ne get Pc 0 2
166+ret 0
167+end
168+if not ctxidle
169+ret 0
170+end
171+for i ulong 4096
172+put Unit i get Pb i
173+end
174+status = ctxtake get Pv 2
175+if ne get Cx 2 0
176+put Pc 0 3
177+end
178+ret status
179+end
180+fn prapply to ulong
181+op = get Pv 0
182+now = get Pv 1
183+arg = get Pv 2
184+if eq op 10
185+ret prload
186+end
187+if eq op 8
188+ret prcopy
189+end
190+if eq op 9
191+ret prnote
192+end
193+if eq op 1
194+if or eq get Pc 0 1 eq get Pc 0 2
195+ret 0
196+end
197+if appinit arg now
198+ret 1
199+end
200+ret 0
201+end
202+if eq get A 0 0
203+ret 0
204+end
205+if eq op 6
206+appcancel
207+ret 1
208+end
209+if eq op 7
210+dreset
211+ret 1
212+end
213+if not appclock now
214+ret 0
215+end
216+if eq op 3
217+offer = apppoll now ne arg 0
218+prevent
219+if offer
220+put Pe 1 1
221+ret 3
222+end
223+ret 1
224+end
225+if eq op 4
226+if appsent now ne arg 0
227+ret 1
228+end
229+ret 0
230+end
231+for i ulong get Pv 3
232+put In i get Pb i
233+end
234+put Inlen 0 get Pv 3
235+if eq op 2
236+if not dask now
237+ret 0
238+end
239+else
240+if not drecv now
241+ret 0
242+end
243+end
244+prevent
245+ret 1
246+end
247+fn prdo to bool
248+if not prparse
249+ret false
250+end
251+put Pe 0 0
252+put Pe 1 0
253+status = prapply
254+prreply status
255+ret true
256+end

aienux/allen/provider.om

new file mode 100644
@@ -0,0 +1,70 @@
1+note Native Linux stdin/stdout provider-stream entry. No fake clock or transport.
2+fn prreadhead to int
3+p = ulong 0
4+while lt p 40
5+n = read 0 Ph p sub ulong 40 p
6+if lt n 0
7+ret 74
8+end
9+if eq n 0
10+if eq p 0
11+ret 0
12+end
13+ret 65
14+end
15+p = add p ulong n
16+end
17+ret 1
18+end
19+fn prreadbody to int
20+p = ulong 0
21+size = get Pv 3
22+while lt p size
23+n = read 0 Pb p sub size p
24+if lt n 0
25+ret 74
26+end
27+if eq n 0
28+ret 65
29+end
30+p = add p ulong n
31+end
32+ret 0
33+end
34+fn prwrite to bool
35+p = ulong 0
36+while lt p get Pn 0
37+n = write 1 Pout p sub get Pn 0 p
38+if le n 0
39+ret false
40+end
41+p = add p ulong n
42+end
43+ret true
44+end
45+fn main to int
46+constants
47+while true
48+status = prreadhead
49+if eq status 0
50+ret 0
51+end
52+if ne status 1
53+ret status
54+end
55+if not prparse
56+ret 65
57+end
58+status = prreadbody
59+if ne status 0
60+ret status
61+end
62+if not prdo
63+ret 65
64+end
65+if not prwrite
66+ret 74
67+end
68+end
69+ret 0
70+end

aienux/allen/reply.om

new file mode 100644
@@ -0,0 +1,175 @@
1+note SAY/WAIT parser, staged folded bytes. Native CODE receive remains separate.
2+global Say uchar 160
3+global S ulong 5
4+fn sayhead to bool
5+put P 0 0
6+put P 2 0
7+if ineq 0 87
8+expect 87
9+expect 65
10+expect 73
11+expect 84
12+expect 32
13+number
14+put S 0 get P 1
15+put S 1 0
16+put S 2 0
17+if ne get P 0 get Inlen 0
18+ret false
19+end
20+ret eq get P 2 0
21+end
22+expect 83
23+expect 65
24+expect 89
25+expect 32
26+number
27+put S 0 get P 1
28+expect 32
29+if ne get P 2 0
30+ret false
31+end
32+put S 1 1
33+put S 2 1
34+save = get P 0
35+number
36+part = get P 1
37+if ineq get P 0 47
38+expect 47
39+number
40+put S 2 get P 1
41+expect 32
42+if or ne get P 2 0 eq part 0
43+ret false
44+end
45+put S 1 part
46+else
47+put P 0 save
48+put P 2 0
49+end
50+put S 3 get P 0
51+ret eq get P 2 0
52+end
53+fn sayfold to bool
54+n = ulong 0
55+p = get S 3
56+space = true
57+while lt p get Inlen 0
58+c = get In p
59+p = add p 1
60+if eq c 92
61+if or ineq p 110 ineq p 116
62+c = 32
63+p = add p 1
64+end
65+end
66+if or lt c 32 ge c 127
67+c = 32
68+end
69+if eq c 32
70+if not space
71+if ge n 159
72+ret false
73+end
74+put Say n c
75+n = add n 1
76+end
77+space = true
78+else
79+if ge n 159
80+ret false
81+end
82+put Say n c
83+n = add n 1
84+space = false
85+end
86+end
87+if gt n 0
88+if eq get Say sub n 1 32
89+n = sub n 1
90+end
91+end
92+put S 4 n
93+ret true
94+end
95+note Return1 accepted,2 request AGAIN,3 give up after retry;0 rejected.
96+fn saytake now ulong to ulong
97+if or eq get R 1 0 gt get Inlen 0 319
98+ret 0
99+end
100+if not sayhead
101+ret 0
102+end
103+if or ne get S 0 get R 0 lt now get R 4
104+ret 0
105+end
106+if eq get S 1 0
107+b = heard get S 0 now
108+ret 1
109+end
110+if not sayfold
111+ret 0
112+end
113+if gt get R 2 1
114+if eq get S 2 0
115+ret 0
116+end
117+if ne get C 0 get R 0
118+ret 0
119+end
120+if ne codestat 2
121+if eq get R 13 0
122+put R 13 1
123+outreset
124+emitb 65
125+emitb 71
126+emitb 65
127+emitb 73
128+emitb 78
129+emitb 32
130+emitn get R 0
131+ret 2
132+end
133+cancel
134+ret 3
135+end
136+else
137+if ne get S 1 add get R 11 1
138+ret 0
139+end
140+if and ne get S 2 0 ne get S 2 get S 1
141+ret 0
142+end
143+end
144+n = get R 8
145+if or eq get S 1 1 gt get R 2 1
146+n = 0
147+end
148+join = ulong 0
149+if and gt n 0 gt get S 4 0
150+join = 1
151+end
152+if gt add add n join get S 4 159
153+ret 0
154+end
155+if gt get R 2 1
156+if not codeshow get R 0
157+ret 0
158+end
159+end
160+if eq join 1
161+put Answer n uchar 32
162+n = add n 1
163+end
164+for i ulong get S 4
165+put Answer add n i get Say i
166+end
167+put R 8 add n get S 4
168+put R 11 get S 1
169+put R 4 now
170+if ne get S 2 0
171+put R 1 0
172+histadd 1
173+end
174+ret 1
175+end

aienux/allen/repository-screen.om

new file mode 100644
@@ -0,0 +1,543 @@
1+note SPDX-License-Identifier: AGPL-3.0-only
2+note Repository window over committed Canvas/font API. No platform calls.
3+note Inputs ghkey: ASCII r refresh,b back,Tab switch,Enter open,Esc back;
4+note 256 up,257 down,258 page up,259 page down,260 left,261 right.
5+note Pointer uses logical Canvas coordinates and button1 press; wheel/swipe in rows.
6+note Gh view README0/files1/details2. Unsupported Unicode glyphs render one ? per scalar.
7+global Ghr ulong 8
8+global Ghlines ulong 262145
9+global Ghnumb uchar 20
10+text Ghlabs "Allen / GitHub\nREADME\nFiles\nRefresh [R]\nBack [B]\nLIVE HTTPS / api.github.com\nLoading live GitHub response...\nNo current response. Refresh to retry.\nAsk me to find Allen's GitHub repository.\nUnsupported request. I can open Allen's repository.\nHTTP / transport error\nResponse exceeds bounded capacity\nInvalid response, identity, path or text\nAccess denied or GitHub rate limit\nRequest generation or path limit\nDefault branch:\nCommit:\nCommit time:\nRetrieved epoch seconds:\nRetrieval clock unavailable; session response:\nREADME not present at this commit (HTTP 404).\nEmpty README.\nEmpty directory.\nPath:\nBytes:\nObject SHA:\nDirectory\nFile\nOther object (not followed)\nText only; links and instructions are not executed.\nUp/Down scroll | PgUp/PgDn | Tab views | Enter open\nSource: github.com/\n"
11+fn ghscalar p ulong to ulong
12+c = get Ghread p
13+if lt c 128
14+ret add p 1
15+end
16+if lt c 224
17+ret add p 2
18+end
19+if lt c 240
20+ret add p 3
21+end
22+ret add p 4
23+end
24+fn ghmeasure to void
25+w = get Cv 0
26+h = get Cv 1
27+if lt w 160
28+w = 160
29+end
30+if lt h 240
31+h = 240
32+end
33+cols = div sub w 32 10
34+put Ghr 0 cols
35+put Ghr 1 div sub h 212 18
36+if eq get Ghr 1 0
37+put Ghr 1 1
38+end
39+if and eq get Ghr 3 get Gh 12 eq get Ghr 4 cols
40+ret
41+end
42+put Ghr 3 get Gh 12
43+put Ghr 4 cols
44+put Ghlines 0 0
45+nrows = ulong 1
46+col = ulong 0
47+p = ulong 0
48+while lt p get Gh 7
49+c = get Ghread p
50+p = ghscalar p
51+if eq c 10
52+put Ghlines nrows p
53+nrows = add nrows 1
54+col = 0
55+else
56+if ne c 13
57+col = add col 1
58+if ge col cols
59+if lt p get Gh 7
60+if ne get Ghread p 10
61+put Ghlines nrows p
62+nrows = add nrows 1
63+col = 0
64+end
65+end
66+end
67+end
68+end
69+end
70+put Ghr 2 nrows
71+end
72+fn ghrows to ulong
73+if eq get Gh 4 0
74+ret get Ghr 2
75+end
76+if eq get Gh 4 1
77+ret get Gh 8
78+end
79+ret 1
80+end
81+fn ghlimit to ulong
82+n = ghrows
83+if le n get Ghr 1
84+ret 0
85+end
86+ret sub n get Ghr 1
87+end
88+fn ghscroll delta long to void
89+if ne get Gh 0 2
90+ret
91+end
92+ghmeasure
93+n = ghlimit
94+at = get Gh 5
95+if gt at n
96+at = n
97+end
98+if lt delta 0
99+note Avoid negating LONG_MIN.
100+if le delta neg long at
101+at = 0
102+else
103+at = ulong add long at delta
104+end
105+else
106+if ge ulong delta sub n at
107+at = n
108+else
109+at = add at ulong delta
110+end
111+end
112+put Gh 5 at
113+end
114+fn ghswipe delta long to void
115+ghscroll delta
116+end
117+fn ghopen to void
118+if ne get Gh 4 1
119+ret
120+end
121+if ge get Gh 6 get Gh 8
122+ret
123+end
124+slot = mul get Gh 6 5
125+if ne get Ghfiles add slot 2 2
126+put Gh 4 2
127+put Gh 5 0
128+ret
129+end
130+p = get Ghfiles slot
131+n = get Ghfiles add slot 1
132+for i ulong n
133+put Ghdir i get Ghpool add p i
134+end
135+put Gh 10 n
136+put Gh 8 0
137+put Gh 9 0
138+put Gh 5 0
139+put Gh 6 0
140+ghissue 4
141+end
142+fn ghback to void
143+if eq get Gh 4 2
144+put Gh 4 1
145+put Gh 5 0
146+ret
147+end
148+if and eq get Gh 4 1 gt get Gh 10 0
149+n = get Gh 10
150+while gt n 0
151+n = sub n 1
152+if eq get Ghdir n 47
153+put Gh 10 n
154+put Gh 8 0
155+put Gh 9 0
156+ghissue 4
157+ret
158+end
159+end
160+put Gh 10 0
161+put Gh 8 0
162+put Gh 9 0
163+ghissue 4
164+ret
165+end
166+put Gh 4 0
167+put Gh 5 0
168+end
169+fn ghselect down bool to void
170+if eq get Gh 8 0
171+ret
172+end
173+n = get Gh 6
174+if down
175+if lt add n 1 get Gh 8
176+n = add n 1
177+end
178+else
179+if gt n 0
180+n = sub n 1
181+end
182+end
183+put Gh 6 n
184+if lt n get Gh 5
185+put Gh 5 n
186+end
187+if ge n add get Gh 5 get Ghr 1
188+put Gh 5 add sub n get Ghr 1 1
189+end
190+end
191+fn ghkey key ulong to void
192+if or eq key 114 eq key 82
193+ghrefresh
194+ret
195+end
196+if ne get Gh 0 2
197+ret
198+end
199+ghmeasure
200+if or or eq key 98 eq key 27 eq key 260
201+ghback
202+ret
203+end
204+if eq key 9
205+put Gh 4 rem add get Gh 4 1 2
206+put Gh 5 0
207+ret
208+end
209+if or eq key 13 eq key 261
210+ghopen
211+ret
212+end
213+if or eq key 256 eq key 257
214+if eq get Gh 4 1
215+ghselect eq key 257
216+else
217+if eq key 256
218+ghscroll -1
219+else
220+ghscroll 1
221+end
222+end
223+end
224+if eq key 258
225+ghscroll neg long get Ghr 1
226+end
227+if eq key 259
228+ghscroll long get Ghr 1
229+end
230+end
231+fn ghpointer x long y long button ulong to void
232+if ne button 1
233+ret
234+end
235+if or lt x 0 lt y 0
236+ret
237+end
238+if or ge x long get Cv 0 ge y long get Cv 1
239+ret
240+end
241+if and ge y 142 lt y 170
242+if and ge x 300 lt x 460
243+ghrefresh
244+ret
245+end
246+if ne get Gh 0 2
247+ret
248+end
249+if lt x 140
250+put Gh 4 0
251+put Gh 5 0
252+else
253+if lt x 280
254+put Gh 4 1
255+put Gh 5 0
256+else
257+if ge x 460
258+ghback
259+end
260+end
261+end
262+ret
263+end
264+if ne get Gh 0 2
265+ret
266+end
267+if and eq get Gh 4 1 ge y 178
268+ghmeasure
269+row = div ulong sub y 178 18
270+if ge row get Ghr 1
271+ret
272+end
273+row = add row get Gh 5
274+if lt row get Gh 8
275+if eq row get Gh 6
276+ghopen
277+else
278+put Gh 6 row
279+end
280+end
281+end
282+end
283+fn ghfill x ulong y ulong w ulong h ulong color ulong to void
284+note The night colour is the screen's shade: translucent, so the sky shows through it.
285+a = ulong 255
286+if eq color 395282
287+a = 208
288+end
289+cvfill x y w h color a
290+end
291+fn ghdraw c uchar x long y long color ulong to void
292+if not cvglyph c x y color
293+put Ghr 7 1
294+end
295+end
296+fn ghlabel wanted ulong x long y long to void
297+which = ulong 0
298+for i ulong len Ghlabs
299+c = get Ghlabs i
300+if eq c 10
301+if eq which wanted
302+ret
303+end
304+which = add which 1
305+else
306+if eq which wanted
307+if ge x long sub get Cv 0 8
308+ret
309+end
310+ghdraw c x y 12573663
311+x = add x 10
312+end
313+end
314+end
315+end
316+fn ghsource src ulong p ulong to uchar
317+if eq src 0
318+ret get Ghmeta p
319+end
320+if eq src 1
321+ret get Ghread p
322+end
323+if eq src 2
324+ret get Ghpool p
325+end
326+ret get Ghdir p
327+end
328+fn ghtext src ulong p ulong n ulong x long y long color ulong to void
329+stop = add p n
330+while lt p stop
331+c = ghsource src p
332+p = add p 1
333+if eq c 10
334+ret
335+end
336+if ne c 13
337+if ge x long sub get Cv 0 8
338+ret
339+end
340+if ge c 128
341+while lt p stop
342+d = ghsource src p
343+if or lt d 128 ge d 192
344+break
345+end
346+p = add p 1
347+end
348+c = 63
349+end
350+if lt c 32
351+c = 32
352+end
353+ghdraw c x y color
354+x = add x 10
355+end
356+end
357+end
358+fn ghnum v ulong x long y long to void
359+n = ulong 0
360+put Ghnumb n uchar add rem v 10 48
361+n = add n 1
362+v = div v 10
363+while gt v 0
364+put Ghnumb n uchar add rem v 10 48
365+n = add n 1
366+v = div v 10
367+end
368+while gt n 0
369+n = sub n 1
370+ghdraw get Ghnumb n x y 12573663
371+x = add x 10
372+end
373+end
374+fn ghreadview to void
375+if ne get Gh 13 0
376+ghlabel 20 16 192
377+ret
378+end
379+if eq get Gh 7 0
380+ghlabel 21 16 192
381+ret
382+end
383+for i ulong get Ghr 1
384+row = add get Gh 5 i
385+if ge row get Ghr 2
386+ret
387+end
388+p = get Ghlines row
389+stop = get Gh 7
390+if lt add row 1 get Ghr 2
391+stop = get Ghlines add row 1
392+end
393+y = long add 192 mul i 18
394+ghtext 1 p sub stop p 16 y 15132654
395+end
396+end
397+fn ghfileview to void
398+if eq get Gh 8 0
399+ghlabel 22 16 192
400+ret
401+end
402+for i ulong get Ghr 1
403+row = add get Gh 5 i
404+if ge row get Gh 8
405+ret
406+end
407+slot = mul row 5
408+y = add 178 mul i 18
409+if eq row get Gh 6
410+ghfill 8 y sub get Cv 0 16 18 1850175
411+end
412+p = get Ghfiles slot
413+n = get Ghfiles add slot 1
414+mark = uchar 45
415+if eq get Ghfiles add slot 2 2
416+mark = 43
417+end
418+ghdraw mark 16 long add y 14 7119850
419+ghtext 2 p n 36 long add y 14 15132654
420+end
421+end
422+fn ghdetails to void
423+slot = mul get Gh 6 5
424+ghlabel 23 16 192
425+ghtext 2 get Ghfiles slot get Ghfiles add slot 1 86 192 15132654
426+ghlabel 24 16 212
427+ghnum get Ghfiles add slot 3 96 212
428+ghlabel 25 16 232
429+ghtext 2 get Ghfiles add slot 4 40 16 250 15132654
430+typ = get Ghfiles add slot 2
431+if eq typ 1
432+ghlabel 27 16 270
433+else
434+ghlabel 28 16 270
435+end
436+end
437+fn ghheader to void
438+ghlabel 0 16 24
439+ghlabel 31 16 44
440+note The repository is whatever discovery validated; until then the line shows only the host.
441+ghtext 0 720 get Ghlen 5 206 44 15132654
442+if eq get Gh 0 2
443+ghlabel 5 16 64
444+ghtext 0 320 get Ghlen 2 16 84 15132654
445+ghlabel 15 16 104
446+ghtext 0 64 get Ghlen 1 176 104 15132654
447+ghlabel 16 16 124
448+ghtext 0 832 12 96 124 15132654
449+ghtext 0 896 get Ghlen 4 236 124 12573663
450+end
451+ghfill 8 142 sub get Cv 0 16 28 1581342
452+ghlabel 1 16 160
453+ghlabel 2 156 160
454+ghlabel 3 306 160
455+ghlabel 4 476 160
456+end
457+fn ghstatus to void
458+state = get Gh 0
459+if eq state 0
460+ghlabel 8 16 192
461+end
462+if eq state 1
463+ghlabel 6 16 192
464+ghnum get Ghreq 0 16 216
465+end
466+if eq state 4
467+ghlabel 9 16 192
468+end
469+if eq state 3
470+ghlabel 7 16 192
471+err = get Gh 2
472+label = ulong 10
473+if eq err 2
474+label = 11
475+end
476+if eq err 3
477+label = 12
478+end
479+if eq err 4
480+label = 13
481+end
482+if eq err 8
483+label = 14
484+end
485+ghlabel label 16 216
486+ghnum get Gh 3 16 240
487+if ne get Gdiag 0 0
488+note Show the failing stage and the transport states so a photograph identifies the break.
489+ghnum get Gdiag 0 96 240
490+ghnum get Gdiag 1 176 240
491+ghnum get Gdiag 2 256 240
492+ghnum get Gdiag 3 336 240
493+ghnum get Gdiag 4 416 240
494+end
495+end
496+end
497+fn ghfooter to void
498+y = long sub get Cv 1 24
499+if eq get Gh 0 2
500+stamp = get Ghat 3
501+if gt stamp 0
502+ghlabel 18 16 y
503+ghnum stamp 266 y
504+else
505+ghlabel 19 16 y
506+ghnum get Gh 12 516 y
507+end
508+end
509+ghlabel 30 16 long sub get Cv 1 6
510+end
511+fn ghrender to bool
512+if eq get Cv 6 0
513+ret false
514+end
515+if or lt get Cv 0 320 lt get Cv 1 288
516+ret false
517+end
518+if not cvfont 10 1000
519+ret false
520+end
521+if not cvclip 0 0 get Cv 0 get Cv 1
522+ret false
523+end
524+put Ghr 7 0
525+ghmeasure
526+ghfill 0 0 get Cv 0 get Cv 1 395282
527+ghheader
528+if eq get Gh 0 2
529+if eq get Gh 4 0
530+ghreadview
531+end
532+if eq get Gh 4 1
533+ghfileview
534+end
535+if eq get Gh 4 2
536+ghdetails
537+end
538+else
539+ghstatus
540+end
541+ghfooter
542+ret eq get Ghr 7 0
543+end

aienux/allen/runtime.om

new file mode 100644
@@ -0,0 +1,145 @@
1+note R: seq, active, kind (1 chat 2 code 3 more), asked, heard, slow,
2+note code-visible, prompt length, answer length, history count, session.
3+global R ulong 16
4+global Prompt uchar 160
5+global Answer uchar 160
6+global Hist uchar 5120
7+global Hlen ulong 32
8+text Ack "I need to code that. Let me send it off to the Spark."
9+text Ackmore "Let me take that change to the Spark."
10+fn textok to bool
11+n = get Inlen 0
12+if or eq n 0 gt n 159
13+ret false
14+end
15+for i ulong n
16+c = get In i
17+if or lt c 32 gt c 126
18+ret false
19+end
20+end
21+ret true
22+end
23+fn histadd which ulong to void
24+n = get R 9
25+if eq n 32
26+for i ulong 4960
27+put Hist i get Hist add i 160
28+end
29+for i ulong 31
30+put Hlen i get Hlen add i 1
31+end
32+n = 31
33+end
34+size = get R add which 7
35+for i ulong size
36+if eq which 0
37+put Hist add mul n 160 i get Prompt i
38+else
39+put Hist add mul n 160 i get Answer i
40+end
41+end
42+put Hlen n size
43+put R 9 add n 1
44+end
45+fn start kind ulong now ulong to bool
46+if or ne get R 1 0 ge get R 0 4294967295
47+ret false
48+end
49+if or lt kind 1 gt kind 3
50+ret false
51+end
52+if and eq kind 3 eq get R 6 0
53+ret false
54+end
55+if not textok
56+ret false
57+end
58+for i ulong get Inlen 0
59+put Prompt i get In i
60+end
61+put R 7 get Inlen 0
62+put R 0 add get R 0 1
63+put R 1 1
64+put R 2 kind
65+put R 3 now
66+put R 4 now
67+put R 5 0
68+put R 8 0
69+put R 11 0
70+put R 13 0
71+if eq kind 2
72+for i ulong len Ack
73+put Answer i get Ack i
74+end
75+put R 8 len Ack
76+end
77+if eq kind 3
78+for i ulong len Ackmore
79+put Answer i get Ackmore i
80+end
81+put R 8 len Ackmore
82+end
83+histadd 0
84+ret true
85+end
86+fn answer seq ulong now ulong to bool
87+if or eq get R 1 0 ne seq get R 0
88+ret false
89+end
90+if or lt now get R 4 not textok
91+ret false
92+end
93+for i ulong get Inlen 0
94+put Answer i get In i
95+end
96+put R 8 get Inlen 0
97+put R 4 now
98+put R 1 0
99+histadd 1
100+ret true
101+end
102+fn cancel to void
103+put R 1 0
104+end
105+fn heard seq ulong now ulong to bool
106+if or eq get R 1 0 ne seq get R 0
107+ret false
108+end
109+if lt now get R 4
110+ret false
111+end
112+put R 4 now
113+ret true
114+end
115+fn tick now ulong to ulong
116+if or eq get R 1 0 lt now get R 4
117+ret 0
118+end
119+if ge sub now get R 4 30000
120+cancel
121+ret 2
122+end
123+if and eq get R 5 0 ge sub now get R 3 20000
124+put R 5 1
125+ret 1
126+end
127+ret 0
128+end
129+fn reset to void
130+for i ulong 9
131+put R add i 1 0
132+end
133+end
134+note Restore one externally decoded transcript line. No live job or ID reuse.
135+fn restore to bool
136+if or ne get R 1 0 not textok
137+ret false
138+end
139+for i ulong get Inlen 0
140+put Answer i get In i
141+end
142+put R 8 get Inlen 0
143+histadd 1
144+ret true
145+end

aienux/allen/scene-input.om

new file mode 100644
@@ -0,0 +1,319 @@
1+note Bounded model scene input. Existing scene stays the strict canonical parser.
2+note Nm thinking,normalized bytes,tidying count,hidden lines,line bytes,mood seen,
3+note invalid/overflow,plain candidate bytes,canonical line count. Input restored.
4+global Nm ulong 9
5+global Nraw uchar 2048
6+global Nline uchar 2048
7+global Nnorm uchar 2048
8+global Nplain uchar 160
9+text Ntags "<think></think>"
10+fn nlow c uchar to uchar
11+if and ge c 65 le c 90
12+ret add sub c 65 97
13+end
14+ret c
15+end
16+fn nalpha c uchar to bool
17+v = nlow c
18+ret and ge v 97 le v 122
19+end
20+fn nmatch at ulong off ulong size ulong to bool
21+if gt add at size get Nm 4
22+ret false
23+end
24+for i ulong size
25+if ne nlow get Nline add at i get Ntags add off i
26+ret false
27+end
28+end
29+ret true
30+end
31+fn nemit c uchar to void
32+n = get Nm 1
33+if ge n 2048
34+put Nm 6 1
35+ret
36+end
37+put Nnorm n c
38+put Nm 1 add n 1
39+end
40+fn nmark c uchar to bool
41+if or eq c 45 eq c 42
42+ret true
43+end
44+if or eq c 35 eq c 62
45+ret true
46+end
47+ret eq c 34
48+end
49+fn nlead c uchar to bool
50+if or eq c 32 eq c 42
51+ret true
52+end
53+if eq c 35
54+ret true
55+end
56+ret nalpha c
57+end
58+fn ndigits p ulong to ulong
59+while lt p get Nm 4
60+if not isdigit get Nline p
61+ret p
62+end
63+p = add p 1
64+end
65+ret p
66+end
67+fn nspaces p ulong to ulong
68+while lt p get Nm 4
69+if ne get Nline p 32
70+ret p
71+end
72+p = add p 1
73+end
74+ret p
75+end
76+fn npstep s ulong to ulong
77+n = get Nm 4
78+c = get Nline s
79+if nmark c
80+if eq add s 1 n
81+ret n
82+end
83+if nlead get Nline add s 1
84+ret add s 1
85+end
86+ret s
87+end
88+if not isdigit c
89+ret s
90+end
91+p = ndigits s
92+if ge add p 1 n
93+ret s
94+end
95+if not or eq get Nline p 46 eq get Nline p 41
96+ret s
97+end
98+if ne get Nline add p 1 32
99+ret s
100+end
101+ret add p 2
102+end
103+fn nprefix to ulong
104+s = ulong 0
105+while lt s get Nm 4
106+next = npstep s
107+if eq next s
108+ret s
109+end
110+put Nm 2 add get Nm 2 1
111+s = nspaces next
112+end
113+ret s
114+end
115+fn nfinish to void
116+n = get Nm 4
117+while gt n 0
118+if eq get Nline sub n 1 32
119+n = sub n 1
120+else
121+nprocess n
122+ret
123+end
124+end
125+end
126+fn nprocess n ulong to void
127+put Nm 4 n
128+hide = ne get Nm 0 0
129+for i ulong n
130+if nmatch i 0 7
131+put Nm 0 1
132+hide = true
133+end
134+if nmatch i 7 8
135+put Nm 0 0
136+hide = true
137+end
138+end
139+if hide
140+put Nm 3 add get Nm 3 1
141+ret
142+end
143+if ge n 3
144+if and eq get Nline 0 96 eq get Nline 1 96
145+if eq get Nline 2 96
146+put Nm 2 add get Nm 2 1
147+ret
148+end
149+end
150+end
151+s = nprefix
152+if ge s n
153+ret
154+end
155+w = s
156+while lt w n
157+if nalpha get Nline w
158+w = add w 1
159+else
160+nword s w n
161+ret
162+end
163+end
164+nword s w n
165+end
166+fn nword s ulong w ulong n ulong to void
167+for i ulong sub w s
168+put In add s i nlow get Nline add s i
169+end
170+word = scword s sub w s
171+if gt word 10
172+word = 0
173+end
174+r = w
175+while lt r n
176+c = get Nline r
177+if or eq c 42 eq c 34
178+r = add r 1
179+put Nm 2 add get Nm 2 1
180+else
181+nappend s w r n word
182+ret
183+end
184+end
185+nappend s w r n word
186+end
187+fn nappend s ulong w ulong r ulong n ulong word ulong to void
188+if lt r n
189+if not or eq get Nline r 32 eq get Nline r 58
190+word = 0
191+end
192+end
193+if eq word 0
194+size = sub n s
195+if and eq get Nm 7 0 le size 159
196+if lt get Nm 8 12
197+for i ulong size
198+put Nplain i get Nline add s i
199+end
200+put Nm 7 size
201+end
202+end
203+for i ulong size
204+nemit get Nline add s i
205+end
206+else
207+if eq word 1
208+if lt get Nm 8 12
209+put Nm 5 1
210+end
211+end
212+for i ulong sub w s
213+nemit nlow get Nline add s i
214+end
215+head = ne word 2
216+for i ulong sub n r
217+c = get Nline add r i
218+if eq c 58
219+if ne word 1
220+head = false
221+end
222+end
223+if head
224+c = nlow c
225+end
226+nemit c
227+end
228+end
229+nemit 10
230+put Nm 8 add get Nm 8 1
231+end
232+fn nclear to void
233+for i ulong 8
234+put Sc i 0
235+end
236+for i ulong 64
237+put Things i 0
238+end
239+put Sw 3 0
240+end
241+fn scdecode to bool
242+for i ulong 9
243+put Nm i 0
244+end
245+nclear
246+n = get Inlen 0
247+if gt n 2048
248+put Nm 6 1
249+ret false
250+end
251+for i ulong n
252+if eq get In i 0
253+put Nm 6 1
254+ret false
255+end
256+put Nraw i get In i
257+end
258+for i ulong n
259+c = get Nraw i
260+if eq c 10
261+nfinish
262+put Nm 4 0
263+else
264+if eq c 9
265+c = uchar 32
266+put Nm 2 add get Nm 2 1
267+end
268+if and ge c 32 le c 126
269+p = get Nm 4
270+keep = true
271+if eq c 32
272+if eq p 0
273+keep = false
274+else
275+if eq get Nline sub p 1 32
276+keep = false
277+end
278+end
279+end
280+if keep
281+put Nline p c
282+put Nm 4 add p 1
283+else
284+put Nm 2 add get Nm 2 1
285+end
286+else
287+put Nm 2 add get Nm 2 1
288+end
289+end
290+end
291+nfinish
292+ok = false
293+if eq get Nm 6 0
294+for i ulong get Nm 1
295+put In i get Nnorm i
296+end
297+put Inlen 0 get Nm 1
298+ok = scene
299+if ne get Nm 5 0
300+ok = true
301+end
302+if not ok
303+if gt get Nm 7 0
304+for i ulong get Nm 7
305+put In i get Nplain i
306+end
307+put Inlen 0 get Nm 7
308+ok = scsay 0 get Nm 7
309+end
310+end
311+else
312+nclear
313+end
314+for i ulong n
315+put In i get Nraw i
316+end
317+put Inlen 0 n
318+ret ok
319+end

aienux/allen/scene.om

new file mode 100644
@@ -0,0 +1,340 @@
1+note Scene state: tone,water,has-say,nthings,used,lines,rejected,over.
2+global Sc ulong 8
3+global Things ulong 64
4+global Stext uchar 2304
5+global Sw ulong 4
6+global Fields uchar 1536
7+global Flens ulong 6
8+global Soffs ulong 6
9+text Vocab "mood|say|note|list|number|quote|person|timer|picture|video|left|right|above|warm|quiet|bloom|rise|fade|to|from|night|dawn|deep|clear|slow|still|lively|"
10+fn scword beg ulong size ulong to ulong
11+s = ulong 0
12+word = ulong 1
13+for i ulong len Vocab
14+if eq get Vocab i 124
15+if eq sub i s size
16+same = true
17+for j ulong size
18+if ne get In add beg j get Vocab add s j
19+same = false
20+end
21+end
22+if same
23+ret word
24+end
25+end
26+word = add word 1
27+s = add i 1
28+end
29+end
30+ret 0
31+end
32+fn fieldcap kind ulong field ulong to ulong
33+if eq kind 2
34+if eq field 0
35+ret 48
36+end
37+ret 64
38+end
39+if eq kind 1
40+if eq field 0
41+ret 48
42+end
43+ret 240
44+end
45+if eq kind 3
46+if eq field 0
47+ret 16
48+end
49+ret 64
50+end
51+if eq kind 4
52+if eq field 0
53+ret 220
54+end
55+ret 48
56+end
57+if eq kind 5
58+if eq field 0
59+ret 32
60+end
61+ret 200
62+end
63+if eq kind 6
64+if eq field 0
65+ret 24
66+end
67+ret 64
68+end
69+if eq field 0
70+ret 120
71+end
72+ret 64
73+end
74+fn scfield slot ulong beg ulong stop ulong kind ulong to bool
75+s = beg
76+e = stop
77+while lt s e
78+if eq get In s 32
79+s = add s 1
80+else
81+ret fieldend slot s e kind
82+end
83+end
84+put Flens slot 0
85+ret true
86+end
87+fn fieldend slot ulong s ulong stop ulong kind ulong to bool
88+e = stop
89+while gt e s
90+if eq get In sub e 1 32
91+e = sub e 1
92+else
93+n = sub e s
94+if gt n fieldcap kind slot
95+ret false
96+end
97+for i ulong n
98+c = get In add s i
99+if or lt c 32 gt c 126
100+ret false
101+end
102+put Fields add mul slot 256 i c
103+end
104+put Flens slot n
105+ret true
106+end
107+end
108+put Flens slot 0
109+ret true
110+end
111+fn scfields beg ulong stop ulong kind ulong to ulong
112+slot = ulong 0
113+s = beg
114+for i ulong sub stop beg
115+p = add beg i
116+if eq get In p 124
117+if ge slot 5
118+ret 0
119+end
120+if not scfield slot s p kind
121+ret 0
122+end
123+slot = add slot 1
124+s = add p 1
125+end
126+end
127+if not scfield slot s stop kind
128+ret 0
129+end
130+n = add slot 1
131+if and ne kind 2 gt n 2
132+ret 0
133+end
134+if eq get Flens 0 0
135+ret 0
136+end
137+if eq kind 5
138+if or lt n 2 eq get Flens 1 0
139+ret 0
140+end
141+end
142+if eq kind 3
143+hasdigit = false
144+for i ulong get Flens 0
145+if isdigit get Fields i
146+hasdigit = true
147+end
148+end
149+if not hasdigit
150+ret 0
151+end
152+end
153+ret n
154+end
155+fn scput slot ulong to ulong
156+off = get Sc 4
157+n = get Flens slot
158+for i ulong n
159+put Stext add off i get Fields add mul slot 256 i
160+end
161+put Stext add off n 0
162+put Sc 4 add add off n 1
163+ret off
164+end
165+fn scmod word ulong base ulong to void
166+if and ge word 11 le word 13
167+put Things add base 1 sub word 10
168+end
169+if and ge word 16 le word 18
170+put Things add base 2 sub word 16
171+end
172+if and ge word 19 le word 20
173+put Things add base 3 sub word 18
174+end
175+if eq word 14
176+put Things add base 4 1
177+end
178+if eq word 15
179+put Things add base 5 1
180+end
181+end
182+fn scsay beg ulong stop ulong to bool
183+if ne get Sc 2 0
184+ret false
185+end
186+n = sub stop beg
187+if or eq n 0 gt n 159
188+ret false
189+end
190+for i ulong n
191+c = get In add beg i
192+if or lt c 32 gt c 126
193+ret false
194+end
195+put Fields i c
196+end
197+put Flens 0 n
198+put Sc 2 1
199+put Sw 3 scput 0
200+ret true
201+end
202+fn scln beg ulong stop ulong to bool
203+p = beg
204+while lt p stop
205+if or eq get In p 32 eq get In p 58
206+ret scbody beg p stop
207+end
208+p = add p 1
209+end
210+ret false
211+end
212+fn scbody beg ulong wordend ulong stop ulong to bool
213+word = scword beg sub wordend beg
214+if eq word 2
215+s = add wordend 1
216+if lt s stop
217+if eq get In s 58
218+s = add s 1
219+end
220+end
221+while lt s stop
222+if eq get In s 32
223+s = add s 1
224+else
225+ret scsay s stop
226+end
227+end
228+ret false
229+end
230+if eq word 1
231+s = add wordend 1
232+for p ulong sub stop s
233+at = add add wordend 1 p
234+if eq get In at 32
235+w = scword s sub at s
236+if and ge w 21 le w 24
237+put Sc 0 sub w 21
238+end
239+if and ge w 25 le w 27
240+put Sc 1 sub w 25
241+end
242+s = add at 1
243+end
244+end
245+w = scword s sub stop s
246+if and ge w 21 le w 24
247+put Sc 0 sub w 21
248+end
249+if and ge w 25 le w 27
250+put Sc 1 sub w 25
251+end
252+ret true
253+end
254+if or lt word 3 gt word 10
255+ret false
256+end
257+if ge get Sc 3 4
258+put Sc 7 add get Sc 7 1
259+ret false
260+end
261+put Sw 0 sub word 2
262+colon = wordend
263+while lt colon stop
264+if eq get In colon 58
265+put Sw 1 wordend
266+put Sw 2 colon
267+ret scthing add colon 1 stop
268+end
269+colon = add colon 1
270+end
271+ret false
272+end
273+fn scthing beg ulong stop ulong to bool
274+n = scfields beg stop get Sw 0
275+if eq n 0
276+ret false
277+end
278+need = n
279+for i ulong n
280+need = add need get Flens i
281+end
282+if gt add get Sc 4 need 2304
283+ret false
284+end
285+base = mul get Sc 3 16
286+put Things base get Sw 0
287+put Things add base 6 n
288+s = get Sw 1
289+for p ulong sub get Sw 2 s
290+at = add get Sw 1 p
291+if eq get In at 32
292+w = scword s sub at s
293+scmod w base
294+s = add at 1
295+end
296+end
297+w = scword s sub get Sw 2 s
298+scmod w base
299+for i ulong n
300+put Things add add base 7 i scput i
301+end
302+put Sc 3 add get Sc 3 1
303+ret true
304+end
305+fn scene to bool
306+for i ulong 8
307+put Sc i 0
308+end
309+for i ulong 64
310+put Things i 0
311+end
312+put Sw 3 0
313+n = get Inlen 0
314+if gt n 2048
315+n = 2048
316+end
317+s = ulong 0
318+for p ulong n
319+if eq get In p 10
320+if gt p s
321+if lt get Sc 5 12
322+put Sc 5 add get Sc 5 1
323+if not scln s p
324+put Sc 6 add get Sc 6 1
325+end
326+else
327+put Sc 7 add get Sc 7 1
328+end
329+end
330+s = add p 1
331+end
332+end
333+if and lt s n lt get Sc 5 12
334+put Sc 5 add get Sc 5 1
335+if not scln s n
336+put Sc 6 add get Sc 6 1
337+end
338+end
339+ret or ne get Sc 2 0 ne get Sc 3 0
340+end

aienux/allen/scheduler.om

new file mode 100644
@@ -0,0 +1,229 @@
1+note Courier client lifecycle; injected monotonic milliseconds, no host clock/socket.
2+note T lastclock, HIvalid, HIat, HELLOvalid, HELLOat, active, acked, jobat,
3+note joblength, cursor, pendingkind, pendingpart, reserved, GOTpart, reserved, reserved.
4+note Serialized API: qnext publishes one datagram; qsent records actual send result.
5+note Consume Outb before another serializer; failed sends leave retries due.
6+global T ulong 16
7+global JobOut uchar 4096
8+fn qstart run ulong now ulong to bool
9+if eq run 0
10+ret false
11+end
12+qbegin run 0
13+for i ulong 16
14+put T i 0
15+end
16+put T 0 now
17+ret true
18+end
19+fn qready now ulong to bool
20+if or eq get Q 0 0 lt now get T 0
21+ret false
22+end
23+if eq get T 1 0
24+ret false
25+end
26+ret lt sub now get T 2 30000
27+end
28+fn qsubmit now ulong to bool
29+if or eq get Q 0 0 lt now get T 0
30+ret false
31+end
32+if ne get T 10 0
33+ret false
34+end
35+if and ne get T 5 0 eq get T 6 0
36+ret false
37+end
38+n = get Inlen 0
39+if or eq n 0 gt n 4096
40+ret false
41+end
42+if ge get Q 1 4294967295
43+ret false
44+end
45+seq = add get Q 1 1
46+qbegin get Q 0 seq
47+for i ulong n
48+c = get In i
49+if or eq c 10 eq c 13
50+c = uchar 32
51+end
52+put JobOut i c
53+end
54+put T 0 now
55+put T 5 1
56+put T 6 0
57+put T 7 now
58+put T 8 n
59+put T 9 1
60+put T 13 0
61+ret true
62+end
63+fn qnext now ulong online bool to bool
64+if or eq get Q 0 0 lt now get T 0
65+ret false
66+end
67+if ne get T 10 0
68+ret false
69+end
70+put T 0 now
71+if not online
72+ret false
73+end
74+if ne get T 13 0
75+put Inlen 0 0
76+if not packet 3 get Q 1 get T 13 0 0
77+ret false
78+end
79+put T 10 3
80+put T 11 get T 13
81+ret true
82+end
83+delay = ulong 2000
84+if qready now
85+delay = ulong 10000
86+end
87+if or eq get T 3 0 ge sub now get T 4 delay
88+put Inlen 0 0
89+if not packet 5 0 0 0 0
90+ret false
91+end
92+put T 10 5
93+put T 11 0
94+ret true
95+end
96+if or eq get T 5 0 ne get T 6 0
97+ret false
98+end
99+part = get T 9
100+if eq part 0
101+if lt sub now get T 7 2000
102+ret false
103+end
104+part = ulong 1
105+end
106+n = get T 8
107+total = div add n 999 1000
108+off = mul sub part 1 1000
109+size = sub n off
110+if gt size 1000
111+size = ulong 1000
112+end
113+for i ulong size
114+put In i get JobOut add off i
115+end
116+put Inlen 0 size
117+if not packet 1 get Q 1 part total n
118+ret false
119+end
120+put T 10 1
121+put T 11 part
122+ret true
123+end
124+fn qsent now ulong ok bool to bool
125+if or eq get T 10 0 lt now get T 0
126+ret false
127+end
128+kind = get T 10
129+part = get T 11
130+put T 0 now
131+put T 10 0
132+put T 11 0
133+if not ok
134+ret true
135+end
136+if eq kind 5
137+put T 3 1
138+put T 4 now
139+end
140+if eq kind 3
141+if eq get T 13 part
142+put T 13 0
143+end
144+end
145+if eq kind 1
146+if or ne get T 6 0 ge part div add get T 8 999 1000
147+put T 9 0
148+put T 7 now
149+else
150+put T 9 add part 1
151+end
152+end
153+ret true
154+end
155+fn qincoming now ulong to ulong
156+if or eq get Q 0 0 lt now get T 0
157+ret 0
158+end
159+if not pkparse
160+ret 0
161+end
162+kind = get N 0
163+if eq kind 6
164+if or ne get N 1 0 ne get N 2 0
165+ret 0
166+end
167+if or ne get N 3 0 ne get N 4 0
168+ret 0
169+end
170+if ne get N 6 0
171+ret 0
172+end
173+put T 0 now
174+put T 1 1
175+put T 2 now
176+ret 1
177+end
178+if or eq get T 5 0 ne get N 1 get Q 1
179+ret 0
180+end
181+if eq kind 4
182+if or ne get N 2 0 ne get N 3 0
183+ret 0
184+end
185+if or ne get N 4 0 ne get N 6 0
186+ret 0
187+end
188+put T 0 now
189+put T 6 1
190+put T 9 0
191+ret 1
192+end
193+if ne kind 2
194+ret 0
195+end
196+note LINE total is 0; bytes is 0 (this line's tests) or the body length (the
197+note relay, allen-courier main.rs datagram(): bytes=body.len()).
198+if ne get N 3 0
199+ret 0
200+end
201+if ne get N 4 0
202+if ne get N 4 get N 6
203+ret 0
204+end
205+end
206+if and ne get T 13 0 ne get T 13 get N 2
207+ret 0
208+end
209+result = qreceive
210+if eq result 0
211+ret 0
212+end
213+put T 0 now
214+put T 6 1
215+put T 9 0
216+put T 13 get N 2
217+ret result
218+end
219+fn qcancel to void
220+put T 5 0
221+put T 6 0
222+put T 8 0
223+put T 9 0
224+put T 10 0
225+put T 11 0
226+put T 13 0
227+put Q 3 0
228+put Q 4 0
229+end

aienux/allen/session.om

new file mode 100644
@@ -0,0 +1,187 @@
1+note SPDX-License-Identifier: MIT
2+note One-request-per-connection GitHub driver over TCP, TLS 1.3 and HTTP framing.
3+note The platform supplies elapsed milliseconds, Unix time, packet results and 96 fresh
4+note random bytes in Gsrand before every gsstart: 64 for TLS, 32 for TCP/DHCP/DNS IDs.
5+global Gsrand uchar 96
6+global Gsrandn ulong 1
7+global Gs ulong 8
8+note Gdiag: last failure code, TCP state, TCP error, TLS state, TLS error. Shown on screen.
9+global Gdiag ulong 5
10+note Gs: state0 idle,1 connecting,2 TLS,3 HTTP,4 completed,5 failed; deadline; request kind;
11+note generation; send offset; failure code; pending close flag.
12+fn gsfail now ulong code ulong to void
13+if ne get Gs 0 0
14+kind = get Gs 2
15+gen = get Gs 3
16+put Gs 0 5
17+put Gs 5 code
18+put Gdiag 0 code
19+put Gdiag 1 get Tcpstate 0
20+put Gdiag 2 get Tcpstate 1
21+put Gdiag 3 get Ndrop 0
22+put Gdiag 4 get Ndropw 0
23+netclose now
24+tlsclose
25+tcwipe
26+ok = ghreply kind 0 0 gen
27+end
28+end
29+fn gsstart now ulong epoch ulong to bool
30+kind = get Ghreq 0
31+if or eq kind 0 ne get Gs 0 0
32+ret false
33+end
34+if ne get Gsrandn 0 len Gsrand
35+ok = ghreply kind 0 0 get Ghreq 2
36+ret false
37+end
38+for i ulong 64
39+put Tlsrand i get Gsrand i
40+end
41+for i ulong 32
42+put Nrand i get Gsrand add i 64
43+end
44+for i ulong len Gsrand
45+put Gsrand i 0
46+end
47+put Gsrandn 0 0
48+if not httpstart kind get Ghreq 2 get Ghreq 3 get Ghreq 4 get Ghreq 1
49+ok = ghreply kind 0 0 get Ghreq 2
50+ret false
51+end
52+for i ulong 8
53+put Gs i 0
54+end
55+put Gs 0 1
56+put Gs 1 add now 120000
57+put Gs 2 kind
58+put Gs 3 get Ghreq 2
59+ghtime epoch
60+tlsinit epoch
61+if eq get Tlsstate 0 4
62+gsfail now 9
63+ret false
64+end
65+netconnect now
66+ret true
67+end
68+fn gstlsout now ulong to void
69+if eq get Tlsoutn 0 0
70+ret
71+end
72+if gt get Tlsoutn 0 len Tcpout
73+gsfail now 2
74+ret
75+end
76+for i ulong get Tlsoutn 0
77+put Tcpout i get Tlsout i
78+end
79+if netwrite get Tlsoutn 0 now
80+tlssent
81+end
82+end
83+fn gstcpin now ulong to void
84+n = get Tcpn 0
85+if eq n 0
86+ret
87+end
88+if gt n len Tlsin
89+n = len Tlsin
90+end
91+for i ulong n
92+put Tlsin i get Tcpin i
93+end
94+tlsinput n
95+netconsume n
96+end
97+fn gshttp now ulong to void
98+while gt get Tlsappn 0 0
99+n = get Tlsappn 0
100+if gt n len Hchunk
101+n = len Hchunk
102+end
103+for i ulong n
104+put Hchunk i get Tlsapp i
105+end
106+if not httpfeed n
107+gsfail now 3
108+ret
109+end
110+tlsconsume n
111+end
112+if eq get Hstate 0 2
113+size = get Hstate 2
114+status = get Hstate 1
115+kind = get Gs 2
116+gen = get Gs 3
117+put Gs 0 4
118+netclose now
119+tlsclose
120+tcwipe
121+ok = ghreply kind status size gen
122+end
123+end
124+fn gsrequest now ulong to void
125+if or ne get Gs 4 0 ne get Tlsstate 0 2
126+ret
127+end
128+if gt get Httpreqn 0 len Tlsplain
129+gsfail now 4
130+ret
131+end
132+for i ulong get Httpreqn 0
133+put Tlsplain i get Httpreq i
134+end
135+if tlswrite get Httpreqn 0
136+put Gs 4 1
137+put Gs 0 3
138+end
139+end
140+fn gspoll now ulong to void
141+state = get Gs 0
142+if or eq state 0 ge state 4
143+ret
144+end
145+if gt now get Gs 1
146+gsfail now 5
147+ret
148+end
149+netstep now
150+if eq get Tcpstate 0 6
151+gsfail now 6
152+ret
153+end
154+if eq get Tcpstate 0 4
155+if eq state 1
156+put Gs 0 2
157+tlsinput 0
158+end
159+end
160+gstcpin now
161+if eq get Tlsstate 0 4
162+gsfail now 7
163+ret
164+end
165+gstlsout now
166+gsrequest now
167+gstlsout now
168+gshttp now
169+if ne get Gs 0 3
170+ret
171+end
172+if or eq get Tcpstate 0 5 eq get Tlsstate 0 3
173+if httpend eq get Tlsstate 2 1
174+gshttp now
175+else
176+gsfail now 8
177+end
178+end
179+end
180+fn gsnext now ulong epoch ulong to void
181+if ge get Gs 0 4
182+put Gs 0 0
183+end
184+if and eq get Gs 0 0 ne get Ghreq 0 0
185+ok = gsstart now epoch
186+end
187+end

aienux/allen/surface.om

new file mode 100644
@@ -0,0 +1,185 @@
1+note Bounded text surface at native scale. See SURFACE.md. The screens lay out on a logical
2+note 768 x 384 grid (Cv); every glyph and fill lands in the native frame Nfrm (look-paint.om) at
3+note Cvs[0] native pixels per logical pixel, centred by Cvs[2], Cvs[3]. Glyphs are rasterised at
4+note the logical cap height times the scale, so type stays crisp on a 4K panel.
5+note Cvs: 0 scale, 1 logical cap, 2 x offset, 3 y offset, 4..7 the clip in native pixels.
6+global Canvas uchar 884736
7+global Cv ulong 8
8+global Cvs ulong 8
9+global Cvpose long 2
10+fn cvinit w ulong h ulong to bool
11+if or eq w 0 gt w 768
12+ret false
13+end
14+if or eq h 0 gt h 384
15+ret false
16+end
17+for i ulong 8
18+put Cv i 0
19+end
20+put Cv 0 w
21+put Cv 1 h
22+put Cv 4 w
23+put Cv 5 h
24+put Cv 6 1
25+for i ulong 8
26+put Cvs i 0
27+end
28+put Cvs 0 1
29+sw = ulong get Lg 0
30+sh = ulong get Lg 1
31+if and ge sw w ge sh h
32+s = div sw w
33+if lt div sh h s
34+s = div sh h
35+end
36+if eq s 0
37+s = 1
38+end
39+put Cvs 0 s
40+put Cvs 2 div sub sw mul w s 2
41+put Cvs 3 div sub sh mul h s 2
42+end
43+put Cvs 4 get Cvs 2
44+put Cvs 5 get Cvs 3
45+put Cvs 6 mul w get Cvs 0
46+put Cvs 7 mul h get Cvs 0
47+ret true
48+end
49+fn cvclip x ulong y ulong w ulong h ulong to bool
50+if eq get Cv 6 0
51+ret false
52+end
53+if or gt x get Cv 0 gt y get Cv 1
54+ret false
55+end
56+if gt w sub get Cv 0 x
57+ret false
58+end
59+if gt h sub get Cv 1 y
60+ret false
61+end
62+put Cv 2 x
63+put Cv 3 y
64+put Cv 4 w
65+put Cv 5 h
66+s = get Cvs 0
67+put Cvs 4 add mul x s get Cvs 2
68+put Cvs 5 add mul y s get Cvs 3
69+put Cvs 6 mul w s
70+put Cvs 7 mul h s
71+ret true
72+end
73+fn cvfont cap ulong wt ulong to bool
74+note The face for the following glyphs: cap in logical pixels, rasterised at native size.
75+put Cvs 1 cap
76+n = mul cap get Cvs 0
77+if gt n 64
78+n = 64
79+end
80+ret afinit n wt
81+end
82+fn cvblend bg ulong fg ulong a ulong to ulong
83+v = mul bg sub ulong 255 a
84+v = add v mul fg a
85+ret div v 255
86+end
87+fn cvin x long y long to bool
88+if or lt x long get Cvs 4 lt y long get Cvs 5
89+ret false
90+end
91+if ge x long add get Cvs 4 get Cvs 6
92+ret false
93+end
94+ret lt y long add get Cvs 5 get Cvs 7
95+end
96+fn cvmixat at ulong a ulong color ulong to void
97+note One native pixel of the frame toward color by a/255.
98+d = ulong get Nfrm at
99+r = cvblend and shr d 16 255 and shr color 16 255 a
100+g = cvblend and shr d 8 255 and shr color 8 255 a
101+b = cvblend and d 255 and color 255 a
102+put Nfrm at uint or or shl r 16 shl g 8 b
103+end
104+fn cvpixel x long y long a uchar color ulong to void
105+note Native coordinates, held inside the clip.
106+if not cvin x y
107+ret
108+end
109+at = add mul ulong y ulong get Lg 0 ulong x
110+cvmixat at ulong a color
111+end
112+fn cvrow yy ulong color ulong to void
113+y = add get Cvpose 1 long yy
114+at = mul yy get Af 3
115+for x ulong get Af 3
116+px = add get Cvpose 0 long x
117+cvpixel px y get Alpha add at x color
118+end
119+end
120+fn cvblit x long y long color ulong to void
121+note x, y: the glyph's logical origin and baseline; the mask offsets Ab are native already.
122+s = long get Cvs 0
123+ox = add mul x s long get Cvs 2
124+oy = add mul y s long get Cvs 3
125+put Cvpose 0 add ox get Ab 0
126+put Cvpose 1 add oy get Ab 1
127+for yy ulong get Af 4
128+cvrow yy color
129+end
130+end
131+fn cvargs x long y long color ulong to bool
132+if or eq get Cv 6 0 eq get Af 0 0
133+ret false
134+end
135+if or lt x -4096 gt x 4096
136+ret false
137+end
138+if or lt y -4096 gt y 4096
139+ret false
140+end
141+ret le color 16777215
142+end
143+fn cvglyph c uchar x long y long color ulong to bool
144+if not cvargs x y color
145+ret false
146+end
147+if not afglyph c
148+ret false
149+end
150+cvblit x y color
151+put Cv 7 div get Af 5 get Cvs 0
152+ret true
153+end
154+fn cvfillrow y long x0 long n long a ulong color ulong to void
155+for k ulong ulong n
156+cvpixel add x0 long k y uchar a color
157+end
158+end
159+fn cvfill x ulong y ulong w ulong h ulong color ulong a ulong to void
160+note A logical rectangle mixed toward color by a/255 (255: solid), inside the clip.
161+if eq get Cv 6 0
162+ret
163+end
164+if gt x get Cv 0
165+ret
166+end
167+if gt y get Cv 1
168+ret
169+end
170+if gt w sub get Cv 0 x
171+ret
172+end
173+if gt h sub get Cv 1 y
174+ret
175+end
176+if gt a 255
177+a = 255
178+end
179+s = get Cvs 0
180+x0 = long add mul x s get Cvs 2
181+y0 = long add mul y s get Cvs 3
182+for yy ulong mul h s
183+cvfillrow add y0 long yy x0 long mul w s a color
184+end
185+end

aienux/allen/target-x86efi.om

new file mode 100644
@@ -0,0 +1 @@
1+target x86efi

aienux/allen/tests/application.om

new file mode 100644
@@ -0,0 +1,346 @@
1+note End-to-end application core over real Omega protocol bytes; no socket simulation claim.
2+text Smallask "hello"
3+text Codeaskt "Please make me a calculator"
4+text Finaltxt " 1/1 Model answer."
5+text Codetxt " 1/1 9 3ce11e06 python print(1)\\n"
6+text Prefixes "SAY WAIT CODE "
7+text Againexp "AGAIN 2"
8+global SavedOut uchar 8192
9+global Heldwire uchar 8192
10+global Heldlen ulong 2
11+fn holdwire to void
12+put Heldlen 0 get Outlen 0
13+put Heldlen 1 get Err 0
14+for i ulong get Outlen 0
15+put Heldwire i get Outb i
16+end
17+end
18+fn unhold to void
19+for i ulong get Heldlen 0
20+put Outb i get Heldwire i
21+end
22+put Outlen 0 get Heldlen 0
23+put Err 0 get Heldlen 1
24+end
25+fn samewire to bool
26+if ne get Outlen 0 get Heldlen 0
27+ret false
28+end
29+for i ulong get Heldlen 0
30+if ne get Outb i get Heldwire i
31+ret false
32+end
33+end
34+ret eq get Err 0 get Heldlen 1
35+end
36+fn test ok bool to void
37+n = get Outlen 0
38+e = get Err 0
39+for i ulong n
40+put SavedOut i get Outb i
41+end
42+check ok add get Checks 0 1
43+for i ulong n
44+put Outb i get SavedOut i
45+end
46+put Outlen 0 n
47+put Err 0 e
48+end
49+fn copyout to void
50+put Inlen 0 get Outlen 0
51+for i ulong get Outlen 0
52+put In i get Outb i
53+end
54+end
55+fn prompt code bool to void
56+if code
57+put Inlen 0 len Codeaskt
58+for i ulong len Codeaskt
59+put In i get Codeaskt i
60+end
61+else
62+put Inlen 0 len Smallask
63+for i ulong len Smallask
64+put In i get Smallask i
65+end
66+end
67+end
68+fn incoming part ulong seq ulong kind ulong to void
69+outreset
70+off = ulong 0
71+size = ulong 4
72+if eq kind 1
73+off = ulong 4
74+size = ulong 5
75+end
76+if eq kind 2
77+off = ulong 9
78+size = ulong 5
79+end
80+for i ulong size
81+emitb get Prefixes add off i
82+end
83+emitn seq
84+if eq kind 0
85+for i ulong len Finaltxt
86+emitb get Finaltxt i
87+end
88+end
89+if eq kind 2
90+for i ulong len Codetxt
91+emitb get Codetxt i
92+end
93+end
94+copyout
95+b = packet 2 get Q 1 part 0 0
96+copyout
97+end
98+fn main to int
99+test not appinit 0 100
100+test appinit 42 100
101+test not appinit 43 100
102+test eq get Q 0 42
103+prompt false
104+test appask 100
105+test eq get R 0 1
106+test eq get Q 1 1
107+test eq get R 9 1
108+test eq get R 1 1
109+test eq get A 2 0
110+prompt false
111+test not appask 101
112+test eq get R 9 1
113+test apppoll 100 true
114+test eq get T 10 5
115+test appsent 100 true
116+test apppoll 100 true
117+test eq get T 10 1
118+copyout
119+test pkparse
120+test eq get N 1 1
121+test eq get In get N 5 74
122+test appsent 100 true
123+incoming 1 1 0
124+test appreceive 101
125+test eq get A 2 1
126+test eq get R 1 0
127+test eq get R 8 13
128+test eq get R 9 2
129+test eq get Answer 0 77
130+prompt true
131+test not appask 102
132+test eq get R 0 1
133+test apppoll 102 true
134+test eq get T 10 3
135+test appsent 102 true
136+note Code acknowledgement is visible immediately, but missing code requests AGAIN.
137+prompt true
138+test appask 103
139+test eq get R 0 2
140+test eq get Q 1 2
141+test eq get R 2 2
142+test eq get A 2 1
143+test eq get R 8 len Ack
144+test apppoll 103 true
145+test appsent 103 false
146+test apppoll 104 true
147+test eq get T 10 1
148+test appsent 104 true
149+incoming 1 2 0
150+test appreceive 105
151+test eq get A 2 2
152+test eq get A 1 len Againexp
153+test eq get R 1 1
154+test eq get R 13 1
155+test apppoll 105 true
156+test eq get T 10 3
157+test eq get Q 1 2
158+test appsent 105 true
159+test apppoll 106 true
160+test eq get T 10 1
161+test eq get Q 1 3
162+test eq get R 0 2
163+copyout
164+test pkparse
165+test eq get N 6 len Againexp
166+bad = ulong 0
167+for i ulong len Againexp
168+if ne get In add get N 5 i get Againexp i
169+bad = add bad 1
170+end
171+end
172+test eq bad 0
173+test appsent 106 true
174+incoming 1 2 0
175+test appreceive 107
176+test eq get A 2 3
177+test eq get R 1 0
178+test eq get A 1 0
179+note Reset cancels pending delivery without reusing either counter.
180+appreset
181+test eq get R 0 2
182+test eq get Q 1 3
183+test eq get R 9 0
184+prompt false
185+test appask 108
186+test eq get R 0 3
187+test eq get Q 1 4
188+test apppoll 108 true
189+test appsent 108 true
190+note Old CODE must not mutate the code buffer during a newer chat job.
191+incoming 1 2 2
192+test appreceive 109
193+test eq get A 2 4
194+test eq get C 1 0
195+test eq get C 2 0
196+test eq get Code 0 0
197+test apppoll 109 true
198+test appsent 109 true
199+incoming 2 2 0
200+test appreceive 109
201+test eq get A 2 4
202+test eq get R 1 1
203+test eq get R 8 0
204+test apppoll 109 true
205+test appsent 109 true
206+incoming 3 3 0
207+test appreceive 110
208+test eq get A 2 1
209+test eq get R 1 0
210+test eq get R 9 2
211+test apppoll 110 true
212+test appsent 110 true
213+note Cancellation drops an outstanding send and stale response safely.
214+prompt false
215+test appask 111
216+test apppoll 111 true
217+appcancel
218+test eq get R 1 0
219+test eq get T 5 0
220+test not appsent 111 true
221+incoming 1 4 0
222+test not appreceive 112
223+note Complete CODE bytes must arrive before a code response becomes visible.
224+prompt true
225+test appask 113
226+test eq get R 0 5
227+test eq get Q 1 6
228+test apppoll 113 true
229+test appsent 113 true
230+incoming 1 5 2
231+test appreceive 114
232+test eq get A 2 0
233+test eq codestat 2
234+test eq get R 6 0
235+test apppoll 114 true
236+test appsent 114 true
237+incoming 2 5 0
238+test appreceive 115
239+test eq get A 2 1
240+test eq get R 6 1
241+test eq get R 1 0
242+test eq get Code 6 49
243+test apppoll 115 true
244+test appsent 115 true
245+note WAIT updates silence deadline, no answer; slow and timeout cancel both layers.
246+prompt false
247+test appask 116
248+test eq get R 0 6
249+test apppoll 116 true
250+test appsent 116 true
251+incoming 1 6 1
252+test appreceive 117
253+test eq get A 2 0
254+test eq get R 4 117
255+test apppoll 117 true
256+test appsent 117 true
257+v = apppoll 20116 true
258+test eq get A 2 5
259+test eq get R 1 1
260+if v
261+test appsent 20116 true
262+end
263+v = apppoll 30116 true
264+test eq get R 1 1
265+if v
266+test appsent 30116 true
267+end
268+v = apppoll 30117 true
269+test eq get A 2 6
270+test eq get R 1 0
271+test eq get T 5 0
272+test eq get A 1 0
273+if v
274+test appsent 30117 true
275+end
276+n = get R 9
277+prompt false
278+test not appask 30116
279+test eq get R 9 n
280+test not apppoll 30116 true
281+note Invalid prompt never becomes a pending job or transcript line.
282+put Inlen 0 160
283+test not appask 30118
284+test eq get R 9 n
285+test eq get R 0 6
286+test eq get Q 1 7
287+note Receiving a code completion before send-result reporting cannot replace
288+note the pending datagram with the newly generated AGAIN text.
289+prompt true
290+test appask 30118
291+test apppoll 30118 true
292+test eq get T 10 1
293+holdwire
294+incoming 1 7 0
295+unhold
296+test appreceive 30119
297+test eq get A 2 2
298+test samewire
299+test eq get T 10 1
300+test appsent 30119 true
301+test apppoll 30120 true
302+test eq get T 10 3
303+test appsent 30120 true
304+test apppoll 30121 true
305+test eq get Q 1 9
306+test eq get R 0 7
307+test appsent 30121 true
308+appcancel
309+note Idle runtime still refuses a new prompt while a HELLO send is outstanding.
310+test apppoll 32122 true
311+test eq get T 10 5
312+holdwire
313+n = get R 9
314+prompt false
315+test not appask 32122
316+test samewire
317+test eq get R 9 n
318+test appsent 32122 true
319+note Late CODE may complete the original job before queued AGAIN is sent.
320+prompt true
321+test appask 32123
322+test eq get R 0 8
323+test eq get Q 1 10
324+test apppoll 32123 true
325+test appsent 32123 true
326+incoming 1 8 0
327+test appreceive 32124
328+test gt get A 1 0
329+test apppoll 32124 true
330+test appsent 32124 true
331+incoming 2 8 2
332+test appreceive 32125
333+test eq codestat 2
334+test apppoll 32125 true
335+test appsent 32125 true
336+incoming 3 8 0
337+test appreceive 32126
338+test eq get A 2 1
339+test eq get R 1 0
340+test eq get A 1 0
341+test apppoll 32126 true
342+test appsent 32126 true
343+test not apppoll 32127 true
344+test eq get Q 1 10
345+ret int get Fails 0
346+end

aienux/allen/tests/build-probe.om

new file mode 100644
@@ -0,0 +1,3 @@
1+fn main to int
2+ret 23
3+end

aienux/allen/tests/check.om

new file mode 100644
@@ -0,0 +1,17 @@
1+global Fails ulong 1
2+global Checks ulong 1
3+fn check ok bool id ulong to void
4+put Checks 0 add get Checks 0 1
5+outreset
6+emitn id
7+if ok
8+emitb 32
9+emitb 48
10+else
11+put Fails 0 add get Fails 0 1
12+emitb 32
13+emitb 49
14+end
15+emitb 10
16+w = write 1 Outb 0 get Outlen 0
17+end

aienux/allen/tests/code.om

new file mode 100644
@@ -0,0 +1,58 @@
1+text Wire "CODE 7 1/1 9 3ce11e06 python print(1)\\n"
2+text Badwire "CODE 7 1/1 9 3ce11e06 python print(2)\\n"
3+text Wrongjob "CODE 8 1/1 9 3ce11e06 python print(1)\\n"
4+text Badnum "CODE 4294967296 1/1 9 3ce11e06 python print(1)\\n"
5+fn wireload to void
6+put Inlen 0 len Wire
7+for i ulong len Wire
8+put In i get Wire i
9+end
10+end
11+fn main to int
12+codebeg 7
13+check eq codestat 0 101
14+check eq missing 1 102
15+wireload
16+check codetake 103
17+check eq codestat 2 104
18+check eq get C 4 1 105
19+check codetake 106
20+check eq get C 4 1 107
21+check eq missing 0 108
22+put R 0 7
23+put R 1 1
24+check codeshow 7 109
25+check eq get R 6 1 110
26+put Inlen 0 len Wrongjob
27+for i ulong len Wrongjob
28+put In i get Wrongjob i
29+end
30+check not codetake 111
31+check eq codestat 2 112
32+put Inlen 0 len Badwire
33+for i ulong len Badwire
34+put In i get Badwire i
35+end
36+check not codetake 113
37+check eq get Code 6 49 114
38+codebeg 7
39+check codetake 115
40+check eq codestat 3 116
41+check not codeshow 7 117
42+codebeg 7
43+put Inlen 0 len Badnum
44+for i ulong len Badnum
45+put In i get Badnum i
46+end
47+check not codetake 118
48+check eq get C 4 0 119
49+wireload
50+put Inlen 0 sub len Wire 1
51+check not codetake 120
52+check eq get C 4 0 121
53+wireload
54+check codetake 122
55+put R 0 8
56+check not codeshow 7 123
57+ret int get Fails 0
58+end

aienux/allen/tests/context.om

new file mode 100644
@@ -0,0 +1,359 @@
1+text Who "Drake"
2+text Selfname "Allen"
3+text Fkey "gate code"
4+text Fval "4471"
5+text Note0 "Meet at noon."
6+text Note1 "Old private note."
7+text Note3 "Bring tools."
8+text MetaWant "\tself=Allen\tname=Drake\tstarts=7\tfact gate code is 4471\tnote Bring tools.\tnote Meet at noon."
9+text NewOnly "\tself=Allen\tname=Drake\tstarts=7\tfact gate code is 4471\tnote Bring tools."
10+text Emptyctx "\tself=Allen\tstarts=0"
11+text Lastsix "\tself=Allen\tstarts=0\tnote N9\tnote N8\tnote N7\tnote N6\tnote N5\tnote N4"
12+text Plural "\tself=Allen\tname=Drake\tstarts=4294967295\tfact gate code are 4471"
13+global Unitsave uchar 8192
14+global Saveout uchar 8192
15+global Saveos ulong 2
16+fn test ok bool to void
17+put Saveos 0 get Outlen 0
18+put Saveos 1 get Err 0
19+for i ulong get Outlen 0
20+put Saveout i get Outb i
21+end
22+check ok add get Checks 0 1
23+for i ulong get Saveos 0
24+put Outb i get Saveout i
25+end
26+put Outlen 0 get Saveos 0
27+put Err 0 get Saveos 1
28+end
29+fn fixture index ulong gone ulong to void
30+put Ns 0 len Note0
31+put Ns 1 index
32+put Ns 2 7
33+put Ns 3 gone
34+for i ulong len Note0
35+put Note i get Note0 i
36+end
37+if eq index 1
38+put Ns 0 len Note1
39+for i ulong len Note1
40+put Note i get Note1 i
41+end
42+end
43+if eq index 3
44+put Ns 0 len Note3
45+for i ulong len Note3
46+put Note i get Note3 i
47+end
48+end
49+test noteenc
50+for i ulong 4096
51+put Unit i get Enc i
52+end
53+end
54+fn memsetup to void
55+for i ulong 3692
56+put Mem i 0
57+end
58+mset32 0 7
59+mset32 32 1
60+mset32 36 4
61+for i ulong len Who
62+put Mem add i 8 get Who i
63+end
64+for i ulong len Fkey
65+put Mem add i 40 get Fkey i
66+end
67+for i ulong len Fval
68+put Mem add i 88 get Fval i
69+end
70+for i ulong len Selfname
71+put Mem add i 153 get Selfname i
72+end
73+end
74+fn prompt to void
75+put Inlen 0 2
76+put In 0 104
77+put In 1 105
78+end
79+fn main to int
80+test appinit 123 0
81+test ctxmeta 6
82+test eq get Mx 0 len Emptyctx
83+same = true
84+for i ulong len Emptyctx
85+if ne get Meta i get Emptyctx i
86+same = false
87+end
88+end
89+test same
90+memsetup
91+test memenc 100
92+for i ulong 4096
93+put Unit i get Enc i
94+end
95+loadbeg
96+test loadcopy 0
97+test eq get St 0 100
98+test ctxbegin
99+test eq get Cx 0 4
100+test eq get Cx 1 0
101+test eq get Cx 2 0
102+test not ctxmeta 6
103+prompt
104+test not appask 0
105+test eq get R 0 0
106+test eq get Q 1 0
107+appcancel
108+fixture 3 0
109+test eq ctxtake 3 1
110+test eq get Ctxlen 3 len Note3
111+test eq get Ctxstart 3 7
112+test eq ctxtake 3 0
113+test eq get Cx 1 1
114+fixture 1 1
115+test eq ctxtake 1 1
116+test eq get Ctxgone 1 1
117+fixture 2 0
118+put Unit 64 33
119+test eq ctxtake 2 2
120+test eq get Cx 3 1
121+test eq get Ctxgone 2 1
122+test not ctxmeta 6
123+fixture 0 0
124+test eq ctxtake 0 1
125+test eq get Cx 1 4
126+test eq get Cx 2 1
127+test eq get Cx 4 0
128+test eq ctxtake 4 0
129+test ctxmeta 6
130+test eq get Mx 0 len MetaWant
131+same = true
132+for i ulong len MetaWant
133+if ne get Meta i get MetaWant i
134+same = false
135+end
136+end
137+test same
138+test ctxmeta 1
139+test eq get Mx 0 len NewOnly
140+same = true
141+for i ulong len NewOnly
142+if ne get Meta i get NewOnly i
143+same = false
144+end
145+end
146+test same
147+test not ctxmeta 513
148+test not ctxappend
149+test ctxmeta 6
150+outreset
151+emitb 120
152+test ctxappend
153+test eq get Outlen 0 add 1 len MetaWant
154+test eq get Outb 0 120
155+same = true
156+for i ulong len MetaWant
157+if ne get Outb add i 1 get MetaWant i
158+same = false
159+end
160+end
161+test same
162+note Exercise the actual appask -> qsubmit job snapshot, not only metadata helpers.
163+prompt
164+test appask 1
165+test eq get R 0 1
166+test eq get Q 1 1
167+test eq get R 9 1
168+n = get T 8
169+test ge n len MetaWant
170+same = ge n len MetaWant
171+if same
172+for i ulong len MetaWant
173+if ne get JobOut add sub n len MetaWant i get MetaWant i
174+same = false
175+end
176+end
177+end
178+test same
179+test not ctxbegin
180+test eq ctxtake 0 0
181+appcancel
182+note Exact append capacity and one byte above, preserving Outb/length/error on refusal.
183+test ctxmeta 6
184+n = sub ulong 4096 get Mx 0
185+put Outlen 0 n
186+for i ulong n
187+put Outb i 90
188+end
189+test ctxappend
190+test eq get Outlen 0 4096
191+put Outlen 0 add n 1
192+put Outb n 88
193+test not ctxappend
194+test eq get Outlen 0 add n 1
195+test eq get Outb n 88
196+put Err 0 5
197+test not ctxappend
198+test eq get Err 0 5
199+outreset
200+mset32 36 5
201+test not ctxmeta 6
202+mset32 36 4
203+mset32 32 33
204+prompt
205+test not appask 2
206+test eq get R 0 1
207+test eq get Q 1 1
208+mset32 32 1
209+note Deliberately full valid facts make metadata fit but the whole JOB exceed4096.
210+for i ulong 3692
211+put Mem i 0
212+end
213+mset32 32 32
214+for k ulong 32
215+off = add 40 mul k 113
216+for i ulong 47
217+put Mem add off i 107
218+end
219+for i ulong 63
220+put Mem add add off 48 i 118
221+end
222+end
223+test ctxmeta 6
224+test le get Mx 0 4096
225+prompt
226+test not appask 2
227+test eq get R 0 1
228+test eq get Q 1 1
229+test eq get R 9 1
230+note Catalog capacity and transaction exclusion.
231+mset32 36 512
232+test ctxbegin
233+test eq get Cx 0 512
234+test eq ctxtake 512 0
235+fixture 511 0
236+test eq ctxtake 511 1
237+test eq get Ctxlen 511 len Note0
238+test not ctxmeta 6
239+put Tx 0 1
240+test not ctxbegin
241+test eq ctxtake 0 0
242+put Tx 0 0
243+put Nt 0 1
244+test not ctxbegin
245+test eq ctxtake 0 0
246+put Nt 0 0
247+mset32 36 513
248+test not ctxbegin
249+test eq get Cx 0 512
250+note Load ten real records, select exactly the newest six, and allow zero selected.
251+for i ulong 3692
252+put Mem i 0
253+end
254+mset32 36 10
255+test ctxbegin
256+for k ulong 10
257+put Ns 0 2
258+put Ns 1 k
259+put Ns 2 7
260+put Ns 3 0
261+put Note 0 78
262+put Note 1 uchar add 48 k
263+test noteenc
264+for i ulong 4096
265+put Unit i get Enc i
266+end
267+test eq ctxtake k 1
268+end
269+test ctxmeta 6
270+test eq get Mx 0 len Lastsix
271+same = true
272+for i ulong len Lastsix
273+if ne get Meta i get Lastsix i
274+same = false
275+end
276+end
277+test same
278+test ctxmeta 0
279+test eq get Mx 0 len Emptyctx
280+note Context construction cannot overwrite a staged memory/note transaction image.
281+for i ulong 4096
282+put Unitsave i get Unit i
283+put Unitsave add i 4096 get Enc i
284+end
285+test ctxmeta 6
286+same = true
287+for i ulong 4096
288+if ne get Unit i get Unitsave i
289+same = false
290+end
291+if ne get Enc i get Unitsave add i 4096
292+same = false
293+end
294+end
295+test same
296+memsetup
297+mset32 36 0
298+mset32 0 4294967295
299+put Mem 152 1
300+test ctxmeta 6
301+test eq get Mx 0 len Plural
302+same = true
303+for i ulong len Plural
304+if ne get Meta i get Plural i
305+same = false
306+end
307+end
308+test same
309+put Mem 40 9
310+test not ctxmeta 6
311+test not ctxappend
312+put Mem 40 103
313+for i ulong 48
314+put Mem add i 40 107
315+end
316+test not ctxmeta 6
317+note Thirty-two full facts and six full notes overflow metadata itself, not only JOB.
318+for i ulong 3692
319+put Mem i 0
320+end
321+mset32 32 32
322+mset32 36 6
323+for k ulong 32
324+off = add 40 mul k 113
325+for i ulong 47
326+put Mem add off i 107
327+end
328+for i ulong 63
329+put Mem add add off 48 i 118
330+end
331+end
332+test ctxbegin
333+for k ulong 6
334+put Ns 0 127
335+put Ns 1 k
336+put Ns 2 7
337+put Ns 3 0
338+for i ulong 127
339+put Note i 110
340+end
341+test noteenc
342+for i ulong 4096
343+put Unit i get Enc i
344+end
345+test eq ctxtake k 1
346+end
347+test not ctxmeta 6
348+test eq get Mx 1 1
349+outreset
350+emitb 90
351+test not ctxappend
352+test eq get Outlen 0 1
353+test eq get Outb 0 90
354+prompt
355+test not appask 2
356+test eq get R 0 1
357+test eq get Q 1 1
358+ret int get Fails 0
359+end

aienux/allen/tests/courier.om

new file mode 100644
@@ -0,0 +1,63 @@
1+text Pkt "ALLEN-COURIER v=1 run=0123456789abcdef kind=LINE seq=7 part=1/0 bytes=0\nSAY 7 1/1 Model words."
2+fn pktload to void
3+put Inlen 0 len Pkt
4+for i ulong len Pkt
5+put In i get Pkt i
6+end
7+end
8+fn outin to void
9+put Inlen 0 get Outlen 0
10+for i ulong get Outlen 0
11+put In i get Outb i
12+end
13+end
14+fn main to int
15+qbegin 81985529216486895 7
16+pktload
17+check eq qreceive 1 201
18+check eq get Q 4 1 202
19+check eq qreceive 2 203
20+check eq get Q 4 1 204
21+check qtake 205
22+check eq get Inlen 0 22 206
23+check not qtake 207
24+pktload
25+put In 22 uchar 49
26+check eq qreceive 0 208
27+check eq get Q 2 1 209
28+pktload
29+put In 53 uchar 56
30+check eq qreceive 0 210
31+qbegin 81985529216486895 7
32+put Inlen 0 1
33+put In 0 uchar 120
34+b = packet 1 7 1 1 1
35+outin
36+check b 211
37+check eq qreceive 1 212
38+check eq get J 2 1 213
39+check eq get Jbuf 0 120 214
40+check eq qreceive 2 215
41+put In sub get Inlen 0 1 uchar 121
42+check eq qreceive 0 216
43+check eq get Jbuf 0 120 217
44+qbegin 81985529216486895 7
45+put Inlen 0 1
46+put In 0 uchar 122
47+b = packet 1 7 2 2 1001
48+outin
49+check b 218
50+check eq qreceive 1 219
51+check eq get J 2 1 220
52+put Inlen 0 1000
53+for i ulong 1000
54+put In i uchar 120
55+end
56+b = packet 1 7 1 2 1001
57+outin
58+check b 221
59+check eq qreceive 1 222
60+check eq get J 2 2 223
61+check eq get Jbuf 1000 122 224
62+ret int get Fails 0
63+end

aienux/allen/tests/edges.om

new file mode 100644
@@ -0,0 +1,157 @@
1+note Boundary and recovery gates. Test input construction is handwritten Omega.
2+fn rt_edges to void
3+reset
4+put R 0 100
5+put Inlen 0 159
6+for i ulong 159
7+put In i uchar 120
8+end
9+check start 1 0 1201
10+check eq get R 7 159 1202
11+cancel
12+put Inlen 0 160
13+check not start 1 0 1203
14+check eq get R 0 101 1204
15+put Inlen 0 1
16+put In 0 uchar 9
17+check not start 1 0 1205
18+check eq classify 0 1206
19+put In 0 uchar 120
20+check start 1 10 1207
21+check heard get R 0 25000 1208
22+check eq tick 30010 1 1209
23+check eq get R 1 1 1210
24+check eq tick 54999 0 1211
25+check eq tick 55000 2 1212
26+check not heard get R 0 55001 1213
27+check restore 1214
28+for i ulong 40
29+check restore add 1220 i
30+end
31+check eq get R 9 32 1260
32+check eq get Hlen 31 1 1261
33+check eq get Hist 4960 120 1262
34+end
35+fn codeinput part ulong total ulong bytes ulong crcval ulong count ulong to void
36+outreset
37+emitb 67
38+emitb 79
39+emitb 68
40+emitb 69
41+emitb 32
42+emitn 1
43+emitb 32
44+emitn part
45+emitb 47
46+emitn total
47+emitb 32
48+emitn bytes
49+emitb 32
50+for i ulong 8
51+emitb get Digits and shr crcval mul sub 7 i 4 15
52+end
53+emitb 32
54+emitb 45
55+emitb 32
56+for i ulong count
57+emitb 120
58+end
59+put Inlen 0 get Outlen 0
60+for i ulong get Outlen 0
61+put In i get Outb i
62+end
63+end
64+fn code_edges to void
65+codebeg 1
66+codeinput 1 1 128 0 127
67+check not codetake 1301
68+check eq get C 4 0 1302
69+codeinput 1 1 128 0 129
70+check not codetake 1303
71+codeinput 0 1 128 0 128
72+check not codetake 1304
73+codeinput 1 257 32769 0 128
74+check not codetake 1305
75+check eq get C 1 0 1306
76+for i ulong 256
77+codeinput add i 1 256 32768 3124632513 128
78+check codetake add 1310 i
79+end
80+check eq get C 4 256 1570
81+check eq missing 0 1571
82+check eq codestat 2 1572
83+put C 3 0
84+check eq codestat 3 1575
85+put C 3 3124632513
86+check eq codestat 2 1573
87+put R 0 1
88+put R 1 1
89+cancel
90+check not codeshow 1 1574
91+end
92+fn lineinput part ulong bytes ulong to void
93+put Inlen 0 bytes
94+for i ulong bytes
95+put In i uchar 120
96+end
97+b = packet 2 1 part 0 0
98+put Inlen 0 get Outlen 0
99+for i ulong get Outlen 0
100+put In i get Outb i
101+end
102+end
103+fn q_edges to void
104+qbegin 1 1
105+for i ulong 8
106+lineinput add i 1 1
107+check eq qreceive 1 add 1600 i
108+end
109+lineinput 9 1
110+check eq qreceive 0 1610
111+check eq get Q 4 8 1611
112+check qtake 1612
113+lineinput 9 1
114+check eq qreceive 1 1613
115+check eq get Q 4 8 1614
116+lineinput 10 320
117+check eq qreceive 0 1615
118+check eq get Q 2 9 1616
119+put Inlen 0 1001
120+check not packet 1 1 1 1 1001 1617
121+end
122+fn mem_edges to void
123+for i ulong 3692
124+put Mem i 0
125+end
126+mset32 32 32
127+mset32 36 512
128+for i ulong 32
129+off = add 40 mul i 113
130+put Mem off uchar 107
131+put Mem add off 48 uchar 118
132+end
133+check memenc 10 1701
134+check eq get32 12 3692 1702
135+check memdec 1703
136+mset32 32 33
137+check not memenc 11 1704
138+check eq get Enc 16 10 1705
139+mset32 32 32
140+mset32 36 513
141+check not memenc 11 1706
142+mset32 36 512
143+check memenc 11 1707
144+put Unit 4095 uchar 1
145+check not memdec 1708
146+check eq get Md 0 10 1709
147+check not txflush true 1710
148+check not txread true 1711
149+end
150+fn main to int
151+constants
152+rt_edges
153+code_edges
154+q_edges
155+mem_edges
156+ret int get Fails 0
157+end

aienux/allen/tests/fixture.om

new file mode 100644
@@ -0,0 +1,67 @@
1+note Native acceptance of frozen existing courier --split fixtures, reversed.
2+global Stream uchar 65536
3+global Starts ulong 257
4+global Sizes ulong 257
5+global Count ulong 1
6+fn partload slot ulong to void
7+n = get Sizes slot
8+put Inlen 0 n
9+for i ulong n
10+put In i get Stream add get Starts slot i
11+end
12+end
13+fn main to int
14+n = read 0 Stream 0 len Stream
15+if le n 0
16+ret 90
17+end
18+used = ulong n
19+while gt n 0
20+if eq used len Stream
21+ret 91
22+end
23+n = read 0 Stream used sub len Stream used
24+if lt n 0
25+ret 92
26+end
27+used = add used ulong n
28+end
29+startpos = ulong 0
30+for i ulong used
31+if eq get Stream i 10
32+if eq get Stream startpos 67
33+slot = get Count 0
34+if ge slot 256
35+ret 93
36+end
37+put Starts slot startpos
38+put Sizes slot sub i startpos
39+put Count 0 add slot 1
40+end
41+startpos = add i 1
42+end
43+end
44+codebeg 1
45+parts = get Count 0
46+check gt parts 1 401
47+for i ulong sub parts 1
48+partload sub sub parts 1 i
49+check codetake add 410 i
50+end
51+check eq codestat 1 402
52+check eq missing 1 403
53+partload 0
54+check codetake 404
55+check eq codestat 2 405
56+check eq get C 4 parts 406
57+for i ulong parts
58+partload i
59+check codetake add 700 i
60+end
61+check eq get C 4 parts 407
62+check eq codestat 2 408
63+partload 0
64+put In 5 uchar 50
65+check not codetake 409
66+ret int get Fails 0
67+end

aienux/allen/tests/font-mutants.om

new file mode 100644
@@ -0,0 +1,101 @@
1+note Reuse native mutation builder; selector0 square-root,1 full-coverage.
2+global Mutbuf uchar 262144
3+global Mutrep uchar 128
4+global Mutmode uchar 1
5+text Mutold0 "\nr = add shr r 1 bit\n"
6+text Mutnew0 "\nr = shr r 1\n"
7+text Mutold1 "\nif ge cov 256\nret 255\nend\n"
8+text Mutnew1 "\nif ge cov 256\nret 254\nend\n"
9+fn mutmatch at ulong mode uchar to bool
10+if eq mode 48
11+for i ulong len Mutold0
12+if ne get Mutbuf add at i get Mutold0 i
13+ret false
14+end
15+end
16+else
17+for i ulong len Mutold1
18+if ne get Mutbuf add at i get Mutold1 i
19+ret false
20+end
21+end
22+end
23+ret true
24+end
25+fn mutwrite at ulong size ulong to bool
26+p = ulong 0
27+while lt p size
28+n = write 1 Mutbuf add at p sub size p
29+if le n 0
30+ret false
31+end
32+p = add p ulong n
33+end
34+ret true
35+end
36+fn mutout n ulong mode uchar to int
37+old = len Mutold0
38+size = len Mutnew0
39+if eq mode 49
40+old = len Mutold1
41+size = len Mutnew1
42+end
43+if lt n old
44+ret 65
45+end
46+found = ulong 0
47+at = ulong 0
48+for i ulong add sub n old 1
49+if mutmatch i mode
50+found = add found 1
51+at = i
52+end
53+end
54+if ne found 1
55+ret 65
56+end
57+for i ulong size
58+if eq mode 48
59+put Mutrep i get Mutnew0 i
60+else
61+put Mutrep i get Mutnew1 i
62+end
63+end
64+if not mutwrite 0 at
65+ret 74
66+end
67+p = ulong 0
68+while lt p size
69+r = write 1 Mutrep p sub size p
70+if le r 0
71+ret 74
72+end
73+p = add p ulong r
74+end
75+if not mutwrite add at old sub n add at old
76+ret 74
77+end
78+ret 0
79+end
80+fn main to int
81+r = read 0 Mutmode 0 1
82+if ne r 1
83+ret 65
84+end
85+mode = get Mutmode 0
86+if and ne mode 48 ne mode 49
87+ret 65
88+end
89+n = ulong 0
90+while lt n len Mutbuf
91+r = read 0 Mutbuf n sub len Mutbuf n
92+if lt r 0
93+ret 74
94+end
95+if eq r 0
96+ret mutout n mode
97+end
98+n = add n ulong r
99+end
100+ret 65
101+end

aienux/allen/tests/font-output.om

new file mode 100644
@@ -0,0 +1,83 @@
1+note Native glyph stream for byte comparison with the external legacy oracle.
2+fn afword v ulong to void
3+for i ulong 8
4+emitb uchar and shr v mul i 8 255
5+end
6+end
7+fn afsigned v long to void
8+if lt v 0
9+afword xor ulong 18446744073709551615 ulong sub neg v 1
10+else
11+afword ulong v
12+end
13+end
14+fn afhead to bool
15+p = ulong 0
16+while lt p get Outlen 0
17+n = write 1 Outb p sub get Outlen 0 p
18+if le n 0
19+ret false
20+end
21+p = add p ulong n
22+end
23+ret true
24+end
25+fn afemit cap ulong wt ulong c uchar to bool
26+if not afglyph c
27+ret false
28+end
29+outreset
30+afword cap
31+afword wt
32+afword ulong c
33+afword get Af 3
34+afword get Af 4
35+afsigned get Ab 0
36+afsigned get Ab 1
37+afword get Af 5
38+if not afhead
39+ret false
40+end
41+size = mul get Af 3 get Af 4
42+p = ulong 0
43+while lt p size
44+n = write 1 Alpha p sub size p
45+if le n 0
46+ret false
47+end
48+p = add p ulong n
49+end
50+ret true
51+end
52+fn main to int
53+for mode ulong 3
54+cap = ulong 14
55+wt = ulong 900
56+if eq mode 1
57+cap = 30
58+wt = 1250
59+end
60+if eq mode 2
61+cap = 64
62+wt = 2500
63+end
64+if not afinit cap wt
65+ret 1
66+end
67+for i ulong 95
68+if not afemit cap wt uchar add i 32
69+ret 1
70+end
71+end
72+if not afemit cap wt 0
73+ret 1
74+end
75+if not afemit cap wt 127
76+ret 1
77+end
78+if not afemit cap wt 255
79+ret 1
80+end
81+end
82+ret 0
83+end

aienux/allen/tests/font-render.om

new file mode 100644
@@ -0,0 +1,79 @@
1+note Actual native 768x384 printable-ASCII specimen; no image generator.
2+note Uses the shared bounded RGB surface storage.
3+global Fpose long 2
4+text Fontppm "P6\n768 384\n255\n"
5+fn fblend bg ulong fg ulong a ulong to uchar
6+n = mul bg sub ulong 255 a
7+n = add n mul fg a
8+ret uchar div n 255
9+end
10+fn fpixel x long y long a uchar to void
11+if or lt x 0 ge x 768
12+ret
13+end
14+if or lt y 0 ge y 384
15+ret
16+end
17+at = mul add mul ulong y 768 ulong x 3
18+alpha = ulong a
19+put Canvas at fblend 6 236 alpha
20+put Canvas add at 1 fblend 8 240 alpha
21+put Canvas add at 2 fblend 18 252 alpha
22+end
23+fn frow yy ulong to void
24+y = add get Fpose 1 long yy
25+at = mul yy get Af 3
26+for x ulong get Af 3
27+px = add get Fpose 0 long x
28+a = get Alpha add at x
29+fpixel px y a
30+end
31+end
32+fn fdraw px long py long to void
33+put Fpose 0 add px get Ab 0
34+put Fpose 1 add py get Ab 1
35+for y ulong get Af 4
36+frow y
37+end
38+end
39+fn foutput to bool
40+p = ulong 0
41+while lt p len Fontppm
42+n = write 1 Fontppm p sub len Fontppm p
43+if le n 0
44+ret false
45+end
46+p = add p ulong n
47+end
48+p = 0
49+while lt p len Canvas
50+n = write 1 Canvas p sub len Canvas p
51+if le n 0
52+ret false
53+end
54+p = add p ulong n
55+end
56+ret true
57+end
58+fn main to int
59+if not afinit 30 1250
60+ret 1
61+end
62+for i ulong mul ulong 768 384
63+put Canvas mul i 3 6
64+put Canvas add mul i 3 1 8
65+put Canvas add mul i 3 2 18
66+end
67+for i ulong 95
68+if not afglyph uchar add i 32
69+ret 1
70+end
71+x = long add mul rem i 16 48 8
72+y = long add mul div i 16 64 45
73+fdraw x y
74+end
75+if not foutput
76+ret 74
77+end
78+ret 0
79+end

aienux/allen/tests/font.om

new file mode 100644
@@ -0,0 +1,114 @@
1+global Oldmask uchar 65536
2+global Oldmeta ulong 6
3+fn test ok bool to void
4+check ok add get Checks 0 1
5+end
6+fn asym to bool
7+w = get Af 3
8+for y ulong get Af 4
9+at = mul y w
10+for x ulong w
11+a = long get Alpha add at x
12+mirror = add at sub sub w 1 x
13+b = long get Alpha mirror
14+d = sub a b
15+if gt d 40
16+ret false
17+end
18+if lt d -40
19+ret false
20+end
21+end
22+end
23+ret true
24+end
25+fn main to int
26+test not afglyph 65
27+test not afinit 0 1250
28+test not afinit 65 1250
29+test not afinit 30 0
30+test not afinit 30 2501
31+test afinit 30 1250
32+test eq get Af 0 384
33+test eq get Af 1 480
34+test eq afsqrt 0 0
35+test eq afsqrt 15 3
36+test eq afsqrt 16 4
37+test eq afsqrt 18446744073709551615 4294967295
38+test eq afsqrt mul ulong 1000000007 1000000007 1000000007
39+test eq afsin 0 0
40+test eq afsin 90 16384
41+test eq afsin -90 -16384
42+test eq afsin 450 16384
43+test eq afcos 180 -16384
44+for c ulong 95
45+test afglyph uchar add c 32
46+test gt get Af 5 0
47+test le mul get Af 3 get Af 4 len Alpha
48+if eq c 0
49+test eq get Af 3 0
50+test eq get Af 4 1
51+else
52+ink = ulong 0
53+for i ulong mul get Af 3 get Af 4
54+if gt get Alpha i 128
55+ink = add ink 1
56+end
57+end
58+test ge ink 4
59+end
60+end
61+test afglyph 111
62+test asym
63+test afglyph 63
64+for i ulong mul get Af 3 get Af 4
65+put Oldmask i get Alpha i
66+end
67+for i ulong 6
68+put Oldmeta i get Af i
69+end
70+test afglyph 0
71+same = true
72+for i ulong 6
73+if ne get Oldmeta i get Af i
74+same = false
75+end
76+end
77+for i ulong mul get Af 3 get Af 4
78+if ne get Oldmask i get Alpha i
79+same = false
80+end
81+end
82+test same
83+test not afinit 999 1250
84+test eq get Af 0 get Oldmeta 0
85+test eq get Af 3 get Oldmeta 3
86+test afinit 64 2500
87+test afglyph 87
88+test le mul get Af 3 get Af 4 len Alpha
89+test afinit 1 1
90+test afglyph 65
91+note Independent analytic coverage for round-capped strokes and zero-length dots.
92+put Af 2 1
93+put Af 1 128
94+put Ag 0 0
95+put Ag 1 0
96+put Ag 2 512
97+put Ag 3 0
98+test eq afalpha 256 0 255
99+test eq afalpha 256 128 127
100+test eq afalpha 256 256 0
101+test eq afalpha 768 0 0
102+test eq afalpha -128 0 127
103+put Ag 0 512
104+put Ag 2 0
105+test eq afalpha 256 128 127
106+put Ag 0 0
107+test eq afalpha 0 0 255
108+test eq afalpha 0 128 127
109+test eq afalpha 0 256 0
110+if ne get Fails 0 0
111+ret 1
112+end
113+ret 0
114+end

aienux/allen/tests/github-fixtures.om

new file mode 100644
@@ -0,0 +1,8 @@
1+note SPDX-License-Identifier: AGPL-3.0-only
2+note TEST ONLY: real API response fixtures captured 2026-10-25, not runtime fallback.
3+note Metadata https://api.github.com/repos/aien-dev/allen
4+note Commit and contents pin e97222eb82f1ec56e852ba9571786db9ccc5c97a.
5+note Source JSON formatting follows the read tool; field bodies are preserved.
6+text Gxmeta "{\n \"id\": 1427000265,\n \"node_id\": \"R_kgDOVQ5LyQ\",\n \"name\": \"allen\",\n \"full_name\": \"aien-dev/allen\",\n \"private\": false,\n \"owner\": {\n \"login\": \"aien-dev\",\n \"id\": 342055988,\n \"node_id\": \"O_kgDOFGNcNA\",\n \"avatar_url\": \"https://avatars.githubusercontent.com/u/342055988?v=4\",\n \"gravatar_id\": \"\",\n \"url\": \"https://api.github.com/users/aien-dev\",\n \"html_url\": \"https://github.com/aien-dev\",\n \"followers_url\": \"https://api.github.com/users/aien-dev/followers\",\n \"following_url\": \"https://api.github.com/users/aien-dev/following{/other_user}\",\n \"gists_url\": \"https://api.github.com/users/aien-dev/gists{/gist_id}\",\n \"starred_url\": \"https://api.github.com/users/aien-dev/starred{/owner}{/repo}\",\n \"subscriptions_url\": \"https://api.github.com/users/aien-dev/subscriptions\",\n \"organizations_url\": \"https://api.github.com/users/aien-dev/orgs\",\n \"repos_url\": \"https://api.github.com/users/aien-dev/repos\",\n \"events_url\": \"https://api.github.com/users/aien-dev/events{/privacy}\",\n \"received_events_url\": \"https://api.github.com/users/aien-dev/received_events\",\n \"type\": \"Organization\",\n \"user_view_type\": \"public\",\n \"site_admin\": false\n },\n \"html_url\": \"https://github.com/aien-dev/allen\",\n \"description\": \"Allen: AIEN's persistent subject, one identity across the iMac, Pi, Spark and MacBook. Project home for the Allen programme (P0 to P7), B0 acceptance contract, data contracts, evaluation harness. Pre-alpha.\",\n \"fork\": false,\n \"url\": \"https://api.github.com/repos/aien-dev/allen\",\n \"forks_url\": \"https://api.github.com/repos/aien-dev/allen/forks\",\n \"keys_url\": \"https://api.github.com/repos/aien-dev/allen/keys{/key_id}\",\n \"collaborators_url\": \"https://api.github.com/repos/aien-dev/allen/collaborators{/collaborator}\",\n \"teams_url\": \"https://api.github.com/repos/aien-dev/allen/teams\",\n \"hooks_url\": \"https://api.github.com/repos/aien-dev/allen/hooks\",\n \"issue_events_url\": \"https://api.github.com/repos/aien-dev/allen/issues/events{/number}\",\n \"events_url\": \"https://api.github.com/repos/aien-dev/allen/events\",\n \"assignees_url\": \"https://api.github.com/repos/aien-dev/allen/assignees{/user}\",\n \"branches_url\": \"https://api.github.com/repos/aien-dev/allen/branches{/branch}\",\n \"tags_url\": \"https://api.github.com/repos/aien-dev/allen/tags\",\n \"blobs_url\": \"https://api.github.com/repos/aien-dev/allen/git/blobs{/sha}\",\n \"git_tags_url\": \"https://api.github.com/repos/aien-dev/allen/git/tags{/sha}\",\n \"git_refs_url\": \"https://api.github.com/repos/aien-dev/allen/git/refs{/sha}\",\n \"trees_url\": \"https://api.github.com/repos/aien-dev/allen/git/trees{/sha}\",\n \"statuses_url\": \"https://api.github.com/repos/aien-dev/allen/statuses/{sha}\",\n \"languages_url\": \"https://api.github.com/repos/aien-dev/allen/languages\",\n \"stargazers_url\": \"https://api.github.com/repos/aien-dev/allen/stargazers\",\n \"contributors_url\": \"https://api.github.com/repos/aien-dev/allen/contributors\",\n \"subscribers_url\": \"https://api.github.com/repos/aien-dev/allen/subscribers\",\n \"subscription_url\": \"https://api.github.com/repos/aien-dev/allen/subscription\",\n \"commits_url\": \"https://api.github.com/repos/aien-dev/allen/commits{/sha}\",\n \"git_commits_url\": \"https://api.github.com/repos/aien-dev/allen/git/commits{/sha}\",\n \"comments_url\": \"https://api.github.com/repos/aien-dev/allen/comments{/number}\",\n \"issue_comment_url\": \"https://api.github.com/repos/aien-dev/allen/issues/comments{/number}\",\n \"contents_url\": \"https://api.github.com/repos/aien-dev/allen/contents/{+path}\",\n \"compare_url\": \"https://api.github.com/repos/aien-dev/allen/compare/{base}...{head}\",\n \"merges_url\": \"https://api.github.com/repos/aien-dev/allen/merges\",\n \"archive_url\": \"https://api.github.com/repos/aien-dev/allen/{archive_format}{/ref}\",\n \"downloads_url\": \"https://api.github.com/repos/aien-dev/allen/downloads\",\n \"issues_url\": \"https://api.github.com/repos/aien-dev/allen/issues{/number}\",\n \"pulls_url\": \"https://api.github.com/repos/aien-dev/allen/pulls{/number}\",\n \"milestones_url\": \"https://api.github.com/repos/aien-dev/allen/milestones{/number}\",\n \"notifications_url\": \"https://api.github.com/repos/aien-dev/allen/notifications{?since,all,participating}\",\n \"labels_url\": \"https://api.github.com/repos/aien-dev/allen/labels{/name}\",\n \"releases_url\": \"https://api.github.com/repos/aien-dev/allen/releases{/id}\",\n \"deployments_url\": \"https://api.github.com/repos/aien-dev/allen/deployments\",\n \"created_at\": \"2026-10-20T12:33:56Z\",\n \"updated_at\": \"2026-10-23T15:27:04Z\",\n \"pushed_at\": \"2026-10-24T18:38:09Z\",\n \"git_url\": \"git://github.com/aien-dev/allen.git\",\n \"ssh_url\": \"git@github.com:aien-dev/allen.git\",\n \"clone_url\": \"https://github.com/aien-dev/allen.git\",\n \"svn_url\": \"https://github.com/aien-dev/allen\",\n \"homepage\": null,\n \"size\": 268,\n \"stargazers_count\": 0,\n \"watchers_count\": 0,\n \"language\": null,\n \"has_issues\": true,\n \"has_projects\": true,\n \"has_downloads\": false,\n \"has_wiki\": false,\n \"has_pages\": false,\n \"has_discussions\": false,\n \"forks_count\": 0,\n \"mirror_url\": null,\n \"archived\": false,\n \"disabled\": false,\n \"open_issues_count\": 14,\n \"license\": {\n \"key\": \"agpl-3.0\",\n \"name\": \"GNU Affero General Public License v3.0\",\n \"spdx_id\": \"AGPL-3.0\",\n \"url\": \"https://api.github.com/licenses/agpl-3.0\",\n \"node_id\": \"MDc6TGljZW5zZTE=\"\n },\n \"allow_forking\": true,\n \"is_template\": false,\n \"web_commit_signoff_required\": false,\n \"has_pull_requests\": true,\n \"pull_request_creation_policy\": \"all\",\n \"topics\": [],\n \"visibility\": \"public\",\n \"forks\": 0,\n \"open_issues\": 14,\n \"watchers\": 0,\n \"default_branch\": \"main\",\n \"temp_clone_token\": null,\n \"custom_properties\": {},\n \"organization\": {\n \"login\": \"aien-dev\",\n \"id\": 342055988,\n \"node_id\": \"O_kgDOFGNcNA\",\n \"avatar_url\": \"https://avatars.githubusercontent.com/u/342055988?v=4\",\n \"gravatar_id\": \"\",\n \"url\": \"https://api.github.com/users/aien-dev\",\n \"html_url\": \"https://github.com/aien-dev\",\n \"followers_url\": \"https://api.github.com/users/aien-dev/followers\",\n \"following_url\": \"https://api.github.com/users/aien-dev/following{/other_user}\",\n \"gists_url\": \"https://api.github.com/users/aien-dev/gists{/gist_id}\",\n \"starred_url\": \"https://api.github.com/users/aien-dev/starred{/owner}{/repo}\",\n \"subscriptions_url\": \"https://api.github.com/users/aien-dev/subscriptions\",\n \"organizations_url\": \"https://api.github.com/users/aien-dev/orgs\",\n \"repos_url\": \"https://api.github.com/users/aien-dev/repos\",\n \"events_url\": \"https://api.github.com/users/aien-dev/events{/privacy}\",\n \"received_events_url\": \"https://api.github.com/users/aien-dev/received_events\",\n \"type\": \"Organization\",\n \"user_view_type\": \"public\",\n \"site_admin\": false\n },\n \"network_count\": 0,\n \"subscribers_count\": 0\n}"
7+text Gxcommit "{\n \"sha\": \"e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"node_id\": \"C_kwDOVQ5LydoAKGU5NzIyMmViODJmMWVjNTZlODUyYmE5NTcxNzg2ZGI5Y2NjNWM5N2E\",\n \"commit\": {\n \"author\": {\n \"name\": \"Drake Stapleton\",\n \"email\": \"drake@aienos.com\",\n \"date\": \"2026-10-20T12:35:09Z\"\n },\n \"committer\": {\n \"name\": \"Drake Stapleton\",\n \"email\": \"drake@aienos.com\",\n \"date\": \"2026-10-20T12:35:09Z\"\n },\n \"message\": \"P0: phase ledger with transferred issue numbers (#1 programme, #2..#9 = P0..P7)\",\n \"tree\": {\n \"sha\": \"2a83aef799f4c3c3585c2e29277cadc2f86c5b51\",\n \"url\": \"https://api.github.com/repos/aien-dev/allen/git/trees/2a83aef799f4c3c3585c2e29277cadc2f86c5b51\"\n },\n \"url\": \"https://api.github.com/repos/aien-dev/allen/git/commits/e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"comment_count\": 0,\n \"verification\": {\n \"verified\": false,\n \"reason\": \"unsigned\",\n \"signature\": null,\n \"payload\": null,\n \"verified_at\": null\n }\n },\n \"url\": \"https://api.github.com/repos/aien-dev/allen/commits/e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"html_url\": \"https://github.com/aien-dev/allen/commit/e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"comments_url\": \"https://api.github.com/repos/aien-dev/allen/commits/e97222eb82f1ec56e852ba9571786db9ccc5c97a/comments\",\n \"author\": {\n \"login\": \"drakestapleton\",\n \"id\": 213298340,\n \"node_id\": \"U_kgDODLaspA\",\n \"avatar_url\": \"https://avatars.githubusercontent.com/u/213298340?v=4\",\n \"gravatar_id\": \"\",\n \"url\": \"https://api.github.com/users/drakestapleton\",\n \"html_url\": \"https://github.com/drakestapleton\",\n \"followers_url\": \"https://api.github.com/users/drakestapleton/followers\",\n \"following_url\": \"https://api.github.com/users/drakestapleton/following{/other_user}\",\n \"gists_url\": \"https://api.github.com/users/drakestapleton/gists{/gist_id}\",\n \"starred_url\": \"https://api.github.com/users/drakestapleton/starred{/owner}{/repo}\",\n \"subscriptions_url\": \"https://api.github.com/users/drakestapleton/subscriptions\",\n \"organizations_url\": \"https://api.github.com/users/drakestapleton/orgs\",\n \"repos_url\": \"https://api.github.com/users/drakestapleton/repos\",\n \"events_url\": \"https://api.github.com/users/drakestapleton/events{/privacy}\",\n \"received_events_url\": \"https://api.github.com/users/drakestapleton/received_events\",\n \"type\": \"User\",\n \"user_view_type\": \"public\",\n \"site_admin\": false\n },\n \"committer\": {\n \"login\": \"drakestapleton\",\n \"id\": 213298340,\n \"node_id\": \"U_kgDODLaspA\",\n \"avatar_url\": \"https://avatars.githubusercontent.com/u/213298340?v=4\",\n \"gravatar_id\": \"\",\n \"url\": \"https://api.github.com/users/drakestapleton\",\n \"html_url\": \"https://github.com/drakestapleton\",\n \"followers_url\": \"https://api.github.com/users/drakestapleton/followers\",\n \"following_url\": \"https://api.github.com/users/drakestapleton/following{/other_user}\",\n \"gists_url\": \"https://api.github.com/users/drakestapleton/gists{/gist_id}\",\n \"starred_url\": \"https://api.github.com/users/drakestapleton/starred{/owner}{/repo}\",\n \"subscriptions_url\": \"https://api.github.com/users/drakestapleton/subscriptions\",\n \"organizations_url\": \"https://api.github.com/users/drakestapleton/orgs\",\n \"repos_url\": \"https://api.github.com/users/drakestapleton/repos\",\n \"events_url\": \"https://api.github.com/users/drakestapleton/events{/privacy}\",\n \"received_events_url\": \"https://api.github.com/users/drakestapleton/received_events\",\n \"type\": \"User\",\n \"user_view_type\": \"public\",\n \"site_admin\": false\n },\n \"parents\": [\n {\n \"sha\": \"2949450005a2df34e48da90bd40037841d49b3da\",\n \"url\": \"https://api.github.com/repos/aien-dev/allen/commits/2949450005a2df34e48da90bd40037841d49b3da\",\n \"html_url\": \"https://github.com/aien-dev/allen/commit/2949450005a2df34e48da90bd40037841d49b3da\"\n }\n ],\n \"stats\": {\n \"total\": 30,\n \"additions\": 29,\n \"deletions\": 1\n },\n \"files\": [\n {\n \"sha\": \"d42f5dea4ca628f6ee539da8d2b732b52faf03ec\",\n \"filename\": \"docs/PHASES.md\",\n \"status\": \"modified\",\n \"additions\": 29,\n \"deletions\": 1,\n \"changes\": 30,\n \"blob_url\": \"https://github.com/aien-dev/allen/blob/e97222eb82f1ec56e852ba9571786db9ccc5c97a/docs%2FPHASES.md\",\n \"raw_url\": \"https://github.com/aien-dev/allen/raw/e97222eb82f1ec56e852ba9571786db9ccc5c97a/docs%2FPHASES.md\",\n \"contents_url\": \"https://api.github.com/repos/aien-dev/allen/contents/docs%2FPHASES.md?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"patch\": \"@@ -1,3 +1,31 @@\\n # Phase ledger\\n \\n-Filled after the issue transfer (coordinator).\\n+Programme issue: [aien-dev/allen#1](https://github.com/aien-dev/allen/issues/1) (transferred 2026-10-20 from aien-architecture-mv#278; the old URL redirects, comments and history preserved).\\n+\\n+Phase numbers are sequence, not priority. Progress status words: PROPOSED, SCOPED, ACTIVE, IN_REVIEW, COMPLETE. Qualification verdicts are separate: PASS, FAIL, INCONCLUSIVE, NOT_RUN. A phase closes only with its acceptance evidence; the programme close guard (`guard/`) reopens the programme otherwise.\\n+\\n+| Phase | Issue here | Former issue | Title | Status | Qualification |\\n+|---|---|---|---|---|---|\\n+| P0 | [#2](https://github.com/aien-dev/allen/issues/2) | arch#279 | Establish Allen's own repository, mission and B0 acceptance contract | ACTIVE (2026-10-20) | NOT_RUN |\\n+| P1 | [#3](https://github.com/aien-dev/allen/issues/3) | arch#280 | Build reproducible training episodes from the existing conversation archive | PROPOSED | NOT_RUN |\\n+| P2 | [#4](https://github.com/aien-dev/allen/issues/4) | arch#281 | Label human intent, corrections, successes and failures with evidence | PROPOSED | NOT_RUN |\\n+| P3 | [#5](https://github.com/aien-dev/allen/issues/5) | arch#282 | Freeze leakage-resistant evaluations and measure the baseline | PROPOSED | NOT_RUN |\\n+| P4 | [#6](https://github.com/aien-dev/allen/issues/6) | arch#283 | Train and compare a bounded first personal Allen candidate | PROPOSED | NOT_RUN |\\n+| P5 | [#7](https://github.com/aien-dev/allen/issues/7) | arch#284 | Qualify Allen B0 through one complete personal-assistance experience | PROPOSED | NOT_RUN |\\n+| P6 | [#8](https://github.com/aien-dev/allen/issues/8) | arch#285 | Keep one Allen continuous across iMac, Pi, Spark and MacBook | PROPOSED | NOT_RUN |\\n+| P7 | [#9](https://github.com/aien-dev/allen/issues/9) | arch#286 | Learn continually and anticipate useful help under bounded exploration | PROPOSED | NOT_RUN |\\n+\\n+Order: P0 -> P1 -> P2 -> P3 -> P4 -> P5 produces B0 only if its gates pass; P6 extends continuity to the four devices; P7 adds evaluated continual learning. P3's evaluation schema may be drafted during P1/P2, but evaluation data is isolated before any fitting, retrieval indexing or preference extraction.\\n+\\n+## Mandatory external prerequisites (programme cannot close while any is open)\\n+\\n+Verified OPEN when the gate was written (2026-10-20). The close guard reads this list from `guard/policy.toml`; keep both in step.\\n+\\n+| Area | Issues |\\n+|---|---|\\n+| Identity, persona, experience, release | aien-architecture-mv #159, #269, #190 |\\n+| Physical Pi to Spark execution and independent acceptance | aien-architecture-mv #231, #232; aienos-mv #396, #398, #399; aien-protocols-mv #27; aien-sovereign-core-mv #586; omega-mv #505; aegis-runtime-mv #53 |\\n+| Native Spark model path | aienos-mv #286, #327 (evaluated under aien-architecture-mv #190) |\\n+| Learning economics and out-of-sample evidence | aien-architecture-mv #246, #262, #263, #276; omega-mv #583, #584, #600 |\\n+\\n+P6 owns the remaining iMac and MacBook physical qualification if no existing issue owns it.\"\n }\n ]\n}"
8+text Gxfiles "[\n {\n \"name\": \".gitignore\",\n \"path\": \".gitignore\",\n \"sha\": \"390c8e3273edabcd8e2c1578fa34c90724dce7d0\",\n \"size\": 197,\n \"url\": \"https://api.github.com/repos/aien-dev/allen/contents/.gitignore?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"html_url\": \"https://github.com/aien-dev/allen/blob/e97222eb82f1ec56e852ba9571786db9ccc5c97a/.gitignore\",\n \"git_url\": \"https://api.github.com/repos/aien-dev/allen/git/blobs/390c8e3273edabcd8e2c1578fa34c90724dce7d0\",\n \"download_url\": \"https://raw.githubusercontent.com/aien-dev/allen/e97222eb82f1ec56e852ba9571786db9ccc5c97a/.gitignore\",\n \"type\": \"file\",\n \"_links\": {\n \"self\": \"https://api.github.com/repos/aien-dev/allen/contents/.gitignore?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"git\": \"https://api.github.com/repos/aien-dev/allen/git/blobs/390c8e3273edabcd8e2c1578fa34c90724dce7d0\",\n \"html\": \"https://github.com/aien-dev/allen/blob/e97222eb82f1ec56e852ba9571786db9ccc5c97a/.gitignore\"\n }\n },\n {\n \"name\": \"AGENTS.md\",\n \"path\": \"AGENTS.md\",\n \"sha\": \"be2dc5881948cb8140a5e500ce71e45b5a34f88b\",\n \"size\": 1985,\n \"url\": \"https://api.github.com/repos/aien-dev/allen/contents/AGENTS.md?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"html_url\": \"https://github.com/aien-dev/allen/blob/e97222eb82f1ec56e852ba9571786db9ccc5c97a/AGENTS.md\",\n \"git_url\": \"https://api.github.com/repos/aien-dev/allen/git/blobs/be2dc5881948cb8140a5e500ce71e45b5a34f88b\",\n \"download_url\": \"https://raw.githubusercontent.com/aien-dev/allen/e97222eb82f1ec56e852ba9571786db9ccc5c97a/AGENTS.md\",\n \"type\": \"file\",\n \"_links\": {\n \"self\": \"https://api.github.com/repos/aien-dev/allen/contents/AGENTS.md?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"git\": \"https://api.github.com/repos/aien-dev/allen/git/blobs/be2dc5881948cb8140a5e500ce71e45b5a34f88b\",\n \"html\": \"https://github.com/aien-dev/allen/blob/e97222eb82f1ec56e852ba9571786db9ccc5c97a/AGENTS.md\"\n }\n },\n {\n \"name\": \"LICENSE\",\n \"path\": \"LICENSE\",\n \"sha\": \"be3f7b28e564e7dd05eaf59d64adba1a4065ac0e\",\n \"size\": 34523,\n \"url\": \"https://api.github.com/repos/aien-dev/allen/contents/LICENSE?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"html_url\": \"https://github.com/aien-dev/allen/blob/e97222eb82f1ec56e852ba9571786db9ccc5c97a/LICENSE\",\n \"git_url\": \"https://api.github.com/repos/aien-dev/allen/git/blobs/be3f7b28e564e7dd05eaf59d64adba1a4065ac0e\",\n \"download_url\": \"https://raw.githubusercontent.com/aien-dev/allen/e97222eb82f1ec56e852ba9571786db9ccc5c97a/LICENSE\",\n \"type\": \"file\",\n \"_links\": {\n \"self\": \"https://api.github.com/repos/aien-dev/allen/contents/LICENSE?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"git\": \"https://api.github.com/repos/aien-dev/allen/git/blobs/be3f7b28e564e7dd05eaf59d64adba1a4065ac0e\",\n \"html\": \"https://github.com/aien-dev/allen/blob/e97222eb82f1ec56e852ba9571786db9ccc5c97a/LICENSE\"\n }\n },\n {\n \"name\": \"README.md\",\n \"path\": \"README.md\",\n \"sha\": \"b6d15246083290c3c4a0d4acf8e6e4bfd1fd6116\",\n \"size\": 2720,\n \"url\": \"https://api.github.com/repos/aien-dev/allen/contents/README.md?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"html_url\": \"https://github.com/aien-dev/allen/blob/e97222eb82f1ec56e852ba9571786db9ccc5c97a/README.md\",\n \"git_url\": \"https://api.github.com/repos/aien-dev/allen/git/blobs/b6d15246083290c3c4a0d4acf8e6e4bfd1fd6116\",\n \"download_url\": \"https://raw.githubusercontent.com/aien-dev/allen/e97222eb82f1ec56e852ba9571786db9ccc5c97a/README.md\",\n \"type\": \"file\",\n \"_links\": {\n \"self\": \"https://api.github.com/repos/aien-dev/allen/contents/README.md?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"git\": \"https://api.github.com/repos/aien-dev/allen/git/blobs/b6d15246083290c3c4a0d4acf8e6e4bfd1fd6116\",\n \"html\": \"https://github.com/aien-dev/allen/blob/e97222eb82f1ec56e852ba9571786db9ccc5c97a/README.md\"\n }\n },\n {\n \"name\": \"docs\",\n \"path\": \"docs\",\n \"sha\": \"d8aaf6c45adb0d7df2a30f67d227b54a5314b460\",\n \"size\": 0,\n \"url\": \"https://api.github.com/repos/aien-dev/allen/contents/docs?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"html_url\": \"https://github.com/aien-dev/allen/tree/e97222eb82f1ec56e852ba9571786db9ccc5c97a/docs\",\n \"git_url\": \"https://api.github.com/repos/aien-dev/allen/git/trees/d8aaf6c45adb0d7df2a30f67d227b54a5314b460\",\n \"download_url\": null,\n \"type\": \"dir\",\n \"_links\": {\n \"self\": \"https://api.github.com/repos/aien-dev/allen/contents/docs?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"git\": \"https://api.github.com/repos/aien-dev/allen/git/trees/d8aaf6c45adb0d7df2a30f67d227b54a5314b460\",\n \"html\": \"https://github.com/aien-dev/allen/tree/e97222eb82f1ec56e852ba9571786db9ccc5c97a/docs\"\n }\n },\n {\n \"name\": \"evidence\",\n \"path\": \"evidence\",\n \"sha\": \"d564d0bc3dd917926892c55e3706cc116d5b165e\",\n \"size\": 0,\n \"url\": \"https://api.github.com/repos/aien-dev/allen/contents/evidence?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"html_url\": \"https://github.com/aien-dev/allen/tree/e97222eb82f1ec56e852ba9571786db9ccc5c97a/evidence\",\n \"git_url\": \"https://api.github.com/repos/aien-dev/allen/git/trees/d564d0bc3dd917926892c55e3706cc116d5b165e\",\n \"download_url\": null,\n \"type\": \"dir\",\n \"_links\": {\n \"self\": \"https://api.github.com/repos/aien-dev/allen/contents/evidence?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"git\": \"https://api.github.com/repos/aien-dev/allen/git/trees/d564d0bc3dd917926892c55e3706cc116d5b165e\",\n \"html\": \"https://github.com/aien-dev/allen/tree/e97222eb82f1ec56e852ba9571786db9ccc5c97a/evidence\"\n }\n },\n {\n \"name\": \"guard\",\n \"path\": \"guard\",\n \"sha\": \"d564d0bc3dd917926892c55e3706cc116d5b165e\",\n \"size\": 0,\n \"url\": \"https://api.github.com/repos/aien-dev/allen/contents/guard?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"html_url\": \"https://github.com/aien-dev/allen/tree/e97222eb82f1ec56e852ba9571786db9ccc5c97a/guard\",\n \"git_url\": \"https://api.github.com/repos/aien-dev/allen/git/trees/d564d0bc3dd917926892c55e3706cc116d5b165e\",\n \"download_url\": null,\n \"type\": \"dir\",\n \"_links\": {\n \"self\": \"https://api.github.com/repos/aien-dev/allen/contents/guard?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"git\": \"https://api.github.com/repos/aien-dev/allen/git/trees/d564d0bc3dd917926892c55e3706cc116d5b165e\",\n \"html\": \"https://github.com/aien-dev/allen/tree/e97222eb82f1ec56e852ba9571786db9ccc5c97a/guard\"\n }\n },\n {\n \"name\": \"inventory\",\n \"path\": \"inventory\",\n \"sha\": \"d564d0bc3dd917926892c55e3706cc116d5b165e\",\n \"size\": 0,\n \"url\": \"https://api.github.com/repos/aien-dev/allen/contents/inventory?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"html_url\": \"https://github.com/aien-dev/allen/tree/e97222eb82f1ec56e852ba9571786db9ccc5c97a/inventory\",\n \"git_url\": \"https://api.github.com/repos/aien-dev/allen/git/trees/d564d0bc3dd917926892c55e3706cc116d5b165e\",\n \"download_url\": null,\n \"type\": \"dir\",\n \"_links\": {\n \"self\": \"https://api.github.com/repos/aien-dev/allen/contents/inventory?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"git\": \"https://api.github.com/repos/aien-dev/allen/git/trees/d564d0bc3dd917926892c55e3706cc116d5b165e\",\n \"html\": \"https://github.com/aien-dev/allen/tree/e97222eb82f1ec56e852ba9571786db9ccc5c97a/inventory\"\n }\n },\n {\n \"name\": \"scripts\",\n \"path\": \"scripts\",\n \"sha\": \"d564d0bc3dd917926892c55e3706cc116d5b165e\",\n \"size\": 0,\n \"url\": \"https://api.github.com/repos/aien-dev/allen/contents/scripts?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"html_url\": \"https://github.com/aien-dev/allen/tree/e97222eb82f1ec56e852ba9571786db9ccc5c97a/scripts\",\n \"git_url\": \"https://api.github.com/repos/aien-dev/allen/git/trees/d564d0bc3dd917926892c55e3706cc116d5b165e\",\n \"download_url\": null,\n \"type\": \"dir\",\n \"_links\": {\n \"self\": \"https://api.github.com/repos/aien-dev/allen/contents/scripts?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a\",\n \"git\": \"https://api.github.com/repos/aien-dev/allen/git/trees/d564d0bc3dd917926892c55e3706cc116d5b165e\",\n \"html\": \"https://github.com/aien-dev/allen/tree/e97222eb82f1ec56e852ba9571786db9ccc5c97a/scripts\"\n }\n }\n]"

aienux/allen/tests/github.om

new file mode 100644
@@ -0,0 +1,413 @@
1+note SPDX-License-Identifier: AGPL-3.0-only
2+note Compose committed gate core + github.om + repository-screen.om + check.om
3+note + github-fixtures.om + this file. Exit0 means every behavioral assertion passed.
4+note Fixtures never enter production composition. Network/TLS are not tested here.
5+text Gxask "Please find your current Git repo"
6+text Gxask2 "Allen, could you open the GitHub repository?"
7+text Gxno "Create a repository for another project"
8+text Gxesc "{\"full_name\":\"aien-dev/allen\",\"private\":false,\"html_url\":\"https://github.com/aien-dev/allen\",\"default_branch\":\"feature/demo\",\"description\":\"say \\\"hi\\\" \\\\ \\u00e9 \\ud83d\\ude00\"}"
9+text Gxdup "{\"full_name\":\"aien-dev/allen\",\"private\":false,\"html_url\":\"https://github.com/aien-dev/allen\",\"default_branch\":\"main\",\"default_\\u0062ranch\":\"evil\",\"description\":null}"
10+text Gxwrong "{\"full_name\":\"aien-dev/not-allen\",\"private\":false,\"html_url\":\"https://github.com/aien-dev/allen\",\"default_branch\":\"main\",\"description\":null}"
11+text Gxbad "{\"a\":1,}\n{\"x\":\"\\q\"}\n{\"x\":\"\\ud800\"}\n[01]\n{}{}\n{\"x\":1e}\n{\"x\":true false}\n"
12+text Gxdirbad "[{\"path\":\"../escape\",\"type\":\"file\",\"size\":0,\"sha\":\"e97222eb82f1ec56e852ba9571786db9ccc5c97a\"}]"
13+text Gxchild "[{\"path\":\"docs/PHASES.md\",\"type\":\"file\",\"size\":2345,\"sha\":\"d42f5dea4ca628f6ee539da8d2b732b52faf03ec\"}]"
14+text Gxpath "/repos/aien-dev/allen/commits/feature%2Fdemo"
15+text Gxroot "/repos/aien-dev/allen/contents?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a"
16+text Gxdocs "/repos/aien-dev/allen/contents/docs?ref=e97222eb82f1ec56e852ba9571786db9ccc5c97a"
17+text Gxpre "{\"full_name\":\"aien-dev/allen\",\"private\":false,\"html_url\":\"https://github.com/aien-dev/allen\",\"default_branch\":\"main\",\"description\":\""
18+text Gxpost "\"}"
19+text Gxlist "[{\"id\":1427000265,\"full_name\":\"aien-dev/allen\",\"private\":false,\"owner\":{\"login\":\"aien-dev\",\"full_name\":\"x/y\"},\"created_at\":\"2026-10-20T12:35:09Z\"}]"
20+text Gxlowner "[{\"full_name\":\"someone/allen\",\"created_at\":\"2026-10-20T12:35:09Z\"}]"
21+text Gxldot "[{\"full_name\":\"aien-dev/.allen\",\"created_at\":\"2026-10-20T12:35:09Z\"}]"
22+text Gxlslash "[{\"full_name\":\"aien-dev/allen/x\",\"created_at\":\"2026-10-20T12:35:09Z\"}]"
23+text Gxlbare "[{\"full_name\":\"aien-dev/\",\"created_at\":\"2026-10-20T12:35:09Z\"}]"
24+text Gxldate "[{\"full_name\":\"aien-dev/allen\",\"created_at\":\"2026-10-20 12:35:09Z\"}]"
25+text Gxlnod "[{\"full_name\":\"aien-dev/allen\"}]"
26+text Gxldup "[{\"full_name\":\"aien-dev/allen\",\"full_\\u006eame\":\"aien-dev/evil\",\"created_at\":\"2026-10-20T12:35:09Z\"}]"
27+text Gxlempty "[]"
28+text Gxlobj "{\"full_name\":\"aien-dev/allen\",\"created_at\":\"2026-10-20T12:35:09Z\"}"
29+text Gxlbase "/repos/aien-dev/allen"
30+fn gxmeta to void
31+for i ulong len Gxmeta
32+put Ghbody i get Gxmeta i
33+end
34+check ghreply 1 200 len Gxmeta get Ghreq 2 100
35+end
36+fn gxcommit to void
37+for i ulong len Gxcommit
38+put Ghbody i get Gxcommit i
39+end
40+check ghreply 2 200 len Gxcommit get Ghreq 2 101
41+end
42+fn gxfiles to void
43+for i ulong len Gxfiles
44+put Ghbody i get Gxfiles i
45+end
46+check ghreply 4 200 len Gxfiles get Ghreq 2 102
47+end
48+fn gxread to void
49+note Enough actual input rows to exercise paging, not a pre-rendered card.
50+for i ulong 200
51+put Ghbody mul i 2 65
52+put Ghbody add mul i 2 1 10
53+end
54+check ghreply 3 200 400 get Ghreq 2 103
55+end
56+fn gxlist to void
57+for i ulong len Gxlist
58+put Ghbody i get Gxlist i
59+end
60+check ghreply 5 200 len Gxlist get Ghreq 2 150
61+end
62+note Every live session starts with discovery; gxfind is refresh plus a valid listing.
63+fn gxfind to void
64+ghrefresh
65+gxlist
66+check eq get Ghreq 0 1 151
67+end
68+fn gxlfail n ulong id ulong to void
69+ghrefresh
70+check eq get Ghreq 0 5 id
71+check ghreply 5 200 n get Ghreq 2 add id 1
72+check eq get Gh 0 3 add id 2
73+check eq get Gh 2 3 add id 3
74+check eq get Ghreq 0 0 add id 4
75+check eq get Ghlen 5 0 add id 5
76+end
77+fn gxdiscover to void
78+ghinit
79+gxfind
80+check eq get Ghlen 5 14 160
81+check eq get Ghlen 6 20 161
82+check eq get Ghreq 1 len Gxlbase 162
83+for i ulong len Gxlbase
84+check eq get Ghpath i get Gxlbase i 163
85+end
86+check eq get Ghmeta 784 50 164
87+gxmeta
88+check eq get Ghreq 0 2 165
89+for i ulong len Gxlowner
90+put Ghbody i get Gxlowner i
91+end
92+gxlfail len Gxlowner 170
93+for i ulong len Gxldot
94+put Ghbody i get Gxldot i
95+end
96+gxlfail len Gxldot 176
97+for i ulong len Gxlslash
98+put Ghbody i get Gxlslash i
99+end
100+gxlfail len Gxlslash 182
101+for i ulong len Gxlbare
102+put Ghbody i get Gxlbare i
103+end
104+gxlfail len Gxlbare 188
105+for i ulong len Gxldate
106+put Ghbody i get Gxldate i
107+end
108+gxlfail len Gxldate 194
109+for i ulong len Gxlnod
110+put Ghbody i get Gxlnod i
111+end
112+gxlfail len Gxlnod 200
113+for i ulong len Gxldup
114+put Ghbody i get Gxldup i
115+end
116+gxlfail len Gxldup 206
117+for i ulong len Gxlempty
118+put Ghbody i get Gxlempty i
119+end
120+gxlfail len Gxlempty 212
121+for i ulong len Gxlobj
122+put Ghbody i get Gxlobj i
123+end
124+gxlfail len Gxlobj 218
125+ghrefresh
126+check ghreply 5 429 0 get Ghreq 2 224
127+check eq get Gh 2 4 225
128+check eq get Ghlen 5 0 226
129+end
130+fn gxready to void
131+gxfind
132+gxmeta
133+gxcommit
134+gxread
135+gxfiles
136+check eq get Gh 0 2 104
137+end
138+fn gxintent to void
139+ghinit
140+for i ulong len Gxask
141+put In i get Gxask i
142+end
143+put Inlen 0 len Gxask
144+check ghask 1
145+check eq get Ghreq 0 5 2
146+check eq get Ghreq 1 len Ghlst 3
147+for i ulong len Ghlst
148+check eq get Ghpath i get Ghlst i 4
149+end
150+for i ulong len Gxask2
151+put In i get Gxask2 i
152+end
153+put Inlen 0 len Gxask2
154+check ghask 5
155+for i ulong len Gxno
156+put In i get Gxno i
157+end
158+put Inlen 0 len Gxno
159+check not ghask 6
160+check eq get Gh 0 4 7
161+check eq get Ghreq 0 0 8
162+end
163+fn gxlive to void
164+ghrefresh
165+old = get Ghreq 2
166+gxfind
167+check not ghreply 1 200 len Gxmeta old 10
168+check eq get Ghreq 0 1 11
169+check not ghreply 2 200 len Gxmeta get Ghreq 2 12
170+ghtime 1792886400
171+gxmeta
172+check eq get Ghreq 0 2 13
173+check eq get Ghlen 1 4 14
174+check eq get Ghmeta 64 109 15
175+check eq get Ghmeta 67 110 16
176+check eq get Ghat 0 1792886400 17
177+gxcommit
178+check eq get Ghlen 3 40 18
179+check eq get Ghlen 4 20 19
180+check eq get Ghreq 3 1 20
181+check eq get Ghreq 0 3 21
182+gxread
183+check eq get Ghreq 0 4 22
184+check eq get Ghreq 1 len Gxroot 23
185+for i ulong len Gxroot
186+check eq get Ghpath i get Gxroot i 24
187+end
188+gxfiles
189+check eq get Gh 0 2 25
190+check eq get Ghreq 0 0 26
191+check eq get Gh 8 9 27
192+check eq get Ghfiles 1 10 28
193+check eq get Ghfiles 3 197 29
194+check not ghreply 4 200 len Gxfiles get Ghreq 2 30
195+end
196+fn gxescape to void
197+gxfind
198+for i ulong len Gxesc
199+put Ghbody i get Gxesc i
200+end
201+check ghreply 1 200 len Gxesc get Ghreq 2 40
202+check eq get Ghreq 0 2 41
203+check eq get Ghreq 1 len Gxpath 42
204+for i ulong len Gxpath
205+check eq get Ghpath i get Gxpath i 43
206+end
207+check eq get Ghmeta 324 34 44
208+check eq get Ghmeta 329 92 45
209+check eq get Ghmeta 331 195 46
210+check eq get Ghmeta 332 169 47
211+check eq get Ghmeta 334 240 48
212+end
213+fn gxmalformed to void
214+n = ulong 0
215+for i ulong len Gxbad
216+c = get Gxbad i
217+if eq c 10
218+gxfind
219+check ghreply 1 200 n get Ghreq 2 50
220+check eq get Gh 0 3 51
221+check eq get Gh 2 3 52
222+check eq get jcnt 0 0 53
223+n = 0
224+else
225+put Ghbody n c
226+n = add n 1
227+end
228+end
229+gxfind
230+for i ulong len Gxdup
231+put Ghbody i get Gxdup i
232+end
233+check ghreply 1 200 len Gxdup get Ghreq 2 54
234+check eq get Gh 0 3 55
235+gxfind
236+for i ulong len Gxwrong
237+put Ghbody i get Gxwrong i
238+end
239+check ghreply 1 200 len Gxwrong get Ghreq 2 56
240+check eq get Gh 0 3 57
241+gxfind
242+check ghreply 1 200 65537 get Ghreq 2 58
243+check eq get Gh 2 2 59
244+gxfind
245+for i ulong len Gxpre
246+put Ghbody i get Gxpre i
247+end
248+for i ulong 513
249+put Ghbody add len Gxpre i 65
250+end
251+for i ulong len Gxpost
252+put Ghbody add add len Gxpre 513 i get Gxpost i
253+end
254+n = add add len Gxpre 513 len Gxpost
255+check ghreply 1 200 n get Ghreq 2 60
256+check eq get Gh 0 3 61
257+end
258+fn gxerrors to void
259+gxfind
260+check ghreply 1 429 0 get Ghreq 2 70
261+check eq get Gh 2 4 71
262+check eq get Gh 3 429 72
263+gxfind
264+check ghreply 1 0 0 get Ghreq 2 73
265+check eq get Gh 2 1 74
266+gxfind
267+gxmeta
268+gxcommit
269+put Ghbody 0 192
270+put Ghbody 1 128
271+check ghreply 3 200 2 get Ghreq 2 75
272+check eq get Gh 0 3 76
273+gxfind
274+gxmeta
275+gxcommit
276+put Ghbody 0 0
277+check ghreply 3 200 1 get Ghreq 2 77
278+check eq get Gh 0 3 78
279+gxfind
280+gxmeta
281+gxcommit
282+check ghreply 3 404 0 get Ghreq 2 79
283+check eq get Gh 13 1 80
284+check eq get Ghreq 0 4 81
285+gxfiles
286+check eq get Gh 0 2 82
287+end
288+fn gxnavigation to void
289+gxready
290+check cvinit 768 384 90
291+ghmeasure
292+check eq get Ghr 2 201 91
293+ghscroll 9223372036854775807
294+check eq get Gh 5 ghlimit 92
295+ghscroll -9223372036854775808
296+check eq get Gh 5 0 93
297+ghkey 259
298+check eq get Gh 5 get Ghr 1 94
299+ghkey 258
300+check eq get Gh 5 0 95
301+ghkey 9
302+check eq get Gh 4 1 96
303+for i ulong 4
304+ghkey 257
305+end
306+check eq get Gh 6 4 97
307+ghkey 13
308+check eq get Ghreq 0 4 98
309+check eq get Ghreq 1 len Gxdocs 99
310+for i ulong len Gxdocs
311+check eq get Ghpath i get Gxdocs i 105
312+end
313+for i ulong len Gxchild
314+put Ghbody i get Gxchild i
315+end
316+check ghreply 4 200 len Gxchild get Ghreq 2 106
317+check eq get Gh 8 1 107
318+ghkey 13
319+check eq get Gh 4 2 108
320+ghkey 98
321+check eq get Gh 4 1 109
322+ghkey 98
323+check eq get Gh 10 0 110
324+check eq get Ghreq 1 len Gxroot 111
325+gxfiles
326+ghpointer 20 150 1
327+check eq get Gh 4 0 112
328+ghswipe 20
329+check eq get Gh 5 20 113
330+ghpointer -1 150 1
331+check eq get Gh 4 0 114
332+check ghrender 115
333+ghkey 114
334+check eq get Gh 0 1 116
335+check eq get Gh 7 0 117
336+check eq get Ghlen 3 0 118
337+end
338+fn gxpathbad to void
339+gxfind
340+gxmeta
341+gxcommit
342+gxread
343+for i ulong len Gxdirbad
344+put Ghbody i get Gxdirbad i
345+end
346+check ghreply 4 200 len Gxdirbad get Ghreq 2 120
347+check eq get Gh 0 3 121
348+gxfind
349+gxmeta
350+gxcommit
351+gxread
352+for i ulong len Gxchild
353+put Ghbody i get Gxchild i
354+end
355+note Root listing cannot inject a nested child path.
356+check ghreply 4 200 len Gxchild get Ghreq 2 122
357+check eq get Gh 0 3 123
358+end
359+fn gxbounds to void
360+gxfind
361+gxmeta
362+gxcommit
363+put Ghbody 0 195
364+put Ghbody 1 169
365+put Ghbody 2 10
366+check ghreply 3 200 3 get Ghreq 2 130
367+old = get Ghreq 2
368+gxfind
369+check not ghreply 4 200 len Gxfiles old 131
370+check eq get Ghreq 0 1 132
371+gxmeta
372+gxcommit
373+put Ghbody 0 240
374+put Ghbody 1 159
375+check ghreply 3 200 2 get Ghreq 2 133
376+check eq get Gh 0 3 134
377+gxfind
378+for i ulong 33
379+put Ghbody i 91
380+put Ghbody add 34 i 93
381+end
382+put Ghbody 33 48
383+check ghreply 1 200 67 get Ghreq 2 135
384+check eq get Gh 0 3 136
385+gxfind
386+gxmeta
387+gxcommit
388+for i ulong 148
389+put Ghbody i 65
390+end
391+check ghreply 3 200 148 get Ghreq 2 137
392+gxfiles
393+ghmeasure
394+check eq get Ghr 2 3 138
395+check eq get Ghlines 1 73 139
396+check eq get Ghlines 2 146 140
397+check eq get Ghat 3 0 141
398+put Inlen 0 160
399+check not ghask 142
400+check eq get Gh 0 4 143
401+end
402+fn main to int
403+gxdiscover
404+gxintent
405+gxlive
406+gxescape
407+gxmalformed
408+gxerrors
409+gxnavigation
410+gxpathbad
411+gxbounds
412+ret int get Fails 0
413+end

aienux/allen/tests/golden.om

new file mode 100644
@@ -0,0 +1,16 @@
1+text Gname "Allen"
2+fn main to int
3+constants
4+mset32 0 3
5+for i ulong len Gname
6+put Mem add i 40 get Gname i
7+end
8+if not memenc 1
9+ret 1
10+end
11+n = write 1 Enc 0 4096
12+if ne n 4096
13+ret 2
14+end
15+ret 0
16+end

aienux/allen/tests/http.om

new file mode 100644
@@ -0,0 +1,105 @@
1+note HTTP response boundary tests; concatenate after base.om, github.om, http.om, tests/check.om.
2+note Fixtures are protocol data only. This gate makes no network or TLS qualification claim.
3+text Hcases "HTTP/1.1 200 OK\nContent-Length: 5\n\nhello|HTTP/1.1 200 OK\nTransfer-Encoding: chunked\n\n2;ext=yes\nhe\n3\nllo\n0\nX-Trace: safe\n\n|HTTP/1.1 200 OK\nContent-Length: 5\nContent-Length: 5\n\nhello|HTTP/1.1 200 OK\nContent-Length: 5\nTransfer-Encoding: chunked\n\n|HTTP/1.1 200 OK\nContent-Encoding: gzip\nContent-Length: 5\n\nhello|HTTP/1.1 200 OK\nContent-Length: 9999999999999999999999999\n\n|HTTP/1.1 200 OK\n\nhello|HTTP/1.1 200 OK\nContent-Length: 5\n\nhell|HTTP/1.1 200 OK\nTransfer-Encoding: chunked\n\n1\nh\n0\nContent-Length: 0\n\n|HTTP/1.1 103 Early Hints\nLink: x\n\nHTTP/1.1 200 OK\nContent-Length: 5\n\nhello|HTTP/1.1 200 OK\nContent-Length: 0\n\nx|HTTP/1.1 200 OK\nTransfer-Encoding: chunked\n\n6\nhello!\n0\n\n|HTTP/1.1 204 No Content\nContent-Length: 4\n\n|HTTP/1.1 403 Forbidden\nContent-Length: 2\n\n{}|HTTP/1.1 200 OK\nTransfer-Encoding: chunked, gzip\n\n|HTTP/1.1 200 OK\nBad Header: x\n\n|"
4+text Hpath "/repos/aien-dev/allen"
5+text Hhello "hello"
6+fn htbegin cap ulong to void
7+for i ulong len Hpath
8+put Ghpath i get Hpath i
9+end
10+check httpstart 1 42 0 cap len Hpath 1
11+end
12+fn htpush c uchar to void
13+put Hchunk 0 c
14+ok = httpfeed 1
15+end
16+fn htcase wanted ulong to void
17+index = ulong 0
18+for i ulong len Hcases
19+c = get Hcases i
20+if eq c 124
21+if eq index wanted
22+ret
23+end
24+index = add index 1
25+else
26+if eq index wanted
27+if eq c 10
28+htpush 13
29+end
30+htpush c
31+end
32+end
33+end
34+end
35+fn htgood id ulong to void
36+check eq get Hstate 0 2 id
37+check eq get Hstate 2 5 add id 1
38+ok = true
39+for i ulong 5
40+if ne get Ghbody i get Hhello i
41+ok = false
42+end
43+end
44+check ok add id 2
45+check eq get Hstate 3 42 add id 3
46+end
47+fn main to int
48+htbegin 5
49+htcase 0
50+htgood 10
51+htbegin 5
52+htcase 1
53+htgood 20
54+for i ulong 4
55+htbegin 5
56+htcase add i 2
57+check eq get Hstate 0 3 add 30 i
58+end
59+htbegin 5
60+htcase 6
61+check eq get Hstate 0 1 40
62+check httpend true 41
63+htgood 42
64+htbegin 5
65+htcase 6
66+check not httpend false 46
67+check eq get Hstate 0 3 47
68+htbegin 5
69+htcase 7
70+check not httpend true 50
71+check eq get Hstate 0 3 51
72+htbegin 5
73+htcase 8
74+check eq get Hstate 0 3 52
75+htbegin 5
76+htcase 9
77+htgood 60
78+for i ulong 3
79+htbegin 5
80+htcase add i 10
81+check eq get Hstate 0 3 add 70 i
82+end
83+htbegin 5
84+htcase 13
85+check eq get Hstate 0 2 80
86+check eq get Hstate 1 403 81
87+check eq get Hstate 2 2 82
88+for i ulong 2
89+htbegin 5
90+htcase add i 14
91+check eq get Hstate 0 3 add 85 i
92+end
93+htbegin 5
94+htpush 10
95+check eq get Hstate 0 3 90
96+htbegin 5
97+put Ghpath 1 13
98+check not httpstart 1 43 0 5 len Hpath 91
99+check eq get Httpreqn 0 0 92
100+htbegin 5
101+put Ghpath 1 35
102+check not httpstart 1 43 0 5 len Hpath 93
103+check eq get Httpreqn 0 0 94
104+ret int get Fails 0
105+end

aienux/allen/tests/https-live.om

new file mode 100644
@@ -0,0 +1,186 @@
1+note SPDX-License-Identifier: MIT
2+note Qualification only: real Omega TLS/HTTP client on Linux AArch64.
3+note Argument1 is a DNS-resolved IPv4 address supplied by the external test orchestrator.
4+note Production firmware build uses net.om DNS instead; this harness is not the deployed network provider.
5+global Laddr uchar 16
6+global Lip uchar 32
7+global Lfd int 1
8+global Lstate ulong 4
9+text Lpath "/repos/aien-dev/allen"
10+fn laddress to bool
11+n = argread 1 Lip 0 len Lip
12+if or le n 0 gt n 15
13+ret false
14+end
15+put Laddr 0 2
16+put Laddr 2 1
17+put Laddr 3 187
18+part = ulong 0
19+value = ulong 0
20+digits = ulong 0
21+for i ulong add ulong n 1
22+c = uchar 46
23+if lt i ulong n
24+c = get Lip i
25+end
26+if eq c 46
27+if or or eq digits 0 gt value 255 ge part 4
28+ret false
29+end
30+put Laddr add 4 part uchar value
31+part = add part 1
32+value = 0
33+digits = 0
34+else
35+if or lt c 48 gt c 57
36+ret false
37+end
38+digits = add digits 1
39+if gt digits 3
40+ret false
41+end
42+value = add mul value 10 sub ulong c 48
43+end
44+end
45+ret eq part 4
46+end
47+fn lflush to bool
48+off = ulong 0
49+while lt off get Tlsoutn 0
50+n = send get Lfd 0 Tlsout off sub get Tlsoutn 0 off 0
51+if gt n 0
52+off = add off ulong n
53+else
54+if ne n -11
55+ret false
56+end
57+r = waitio get Lfd 0 4 10000000000
58+if le r 0
59+ret false
60+end
61+end
62+end
63+tlssent
64+ret true
65+end
66+fn lhttp to bool
67+while gt get Tlsappn 0 0
68+n = get Tlsappn 0
69+if gt n len Hchunk
70+n = len Hchunk
71+end
72+for i ulong n
73+put Hchunk i get Tlsapp i
74+end
75+if not httpfeed n
76+ret false
77+end
78+tlsconsume n
79+end
80+ret true
81+end
82+fn ldrive to int
83+start = monons
84+sent = false
85+while eq get Hstate 0 1
86+if gt sub monons start 120000000000
87+ret 71
88+end
89+if eq get Tlsstate 0 4
90+ret 72
91+end
92+if gt get Tlsoutn 0 0
93+if not lflush
94+ret 73
95+end
96+end
97+if and eq get Tlsstate 0 2 not sent
98+for i ulong get Httpreqn 0
99+put Tlsplain i get Httpreq i
100+end
101+if tlswrite get Httpreqn 0
102+sent = true
103+end
104+end
105+if not lhttp
106+ret 74
107+end
108+if eq get Hstate 0 2
109+break
110+end
111+if eq get Tlsstate 0 3
112+if not httpend eq get Tlsstate 2 1
113+ret 75
114+end
115+break
116+end
117+if eq get Tlsoutn 0 0
118+r = waitio get Lfd 0 1 1000000000
119+if lt r 0
120+ret 76
121+end
122+if gt r 0
123+n = recv get Lfd 0 Tlsin 0 len Tlsin 0
124+if gt n 0
125+tlsinput ulong n
126+else
127+if eq n 0
128+ret 77
129+end
130+if ne n -11
131+ret 78
132+end
133+end
134+end
135+end
136+end
137+if ne get Hstate 1 200
138+ret 79
139+end
140+n = write 1 Ghbody 0 get Hstate 2
141+if ne n long get Hstate 2
142+ret 80
143+end
144+ret 0
145+end
146+fn main to int
147+if ne argcnt 2
148+ret 64
149+end
150+if not laddress
151+ret 65
152+end
153+for i ulong len Lpath
154+put Ghpath i get Lpath i
155+end
156+if not httpstart 1 1 0 65536 len Lpath
157+ret 66
158+end
159+off = ulong 0
160+while lt off len Tlsrand
161+n = random Tlsrand off sub len Tlsrand off 0
162+if le n 0
163+ret 67
164+end
165+off = add off ulong n
166+end
167+now = realns
168+if le now 0
169+ret 68
170+end
171+tlsinit ulong div now 1000000000
172+fd = socknew 2 526337 0
173+if lt fd 0
174+ret 69
175+end
176+put Lfd 0 int fd
177+r = connect int fd Laddr 0 len Laddr
178+if and ne r 0 ne r -115
179+r = fclose int fd
180+ret 70
181+end
182+rc = ldrive
183+r = fclose int fd
184+tcwipe
185+ret rc
186+end

aienux/allen/tests/intent.om

new file mode 100644
@@ -0,0 +1,41 @@
1+text Askcode "Please make me a calculator"
2+text Askpoem "Write a poem about python"
3+text Askmore "Now add a square root key"
4+text Expected "JOB 9 code the person asked Allen for code.\tPlease make me a calculator"
5+text Nscript "script a poem"
6+fn main to int
7+put Inlen 0 len Askcode
8+for i ulong len Askcode
9+put In i get Askcode i
10+end
11+check eq classify 2 501
12+b = jobbuild 2 9
13+same = eq get Outlen 0 len Expected
14+for i ulong len Expected
15+if ne get Outb i get Expected i
16+same = false
17+end
18+end
19+check b 502
20+check same 503
21+put Inlen 0 len Askpoem
22+for i ulong len Askpoem
23+put In i get Askpoem i
24+end
25+check eq classify 1 504
26+check eq jobwant 1 505
27+put Inlen 0 len Askmore
28+for i ulong len Askmore
29+put In i get Askmore i
30+end
31+check eq classify 1 506
32+put R 6 1
33+check eq classify 3 507
34+put R 6 0
35+put Inlen 0 len Nscript
36+for i ulong len Nscript
37+put In i get Nscript i
38+end
39+check eq classify 1 508
40+ret int get Fails 0
41+end

aienux/allen/tests/look-chat.om

new file mode 100644
@@ -0,0 +1,313 @@
1+note Courier over UDP 47033 on net.om: concatenate after platform.om, the gate.sh
2+note core list, net.om, look-chat.om and tests/check.om. Host-only fixtures: HI,
3+note ACK and LINE datagrams are built by courier.om's own serializer in the live
4+note relay's form (allen-courier main.rs datagram(): HI/ACK part=0/0 bytes=0,
5+note LINE part=i/0 bytes=<body length>), wrapped in Ethernet/IPv4/UDP frames with
6+note an independent checksum, and fed through netinput; outgoing frames are
7+note checked against the same rules. The first HELLO frame is written raw to
8+note fd 2 for an outside checksum check. check prints through Outb, so every
9+note fixture is delivered before its packet result is checked.
10+text Cvline " 1/1 Model answer."
11+text Cvsay "SAY "
12+text Cvask "hello"
13+global Cvdst ulong 1
14+fn cvw16 p ulong v ulong to void
15+put Nrx p uchar and shr v 8 255
16+put Nrx add p 1 uchar and v 255
17+end
18+fn cvw32 p ulong v ulong to void
19+cvw16 p shr v 16
20+cvw16 add p 2 and v 65535
21+end
22+fn cvt16 p ulong to ulong
23+ret add shl ulong get Ntx p 8 ulong get Ntx add p 1
24+end
25+fn cvt32 p ulong to ulong
26+ret add shl cvt16 p 16 cvt16 add p 2
27+end
28+note Independent one's-complement sum over Nrx (tx false) or Ntx (tx true).
29+fn cvsum tx bool p ulong n ulong to ulong
30+s = ulong 0
31+for i ulong n
32+v = ulong 0
33+if tx
34+v = ulong get Ntx add p i
35+else
36+v = ulong get Nrx add p i
37+end
38+if eq rem i 2 0
39+s = add s shl v 8
40+else
41+s = add s v
42+end
43+end
44+ret s
45+end
46+fn cvcpl s ulong to ulong
47+while gt s 65535 bound 8
48+s = add shr s 16 and s 65535
49+end
50+ret xor s 65535
51+end
52+fn cvpseudo a ulong b ulong n ulong to ulong
53+s = add add shr a 16 and a 65535 add shr b 16 and b 65535
54+ret add s add 17 n
55+end
56+fn cvip4 a ulong b ulong c ulong d ulong to ulong
57+ret add add shl a 24 shl b 16 add shl c 8 d
58+end
59+note Wrap Outb[0..Outlen) in a frame from 192.168.1.10:sp to Cvdst:dp and feed it in.
60+fn cvdeliver sp ulong dp ulong now ulong to void
61+n = get Outlen 0
62+for i ulong 2048
63+put Nrx i uchar 0
64+end
65+for i ulong 6
66+put Nrx i uchar 255
67+put Nrx add i 6 uchar 0
68+end
69+put Nrx 6 uchar 2
70+put Nrx 11 uchar 170
71+cvw16 12 2048
72+put Nrx 14 uchar 69
73+cvw16 16 add n 28
74+cvw16 20 16384
75+put Nrx 22 uchar 64
76+put Nrx 23 uchar 17
77+src = cvip4 192 168 1 10
78+cvw32 26 src
79+cvw32 30 get Cvdst 0
80+cvw16 24 cvcpl cvsum false 14 20
81+cvw16 34 sp
82+cvw16 36 dp
83+cvw16 38 add n 8
84+for i ulong n
85+put Nrx add 42 i get Outb i
86+end
87+c = cvcpl add cvpseudo src get Cvdst 0 add n 8 cvsum false 34 add n 8
88+if eq c 0
89+c = 65535
90+end
91+cvw16 40 c
92+if lt n 18
93+n = 18
94+end
95+netinput add 42 n now
96+end
97+note A 20-byte TCP segment from 192.168.1.10:443 to Cvdst:Ncfg21 (session port).
98+fn cvtcp now ulong to void
99+for i ulong 2048
100+put Nrx i uchar 0
101+end
102+for i ulong 6
103+put Nrx i uchar 255
104+put Nrx add i 6 uchar 0
105+end
106+put Nrx 6 uchar 2
107+put Nrx 11 uchar 170
108+cvw16 12 2048
109+put Nrx 14 uchar 69
110+cvw16 16 40
111+cvw16 20 16384
112+put Nrx 22 uchar 64
113+put Nrx 23 uchar 6
114+cvw32 26 cvip4 192 168 1 10
115+cvw32 30 get Cvdst 0
116+cvw16 24 cvcpl cvsum false 14 20
117+cvw16 34 443
118+cvw16 36 get Ncfg 21
119+put Nrx 46 uchar 80
120+netinput 54 now
121+end
122+note Outgoing courier frame: broadcast, IPv4/UDP 47033 both ways, valid checksums.
123+fn cvtxok to bool
124+if eq get Ntxlen 0 0
125+ret false
126+end
127+for i ulong 6
128+if ne get Ntx i 255
129+ret false
130+end
131+end
132+if or ne cvt16 12 2048 ne get Ntx 23 17
133+ret false
134+end
135+if ne cvcpl cvsum true 14 20 0
136+ret false
137+end
138+if or ne cvt16 34 47033 ne cvt16 36 47033
139+ret false
140+end
141+n = sub cvt16 16 20
142+if or ne n cvt16 38 gt add n 34 get Ntxlen 0
143+ret false
144+end
145+if ne cvt32 30 4294967295
146+ret false
147+end
148+s = cvpseudo cvt32 26 cvt32 30 n
149+ret eq cvcpl add s cvsum true 34 n 0
150+end
151+fn cvkind c uchar to bool
152+note The kind field starts at offset 22+16+6 of the head (ALLEN-COURIER v=1 run=<16> kind=).
153+ret eq ulong get Ntx 86 ulong c
154+end
155+fn cvbody seq ulong to void
156+outreset
157+for i ulong len Cvsay
158+emitb get Cvsay i
159+end
160+emitn seq
161+for i ulong len Cvline
162+emitb get Cvline i
163+end
164+put Inlen 0 get Outlen 0
165+for i ulong get Outlen 0
166+put In i get Outb i
167+end
168+end
169+fn main to int
170+put Cvdst 0 4294967295
171+put Nmac 0 uchar 2
172+for i ulong 4
173+put Nmac add i 1 uchar 0
174+end
175+put Nmac 5 uchar 1
176+netinit 5000
177+netsent true 5000
178+check eq get Ntxlen 0 0 7
179+check not chbusy 1
180+check chinit 5000 0 2
181+check ne get Q 0 0 3
182+check eq get Q 0 chrun 5000 4
183+check not chinit 5000 0 5
184+check eq get Ncfg 2 0 6
185+chstep 5000 true
186+check cvtxok 10
187+check eq cvt32 26 0 11
188+check cvkind 72 12
189+check eq get Ch 2 1 13
190+check not netudpsend 10 14
191+w = write 2 Ntx 0 get Ntxlen 0
192+netsent true 5000
193+check eq get Ntxlen 0 0 15
194+put Inlen 0 0
195+ok = packet 6 0 0 0 0
196+n = get Outlen 0
197+cvdeliver 47033 47033 5001
198+check ok 16
199+check eq get Chrxn 0 n 17
200+chstep 5001 true
201+check eq get Chrxn 0 0 18
202+check eq get T 1 1 19
203+check eq get Ch 3 1 20
204+check eq get Ntxlen 0 0 21
205+put Dprmn 0 len Cvask
206+for i ulong len Cvask
207+put Dprm i get Cvask i
208+end
209+check chask 5002 30
210+check chbusy 31
211+check not chask 5003 32
212+chstep 5003 true
213+check cvtxok 33
214+check cvkind 74 34
215+netsent true 5003
216+put Inlen 0 0
217+ok = packet 4 get Q 1 0 0 0
218+cvdeliver 47033 47033 5004
219+check ok 35
220+chstep 5004 true
221+check eq get T 6 1 36
222+check eq get Ntxlen 0 0 37
223+note Negative control: a LINE whose bytes= is neither 0 nor the body length is refused.
224+cvbody get Q 1
225+ok = packet 2 get Q 1 1 0 add get Inlen 0 1
226+cvdeliver 47033 47033 5005
227+chstep 5005 true
228+check and ok and eq get Chevent 0 0 eq get Ntxlen 0 0 39
229+cvbody get Q 1
230+ok = packet 2 get Q 1 1 0 get Inlen 0
231+cvdeliver 47033 47033 5005
232+n = get Chdrop 0
233+cvdeliver 47033 47033 5005
234+check ok 40
235+check eq n 0 41
236+check eq get Chdrop 0 1 42
237+chstep 5005 true
238+check eq get Chevent 0 1 43
239+check eq get Chsayn 0 13 44
240+check eq get Chsay 0 77 45
241+check eq get Ch 5 1 46
242+check cvtxok 47
243+check cvkind 71 48
244+check not chbusy 49
245+netsent true 5005
246+note Like the C kernel, ours by Ethernet destination and port alone: other ports
247+note never reach the courier slot; any IPv4 destination does, so the relay's
248+note --udp-answer 192.168.1.255 is heard without a lease.
249+cvdeliver 47033 47034 5006
250+check eq get Chrxn 0 0 50
251+cvdeliver 1234 47033 5006
252+check ne get Chrxn 0 0 51
253+put Chrxn 0 0
254+put Cvdst 0 cvip4 192 168 1 255
255+cvdeliver 47033 47033 5007
256+check ne get Chrxn 0 0 52
257+put Chrxn 0 0
258+put Ncfg 2 cvip4 192 168 1 20
259+put Ncfg 3 cvip4 255 255 255 0
260+put Cvdst 0 cvip4 192 168 1 20
261+cvdeliver 47033 47033 5007
262+check ne get Chrxn 0 0 53
263+put Chrxn 0 0
264+put Cvdst 0 cvip4 192 168 1 21
265+cvdeliver 47033 47033 5007
266+check ne get Chrxn 0 0 54
267+put Chrxn 0 0
268+put Chevent 0 1
269+chcancel
270+check eq get Chevent 0 0 55
271+check not chbusy 56
272+note With a lease the frame leaves from our address and the relay's subnet
273+note broadcast answer (--udp-answer 192.168.1.255) is still heard.
274+put Dprmn 0 len Cvask
275+check chask 5008 60
276+chstep 5008 true
277+check cvtxok 61
278+check eq cvt32 26 cvip4 192 168 1 20 62
279+netsent true 5008
280+put Cvdst 0 cvip4 192 168 1 255
281+put Inlen 0 0
282+ok = packet 4 get Q 1 0 0 0
283+cvdeliver 47033 47033 5009
284+chstep 5009 true
285+check and ok eq get T 6 1 63
286+note Error state 6 after a failed repository session: the courier still hears a
287+note LINE and sends its GOT, while a TCP segment for the dead session is frozen
288+note (Ndrop 12 is ntcpin's first verdict for a segment from the wrong peer).
289+put Tcpstate 0 6
290+cvbody get Q 1
291+ok = packet 2 get Q 1 1 0 get Inlen 0
292+cvdeliver 47033 47033 5010
293+check and ok ne get Chrxn 0 0 64
294+r = get Ch 4
295+chstep 5010 true
296+check eq get Chevent 0 1 65
297+check and cvtxok cvkind 71 66
298+check eq get Ch 4 r 67
299+netsent true 5010
300+put Cvdst 0 cvip4 192 168 1 20
301+put Ncfg 1 4
302+put Ncfg 21 40000
303+put Tcpstate 2 cvip4 10 0 0 1
304+put Tcpstate 0 5
305+put Ndrop 0 0
306+cvtcp 5011
307+check eq get Ndrop 0 12 68
308+put Ndrop 0 0
309+put Tcpstate 0 6
310+cvtcp 5011
311+check eq get Ndrop 0 0 69
312+ret int get Fails 0
313+end

aienux/allen/tests/look-home-dirty.om

new file mode 100644
@@ -0,0 +1,151 @@
1+note Incremental HOME pixels must equal a complete redraw, including an independently moving background.
2+note Reuses the HOME oracle's isolated NIGHT/MIND boundary and existing Nsky storage for comparison.
3+global Targ uchar 32
4+global Ttime long 1
5+fn tdstrip to long
6+ret add get Hm 24 div get Hm 26 2
7+end
8+fn tdpx xx long yy long to void
9+c = ulong add 131844 and add xx yy 31
10+if lt xx add tdstrip hms 70
11+if ge xx tdstrip
12+c = add c shl ulong and get Ttime 0 31 8
13+end
14+end
15+put Nfrm add mul ulong yy ulong get Lg 0 ulong xx uint c
16+end
17+fn tdrow x long y long w long to void
18+for i ulong ulong w
19+tdpx add x long i y
20+end
21+end
22+fn tdback x long y long w long h long to void
23+for j ulong ulong h
24+tdrow x add y long j w
25+end
26+hmtext x y w h
27+end
28+fn tdwhole to void
29+tdback get Hm 28 get Hm 29 get Hm 30 get Hm 31
30+end
31+fn tdsaverow at ulong to void
32+for i ulong ulong get Hm 30
33+put Nsky add at i get Nfrm add at i
34+end
35+end
36+fn tdsave to void
37+at = mul ulong get Hm 29 ulong get Lg 0
38+at = add at ulong get Hm 28
39+for j ulong ulong get Hm 31
40+tdsaverow at
41+at = add at ulong get Lg 0
42+end
43+end
44+fn tdequalrow at ulong to bool
45+for i ulong ulong get Hm 30
46+if ne get Nsky add at i get Nfrm add at i
47+ret false
48+end
49+end
50+ret true
51+end
52+fn tdequal to bool
53+at = mul ulong get Hm 29 ulong get Lg 0
54+at = add at ulong get Hm 28
55+for j ulong ulong get Hm 31
56+if not tdequalrow at
57+ret false
58+end
59+at = add at ulong get Lg 0
60+end
61+ret true
62+end
63+fn tdpartial to void
64+x = pkmax get Hm 28 get Hmdirty 0
65+y = pkmax get Hm 29 get Hmdirty 1
66+w = add get Hm 28 get Hm 30
67+w = pkmin w add get Hmdirty 0 get Hmdirty 2
68+w = sub w x
69+h = add get Hm 29 get Hm 31
70+h = pkmin h add get Hmdirty 1 get Hmdirty 3
71+h = sub h y
72+if gt get Hmdirty 2 0
73+if gt w 0
74+if gt h 0
75+tdback x y w h
76+end
77+end
78+end
79+note The changing strip represents a NIGHT dirty region intersecting the bar.
80+tdback tdstrip get Hm 29 hms 70 get Hm 31
81+end
82+fn tdbudget to bool
83+a = mul get Hmdirty 2 get Hmdirty 3
84+b = mul get Hm 30 get Hm 31
85+ret le a div b 4
86+end
87+fn main to long
88+put Lg 0 1280
89+put Lg 1 800
90+put Lg 2 170
91+n = argread 2 Targ 0 32
92+if le n 0
93+ret 64
94+end
95+if eq get Targ 0 52
96+put Lg 0 3840
97+put Lg 1 2160
98+put Lg 2 512
99+end
100+put Targ 0 0
101+n = argread 1 Targ 0 32
102+if le n 0
103+ret 64
104+end
105+put Lg 3 div get Lg 0 2
106+put Lg 4 div mul get Lg 1 40 100
107+pkinit
108+hminit
109+note A static footer exercises its invalidation when typing and opacity change.
110+put Hmfoot 0 65
111+put Hmfootn 0 1
112+put Ttime 0 15300
113+tdwhole
114+for frame ulong 400
115+if ge frame 15
116+if lt frame 174
117+hmkey add 65 rem frame 26
118+end
119+end
120+if ge frame 200
121+if lt frame 210
122+hmkey 8
123+end
124+end
125+if eq frame 220
126+hmkey 13
127+end
128+if eq frame 350
129+put Hmsay 0 72
130+put Hmsay 1 105
131+put Hmsayn 0 2
132+hmsaid
133+end
134+hmstep get Ttime 0
135+if eq get Targ 0 98
136+if or eq frame 12 eq frame 190
137+if not tdbudget
138+ret 11
139+end
140+end
141+end
142+tdpartial
143+tdsave
144+tdwhole
145+if not tdequal
146+ret 30
147+end
148+put Ttime 0 add get Ttime 0 100
149+end
150+ret 0
151+end

aienux/allen/tests/look-home-stubs.om

new file mode 100644
@@ -0,0 +1,14 @@
1+note HOME oracle boundary, reused from IMacLook/home/stubs.om: only MIND mode/voice state and NIGHT hole data.
2+global Nthol ulong 1
3+global Nthole long 8
4+global Mdv long 32
5+fn mdmode m long t long to void
6+put Mdv 9 m
7+end
8+fn mdword t long to void
9+end
10+fn mdkey t long to void
11+end
12+fn mdvoice lvl long to void
13+put Mdv 10 lvl
14+end

aienux/allen/tests/look-home.om

new file mode 100644
@@ -0,0 +1,197 @@
1+note tests/look-home.om: drives look-home.om on the C harness's schedule (~/work/IMacLook/home/harness.c) and writes
2+note the same regions as P6 PPMs to fd 1, in the harness's order: flashA flashB barA barB wordsC barC wordsD barD.
3+note NIGHT's hole radius at the two flash frames is taken from the C harness log (346/417 at 1280, 1066/1285 at 3840).
4+note stdin: the harness's <name>-night.ppm files, in that order (the bare night each frame is drawn on).
5+note Unit: font-data.om font.om look-paint.om look-night.om look-mind.om look-home.om tio.om tests/look-home.om.
6+global Tbg uchar 16384
7+global Thead ulong 4
8+global Tnow long 1
9+text Tsay "Opening the Allen repository on GitHub, aien-dev/aienux. The same code runs on the Spark, so ask me about any file."
10+text Ttyped "open allen github repository"
11+note reads exactly n bytes from fd 0 into Tbg
12+fn tfill n ulong to void
13+got = ulong 0
14+while lt got n
15+r = read 0 Tbg got sub n got
16+if le r 0
17+trap 2
18+end
19+got = add got ulong r
20+end
21+end
22+note one P6 header: "P6\n<w> <h>\n255\n" read byte by byte; Thead 1 2 = w h
23+fn thead to void
24+nl = ulong 0
25+v = ulong 0
26+k = ulong 0
27+while lt nl 4
28+tfill 1
29+c = get Tbg 0
30+if or eq c 10 eq c 32
31+if ne k 0
32+put Thead nl v
33+nl = add nl 1
34+end
35+v = 0
36+k = 0
37+else
38+if ge c 48
39+v = add mul v 10 sub ulong c 48
40+k = add k 1
41+end
42+end
43+end
44+end
45+note one P6 from fd 0 into Nfrm (the frame's size must match Lg 0 1)
46+fn tpx p ulong to ulong
47+c = shl ulong get Tbg p 16
48+c = or c shl ulong get Tbg add p 1 8
49+ret or c ulong get Tbg add p 2
50+end
51+fn trow at ulong w ulong to void
52+for i ulong w
53+put Nfrm add at i uint tpx mul i 3
54+end
55+end
56+fn tload to void
57+thead
58+w = get Thead 1
59+for j ulong get Thead 2
60+tfill mul w 3
61+trow mul j w w
62+end
63+end
64+fn tpix c ulong to void
65+tc uchar and shr c 16 255
66+tc uchar and shr c 8 255
67+tc uchar and c 255
68+end
69+fn tprow at ulong w ulong to void
70+for i ulong w
71+tpix ulong get Nfrm add at i
72+end
73+end
74+fn tppm x long y long w long h long to void
75+tc 80
76+tc 54
77+tc 10
78+tu ulong w
79+tc 32
80+tu ulong h
81+tc 10
82+tu 255
83+tc 10
84+at = add mul ulong y ulong get Lg 0 ulong x
85+for j ulong ulong h
86+tprow at ulong w
87+at = add at ulong get Lg 0
88+end
89+end
90+fn trun upto long to void
91+while le get Tnow 0 upto
92+hmstep get Tnow 0
93+put Tnow 0 add get Tnow 0 16
94+end
95+end
96+note draws the frame last stepped on the bare night from stdin, and writes the region
97+fn tdump x long y long w long h long to void
98+tload
99+hmflash 0 0 get Lg 0 get Lg 1
100+hmtext 0 0 get Lg 0 get Lg 1
101+tppm x y w h
102+end
103+note the regions the C harness dumps: the flash box, the bar box (Hm 28..31) and the words box of lay_out
104+fn tflash to void
105+r = add shr hmfrad get Hm 12 4 2
106+x = sub get Lg 3 r
107+y = sub get Lg 4 r
108+r = add mul 2 r 1
109+tppm x y r r
110+end
111+fn tbar to void
112+tppm get Hm 28 get Hm 29 get Hm 30 get Hm 31
113+end
114+fn twords to void
115+x = sub sub get Lg 3 hms 450 hms 8
116+y = sub add get Lg 4 hms 250 hms 34
117+w = add hms 900 hms 16
118+h = add mul 5 hms 40 hms 30
119+tppm x y w h
120+end
121+fn tdraw to void
122+hmflash 0 0 get Lg 0 get Lg 1
123+hmtext 0 0 get Lg 0 get Lg 1
124+end
125+fn main to long
126+note the first night file gives the size (all frames share it): Lg 0 1 are only placeholders for its load
127+put Lg 0 1280
128+put Lg 1 800
129+tload
130+put Lg 0 long get Thead 1
131+put Lg 1 long get Thead 2
132+kw = div mul get Lg 0 256 1920
133+kh = div mul get Lg 1 256 1080
134+put Lg 2 pkmin kw kh
135+put Lg 3 div get Lg 0 2
136+put Lg 4 div mul get Lg 1 40 100
137+pkinit
138+hminit
139+put Tnow 0 0
140+put Nthol 0 1
141+put Nthole 0 add mul get Lg 3 16 8
142+put Nthole 1 add mul get Lg 4 16 8
143+trun 12100
144+put Nthole 3 346
145+if ne get Lg 0 1280
146+put Nthole 3 1066
147+end
148+tdraw
149+tflash
150+trun 12290
151+put Nthole 3 417
152+if ne get Lg 0 1280
153+put Nthole 3 1285
154+end
155+tload
156+tdraw
157+tflash
158+put Nthol 0 0
159+trun 16500
160+tload
161+tdraw
162+tbar
163+for i ulong len Ttyped
164+hmkey ulong get Ttyped i
165+trun add get Tnow 0 120
166+end
167+tload
168+tdraw
169+tbar
170+trun 20500
171+hmkey 13
172+hmthink 1
173+trun 23500
174+for i ulong len Tsay
175+put Hmsay i get Tsay i
176+end
177+put Hmsayn 0 len Tsay
178+hmsaid
179+speak = add get Tnow 0 400
180+n = long len Tsay
181+trun add speak div mul n 35 2
182+tload
183+tdraw
184+twords
185+tload
186+tdraw
187+tbar
188+trun add add speak mul n 35 500
189+tload
190+tdraw
191+twords
192+tload
193+tdraw
194+tbar
195+tflush
196+ret 0
197+end

aienux/allen/tests/look-mind.om

new file mode 100644
@@ -0,0 +1,156 @@
1+note tests/look-mind.om: Allen's presence alone on a black frame, as mindref.c / oracle.c layer 8.
2+note stdin: W H T REPS N then N events "ms op arg" (op 0 mode(arg) 1 word 2 key 3 voice(arg)),
3+note applied before the first 16 ms step s >= ms. The mind is stepped every 16 ms from 0 to T,
4+note then at T, drawn REPS times over the full frame, and written as a P6 PPM to fd 1.
5+note fd 2 gets "box x y w h dirty x y w h nspark n" like mindref.c.
6+global Tin uchar 65536
7+global Tinn ulong 2
8+global Tev long 192
9+global Terr uchar 256
10+global Terrn ulong 1
11+fn tnum to long
12+n = get Tinn 0
13+end0 = get Tinn 1
14+while lt n end0 bound 65536
15+if gt get Tin n 32
16+break
17+end
18+n = add n 1
19+end
20+v = long 0
21+while lt n end0 bound 65536
22+c = get Tin n
23+if le c 32
24+break
25+end
26+v = add mul v 10 sub long c 48
27+n = add n 1
28+end
29+put Tinn 0 n
30+ret v
31+end
32+fn tec c uchar to void
33+put Terr get Terrn 0 c
34+put Terrn 0 add get Terrn 0 1
35+end
36+fn teu v ulong to void
37+if ge v 10
38+teu div v 10
39+end
40+tec uchar add 48 rem v 10
41+end
42+fn tel v long to void
43+if lt v 0
44+tec 45
45+teu bitcast ulong neg v
46+ret
47+end
48+teu ulong v
49+end
50+fn tesp to void
51+tec 32
52+end
53+fn terr to void
54+w = write 2 Terr 0 get Terrn 0
55+end
56+fn tprow n ulong w ulong to void
57+for x ulong w
58+p = get Nfrm n
59+tc uchar and shr p 16 255
60+tc uchar and shr p 8 255
61+tc uchar and p 255
62+n = add n 1
63+end
64+end
65+fn tppm w long h long to void
66+tc 80
67+tc 54
68+tc 10
69+tu ulong w
70+tc 32
71+tu ulong h
72+tc 10
73+tu 255
74+tc 10
75+for y ulong ulong h
76+tprow mul y ulong w ulong w
77+end
78+tflush
79+end
80+fn tevent j long s long to void
81+op = get Tev add mul j 3 1
82+arg = get Tev add mul j 3 2
83+if eq op 0
84+mdmode arg s
85+end
86+if eq op 1
87+mdword s
88+end
89+if eq op 2
90+mdkey s
91+end
92+if eq op 3
93+mdvoice arg
94+end
95+end
96+fn main to int
97+r = read 0 Tin 0 65536
98+if le r 0
99+ret 2
100+end
101+put Tinn 1 ulong r
102+w = tnum
103+h = tnum
104+t = tnum
105+reps = tnum
106+n = tnum
107+for i ulong ulong n
108+put Tev mul i 3 tnum
109+put Tev add mul i 3 1 tnum
110+put Tev add mul i 3 2 tnum
111+end
112+pkinit
113+put Lg 0 w
114+put Lg 1 h
115+put Lg 2 pkmin div mul w 256 1920 div mul h 256 1080
116+put Lg 3 div w 2
117+put Lg 4 div mul h 40 100
118+pkclip 0 0 w h
119+mdinit 12300
120+j = long 0
121+s = long 0
122+note (T / 16) + 1 steps
123+while le s t bound 999999
124+while lt j n bound 64
125+if gt get Tev mul j 3 s
126+break
127+end
128+tevent j s
129+j = add j 1
130+end
131+mdat s
132+s = add s 16
133+end
134+mdat t
135+for k ulong ulong reps
136+mddraw 0 0 w h
137+end
138+mddirty
139+tec 98
140+tesp
141+for i ulong 4
142+tel get Mdnow i
143+tesp
144+end
145+tec 100
146+tesp
147+for i ulong 4
148+tel get Mdbox i
149+tesp
150+end
151+tel get Mdv 15
152+tec 10
153+terr
154+tppm w h
155+ret 0
156+end

aienux/allen/tests/look-night.om

new file mode 100644
@@ -0,0 +1,104 @@
1+global Tb uchar 4194304
2+global Tn ulong 1
3+fn tflush to void
4+n = ulong 0
5+while lt n get Tn 0
6+w = write 1 Tb n sub get Tn 0 n
7+if le w 0
8+ret
9+end
10+n = add n ulong w
11+end
12+put Tn 0 0
13+end
14+fn tc c uchar to void
15+if ge get Tn 0 4194000
16+tflush
17+end
18+put Tb get Tn 0 c
19+put Tn 0 add get Tn 0 1
20+end
21+fn tu v ulong to void
22+if ge v 10
23+tu div v 10
24+end
25+tc uchar add 48 rem v 10
26+end
27+fn tl v long to void
28+if lt v 0
29+tc 45
30+tu bitcast ulong neg v
31+ret
32+end
33+tu ulong v
34+end
35+fn tnl to void
36+tc 10
37+end
38+note tests/look-night.om: argv W H T [shim voice]; writes Nfrm after ntinit, ntat T, ntbase, ntlights as P6 to fd 1,
39+note ntbase and ntlights microseconds to fd 2. Compare with cref2 oracle W H T 6 (host-only).
40+note Unit: font-data font look-paint look-skydata look-sky look-night + this file.
41+global Dargs uchar 32
42+fn darg i ulong to long
43+n = argread i Dargs 0 32
44+v = long 0
45+for k ulong ulong n
46+v = add mul v 10 long sub get Dargs k 48
47+end
48+ret v
49+end
50+fn dppm to void
51+w = ulong get Lg 0
52+h = ulong get Lg 1
53+tc 80
54+tc 54
55+tnl
56+tu w
57+tc 32
58+tu h
59+tnl
60+tu 255
61+tnl
62+for y ulong h
63+for x ulong w
64+c = ulong get Nfrm add mul y w x
65+tc uchar and shr c 16 255
66+tc uchar and shr c 8 255
67+tc uchar and c 255
68+end
69+end
70+tflush
71+end
72+fn main to int
73+w = darg 1
74+h = darg 2
75+t = ulong darg 3
76+put Lg 0 w
77+put Lg 1 h
78+put Lg 2 pkmin div mul w 256 1920 div mul h 256 1080
79+put Lg 3 div w 2
80+put Lg 4 div mul h 40 100
81+pkinit
82+pkclip 0 0 w h
83+ntinit
84+ntat t
85+t0 = monons
86+ntbase 0 0 w h
87+t1 = monons
88+sh = ulong 0
89+vo = ulong 0
90+if gt argcnt 5
91+sh = ulong darg 4
92+vo = ulong darg 5
93+end
94+ntlights 0 0 w h sh vo
95+t2 = monons
96+dppm
97+put Tn 0 0
98+tu ulong div sub t1 t0 1000
99+tc 32
100+tu ulong div sub t2 t1 1000
101+tnl
102+n = write 2 Tb 0 get Tn 0
103+ret 0
104+end

aienux/allen/tests/look-paint.om

new file mode 100644
@@ -0,0 +1,243 @@
1+note tests/look-paint.om: prints the drawing kit's values in the same order as the C harness
2+note (~/work/IMacLook/paint/ptest.c over aienux 4b24df65 paint.c); the two outputs must cmp equal.
3+note Unit: font-data.om font.om look-paint.om tio.om tests/look-paint.om.
4+global Tcs ulong 12
5+fn tdump to void
6+for i ulong 3072
7+tu ulong get Nfrm i
8+tnl
9+end
10+end
11+fn tword pen ulong y long c uchar color ulong a ulong plus bool to ulong
12+pen = pkletter pen y c color a plus
13+tu pen
14+tnl
15+ret pen
16+end
17+fn tblend to void
18+put Tcs 0 0
19+put Tcs 1 1052688
20+put Tcs 2 1193046
21+put Tcs 3 16777215
22+put Tcs 4 13158655
23+put Tcs 5 4227327
24+put Tcs 6 16711680
25+put Tcs 7 65280
26+put Tcs 8 255
27+put Tcs 9 8355711
28+put Tcs 10 66051
29+put Tcs 11 16711422
30+for i ulong 12
31+for j ulong 12
32+a = ulong 0
33+while le a 256
34+tu pkadd get Tcs i get Tcs j a
35+tc 32
36+tu pkmix get Tcs i get Tcs j a
37+tc 32
38+tu pkscale get Tcs i a
39+tnl
40+a = add a 19
41+end
42+end
43+end
44+for i ulong 12
45+j = rem add i 1 12
46+tu pkadd get Tcs i get Tcs j 256
47+tc 32
48+tu pkmix get Tcs i get Tcs j 256
49+tc 32
50+tu pkscale get Tcs i 256
51+tnl
52+end
53+end
54+fn tthread x0 long y0 long x1 long y1 long color ulong w long to void
55+put Pa 0 w
56+pkthread x0 y0 x1 y1 color 0
57+end
58+fn tshapes to void
59+for i ulong 3072
60+put Nfrm i 1052688
61+end
62+pkclip 0 0 64 48
63+pkglow 500 400 300 13158655 200
64+pkglow -40 700 160 16777215 256
65+put Pa 1 200
66+put Pa 2 60
67+tthread 30 40 900 600 16762368 16
68+put Pa 1 30
69+put Pa 2 255
70+tthread 800 20 100 700 4227327 40
71+put Pa 1 255
72+put Pa 2 255
73+tthread 100 100 110 700 16777215 24
74+put Pa 1 0
75+put Pa 2 256
76+tthread 50 650 950 660 16746496 8
77+put Pa 1 100
78+put Pa 2 100
79+tthread 300 300 300 300 16777215 16
80+tthread 300 300 500 500 16777215 0
81+put Pa 1 256
82+put Pa 2 0
83+tthread -200 -100 1200 900 8454016 50
84+pkclip 10 5 30 30
85+pkglow 300 300 400 16711680 128
86+pkclip -5 -5 20 20
87+put Pa 1 200
88+put Pa 2 200
89+tthread 0 0 500 120 16777215 12
90+tdump
91+end
92+fn trrect to void
93+put Lg 9 6
94+for j ulong 48
95+for i ulong 64
96+tl pksdrrect long i long j 8 6 40 30
97+tc 32
98+end
99+tnl
100+end
101+put Lg 9 0
102+for j ulong 48
103+for i ulong 64
104+tl pksdrrect long i long j -3 10 70 15
105+tc 32
106+end
107+tnl
108+end
109+end
110+fn tletters to void
111+if not afinit 14 1250
112+trap 9
113+end
114+for i ulong 3072
115+if eq and i 1 1
116+put Nfrm i 2105408
117+else
118+put Nfrm i 0
119+end
120+end
121+pkclip 0 0 64 48
122+pen = ulong 868
123+pen = tword pen 20 65 16769184 230 false
124+pen = tword pen 20 103 16769184 230 false
125+pen = tword pen 20 63 16769184 230 false
126+pen = tword pen 20 106 16769184 230 false
127+pen = tword pen 20 32 16769184 230 false
128+pen = tword pen 20 44 16769184 230 false
129+pen = tword pen 20 87 16769184 230 false
130+pen = 256
131+pen = tword pen 38 105 8438015 256 true
132+pen = tword pen 38 77 8438015 256 true
133+pen = tword pen 38 97 8438015 256 true
134+pen = tword pen 38 99 8438015 256 true
135+pkclip 10 5 30 30
136+pen = 256
137+pen = tword pen 30 88 16728128 120 true
138+pen = tword pen 30 121 16728128 120 true
139+pkclip 0 0 64 48
140+pen = 256
141+pen = tword pen 30 81 16728128 0 false
142+tdump
143+end
144+fn main to int
145+pkinit
146+for i ulong 677
147+a = mul i 97
148+tl pksin a
149+tc 32
150+tl pkcos a
151+tnl
152+end
153+y = long -50000
154+while le y 50000
155+x = long -50000
156+while le x 50000
157+tu pkatan2 y x
158+tnl
159+x = add x 3331
160+end
161+y = add y 2917
162+end
163+tu pkatan2 3 0
164+tnl
165+tu pkatan2 -7 0
166+tnl
167+for i ulong 600
168+tu pkexpneg mul i 7
169+tnl
170+end
171+for i ulong 257
172+tu get Plog i
173+tnl
174+end
175+v = ulong 1
176+while lt v 4611686018427387904
177+tu pklog2q16 v
178+tc 32
179+tu pkisqrt v
180+tnl
181+v = add mul v 3 1
182+end
183+tu pklog2q16 0
184+tc 32
185+tu pkisqrt 0
186+tnl
187+y = long -2000
188+while le y 2000
189+x = long -3000
190+while le x 3000
191+tu pkhash x y 909
192+tc 32
193+tu pknoise x y 909
194+tc 32
195+tu pkfbm x y 909 4
196+tnl
197+x = add x 413
198+end
199+y = add y 377
200+end
201+t = long -20
202+while le t 280
203+tu pksmooth t
204+tc 32
205+tu pkeaseout t
206+tc 32
207+tl pkprog ulong add 1000 t 990 1200
208+tnl
209+t = add t 7
210+end
211+tl pkprog 5 9 20
212+tc 32
213+tl pkprog 50 9 20
214+tc 32
215+tl pkprog 20 9 20
216+tnl
217+t = long -40
218+while le t 40
219+tu pkcover t
220+tnl
221+t = add t 3
222+end
223+l = ulong 0
224+while lt l 40000
225+tu pklenc l
226+tnl
227+l = add l 61
228+end
229+for i ulong 256
230+tu ulong get Slin i
231+tc 32
232+tu ulong get Ssrgb add mul i 16 1
233+tnl
234+end
235+tblend
236+put Lg 0 64
237+put Lg 1 48
238+tshapes
239+trrect
240+tletters
241+tflush
242+ret 0
243+end

aienux/allen/tests/look-sky.om

new file mode 100644
@@ -0,0 +1,121 @@
1+note tests/look-sky.om: the sky as the C oracle (layer 1, cref2/oracle W H 0 1) draws it, as a P6 PPM on
2+note stdout: argv 1 W, argv 2 H. k and the centre as allen_ui.c sets them: k = min(w*4/30, h*4/25)
3+note rounded to 2 (ck_night_init's caller), cx = w/2, cy = h*2/5. Then one twinkle check (argv 3 = "tw"):
4+note Nfrm black, clip (100, 100, w-200, h-200), sktwink of every listed star with amount 96, PPM of Nfrm.
5+global Targ uchar 16
6+fn targ i ulong to long
7+n = argread i Targ 0 16
8+if lt n 0
9+ret -1
10+end
11+v = long 0
12+for j ulong ulong n
13+v = add mul v 10 long sub ulong get Targ j 48
14+end
15+ret v
16+end
17+fn tppm to void
18+w = ulong get Lg 0
19+h = ulong get Lg 1
20+tc 80
21+tc 54
22+tc 10
23+tu w
24+tc 32
25+tu h
26+tc 10
27+tu 255
28+tc 10
29+tflush
30+for y ulong h
31+r = mul y w
32+for x ulong w
33+c = ulong 0
34+if eq get Sktgt 0 0
35+c = ulong get Nsky add r x
36+else
37+c = ulong get Nfrm add r x
38+end
39+tc uchar and shr c 16 255
40+tc uchar and shr c 8 255
41+tc uchar and c 255
42+end
43+tflush
44+end
45+end
46+fn tgsum i ulong to void
47+b = mul i 4
48+n = mul ulong get Skgbox add b 2 ulong get Skgbox add b 3
49+o = get Skgoff i
50+sl = ulong 0
51+sp = ulong 0
52+for k ulong n
53+b = add o k
54+sl = add sl mul ulong get Skglit b add rem k 1000 1
55+sp = add sp mul ulong get Skgpha b add rem k 997 1
56+end
57+tu sl
58+tc 32
59+tu sp
60+end
61+fn main to int
62+w = targ 1
63+h = targ 2
64+if lt w 1
65+ret 2
66+end
67+if lt h 1
68+ret 2
69+end
70+put Lg 0 w
71+put Lg 1 h
72+k = pkmin div mul w 4 30 div mul h 4 25
73+put Lg 2 and k -2
74+put Lg 3 div w 2
75+put Lg 4 div mul h 2 5
76+pkinit
77+skmake
78+if eq argcnt 3
79+tppm
80+ret 0
81+end
82+n = argread 3 Targ 0 16
83+if eq get Targ 0 103
84+note argv 3 "gal": per galaxy i box tint period and weighted sums of light and phase, then ntw
85+for i ulong 6
86+b = mul i 4
87+tu i
88+tc 32
89+tl get Skgbox b
90+tc 32
91+tl get Skgbox add b 1
92+tc 32
93+tl get Skgbox add b 2
94+tc 32
95+tl get Skgbox add b 3
96+tc 32
97+tu ulong get Skgtint i
98+tc 32
99+tu get Skgper i
100+tc 32
101+tgsum i
102+tnl
103+end
104+tu 103
105+tc 32
106+tu get Sktwn 0
107+tnl
108+tflush
109+ret 0
110+end
111+put Lg 5 100
112+put Lg 6 100
113+put Lg 7 sub w 200
114+put Lg 8 sub h 200
115+for i ulong get Sktwn 0
116+sktwink i 96
117+end
118+put Sktgt 0 1
119+tppm
120+ret 0
121+end

aienux/allen/tests/look-submit.om

new file mode 100644
@@ -0,0 +1,108 @@
1+note SPDX-License-Identifier: MIT
2+note Offline Enter must give visible feedback without losing the unsent line or sending a job.
3+note The real show/input/application modules are used; firmware-only calls are not exercised.
4+text Trequest "hello"
5+text Tnet "STAT net=0 e=14 h=2 l=0 c=7 p=88 m=787b8abdd051 s="
6+text Tnone "STAT net=0 e=14 h=0 l=14 c=1 p=0 m=787b8abdd051 s="
7+fn tinput to void
8+put Hminn 0 0
9+for i ulong len Trequest
10+hmkey ulong get Trequest i
11+end
12+end
13+fn main to int
14+constants
15+put Sh 11 1000
16+ok = chinit 1000 8765
17+if not ok
18+ret 90
19+end
20+tinput
21+put Hm 14 long len Trequest
22+put Hm 16 get Hm 15
23+put Es 6 0
24+put Hmsayn 0 0
25+ok = shkey 13
26+if eq get Hmsayn 0 0
27+ret 11
28+end
29+if ne get Hminn 0 len Trequest
30+ret 12
31+end
32+for i ulong len Trequest
33+if ne get Hmin i get Trequest i
34+ret 13
35+end
36+end
37+if chbusy
38+ret 14
39+end
40+note The next rendered frame must keep the unsent text visible, not show the empty placeholder.
41+hmnotes 1000
42+if ne get Hm 14 long len Trequest
43+ret 15
44+end
45+note The stats line leads with efnetup's network fields (Es 6 12 14 15 and Nmac): two adapters
46+note refused for their link after seven scans, then a firmware with no SNP handle at all.
47+put Es 12 14
48+put Es 14 add 2 shl ulong 7 16
49+put Es 15 136
50+put Nmac 0 120
51+put Nmac 1 123
52+put Nmac 2 138
53+put Nmac 3 189
54+put Nmac 4 208
55+put Nmac 5 81
56+stline
57+if lt get Sttn 0 len Tnet
58+ret 16
59+end
60+for i ulong len Tnet
61+if ne get Stt i get Tnet i
62+ret 17
63+end
64+end
65+put Es 14 add shl ulong 14 8 shl ulong 1 16
66+put Es 15 0
67+note Diagnostics must remain usable without a network link.
68+put Hminn 0 0
69+for i ulong len Stkey
70+hmkey ulong get Stkey i
71+end
72+stline
73+ok = shkey 13
74+if ne get Hminn 0 0
75+ret 21
76+end
77+if lt get Hmsayn 0 5
78+ret 22
79+end
80+if ne get Hmsay 0 83
81+ret 23
82+end
83+if lt get Hmsayn 0 len Tnone
84+ret 24
85+end
86+for i ulong len Tnone
87+if ne get Hmsay i get Tnone i
88+ret 25
89+end
90+end
91+note Empty Enter does not replace the last answer.
92+put Hmsayn 0 5
93+ok = shkey 13
94+if ne get Hmsayn 0 5
95+ret 31
96+end
97+note Reconnecting must still allow a normal request to enter the courier workflow.
98+put Es 6 1
99+tinput
100+ok = shkey 13
101+if ne get Hminn 0 0
102+ret 41
103+end
104+if not chbusy
105+ret 42
106+end
107+ret 0
108+end

aienux/allen/tests/memory.om

new file mode 100644
@@ -0,0 +1,146 @@
1+global Disk uchar 8192
2+text Name "Allen"
3+text Ntext "Meet at noon."
4+fn enctounit to void
5+for i ulong 4096
6+put Unit i get Enc i
7+end
8+end
9+fn diskput slot ulong count ulong to void
10+for i ulong count
11+put Disk add mul slot 4096 i get Enc i
12+end
13+end
14+fn diskget slot ulong to void
15+for i ulong 4096
16+put Unit i get Disk add mul slot 4096 i
17+end
18+end
19+fn main to int
20+constants
21+mset32 0 3
22+for i ulong len Name
23+put Mem add i 40 get Name i
24+end
25+check memenc 1 301
26+check eq get32 12 76 302
27+check memdec 303
28+check eq get Md 0 1 304
29+check eq get Mem 40 65 305
30+put Unit 24 uchar 1
31+check not memdec 306
32+check eq get Md 0 1 307
33+check eq get Mem 40 65 308
34+enctounit
35+put Unit 64 uchar 4
36+check not memdec 309
37+check eq get Mem 0 3 310
38+enctounit
39+put32 8 3
40+put32 12 64
41+seal 64
42+check memdec 311
43+check eq get Md 1 3 312
44+check eq get Mem 40 65 313
45+put32 8 2
46+put32 12 40
47+for i ulong 24
48+put Unit add i 104 0
49+end
50+seal 40
51+check memdec 314
52+check eq get Md 1 2 315
53+check eq get Mem 40 0 316
54+put Mem 40 uchar 65
55+check memenc 1 317
56+check txbegin 318
57+check eq get Tx 1 0 319
58+diskput 0 4096
59+check txwrite true 320
60+check txflush true 321
61+diskget 0
62+check txread true 322
63+check eq get St 0 1 323
64+check eq get St 1 0 324
65+mset32 0 4
66+check txbegin 325
67+check eq get Tx 1 1 326
68+diskput 1 512
69+check not txwrite false 327
70+check eq get St 0 1 328
71+diskget 0
72+check memdec 329
73+check eq get Mem 0 3 330
74+mset32 0 4
75+check txbegin 331
76+diskput 1 4096
77+check txwrite true 332
78+check not txflush false 333
79+check eq get St 0 1 334
80+check txbegin 335
81+check txwrite true 336
82+check txflush true 337
83+diskget 1
84+put Unit 200 uchar 1
85+check not txread true 338
86+check eq get St 0 1 339
87+check txbegin 340
88+check txwrite true 341
89+check txflush true 342
90+check not txread false 343
91+check eq get St 0 1 344
92+check txbegin 345
93+diskput 1 4096
94+check txwrite true 346
95+check txflush true 347
96+diskget 1
97+check txread true 348
98+check eq get St 0 2 349
99+check eq get St 1 1 350
100+for i ulong 3
101+put St i 0
102+end
103+diskget 1
104+check loadcopy 1 351
105+diskget 0
106+check loadcopy 0 352
107+check not loadcopy 0 362
108+check eq get St 2 2 363
109+check eq get St 0 2 353
110+check eq get Mem 0 4 354
111+put Ns 0 len Ntext
112+put Ns 1 2
113+put Ns 2 3
114+for i ulong len Ntext
115+put Note i get Ntext i
116+end
117+check noteenc 355
118+check notedec 2 356
119+check eq get Ns 0 len Ntext 357
120+check not notedec 3 358
121+put Unit 28 uchar 1
122+check not notedec 2 359
123+check eq get Ns 1 2 360
124+check nbegin 364
125+check not txbegin 365
126+check not nwrite false 366
127+check eq get Nt 0 0 367
128+check nbegin 368
129+check nwrite true 369
130+check not nflush false 370
131+check nbegin 371
132+check nwrite true 372
133+check nflush true 373
134+enctounit
135+put Unit 300 uchar 1
136+check not nread true 374
137+check nbegin 375
138+check nwrite true 376
139+check nflush true 377
140+enctounit
141+check nread true 378
142+check eq get St 0 2 379
143+put St 0 18446744073709551615
144+check not txbegin 361
145+ret int get Fails 0
146+end

aienux/allen/tests/net.om

new file mode 100644
@@ -0,0 +1,722 @@
1+note Packet stack behavior; concatenate after base.om, net.om, tests/check.om.
2+note Frames are built here from RFC791/768/826/2131/1035/9293 layouts with an
3+note independent checksum; outgoing frames are checked against the same rules.
4+note Host-only protocol fixtures: no live network, firmware or peer qualification.
5+global Vnow ulong 1
6+global Vpeer uchar 6
7+global Vip ulong 1
8+global Vxid ulong 1
9+global Vport ulong 1
10+global Viss ulong 1
11+global Vdport ulong 1
12+global Vdid ulong 1
13+text Vq "apigithubcom"
14+text Vqmix "ApIgithubCOM"
15+text Vget "GEThello"
16+fn nvip4 a ulong b ulong c ulong d ulong to ulong
17+ret add add shl a 24 shl b 16 add shl c 8 d
18+end
19+fn nvsrv to ulong
20+ret nvip4 10 9 8 1
21+end
22+fn nvdns to ulong
23+ret nvip4 10 9 8 53
24+end
25+fn nvgh to ulong
26+ret nvip4 140 82 112 6
27+end
28+fn nvsseq to ulong
29+ret 3000000000
30+end
31+fn nvw16 p ulong v ulong to void
32+put Nrx p uchar and shr v 8 255
33+put Nrx add p 1 uchar and v 255
34+end
35+fn nvw32 p ulong v ulong to void
36+nvw16 p shr v 16
37+nvw16 add p 2 and v 65535
38+end
39+fn nvt16 p ulong to ulong
40+ret add shl ulong get Ntx p 8 ulong get Ntx add p 1
41+end
42+fn nvt32 p ulong to ulong
43+ret add shl nvt16 p 16 nvt16 add p 2
44+end
45+note Independent one's-complement sum: byte pairs, odd tail as high octet.
46+fn nvsum tx bool p ulong n ulong to ulong
47+s = ulong 0
48+for i ulong n
49+v = ulong 0
50+if tx
51+v = ulong get Ntx add p i
52+else
53+v = ulong get Nrx add p i
54+end
55+if eq rem i 2 0
56+s = add s shl v 8
57+else
58+s = add s v
59+end
60+end
61+ret s
62+end
63+fn nvcpl s ulong to ulong
64+while gt s 65535 bound 8
65+s = add shr s 16 and s 65535
66+end
67+ret xor s 65535
68+end
69+fn nvpseudo a ulong b ulong pr ulong n ulong to ulong
70+s = add add shr a 16 and a 65535 add shr b 16 and b 65535
71+ret add s add pr n
72+end
73+fn nvsetmac p ulong last ulong to void
74+for i ulong 5
75+put Vpeer i uchar 0
76+end
77+put Vpeer 0 uchar 2
78+put Vpeer 5 uchar last
79+put Vpeer 4 uchar p
80+end
81+fn nvclr to void
82+for i ulong 2048
83+put Nrx i uchar 0
84+end
85+end
86+fn nveth typ ulong to void
87+for i ulong 6
88+put Nrx i get Nmac i
89+put Nrx add i 6 get Vpeer i
90+end
91+nvw16 12 typ
92+end
93+fn nvip src ulong dst ulong pr ulong l4 ulong to void
94+nveth 2048
95+put Nrx 14 uchar 69
96+nvw16 16 add l4 20
97+nvw16 20 16384
98+put Nrx 22 uchar 64
99+put Nrx 23 uchar pr
100+nvw32 26 src
101+nvw32 30 dst
102+nvw16 24 0
103+nvw16 24 nvcpl nvsum false 14 20
104+end
105+fn nvudp src ulong dst ulong sp ulong dp ulong n ulong to ulong
106+nvw16 34 sp
107+nvw16 36 dp
108+nvw16 38 add n 8
109+s = nvpseudo src dst 17 add n 8
110+c = nvcpl add s nvsum false 34 add n 8
111+if eq c 0
112+c = 65535
113+end
114+nvw16 40 c
115+nvip src dst 17 add n 8
116+ret add 42 n
117+end
118+fn nvtcp src ulong seq ulong ack ulong fl ulong hl ulong dl ulong to ulong
119+nvw16 34 443
120+nvw16 36 get Vport 0
121+nvw32 38 seq
122+nvw32 42 ack
123+put Nrx 46 uchar mul div hl 4 16
124+put Nrx 47 uchar fl
125+nvw16 48 65535
126+nvw16 50 0
127+s = nvpseudo src get Vip 0 6 add hl dl
128+nvw16 50 nvcpl add s nvsum false 34 add hl dl
129+nvip src get Vip 0 6 add hl dl
130+ret add 34 add hl dl
131+end
132+fn nvin n ulong to void
133+if lt n 60
134+n = 60
135+end
136+netinput n get Vnow 0
137+end
138+note Each outgoing IPv4 frame: header checksum, UDP/TCP pseudo-header checksum.
139+fn nvtxok to bool
140+if ne nvt16 12 2048
141+ret false
142+end
143+if ne nvcpl nvsum true 14 20 0
144+ret false
145+end
146+n = sub nvt16 16 20
147+if gt add n 34 get Ntxlen 0
148+ret false
149+end
150+s = nvpseudo nvt32 26 nvt32 30 ulong get Ntx 23 n
151+ret eq nvcpl add s nvsum true 34 n 0
152+end
153+fn nvnext to bool
154+for i ulong 400
155+netstep get Vnow 0
156+if ne get Ntxlen 0 0
157+ret true
158+end
159+put Vnow 0 add get Vnow 0 250
160+end
161+ret false
162+end
163+fn nvsent to void
164+netsent true get Vnow 0
165+end
166+fn nvstart to bool
167+put Vnow 0 5000
168+put Nmac 0 uchar 2
169+for i ulong 4
170+put Nmac add i 1 uchar 0
171+end
172+put Nmac 5 uchar 1
173+netinit get Vnow 0
174+for i ulong 32
175+put Nrand i uchar add i 1
176+end
177+put Vip 0 nvip4 10 9 8 20
178+netconnect get Vnow 0
179+for i ulong 32
180+if ne get Nrand i 0
181+ret false
182+end
183+end
184+ret eq get Tcpstate 0 1
185+end
186+fn nvdisc to bool
187+if not nvnext
188+ret false
189+end
190+for i ulong 6
191+if ne get Ntx i 255
192+ret false
193+end
194+end
195+if or ne nvt16 34 68 ne nvt16 36 67
196+ret false
197+end
198+if or ne get Ntx 42 1 ne nvt32 278 1669485411
199+ret false
200+end
201+put Vxid 0 nvt32 46
202+if ne get Vxid 0 nvip4 1 2 3 4
203+ret false
204+end
205+if or ne get Ntx 282 53 ne get Ntx 284 1
206+ret false
207+end
208+ret nvtxok
209+end
210+fn nvopt p ulong code ulong v ulong to void
211+put Nrx p uchar code
212+put Nrx add p 1 uchar 4
213+nvw32 add p 2 v
214+end
215+fn nvdhcp typ ulong xid ulong to ulong
216+nvclr
217+nvsetmac 0 170
218+put Nrx 42 uchar 2
219+put Nrx 43 uchar 1
220+put Nrx 44 uchar 6
221+nvw32 46 xid
222+nvw32 58 get Vip 0
223+for i ulong 6
224+put Nrx add i 70 get Nmac i
225+end
226+nvw32 278 1669485411
227+put Nrx 282 uchar 53
228+put Nrx 283 uchar 1
229+put Nrx 284 uchar typ
230+nvopt 285 54 nvsrv
231+nvopt 291 1 nvip4 255 255 255 0
232+nvopt 297 3 nvsrv
233+nvopt 303 6 nvdns
234+nvopt 309 51 3600
235+put Nrx 315 uchar 255
236+ret nvudp nvsrv 4294967295 67 68 274
237+end
238+fn nvreq to bool
239+if not nvnext
240+ret false
241+end
242+if or ne get Ntx 284 3 ne get Ntx 285 50
243+ret false
244+end
245+if or ne nvt32 287 get Vip 0 ne nvt32 293 nvsrv
246+ret false
247+end
248+if ne nvt32 46 get Vxid 0
249+ret false
250+end
251+ret nvtxok
252+end
253+fn nvarpq spa ulong tpa ulong to bool
254+if not nvnext
255+ret false
256+end
257+if or ne nvt16 12 2054 ne nvt16 20 1
258+ret false
259+end
260+for i ulong 6
261+if or ne get Ntx add i 6 get Nmac i ne get Ntx add i 22 get Nmac i
262+ret false
263+end
264+end
265+ret and eq nvt32 28 spa eq nvt32 38 tpa
266+end
267+fn nvarp op ulong spa ulong tpa ulong to ulong
268+nvclr
269+nveth 2054
270+nvw16 14 1
271+nvw16 16 2048
272+put Nrx 18 uchar 6
273+put Nrx 19 uchar 4
274+nvw16 20 op
275+for i ulong 6
276+put Nrx add i 22 get Vpeer i
277+put Nrx add i 32 get Nmac i
278+end
279+nvw32 28 spa
280+nvw32 38 tpa
281+ret 60
282+end
283+fn nvdnsq to bool
284+if not nvnext
285+ret false
286+end
287+for i ulong 6
288+if ne get Ntx i get Vpeer i
289+ret false
290+end
291+end
292+if or ne nvt32 30 nvdns ne nvt16 36 53
293+ret false
294+end
295+put Vdport 0 nvt16 34
296+put Vdid 0 nvt16 42
297+if ne get Vdport 0 add 49152 rem nvip4 9 10 11 12 16384
298+ret false
299+end
300+if or ne get Vdid 0 and nvip4 5 6 7 8 65535 ne nvt16 44 256
301+ret false
302+end
303+if or ne get Ntx 54 3 ne get Ntx 58 6
304+ret false
305+end
306+if or ne get Ntx 65 3 ne get Ntx 69 0
307+ret false
308+end
309+for i ulong 3
310+if or ne get Ntx add i 55 get Vq i ne get Ntx add i 66 get Vq add i 9
311+ret false
312+end
313+end
314+for i ulong 6
315+if ne get Ntx add i 59 get Vq add i 3
316+ret false
317+end
318+end
319+if or ne nvt16 70 1 ne nvt16 72 1
320+ret false
321+end
322+ret nvtxok
323+end
324+fn nvboot to bool
325+if not nvstart
326+ret false
327+end
328+if not nvdisc
329+ret false
330+end
331+nvsent
332+nvin nvdhcp 2 add get Vxid 0 1
333+netstep get Vnow 0
334+if ne get Ntxlen 0 0
335+ret false
336+end
337+n = nvdhcp 2 get Vxid 0
338+put Nrx 100 uchar 1
339+nvin n
340+netstep get Vnow 0
341+if ne get Ntxlen 0 0
342+ret false
343+end
344+nvin nvdhcp 2 get Vxid 0
345+if not nvreq
346+ret false
347+end
348+nvsent
349+nvin nvdhcp 5 get Vxid 0
350+for k ulong 3
351+if not nvarpq 0 get Vip 0
352+ret false
353+end
354+nvsent
355+end
356+for k ulong 2
357+if not nvarpq get Vip 0 get Vip 0
358+ret false
359+end
360+nvsent
361+end
362+if not nvarpq get Vip 0 nvdns
363+ret false
364+end
365+nvsent
366+if ne get Tcpstate 0 2
367+ret false
368+end
369+nvsetmac 0 187
370+nvin nvarp 2 nvdns get Vip 0
371+if not nvdnsq
372+ret false
373+end
374+nvsent
375+ret true
376+end
377+note DNS question in mixed case; CNAME via compression to the question, A via
378+note compression to the CNAME rdata. mode 1 forward pointer, 2 TC, 3 wrong id.
379+fn nvqname p ulong to void
380+put Nrx p uchar 3
381+put Nrx add p 4 uchar 6
382+put Nrx add p 11 uchar 3
383+for i ulong 3
384+put Nrx add add p 1 i get Vqmix i
385+put Nrx add add p 12 i get Vqmix add i 9
386+end
387+for i ulong 6
388+put Nrx add add p 5 i get Vqmix add i 3
389+end
390+end
391+fn nvrr p ulong name ulong typ ulong n ulong to void
392+nvw16 p name
393+nvw16 add p 2 typ
394+nvw16 add p 4 1
395+nvw32 add p 6 60
396+nvw16 add p 10 n
397+end
398+fn nvdnsr mode ulong to ulong
399+nvclr
400+nvsetmac 0 187
401+id = get Vdid 0
402+if eq mode 3
403+id = xor id 1
404+end
405+nvw16 42 id
406+if eq mode 2
407+nvw16 44 33664
408+else
409+nvw16 44 33152
410+end
411+nvw16 46 1
412+nvw16 48 2
413+nvqname 54
414+nvw16 70 1
415+nvw16 72 1
416+nvrr 74 49164 5 7
417+put Nrx 86 uchar 4
418+put Nrx 87 uchar 101
419+put Nrx 88 uchar 100
420+put Nrx 89 uchar 103
421+put Nrx 90 uchar 101
422+nvw16 91 49168
423+if eq mode 1
424+nvrr 93 49232 1 4
425+else
426+nvrr 93 49196 1 4
427+end
428+nvw32 105 nvgh
429+src = nvdns
430+if eq mode 6
431+src = add src 1
432+end
433+dp = get Vdport 0
434+if eq mode 4
435+dp = add dp 1
436+end
437+n = nvudp src get Vip 0 53 dp 67
438+if eq mode 5
439+put Nrx 108 xor get Nrx 108 1
440+end
441+ret n
442+end
443+fn nvsyn to bool
444+if not nvnext
445+ret false
446+end
447+for i ulong 6
448+if ne get Ntx i get Vpeer i
449+ret false
450+end
451+end
452+if or ne nvt32 30 nvgh ne get Ntx 23 6
453+ret false
454+end
455+if or ne get Ntx 47 2 ne get Ntx 46 96
456+ret false
457+end
458+if or ne nvt16 54 516 ne nvt16 56 1460
459+ret false
460+end
461+put Viss 0 nvt32 38
462+put Vport 0 nvt16 34
463+if ne get Viss 0 nvip4 13 14 15 16
464+ret false
465+end
466+if ne get Vport 0 add 49152 rem nvip4 17 18 19 20 16384
467+ret false
468+end
469+if ne nvt16 36 443
470+ret false
471+end
472+ret nvtxok
473+end
474+fn nvsynack bad ulong to ulong
475+nvclr
476+nvsetmac 0 170
477+put Nrx 54 uchar 2
478+put Nrx 55 uchar 4
479+nvw16 56 1400
480+src = nvgh
481+ack = nadd get Viss 0 1
482+if eq bad 2
483+ack = nadd ack 1
484+end
485+if eq bad 3
486+src = add src 1
487+end
488+n = nvtcp src nvsseq ack 18 24 0
489+if eq bad 1
490+put Nrx 51 xor get Nrx 51 1
491+end
492+ret n
493+end
494+fn nvisack seq ulong ack ulong fl ulong dl ulong to bool
495+if not nvtxok
496+ret false
497+end
498+if or ne nvt32 38 seq ne nvt32 42 ack
499+ret false
500+end
501+if or ne get Ntx 47 uchar fl ne nvt16 16 add 40 dl
502+ret false
503+end
504+ret and eq nvt16 34 get Vport 0 eq nvt16 36 443
505+end
506+fn nvopen hard bool to bool
507+if not nvboot
508+ret false
509+end
510+if hard
511+for m ulong 4
512+nvin nvdnsr add m 3
513+end
514+if ne get Tcpstate 0 2
515+ret false
516+end
517+end
518+nvin nvdnsr 0
519+if or ne get Tcpstate 0 3 ne get Tcpstate 2 nvgh
520+ret false
521+end
522+if not nvarpq get Vip 0 nvsrv
523+ret false
524+end
525+nvsent
526+nvsetmac 0 170
527+nvin nvarp 2 nvsrv get Vip 0
528+if not nvsyn
529+ret false
530+end
531+nvsent
532+if hard
533+for b ulong 3
534+nvin nvsynack add b 1
535+if ne get Tcpstate 0 3
536+ret false
537+end
538+end
539+end
540+nvin nvsynack 0
541+if ne get Tcpstate 0 4
542+ret false
543+end
544+if not nvnext
545+ret false
546+end
547+if not nvisack nadd get Viss 0 1 nadd nvsseq 1 16 0
548+ret false
549+end
550+nvsent
551+ret true
552+end
553+fn nvinj off ulong n ulong fl ulong src ulong ack ulong to ulong
554+note Inject a TCP segment at a stream offset with a repeated payload byte; no golden bytes needed.
555+nvclr
556+nvsetmac 0 170
557+for i ulong n
558+put Nrx add 54 i uchar and i 255
559+end
560+ret nvtcp src nadd nvsseq add 1 off ack fl 20 n
561+end
562+fn nvdata off ulong n ulong fl ulong src ulong ack ulong dat ulong to ulong
563+nvclr
564+nvsetmac 0 170
565+for i ulong n
566+put Nrx add 54 i get Vget add dat i
567+end
568+ret nvtcp src nadd nvsseq add 1 off ack fl 20 n
569+end
570+fn nvwire to void
571+note RFC1071/791 header example with known checksum b861.
572+for i ulong 20
573+put Ntx i uchar 0
574+end
575+put Ntx 0 uchar 69
576+put Ntx 3 uchar 115
577+put Ntx 6 uchar 64
578+put Ntx 8 uchar 64
579+put Ntx 9 uchar 17
580+put Ntx 12 uchar 192
581+put Ntx 13 uchar 168
582+put Ntx 15 uchar 1
583+put Ntx 16 uchar 192
584+put Ntx 17 uchar 168
585+put Ntx 19 uchar 199
586+check eq nfold ntsum 0 20 47201 1
587+check eq nvcpl nvsum true 0 20 47201 2
588+put Nrx 0 uchar 1
589+put Nrx 1 uchar 2
590+put Nrx 2 uchar 3
591+check eq nrsum 0 3 1026 3
592+check nlt 4294967295 0 4
593+check not nlt 0 4294967295 5
594+check eq nadd 4294967295 2 1 6
595+check eq ndiff 1 4294967295 2 7
596+end
597+fn nvfail code ulong id ulong to void
598+check eq get Tcpstate 0 6 id
599+check eq get Tcpstate 1 code add id 1
600+check eq get Ntxlen 0 0 add id 2
601+end
602+fn main to int
603+nvwire
604+check nvopen true 10
605+put Tcpout 0 uchar 71
606+put Tcpout 1 uchar 69
607+put Tcpout 2 uchar 84
608+check netwrite 3 get Vnow 0 11
609+check not netwrite 1 get Vnow 0 12
610+check nvnext 13
611+a = nadd nvsseq 1
612+check nvisack nadd get Viss 0 1 a 24 3 14
613+check eq get Ntx 54 71 15
614+netstep get Vnow 0
615+check eq get Ntx 54 71 16
616+netsent false get Vnow 0
617+check ne get Ntxlen 0 0 17
618+nvsent
619+check nvnext 18
620+check nvisack nadd get Viss 0 1 a 24 3 19
621+nvsent
622+s = nadd get Viss 0 4
623+nvin nvdata 3 2 24 nvgh s 6
624+check eq get Tcpn 0 0 20
625+nvin nvdata 0 3 24 nvgh s 3
626+check eq get Tcpn 0 5 21
627+for i ulong 5
628+check eq get Tcpin i get Vget add i 3 add 22 i
629+end
630+check netwrite 1 get Vnow 0 27
631+nvin nvdata 0 3 24 nvgh s 3
632+check eq get Tcpn 0 5 28
633+nvin nvdata 5 1 24 add nvgh 1 s 3
634+check eq get Tcpn 0 5 29
635+nvin nvdata 5 0 17 nvgh s 3
636+check eq get Tcpstate 0 5 30
637+check eq get Tcpn 0 5 31
638+netconsume 5
639+check eq get Tcpn 0 0 32
640+netconsume 1
641+nvfail 17 33
642+check nvopen false 40
643+nvin nvtcp nvgh nadd nvsseq 101 nadd get Viss 0 1 4 20 0
644+check eq get Tcpstate 0 4 41
645+check nvnext 42
646+nvin nvtcp nvgh nadd nvsseq 1 nadd get Viss 0 1 4 20 0
647+nvfail 12 43
648+check nvopen false 50
649+s = nadd get Viss 0 1
650+nvin nvdata 10 2 24 nvgh s 3
651+check eq get Tcpn 0 0 51
652+nvin nvdata 10 2 24 nvgh s 5
653+nvfail 13 52
654+check nvopen false 60
655+check not netwrite 65537 get Vnow 0 61
656+nvfail 17 62
657+check nvboot 70
658+nvin nvdnsr 1
659+nvfail 10 71
660+check nvboot 80
661+nvin nvdnsr 2
662+nvfail 9 81
663+check nvstart 90
664+netstep 1
665+nvfail 1 91
666+put Vnow 0 5000
667+netinit get Vnow 0
668+netconnect get Vnow 0
669+nvfail 2 92
670+check nvstart 100
671+check nvdisc 101
672+nvsent
673+nvin nvdhcp 2 get Vxid 0
674+check nvreq 102
675+nvsent
676+nvin nvdhcp 5 get Vxid 0
677+check nvarpq 0 get Vip 0 103
678+nvsent
679+nvsetmac 0 204
680+nvin nvarp 1 get Vip 0 nvsrv
681+check nvnext 104
682+check eq get Ntx 284 4 105
683+nvsent
684+nvfail 6 106
685+note aienux#454: three in-order 1440-byte segments after the app consumed the previous record.
686+check nvopen false 200
687+ok = netwrite 3 get Vnow 0
688+ok = nvnext
689+nvsent
690+a = nadd nvsseq 4
691+b = nadd nvsseq 1
692+put Ndrop 0 0
693+nvin nvinj 0 1440 24 nvgh a
694+nvin nvinj 1440 1440 24 nvgh a
695+nvin nvinj 2880 1440 24 nvgh a
696+check eq get Tcpn 0 4320 201
697+check eq ndiff get Nct 2 b 4320 202
698+check eq get Ndrop 0 0 203
699+netconsume 4320
700+note aienux#454: a long transfer must not die on the mode-3 idle cap while frames keep arriving.
701+put Ncfg 1 3
702+put Ncfg 9 5000
703+t = get Vnow 0
704+put Vnow 0 add t 4000
705+nvin nvinj 4320 0 16 nvgh a
706+put Vnow 0 add t 6000
707+netstep get Vnow 0
708+check ne get Tcpstate 0 6 204
709+put Ncfg 1 2
710+note aienux#454: an in-order peer FIN completes the stream instead of being ignored.
711+check nvopen false 205
712+ok = netwrite 3 get Vnow 0
713+ok = nvnext
714+nvsent
715+c = nadd nvsseq 4
716+nvin nvinj 0 3 24 nvgh c
717+netconsume 3
718+nvin nvinj 3 0 17 nvgh c
719+check eq get Tcpstate 0 5 206
720+check eq get Tcpn 0 0 207
721+ret int get Fails 0
722+end

aienux/allen/tests/paint.om

new file mode 100644
@@ -0,0 +1,16 @@
1+fn main to int
2+check eq addcolor 0 16777215 256 16777215 1101
3+check eq addcolor 16777215 16777215 256 16777215 1102
4+check eq mix 0 16777215 256 16777215 1103
5+check eq mix 0 16777215 0 0 1104
6+check eq scale 16777215 128 8355711 1105
7+check not glow 0 0 0 0 1 1106
8+render
9+check eq get Frame 0 0 1107
10+check gt get Frame 12384 0 1108
11+check eq get Frame 24575 0 1109
12+old = get Frame 12384
13+check not glow 9000 0 16 1 1 1110
14+check eq get Frame 12384 old 1111
15+ret int get Fails 0
16+end

aienux/allen/tests/presentation-mutants.om

new file mode 100644
@@ -0,0 +1,101 @@
1+note Reuses L748 native mutation builder; selector0 stale-event,1 input-tail.
2+global Mutbuf uchar 262144
3+global Mutrep uchar 128
4+global Mutmode uchar 1
5+text Mutold0 "\nif not appreceive now\nret false\nend\nb = dpresent\n"
6+text Mutnew0 "\nb = appreceive now\nb = dpresent\n"
7+text Mutold1 "\nfor i ulong 8192\nput In i get Din i\nend\n"
8+text Mutnew1 "\nfor i ulong n\nput In i get Din i\nend\n"
9+fn mutmatch at ulong mode uchar to bool
10+if eq mode 48
11+for i ulong len Mutold0
12+if ne get Mutbuf add at i get Mutold0 i
13+ret false
14+end
15+end
16+else
17+for i ulong len Mutold1
18+if ne get Mutbuf add at i get Mutold1 i
19+ret false
20+end
21+end
22+end
23+ret true
24+end
25+fn mutwrite at ulong size ulong to bool
26+p = ulong 0
27+while lt p size
28+n = write 1 Mutbuf add at p sub size p
29+if le n 0
30+ret false
31+end
32+p = add p ulong n
33+end
34+ret true
35+end
36+fn mutout n ulong mode uchar to int
37+old = len Mutold0
38+size = len Mutnew0
39+if eq mode 49
40+old = len Mutold1
41+size = len Mutnew1
42+end
43+if lt n old
44+ret 65
45+end
46+found = ulong 0
47+at = ulong 0
48+for i ulong add sub n old 1
49+if mutmatch i mode
50+found = add found 1
51+at = i
52+end
53+end
54+if ne found 1
55+ret 65
56+end
57+for i ulong size
58+if eq mode 48
59+put Mutrep i get Mutnew0 i
60+else
61+put Mutrep i get Mutnew1 i
62+end
63+end
64+if not mutwrite 0 at
65+ret 74
66+end
67+p = ulong 0
68+while lt p size
69+r = write 1 Mutrep p sub size p
70+if le r 0
71+ret 74
72+end
73+p = add p ulong r
74+end
75+if not mutwrite add at old sub n add at old
76+ret 74
77+end
78+ret 0
79+end
80+fn main to int
81+r = read 0 Mutmode 0 1
82+if ne r 1
83+ret 65
84+end
85+mode = get Mutmode 0
86+if and ne mode 48 ne mode 49
87+ret 65
88+end
89+n = ulong 0
90+while lt n len Mutbuf
91+r = read 0 Mutbuf n sub len Mutbuf n
92+if lt r 0
93+ret 74
94+end
95+if eq r 0
96+ret mutout n mode
97+end
98+n = add n ulong r
99+end
100+ret 65
101+end

aienux/allen/tests/presentation.om

new file mode 100644
@@ -0,0 +1,238 @@
1+text Prompt1 "hello"
2+text Leak "LEAK"
3+text Scene1 "SAY 1 1/1 note left: Heading | Body"
4+text Hidden1 "<think>private</think>"
5+text Badscene "number: nope"
6+text Prompt2 "write a calculator"
7+text Code2 "CODE 2 1/1 2 d8932aac text hi"
8+text Done2 "SAY 2 1/1 Done."
9+global Saved uchar 8192
10+global Keep ulong 2
11+global Before uchar 8192
12+global Wire uchar 8192
13+fn test ok bool to void
14+put Keep 0 get Outlen 0
15+put Keep 1 get Err 0
16+for i ulong get Outlen 0
17+put Saved i get Outb i
18+end
19+check ok add get Checks 0 1
20+for i ulong get Keep 0
21+put Outb i get Saved i
22+end
23+put Outlen 0 get Keep 0
24+put Err 0 get Keep 1
25+end
26+fn inbound part ulong to void
27+n = get Outlen 0
28+e = get Err 0
29+for i ulong n
30+put Before i get Outb i
31+end
32+b = packet 2 get Q 1 part 0 0
33+size = get Outlen 0
34+for i ulong size
35+put In i get Outb i
36+end
37+put Inlen 0 size
38+for i ulong n
39+put Outb i get Before i
40+end
41+put Outlen 0 n
42+put Err 0 e
43+end
44+fn main to int
45+test not dpresent
46+test appinit 77 0
47+put Inlen 0 len Prompt1
48+for i ulong len Prompt1
49+put In i get Prompt1 i
50+end
51+test dask 1
52+test eq get R 0 1
53+test eq get Dm 0 0
54+test apppoll 1 true
55+n = get Outlen 0
56+for i ulong n
57+put Wire i get Outb i
58+end
59+for i ulong len Scene1
60+put In i get Scene1 i
61+end
62+put Inlen 0 len Scene1
63+inbound 1
64+size = get Inlen 0
65+for i ulong size
66+put Before i get In i
67+end
68+test drecv 2
69+test eq get A 2 1
70+test eq get Dm 0 1
71+test eq get Dm 2 1
72+test eq get Ds 3 1
73+test eq get Dt 0 1
74+test eq get Dt 1 1
75+test eq get Dtext get Dt 7 72
76+test eq get Dtext get Dt 8 66
77+test eq get Outlen 0 n
78+same = true
79+for i ulong n
80+if ne get Outb i get Wire i
81+same = false
82+end
83+end
84+test same
85+test eq get T 10 5
86+note appreceive replaces In with its payload; only dpresent must preserve that.
87+size = get Inlen 0
88+for i ulong size
89+put Before i get In i
90+end
91+test dpresent
92+test eq get Inlen 0 size
93+same = true
94+for i ulong size
95+if ne get Before i get In i
96+same = false
97+end
98+end
99+test same
100+note Even bytes outside current Inlen survive decoder scratch expansion.
101+for i ulong 8192
102+put In i 165
103+put Before i 165
104+end
105+put Inlen 0 1
106+test dpresent
107+test eq get Inlen 0 1
108+same = true
109+for i ulong 8192
110+if ne get In i get Before i
111+same = false
112+end
113+end
114+test same
115+put Inlen 0 8193
116+test not dpresent
117+put Inlen 0 1
118+note Hidden or invalid scene text cannot erase the last admitted presentation.
119+for i ulong len Hidden1
120+put Answer i get Hidden1 i
121+end
122+put R 8 len Hidden1
123+test not dpresent
124+test eq get Ds 3 1
125+test eq get Dtext get Dt 7 72
126+for i ulong len Badscene
127+put Answer i get Badscene i
128+end
129+put R 8 len Badscene
130+test not dpresent
131+test eq get Ds 3 1
132+put A 2 0
133+test not dpresent
134+put A 2 1
135+put R 8 160
136+test not dpresent
137+put R 8 0
138+test not dpresent
139+note Refused receive cannot publish a stale event1.
140+for i ulong len Leak
141+put Answer i get Leak i
142+end
143+put R 8 len Leak
144+put Inlen 0 1
145+put In 0 88
146+test not drecv 2
147+test eq get Ds 3 1
148+test appsent 2 true
149+test apppoll 2 true
150+test appsent 2 true
151+put Inlen 0 len Prompt2
152+for i ulong len Prompt2
153+put In i get Prompt2 i
154+end
155+test dask 3
156+test eq get R 0 2
157+test eq get Ds 2 1
158+test eq get Dtext get Dsay 0 73
159+for i ulong len Code2
160+put In i get Code2 i
161+end
162+put Inlen 0 len Code2
163+inbound 1
164+test drecv 4
165+test eq get Dm 1 0
166+test apppoll 4 true
167+test appsent 4 true
168+for i ulong len Done2
169+put In i get Done2 i
170+end
171+put Inlen 0 len Done2
172+inbound 2
173+test drecv 5
174+test eq get Dm 1 1
175+test eq get Dm 2 2
176+test eq get Dview 0 1
177+test eq get Dview 1 0
178+test eq get Dview 2 2
179+test eq get Dstart 0 0
180+test eq get Dlen 0 2
181+test eq get Dline 0 1
182+test eq get Dcode 0 104
183+test eq get Dcode 1 105
184+test eq get Dtext get Dsay 0 68
185+note Code completion does not require a nonempty closing sentence.
186+put R 8 0
187+test dpresent
188+test eq get Dm 1 1
189+test eq get Dcode 0 104
190+put Code 0 88
191+test not dpresent
192+test eq get Dcode 0 104
193+test eq get Dlen 0 2
194+put Code 0 104
195+note Later assembly may reuse Code; the displayed snapshot cannot alias it.
196+codebeg 3
197+put Code 0 88
198+test eq get Dcode 0 104
199+put A 2 0
200+test not dpresent
201+test eq get Dm 1 1
202+put Dtext 2303 88
203+put Dcode 32767 88
204+put Dstart 4095 88
205+put Dlen 4095 88
206+put Dline 4095 88
207+dreset
208+test eq get Dm 0 0
209+test eq get Dm 1 0
210+test eq get Dview 0 0
211+test eq get R 0 2
212+test eq get Q 1 2
213+same = true
214+for i ulong 2304
215+if ne get Dtext i 0
216+same = false
217+end
218+end
219+test same
220+same = true
221+for i ulong 32768
222+if ne get Dcode i 0
223+same = false
224+end
225+end
226+test same
227+same = true
228+for i ulong 4096
229+if ne or or get Dstart i get Dlen i get Dline i 0
230+same = false
231+end
232+end
233+test same
234+if ne get Fails 0 0
235+ret 1
236+end
237+ret 0
238+end

aienux/allen/tests/probe.om

new file mode 100644
@@ -0,0 +1,8 @@
1+text ready "Allen Omega native probe\n"
2+fn main to int
3+n = write 1 ready 0 len ready
4+if ne n long len ready
5+ret 1
6+end
7+ret 0
8+end

aienux/allen/tests/provider-core.om

new file mode 100644
@@ -0,0 +1,306 @@
1+text Fmagic "ALNPRV01"
2+text Hi "hi"
3+text Leak "LEAK"
4+text Reply "SAY 1 1/1 hello"
5+text Askcode "write a calculator"
6+text Tinycode "CODE 2 1/1 2 d8932aac text hi"
7+text Done "SAY 2 1/1 Done."
8+global Held uchar 8192
9+global Holdn ulong 2
10+global Before uchar 8192
11+fn test ok bool to void
12+note Direct write logger would clobber the very datagram being tested.
13+put Holdn 0 get Outlen 0
14+put Holdn 1 get Err 0
15+for i ulong get Outlen 0
16+put Held i get Outb i
17+end
18+check ok add get Checks 0 1
19+for i ulong get Holdn 0
20+put Outb i get Held i
21+end
22+put Outlen 0 get Holdn 0
23+put Err 0 get Holdn 1
24+end
25+fn hword off ulong v ulong to void
26+for i ulong 8
27+put Ph add off i uchar and shr v mul i 8 255
28+end
29+end
30+fn frame op ulong now ulong arg ulong size ulong to void
31+for i ulong 8
32+put Ph i get Fmagic i
33+end
34+hword 8 op
35+hword 16 now
36+hword 24 arg
37+hword 32 size
38+end
39+fn oword off ulong to ulong
40+v = ulong 0
41+for i ulong 8
42+v = or v shl ulong get Pout add off i mul i 8
43+end
44+ret v
45+end
46+fn receive part ulong size ulong to void
47+note Caller placed LINE payload in In; packet overwrites Outb, so preserve it.
48+n = get Outlen 0
49+e = get Err 0
50+for i ulong n
51+put Held i get Outb i
52+end
53+put Inlen 0 size
54+b = packet 2 get Q 1 part 0 0
55+size = get Outlen 0
56+for i ulong size
57+put Pb i get Outb i
58+end
59+for i ulong n
60+put Outb i get Held i
61+end
62+put Outlen 0 n
63+put Err 0 e
64+frame 5 4294967297 0 size
65+end
66+fn main to int
67+frame 1 4294967296 77 0
68+test prparse
69+test eq get Pv 0 1
70+test eq get Pv 1 4294967296
71+test eq get Pv 2 77
72+put Ph 0 88
73+test not prparse
74+frame 11 0 0 0
75+test not prparse
76+frame 1 0 77 1
77+test not prparse
78+frame 3 0 2 0
79+test not prparse
80+frame 2 0 0 160
81+test not prparse
82+frame 10 0 0 0
83+test prdo
84+test eq oword 16 1
85+test eq get Pc 0 1
86+mset32 0 3
87+mset32 36 1
88+test memenc 10
89+for i ulong 4096
90+put Pb i get Enc i
91+end
92+frame 8 0 1 4096
93+test prdo
94+test eq oword 16 1
95+test eq get St 0 10
96+test prdo
97+test eq oword 16 0
98+frame 1 4294967296 77 0
99+test prdo
100+test eq oword 16 0
101+for i ulong 4096
102+put Pb i 0
103+end
104+frame 8 0 0 4096
105+test prdo
106+test eq oword 16 2
107+test eq get Pc 0 2
108+test eq get St 0 10
109+frame 1 4294967296 77 0
110+test prdo
111+test eq oword 16 0
112+put Ns 0 2
113+put Ns 1 0
114+put Ns 2 3
115+put Ns 3 0
116+put Note 0 78
117+put Note 1 48
118+test noteenc
119+for i ulong 4096
120+put Pb i get Enc i
121+end
122+frame 9 0 1 4096
123+test prdo
124+test eq oword 16 0
125+frame 9 0 0 4096
126+test prdo
127+test eq oword 16 1
128+test eq get Pc 0 3
129+frame 1 4294967296 77 0
130+test prdo
131+test eq oword 16 1
132+test eq get A 0 1
133+test eq get Dm 0 0
134+test eq get Dm 1 0
135+test prdo
136+test eq oword 16 0
137+frame 10 0 0 0
138+test prdo
139+test eq oword 16 0
140+test eq mem32 0 3
141+frame 2 4294967297 0 len Hi
142+for i ulong len Hi
143+put Pb i get Hi i
144+end
145+test prdo
146+test eq oword 16 1
147+test eq get R 0 1
148+test eq get Dm 0 0
149+frame 3 4294967297 1 0
150+test prdo
151+test eq oword 16 3
152+test eq oword 32 get Outlen 0
153+test eq get T 10 5
154+same = true
155+for i ulong get Outlen 0
156+if ne get Pout add i 40 get Outb i
157+same = false
158+end
159+end
160+test same
161+test prdo
162+test eq oword 16 1
163+test eq get T 10 5
164+frame 4 4294967297 0 0
165+test prdo
166+test eq get T 3 0
167+frame 3 4294967297 1 0
168+test prdo
169+test eq oword 16 3
170+frame 4 4294967297 1 0
171+test prdo
172+test eq get T 3 1
173+frame 3 4294967297 1 0
174+test prdo
175+test eq get T 10 1
176+for i ulong len Reply
177+put In i get Reply i
178+end
179+receive 1 len Reply
180+n = get Outlen 0
181+e = get Err 0
182+for i ulong n
183+put Before i get Outb i
184+end
185+test prdo
186+test eq get Outlen 0 n
187+test eq get Err 0 e
188+same = true
189+for i ulong n
190+if ne get Outb i get Before i
191+same = false
192+end
193+end
194+test same
195+test eq oword 16 1
196+test eq oword 24 1
197+test eq oword 32 5
198+test eq get Pout 40 104
199+test eq get Dm 0 1
200+test eq get Dm 2 1
201+test eq get Ds 2 1
202+test eq get Dtext get Dsay 0 104
203+test eq get R 1 0
204+test eq get T 10 1
205+test eq get Outb 0 65
206+note A stale visible event must not be projected by a rejected provider frame.
207+for i ulong len Leak
208+put Answer i get Leak i
209+end
210+put R 8 len Leak
211+frame 5 4294967297 0 65
212+put Ph 0 88
213+test not prdo
214+test eq get Dtext get Dsay 0 104
215+frame 5 4294967297 0 65
216+for i ulong 65
217+put Pb i 0
218+end
219+test prdo
220+test eq oword 16 0
221+test eq get Dtext get Dsay 0 104
222+test eq get Dm 2 1
223+frame 4 4294967297 1 0
224+test prdo
225+frame 3 4294967297 1 0
226+test prdo
227+test eq oword 16 3
228+test eq get T 10 3
229+frame 4 4294967297 1 0
230+test prdo
231+frame 3 4294967297 1 0
232+test prdo
233+test eq oword 16 1
234+test eq oword 32 0
235+frame 2 4294967297 0 len Askcode
236+for i ulong len Askcode
237+put Pb i get Askcode i
238+end
239+test prdo
240+test eq oword 24 1
241+test eq oword 32 len Ack
242+test eq get Dm 0 1
243+test eq get Dm 2 2
244+test eq get Dtext get Dsay 0 73
245+for i ulong len Tinycode
246+put In i get Tinycode i
247+end
248+receive 1 len Tinycode
249+test prdo
250+test eq oword 24 0
251+test eq get Dm 1 0
252+frame 3 4294967297 1 0
253+test prdo
254+frame 4 4294967297 1 0
255+test prdo
256+for i ulong len Done
257+put In i get Done i
258+end
259+receive 2 len Done
260+test prdo
261+test eq oword 24 1
262+test eq oword 32 5
263+off = ulong 45
264+test eq oword add off 8 11
265+test eq oword add off 32 2
266+test eq get Pout add off 40 104
267+test eq get Pout add off 41 105
268+test eq get Pn 0 add off 42
269+test eq get Dm 1 1
270+test eq get Dm 2 2
271+test eq get Dview 0 1
272+test eq get Dview 2 2
273+test eq get Dlen 0 2
274+test eq get Dcode 0 104
275+test eq get Dcode 1 105
276+test eq get Dtext get Dsay 0 68
277+note Snapshot stays independent of later assembly and refused clock.
278+put Code 0 88
279+test eq get Dcode 0 104
280+frame 3 4294967296 1 0
281+test prdo
282+test eq oword 16 0
283+test eq oword 24 0
284+test eq get Dcode 0 104
285+test eq get Dtext get Dsay 0 68
286+put Dtext 2303 88
287+put Dcode 32767 88
288+put Dlen 4095 88
289+frame 7 0 0 0
290+test prdo
291+test eq get Dm 0 0
292+test eq get Dm 1 0
293+test eq get Dm 2 0
294+test eq get Dview 0 0
295+test eq get Dview 2 0
296+test eq get Dtext 2303 0
297+test eq get Dcode 32767 0
298+test eq get Dlen 4095 0
299+test eq get R 9 0
300+test eq get R 0 2
301+test eq get Q 1 2
302+if ne get Fails 0 0
303+ret 1
304+end
305+ret 0
306+end

aienux/allen/tests/provider-display-mutants.om

new file mode 100644
@@ -0,0 +1,119 @@
1+note Native exact-line mutant construction; selector0 raw-ASK,1 raw-RECV,2 raw-RESET.
2+global Mutbuf uchar 262144
3+global Mutrep uchar 128
4+global Mutmode uchar 1
5+text Mutold0 "\nif not dask now\n"
6+text Mutnew0 "\nif not appask now\n"
7+text Mutold1 "\nif not drecv now\n"
8+text Mutnew1 "\nif not appreceive now\n"
9+text Mutold2 "\ndreset\nret 1\n"
10+text Mutnew2 "\nappreset\nret 1\n"
11+fn mutmatch at ulong mode uchar to bool
12+if eq mode 48
13+for i ulong len Mutold0
14+if ne get Mutbuf add at i get Mutold0 i
15+ret false
16+end
17+end
18+else
19+if eq mode 49
20+for i ulong len Mutold1
21+if ne get Mutbuf add at i get Mutold1 i
22+ret false
23+end
24+end
25+else
26+for i ulong len Mutold2
27+if ne get Mutbuf add at i get Mutold2 i
28+ret false
29+end
30+end
31+end
32+end
33+ret true
34+end
35+fn mutwrite at ulong size ulong to bool
36+p = ulong 0
37+while lt p size
38+n = write 1 Mutbuf add at p sub size p
39+if le n 0
40+ret false
41+end
42+p = add p ulong n
43+end
44+ret true
45+end
46+fn mutout n ulong mode uchar to int
47+old = len Mutold0
48+size = len Mutnew0
49+if eq mode 49
50+old = len Mutold1
51+size = len Mutnew1
52+end
53+if eq mode 50
54+old = len Mutold2
55+size = len Mutnew2
56+end
57+if lt n old
58+ret 65
59+end
60+found = ulong 0
61+at = ulong 0
62+for i ulong add sub n old 1
63+if mutmatch i mode
64+found = add found 1
65+at = i
66+end
67+end
68+if ne found 1
69+ret 65
70+end
71+for i ulong size
72+if eq mode 48
73+put Mutrep i get Mutnew0 i
74+else
75+if eq mode 49
76+put Mutrep i get Mutnew1 i
77+else
78+put Mutrep i get Mutnew2 i
79+end
80+end
81+end
82+if not mutwrite 0 at
83+ret 74
84+end
85+p = ulong 0
86+while lt p size
87+r = write 1 Mutrep p sub size p
88+if le r 0
89+ret 74
90+end
91+p = add p ulong r
92+end
93+if not mutwrite add at old sub n add at old
94+ret 74
95+end
96+ret 0
97+end
98+fn main to int
99+r = read 0 Mutmode 0 1
100+if ne r 1
101+ret 65
102+end
103+mode = get Mutmode 0
104+if or lt mode 48 gt mode 50
105+ret 65
106+end
107+n = ulong 0
108+while lt n len Mutbuf
109+r = read 0 Mutbuf n sub len Mutbuf n
110+if lt r 0
111+ret 74
112+end
113+if eq r 0
114+ret mutout n mode
115+end
116+n = add n ulong r
117+end
118+ret 65
119+end

aienux/allen/tests/provider-input.om

new file mode 100644
@@ -0,0 +1,144 @@
1+note Generates real framed stdin. Mode byte0 normal,1..5 malformed,6 fail-fast.
2+text Iomagic "ALNPRV01"
3+text Wireline "ALLEN-COURIER v=1 run=000000000000004d kind=LINE seq=1 part=1/0 bytes=0\nSAY 1 1/1 hello"
4+global Ih uchar 40
5+global Choice uchar 1
6+fn iword off ulong v ulong to void
7+for i ulong 8
8+put Ih add off i uchar and shr v mul i 8 255
9+end
10+end
11+fn ihead op ulong now ulong arg ulong size ulong to void
12+for i ulong 8
13+put Ih i get Iomagic i
14+end
15+iword 8 op
16+iword 16 now
17+iword 24 arg
18+iword 32 size
19+end
20+fn ihwrite count ulong to bool
21+p = ulong 0
22+while lt p count
23+size = sub count p
24+if eq get Choice 0 55
25+size = 1
26+end
27+n = write 1 Ih p size
28+if le n 0
29+ret false
30+end
31+p = add p ulong n
32+end
33+ret true
34+end
35+fn ibwrite count ulong to bool
36+p = ulong 0
37+while lt p count
38+size = sub count p
39+if eq get Choice 0 55
40+size = 1
41+end
42+n = write 1 Pb p size
43+if le n 0
44+ret false
45+end
46+p = add p ulong n
47+end
48+ret true
49+end
50+fn iframe op ulong now ulong arg ulong size ulong to bool
51+ihead op now arg size
52+if not ihwrite 40
53+ret false
54+end
55+ret ibwrite size
56+end
57+fn main to int
58+n = read 0 Choice 0 1
59+if ne n 1
60+ret 65
61+end
62+mode = get Choice 0
63+if eq mode 56
64+ihead 1 1 0 0
65+b = ihwrite 40
66+ret 0
67+end
68+if eq mode 49
69+ihead 1 0 77 0
70+put Ih 0 88
71+b = ihwrite 40
72+ret 0
73+end
74+if eq mode 50
75+ihead 2 0 0 160
76+b = ihwrite 40
77+ret 0
78+end
79+if eq mode 51
80+ihead 1 0 77 0
81+b = ihwrite 39
82+ret 0
83+end
84+if eq mode 52
85+ihead 2 0 0 2
86+b = ihwrite 40
87+put Pb 0 104
88+b = ibwrite 1
89+ret 0
90+end
91+if eq mode 53
92+ihead 11 0 0 0
93+b = ihwrite 40
94+ret 0
95+end
96+if not iframe 1 0 77 0
97+ret 74
98+end
99+if eq mode 54
100+ihead 2 1 0 160
101+b = ihwrite 40
102+for i ulong 160
103+put Pb i 120
104+end
105+b = ibwrite 160
106+put Pb 0 104
107+put Pb 1 105
108+b = iframe 2 1 0 2
109+ret 0
110+end
111+put Pb 0 104
112+put Pb 1 105
113+if not iframe 2 1 0 2
114+ret 74
115+end
116+if not iframe 3 1 1 0
117+ret 74
118+end
119+if not iframe 4 1 1 0
120+ret 74
121+end
122+if not iframe 3 1 1 0
123+ret 74
124+end
125+if not iframe 4 1 1 0
126+ret 74
127+end
128+for i ulong len Wireline
129+put Pb i get Wireline i
130+end
131+if not iframe 5 2 0 len Wireline
132+ret 74
133+end
134+if not iframe 3 2 1 0
135+ret 74
136+end
137+if not iframe 4 2 1 0
138+ret 74
139+end
140+if not iframe 3 2 1 0
141+ret 74
142+end
143+ret 0
144+end

aienux/allen/tests/provider-mutants.om

new file mode 100644
@@ -0,0 +1,101 @@
1+note Native exact-line mutant construction; selector0 auto-SENT,1 skip-shape.
2+global Mutbuf uchar 262144
3+global Mutrep uchar 128
4+global Mutmode uchar 1
5+text Mutold0 "\nprreply status\n"
6+text Mutnew0 "\nb = qsent get Pv 1 true\nprreply status\n"
7+text Mutold1 "\nret prshape\n"
8+text Mutnew1 "\nret true\n"
9+fn mutmatch at ulong mode uchar to bool
10+if eq mode 48
11+for i ulong len Mutold0
12+if ne get Mutbuf add at i get Mutold0 i
13+ret false
14+end
15+end
16+else
17+for i ulong len Mutold1
18+if ne get Mutbuf add at i get Mutold1 i
19+ret false
20+end
21+end
22+end
23+ret true
24+end
25+fn mutwrite at ulong size ulong to bool
26+p = ulong 0
27+while lt p size
28+n = write 1 Mutbuf add at p sub size p
29+if le n 0
30+ret false
31+end
32+p = add p ulong n
33+end
34+ret true
35+end
36+fn mutout n ulong mode uchar to int
37+old = len Mutold0
38+size = len Mutnew0
39+if eq mode 49
40+old = len Mutold1
41+size = len Mutnew1
42+end
43+if lt n old
44+ret 65
45+end
46+found = ulong 0
47+at = ulong 0
48+for i ulong add sub n old 1
49+if mutmatch i mode
50+found = add found 1
51+at = i
52+end
53+end
54+if ne found 1
55+ret 65
56+end
57+for i ulong size
58+if eq mode 48
59+put Mutrep i get Mutnew0 i
60+else
61+put Mutrep i get Mutnew1 i
62+end
63+end
64+if not mutwrite 0 at
65+ret 74
66+end
67+p = ulong 0
68+while lt p size
69+r = write 1 Mutrep p sub size p
70+if le r 0
71+ret 74
72+end
73+p = add p ulong r
74+end
75+if not mutwrite add at old sub n add at old
76+ret 74
77+end
78+ret 0
79+end
80+fn main to int
81+r = read 0 Mutmode 0 1
82+if ne r 1
83+ret 65
84+end
85+mode = get Mutmode 0
86+if and ne mode 48 ne mode 49
87+ret 65
88+end
89+n = ulong 0
90+while lt n len Mutbuf
91+r = read 0 Mutbuf n sub len Mutbuf n
92+if lt r 0
93+ret 74
94+end
95+if eq r 0
96+ret mutout n mode
97+end
98+n = add n ulong r
99+end
100+ret 65
101+end

aienux/allen/tests/provider-output.om

new file mode 100644
@@ -0,0 +1,104 @@
1+note Independent stream-output assertions, not a captured/blessed output fixture.
2+global Vbuf uchar 65536
3+text Vmagic "ALNPRV01"
4+text Ops "1234345343"
5+text Hello "ALLEN-COURIER v=1 run=000000000000004d kind=HELLO seq=0 part=0/0 bytes=0\n"
6+text Got "ALLEN-COURIER v=1 run=000000000000004d kind=GOT seq=1 part=1/0 bytes=0\n"
7+text Jobtail "hi\tself=Allen\tstarts=0"
8+text Wordsout "hello"
9+fn test ok bool to void
10+check ok add get Checks 0 1
11+end
12+fn vword off ulong to ulong
13+v = ulong 0
14+for i ulong 8
15+v = or v shl ulong get Vbuf add off i mul i 8
16+end
17+ret v
18+end
19+fn vbyte at ulong expected uchar to void
20+test eq get Vbuf at expected
21+end
22+fn verify n ulong to int
23+p = ulong 0
24+count = ulong 0
25+while lt p n
26+if or lt sub n p 40 ge count 10
27+ret 65
28+end
29+for i ulong 8
30+vbyte add p i get Vmagic i
31+end
32+op = vword add p 8
33+status = vword add p 16
34+event = vword add p 24
35+size = vword add p 32
36+p = add p 40
37+if gt size sub n p
38+ret 65
39+end
40+test eq op sub ulong get Ops count 48
41+wanted = ulong 1
42+if or eq count 2 eq count 4
43+wanted = 3
44+end
45+if eq count 7
46+wanted = 3
47+end
48+test eq status wanted
49+if eq count 6
50+test eq event 1
51+test eq size len Wordsout
52+for i ulong len Wordsout
53+vbyte add p i get Wordsout i
54+end
55+else
56+test eq event 0
57+end
58+if eq count 2
59+test eq size len Hello
60+for i ulong len Hello
61+vbyte add p i get Hello i
62+end
63+end
64+if eq count 7
65+test eq size len Got
66+for i ulong len Got
67+vbyte add p i get Got i
68+end
69+end
70+if eq count 4
71+test ge size len Jobtail
72+if ge size len Jobtail
73+at = add p sub size len Jobtail
74+for i ulong len Jobtail
75+vbyte add at i get Jobtail i
76+end
77+end
78+end
79+if and ne wanted 3 ne count 6
80+test eq size 0
81+end
82+p = add p size
83+count = add count 1
84+end
85+test eq count 10
86+if ne get Fails 0 0
87+ret 1
88+end
89+ret 0
90+end
91+fn main to int
92+n = ulong 0
93+while lt n len Vbuf
94+r = read 0 Vbuf n sub len Vbuf n
95+if lt r 0
96+ret 74
97+end
98+if eq r 0
99+ret verify n
100+end
101+n = add n ulong r
102+end
103+ret 65
104+end

aienux/allen/tests/provider-process.om

new file mode 100644
@@ -0,0 +1,100 @@
1+note Native assertions over host-collected process receipts.
2+note Four decimal lines: mode, exit, stdout bytes, stderr bytes; then stdout+stderr.
3+global Procbuf uchar 65536
4+global Procnum ulong 4
5+global Procpos ulong 1
6+text Procmag "ALNPRV01"
7+fn pcheck ok bool to void
8+check ok add get Checks 0 1
9+end
10+fn pnumber n ulong to bool
11+v = ulong 0
12+digits = ulong 0
13+while lt get Procpos 0 n
14+c = get Procbuf get Procpos 0
15+put Procpos 0 add get Procpos 0 1
16+if eq c 10
17+if eq digits 0
18+ret false
19+end
20+put Procnum 3 v
21+ret true
22+end
23+if or lt c 48 gt c 57
24+ret false
25+end
26+if ge digits 8
27+ret false
28+end
29+v = add mul v 10 sub ulong c 48
30+digits = add digits 1
31+end
32+ret false
33+end
34+fn pword off ulong to ulong
35+v = ulong 0
36+for i ulong 8
37+v = or v shl ulong get Procbuf add off i mul i 8
38+end
39+ret v
40+end
41+fn pverify n ulong to int
42+for i ulong 3
43+if not pnumber n
44+ret 65
45+end
46+put Procnum i get Procnum 3
47+end
48+if not pnumber n
49+ret 65
50+end
51+mode = get Procnum 0
52+rc = get Procnum 1
53+size = get Procnum 2
54+err = get Procnum 3
55+p = get Procpos 0
56+pcheck eq n add add p size err
57+pcheck eq err 0
58+if le mode 6
59+pcheck ge mode 1
60+pcheck eq rc 65
61+if eq mode 6
62+pcheck eq size 40
63+if ge sub n p 40
64+for i ulong 8
65+pcheck eq get Procbuf add p i get Procmag i
66+end
67+pcheck eq pword add p 8 1
68+pcheck eq pword add p 16 1
69+pcheck eq pword add p 24 0
70+pcheck eq pword add p 32 0
71+end
72+else
73+pcheck eq size 0
74+end
75+else
76+if eq mode 7
77+pcheck eq rc 0
78+else
79+ret 65
80+end
81+end
82+if ne get Fails 0 0
83+ret 1
84+end
85+ret 0
86+end
87+fn main to int
88+n = ulong 0
89+while lt n len Procbuf
90+r = read 0 Procbuf n sub len Procbuf n
91+if lt r 0
92+ret 74
93+end
94+if eq r 0
95+ret pverify n
96+end
97+n = add n ulong r
98+end
99+ret 65
100+end

aienux/allen/tests/render.om

new file mode 100644
@@ -0,0 +1,12 @@
1+text Ppm "P6\n192 128\n255\n"
2+fn main to int
3+render
4+w = write 1 Ppm 0 len Ppm
5+if ne w long len Ppm
6+ret 1
7+end
8+if not frameout
9+ret 2
10+end
11+ret 0
12+end

aienux/allen/tests/reply.om

new file mode 100644
@@ -0,0 +1,47 @@
1+text Wait "WAIT 7"
2+text Say1 "SAY 7 1/0 First\\npart"
3+text Say2 "SAY 7 2/2 Model words."
4+text Final "SAY 8 1/1 Code ready."
5+fn main to int
6+put R 0 7
7+put R 1 1
8+put R 2 1
9+put Inlen 0 len Wait
10+for i ulong len Wait
11+put In i get Wait i
12+end
13+check eq saytake 10 1 801
14+check eq get R 4 10 802
15+put Inlen 0 len Say1
16+for i ulong len Say1
17+put In i get Say1 i
18+end
19+check eq saytake 11 1 803
20+check eq get R 8 10 804
21+check eq saytake 12 0 805
22+check eq get R 8 10 806
23+put Inlen 0 len Say2
24+for i ulong len Say2
25+put In i get Say2 i
26+end
27+check eq saytake 13 1 807
28+check eq get R 1 0 808
29+check eq get R 8 23 809
30+check eq saytake 14 0 810
31+put R 0 8
32+put R 1 1
33+put R 2 2
34+codebeg 8
35+put Inlen 0 len Final
36+for i ulong len Final
37+put In i get Final i
38+end
39+v = saytake 15
40+same = eq get Outlen 0 7
41+check eq v 2 811
42+check same 812
43+check eq get R 1 1 813
44+check eq saytake 16 3 814
45+check eq get R 1 0 815
46+ret int get Fails 0
47+end

aienux/allen/tests/runtime.om

new file mode 100644
@@ -0,0 +1,57 @@
1+text Ask "make me a calculator"
2+text Reply "Model supplied answer."
3+fn askload to void
4+put Inlen 0 len Ask
5+for i ulong len Ask
6+put In i get Ask i
7+end
8+end
9+fn main to int
10+askload
11+check start 2 0 1
12+check eq get R 1 1 2
13+check eq get R 2 2 3
14+check eq get R 8 len Ack 4
15+old = get R 0
16+check not start 1 1 5
17+put Inlen 0 len Reply
18+for i ulong len Reply
19+put In i get Reply i
20+end
21+check not answer add old 1 2 6
22+check eq get R 8 len Ack 7
23+check answer old 3 8
24+check eq get R 1 0 9
25+askload
26+check start 1 4 10
27+check gt get R 0 old 11
28+cancel
29+check eq get R 1 0 12
30+check not answer get R 0 5 13
31+askload
32+check start 1 10 14
33+check eq tick 20009 0 15
34+check eq tick 20010 1 16
35+check eq tick 20011 0 17
36+check eq tick 30010 2 18
37+check eq get R 1 0 19
38+old = get R 0
39+reset
40+check eq get R 0 old 20
41+askload
42+check start 2 40000 21
43+check gt get R 0 old 22
44+cancel
45+put Inlen 0 160
46+check not start 1 40001 23
47+check eq get R 1 0 24
48+askload
49+check not start 3 40002 25
50+put R 6 1
51+check start 3 40003 26
52+check eq get R 8 len Ackmore 27
53+cancel
54+put R 0 4294967295
55+check not start 1 40004 28
56+ret int get Fails 0
57+end

aienux/allen/tests/scene-input.om

new file mode 100644
@@ -0,0 +1,213 @@
1+text Fancy "\t- **SaY**:\tKeep My CASE.~\n> NOTE RIGHT WARM: Title | Body TEXT\n"
2+text Private "<THINK>say secret\nnote: secret | hidden\n</THINK>\n```scene\nsay Visible\n```\n"
3+text Inline "say public <think>secret</think>\nsay Safe\n"
4+text Unclosed "<think>never closed\nsay secret\n"
5+text Plain "Hello there.\nAnother sentence.\n"
6+text Mixed "Unrecognized text.\nnote: Heading | Body\n"
7+text Invalid "number: nope\n"
8+text Moodonly "MOOD Dawn Lively\n"
9+text Listmark "1. note left: Heading | Body\n"
10+text Wanted "Keep My CASE."
11+text Vis "Visible"
12+text Hello "Hello there."
13+text Nested "- > - **SaY**: Nested works.\n"
14+text Negative "-3 is negative.\n"
15+global Savedin uchar 2048
16+fn test ok bool to void
17+check ok add get Checks 0 1
18+end
19+fn load which ulong to void
20+if eq which 0
21+put Inlen 0 len Fancy
22+for i ulong len Fancy
23+c = get Fancy i
24+if eq c 126
25+c = uchar 13
26+end
27+put In i c
28+end
29+end
30+if eq which 1
31+put Inlen 0 len Private
32+for i ulong len Private
33+put In i get Private i
34+end
35+end
36+if eq which 2
37+put Inlen 0 len Inline
38+for i ulong len Inline
39+put In i get Inline i
40+end
41+end
42+if eq which 3
43+put Inlen 0 len Unclosed
44+for i ulong len Unclosed
45+put In i get Unclosed i
46+end
47+end
48+if eq which 4
49+put Inlen 0 len Plain
50+for i ulong len Plain
51+put In i get Plain i
52+end
53+end
54+if eq which 5
55+put Inlen 0 len Mixed
56+for i ulong len Mixed
57+put In i get Mixed i
58+end
59+end
60+if eq which 6
61+put Inlen 0 len Invalid
62+for i ulong len Invalid
63+put In i get Invalid i
64+end
65+end
66+if eq which 7
67+put Inlen 0 len Moodonly
68+for i ulong len Moodonly
69+put In i get Moodonly i
70+end
71+end
72+if eq which 8
73+put Inlen 0 len Listmark
74+for i ulong len Listmark
75+put In i get Listmark i
76+end
77+end
78+end
79+fn main to int
80+load 0
81+n = get Inlen 0
82+for i ulong n
83+put Savedin i get In i
84+end
85+test scdecode
86+test eq get Sc 2 1
87+test eq get Sc 3 1
88+test eq get Things 0 1
89+test eq get Things 1 2
90+test eq get Things 4 1
91+test gt get Nm 2 0
92+test eq get Inlen 0 n
93+same = true
94+for i ulong n
95+if ne get In i get Savedin i
96+same = false
97+end
98+end
99+test same
100+same = true
101+for i ulong len Wanted
102+if ne get Stext add get Sw 3 i get Wanted i
103+same = false
104+end
105+end
106+test same
107+test eq get Stext add get Sw 3 len Wanted 0
108+load 1
109+test scdecode
110+test eq get Sc 2 1
111+test eq get Sc 3 0
112+test eq get Nm 3 3
113+same = true
114+for i ulong len Vis
115+if ne get Stext add get Sw 3 i get Vis i
116+same = false
117+end
118+end
119+test same
120+test eq get Stext add get Sw 3 len Vis 0
121+load 2
122+test scdecode
123+test eq get Nm 3 1
124+test eq get Stext get Sw 3 83
125+load 3
126+test not scdecode
127+test eq get Sc 2 0
128+test eq get Sc 3 0
129+test eq get Nm 0 1
130+load 4
131+test scdecode
132+test eq get Sc 2 1
133+test eq get Sc 3 0
134+same = true
135+for i ulong len Hello
136+if ne get Stext add get Sw 3 i get Hello i
137+same = false
138+end
139+end
140+test same
141+load 5
142+test scdecode
143+test eq get Sc 2 0
144+test eq get Sc 3 1
145+load 6
146+test not scdecode
147+test eq get Sc 2 0
148+test eq get Sc 3 0
149+load 7
150+test scdecode
151+test eq get Sc 0 1
152+test eq get Sc 1 2
153+test eq get Sc 2 0
154+load 8
155+test scdecode
156+test eq get Things 1 1
157+put Inlen 0 160
158+for i ulong 160
159+put In i 120
160+end
161+test not scdecode
162+test eq get Sc 2 0
163+put Inlen 0 159
164+test scdecode
165+test eq get Sc 2 1
166+test eq get Stext add get Sw 3 159 0
167+put Inlen 0 2049
168+test not scdecode
169+test eq get Nm 6 1
170+test eq get Sc 2 0
171+test eq get Sc 3 0
172+load 4
173+put In 2 0
174+test not scdecode
175+test eq get Nm 6 1
176+test eq get In 2 0
177+put Inlen 0 0
178+test not scdecode
179+test eq get Sc 2 0
180+put Inlen 0 len Nested
181+for i ulong len Nested
182+put In i get Nested i
183+end
184+test scdecode
185+test eq get Stext get Sw 3 78
186+put Inlen 0 len Negative
187+for i ulong len Negative
188+put In i get Negative i
189+end
190+test scdecode
191+test eq get Stext get Sw 3 45
192+note A thirteenth line cannot enable mood or plain fallback after twelve refusals.
193+for k ulong 12
194+for i ulong len Invalid
195+put In add mul k len Invalid i get Invalid i
196+end
197+end
198+n = mul 12 len Invalid
199+for i ulong len Moodonly
200+put In add n i get Moodonly i
201+end
202+put Inlen 0 add n len Moodonly
203+test not scdecode
204+test eq get Sc 0 0
205+test eq get Sc 7 1
206+for i ulong len Plain
207+put In add n i get Plain i
208+end
209+put Inlen 0 add n len Plain
210+test not scdecode
211+test eq get Sc 2 0
212+ret int get Fails 0
213+end

aienux/allen/tests/scene.om

new file mode 100644
@@ -0,0 +1,23 @@
1+text Scenein "mood dawn lively\nsay Seventeen percent of 240 is 40.8.\nnumber right warm: 40.8 | 17% of 240\nnote left: How | 240 x 0.17 = 40.8\n"
2+fn main to int
3+put Inlen 0 len Scenein
4+for i ulong len Scenein
5+put In i get Scenein i
6+end
7+check scene 1001
8+check eq get Sc 0 1 1002
9+check eq get Sc 1 2 1003
10+check eq get Sc 2 1 1004
11+check eq get Sc 3 2 1005
12+check eq get Sc 6 0 1006
13+check eq get Things 0 3 1007
14+check eq get Things 1 2 1008
15+check eq get Things 4 1 1009
16+check eq get Things 6 2 1010
17+check eq get Things 16 1 1011
18+check eq get Things 17 1 1012
19+put Inlen 0 0
20+check not scene 1013
21+check eq get Sc 3 0 1014
22+ret int get Fails 0
23+end

aienux/allen/tests/scheduler.om

new file mode 100644
@@ -0,0 +1,258 @@
1+note Native courier lifecycle regression. Clock values are injected milliseconds.
2+text Lineone "SAY 1 1/1 Model text."
3+note check writes through Outb; preserve the actual pending datagram around logging.
4+global SavedOut uchar 8192
5+fn test ok bool to void
6+n = get Outlen 0
7+e = get Err 0
8+for i ulong n
9+put SavedOut i get Outb i
10+end
11+check ok add get Checks 0 1
12+for i ulong n
13+put Outb i get SavedOut i
14+end
15+put Outlen 0 n
16+put Err 0 e
17+end
18+fn tcopy to void
19+put Inlen 0 get Outlen 0
20+for i ulong get Outlen 0
21+put In i get Outb i
22+end
23+end
24+fn control kind ulong seq ulong to void
25+put Inlen 0 0
26+b = packet kind seq 0 0 0
27+tcopy
28+end
29+fn linepkt part ulong to void
30+put Inlen 0 len Lineone
31+for i ulong len Lineone
32+put In i get Lineone i
33+end
34+b = packet 2 get Q 1 part 0 0
35+tcopy
36+end
37+fn jobinput to void
38+put Inlen 0 1001
39+for i ulong 1001
40+put In i 120
41+end
42+put In 999 10
43+put In 1000 121
44+end
45+fn main to int
46+test qstart 42 100
47+test not qready 100
48+test not qnext 100 false
49+test eq get T 3 0
50+test qnext 100 true
51+test eq get T 10 5
52+test not qnext 100 true
53+test qsent 100 false
54+test eq get T 3 0
55+test qnext 101 true
56+test qsent 101 true
57+test eq get T 3 1
58+test not qnext 2100 true
59+test qnext 2101 true
60+test qsent 2101 true
61+control 6 0
62+test eq qincoming 2102 1
63+test qready 2102
64+test not qnext 12100 true
65+test qnext 12101 true
66+test eq get T 10 5
67+test qsent 12101 true
68+test qready 32101
69+test not qready 32102
70+test qnext 32102 true
71+test qsent 32102 true
72+test not qnext 32101 true
73+test eq get T 0 32102
74+jobinput
75+test qsubmit 32103
76+test eq get Q 1 1
77+test eq get JobOut 999 32
78+test eq get JobOut 1000 121
79+test not qsubmit 32103
80+test qnext 32103 true
81+test eq get T 10 1
82+test eq get T 11 1
83+tcopy
84+test pkparse
85+test eq get N 6 1000
86+test eq get In add get N 5 999 32
87+test qsent 32103 false
88+test eq get T 9 1
89+test qnext 32104 true
90+test eq get T 11 1
91+test qsent 32104 true
92+test qnext 32104 true
93+test eq get T 11 2
94+tcopy
95+test pkparse
96+test eq get N 6 1
97+test eq get In get N 5 121
98+test qsent 32104 true
99+test eq get T 9 0
100+control 6 0
101+test eq qincoming 32105 1
102+test qready 32105
103+test not qnext 34103 true
104+test qnext 34104 true
105+test eq get T 10 1
106+test eq get T 11 1
107+test qsent 34104 true
108+test qnext 34104 true
109+test eq get T 11 2
110+test qsent 34104 true
111+control 4 2
112+test eq qincoming 34105 0
113+test eq get T 6 0
114+control 4 1
115+test eq qincoming 34105 1
116+test eq get T 6 1
117+test not qnext 36104 true
118+linepkt 1
119+test eq qincoming 36105 1
120+test eq get Q 4 1
121+test eq get T 13 1
122+test qnext 36105 true
123+test eq get T 10 3
124+test qsent 36105 false
125+test eq get T 13 1
126+linepkt 1
127+test eq qincoming 36106 2
128+test eq get Q 4 1
129+test qnext 36106 true
130+test eq get T 10 3
131+test qsent 36106 true
132+test eq get T 13 0
133+test qtake
134+test eq get Inlen 0 len Lineone
135+test not qtake
136+linepkt 2
137+test eq qincoming 36107 1
138+linepkt 3
139+test eq qincoming 36107 0
140+test eq get Q 2 2
141+test eq get Q 4 1
142+test qnext 36108 true
143+test qsent 36108 true
144+linepkt 3
145+test eq qincoming 36109 1
146+test eq get Q 2 3
147+qcancel
148+test eq get T 5 0
149+linepkt 4
150+test eq qincoming 36110 0
151+jobinput
152+test qsubmit 36111
153+test eq get Q 1 2
154+test eq get Q 4 0
155+control 6 0
156+test eq qincoming 36112 1
157+control 6 0
158+put In 22 49
159+test eq qincoming 36113 0
160+test eq get T 2 36112
161+control 4 2
162+test eq qincoming 36110 0
163+test eq get T 6 0
164+qcancel
165+put Q 1 4294967295
166+jobinput
167+test not qsubmit 36114
168+test eq get Q 1 4294967295
169+test not qstart 0 36114
170+test eq get Q 0 42
171+test qstart 43 0
172+put Inlen 0 4097
173+test not qsubmit 0
174+test eq get Q 1 0
175+put Inlen 0 0
176+test not qsubmit 0
177+test not qsent 0 true
178+note Maximum payload crosses all five datagrams, preserving every byte except CR/LF.
179+put Inlen 0 4096
180+for i ulong 4096
181+put In i uchar rem i 251
182+end
183+test qsubmit 0
184+test qnext 0 true
185+test eq get T 10 5
186+test qsent 0 true
187+for k ulong 5
188+test qnext 0 true
189+test eq get T 10 1
190+tcopy
191+test pkparse
192+test eq get N 1 1
193+test eq get N 2 add k 1
194+test eq get N 3 5
195+test eq get N 4 4096
196+size = ulong 1000
197+if eq k 4
198+size = ulong 96
199+end
200+test eq get N 6 size
201+bad = ulong 0
202+for j ulong size
203+want = uchar rem add mul k 1000 j 251
204+if or eq want 10 eq want 13
205+want = uchar 32
206+end
207+if ne get In add get N 5 j want
208+bad = add bad 1
209+end
210+end
211+test eq bad 0
212+test qsent 0 true
213+end
214+note A first LINE also stops job retries without a preceding ACK.
215+linepkt 1
216+test eq qincoming 1 1
217+test eq get T 6 1
218+test qnext 1 true
219+test eq get T 10 3
220+test qsent 1 true
221+control 6 0
222+test eq qincoming 2 1
223+test not qnext 2000 true
224+note Fill the eight-line queue; no GOT until a ninth line can actually be kept.
225+for k ulong 7
226+linepkt add k 2
227+test eq qincoming add k 2003 1
228+test qnext add k 2003 true
229+test eq get T 10 3
230+test qsent add k 2003 true
231+end
232+linepkt 9
233+test eq qincoming 2010 0
234+test eq get Q 2 8
235+test eq get T 13 0
236+test qtake
237+linepkt 9
238+test eq qincoming 2011 1
239+test eq get Q 2 9
240+test qnext 2011 true
241+test not qsent 2010 true
242+test eq get T 10 3
243+test qsent 2011 true
244+note Malformed ACK and wrong kinds cannot advance the accepted clock.
245+put Inlen 0 0
246+b = packet 4 1 1 0 0
247+tcopy
248+test eq qincoming 2012 0
249+test eq get T 0 2011
250+control 5 0
251+test eq qincoming 2012 0
252+test eq get T 0 2011
253+qcancel
254+control 4 1
255+test eq qincoming 2013 0
256+test eq get Q 4 0
257+ret int get Fails 0
258+end

aienux/allen/tests/stdio-overflow.om

new file mode 100644
@@ -0,0 +1,30 @@
1+note Regression input for L719: one over-capacity command then a valid one.
2+note The standalone Allen program must refuse with65, never emit the later JOB.
3+global Huge uchar 8193
4+text Suffix "\nASK hi\n"
5+fn main to int
6+for i ulong len Huge
7+put Huge i 120
8+end
9+put Huge 0 65
10+put Huge 1 83
11+put Huge 2 75
12+put Huge 3 32
13+sent = ulong 0
14+while lt sent len Huge
15+n = write 1 Huge sent sub len Huge sent
16+if le n 0
17+ret 2
18+end
19+sent = add sent ulong n
20+end
21+sent = ulong 0
22+while lt sent len Suffix
23+n = write 1 Suffix sent sub len Suffix sent
24+if le n 0
25+ret 2
26+end
27+sent = add sent ulong n
28+end
29+ret 0
30+end

aienux/allen/tests/surface-mutants.om

new file mode 100644
@@ -0,0 +1,101 @@
1+note Native exact-line mutant construction; selector0 remove-right-clip,1 wrong-destination-blend.
2+global Mutbuf uchar 262144
3+global Mutrep uchar 128
4+global Mutmode uchar 1
5+text Mutold0 "\nif ge x long add get Cvs 4 get Cvs 6\n"
6+text Mutnew0 "\nif false\n"
7+text Mutold1 "\nd = ulong get Nfrm at\n"
8+text Mutnew1 "\nd = ulong 395282\n"
9+fn mutmatch at ulong mode uchar to bool
10+if eq mode 48
11+for i ulong len Mutold0
12+if ne get Mutbuf add at i get Mutold0 i
13+ret false
14+end
15+end
16+else
17+for i ulong len Mutold1
18+if ne get Mutbuf add at i get Mutold1 i
19+ret false
20+end
21+end
22+end
23+ret true
24+end
25+fn mutwrite at ulong size ulong to bool
26+p = ulong 0
27+while lt p size
28+n = write 1 Mutbuf add at p sub size p
29+if le n 0
30+ret false
31+end
32+p = add p ulong n
33+end
34+ret true
35+end
36+fn mutout n ulong mode uchar to int
37+old = len Mutold0
38+size = len Mutnew0
39+if eq mode 49
40+old = len Mutold1
41+size = len Mutnew1
42+end
43+if lt n old
44+ret 65
45+end
46+found = ulong 0
47+at = ulong 0
48+for i ulong add sub n old 1
49+if mutmatch i mode
50+found = add found 1
51+at = i
52+end
53+end
54+if ne found 1
55+ret 65
56+end
57+for i ulong size
58+if eq mode 48
59+put Mutrep i get Mutnew0 i
60+else
61+put Mutrep i get Mutnew1 i
62+end
63+end
64+if not mutwrite 0 at
65+ret 74
66+end
67+p = ulong 0
68+while lt p size
69+r = write 1 Mutrep p sub size p
70+if le r 0
71+ret 74
72+end
73+p = add p ulong r
74+end
75+if not mutwrite add at old sub n add at old
76+ret 74
77+end
78+ret 0
79+end
80+fn main to int
81+r = read 0 Mutmode 0 1
82+if ne r 1
83+ret 65
84+end
85+mode = get Mutmode 0
86+if and ne mode 48 ne mode 49
87+ret 65
88+end
89+n = ulong 0
90+while lt n len Mutbuf
91+r = read 0 Mutbuf n sub len Mutbuf n
92+if lt r 0
93+ret 74
94+end
95+if eq r 0
96+ret mutout n mode
97+end
98+n = add n ulong r
99+end
100+ret 65
101+end

aienux/allen/tests/surface-render.om

new file mode 100644
@@ -0,0 +1,128 @@
1+note Native provider-to-pixels fixture. Reply is a labeled test input, not live inference.
2+note The surface draws into the native frame Nfrm; the frame is 768 x 384 (scale 1) over night.
3+text Cvppm "P6\n768 384\n255\n"
4+text Cvask "hello"
5+text Cvanswer "SAY 1 1/1 note: Hello, Drake. | This text was drawn in Omega."
6+global Svrow uchar 2304
7+fn svnight to void
8+put Lg 0 768
9+put Lg 1 384
10+for i ulong 294912
11+put Nfrm i 395282
12+end
13+end
14+fn svrow y ulong to bool
15+for x ulong 768
16+v = ulong get Nfrm add mul y 768 x
17+put Svrow mul x 3 uchar and shr v 16 255
18+put Svrow add mul x 3 1 uchar and shr v 8 255
19+put Svrow add mul x 3 2 uchar and v 255
20+end
21+p = ulong 0
22+while lt p 2304
23+n = write 1 Svrow p sub 2304 p
24+if le n 0
25+ret false
26+end
27+p = add p ulong n
28+end
29+ret true
30+end
31+fn svword off ulong v ulong to void
32+for i ulong 8
33+put Ph add off i uchar and shr v mul i 8 255
34+end
35+end
36+fn svframe op ulong now ulong arg ulong size ulong to void
37+for i ulong 8
38+put Ph i get Prmagic i
39+end
40+svword 8 op
41+svword 16 now
42+svword 24 arg
43+svword 32 size
44+end
45+fn svsize beg ulong to ulong
46+if ge beg len Dtext
47+ret 0
48+end
49+n = ulong 0
50+while lt add beg n len Dtext
51+if eq get Dtext add beg n 0
52+ret n
53+end
54+n = add n 1
55+end
56+ret 0
57+end
58+fn svout to bool
59+p = ulong 0
60+while lt p len Cvppm
61+n = write 1 Cvppm p sub len Cvppm p
62+if le n 0
63+ret false
64+end
65+p = add p ulong n
66+end
67+for y ulong 384
68+if not svrow y
69+ret false
70+end
71+end
72+ret true
73+end
74+fn main to int
75+svframe 1 0 77 0
76+if not prdo
77+ret 1
78+end
79+for i ulong len Cvask
80+put Pb i get Cvask i
81+end
82+svframe 2 1 0 len Cvask
83+if not prdo
84+ret 2
85+end
86+for i ulong len Cvanswer
87+put In i get Cvanswer i
88+end
89+put Inlen 0 len Cvanswer
90+if not packet 2 get Q 1 1 0 0
91+ret 3
92+end
93+for i ulong get Outlen 0
94+put Pb i get Outb i
95+end
96+svframe 5 2 0 get Outlen 0
97+if not prdo
98+ret 4
99+end
100+if or ne get Dm 0 1 ne get Ds 3 1
101+ret 5
102+end
103+if or ne get Dt 0 1 ne get Dt 6 2
104+ret 6
105+end
106+svnight
107+if not cvinit 768 384
108+ret 7
109+end
110+if not afinit 30 1250
111+ret 8
112+end
113+a = get Dt 7
114+if not cvspan a svsize a 48 166 15528188
115+ret 9
116+end
117+if not afinit 18 900
118+ret 10
119+end
120+a = get Dt 8
121+if not cvspan a svsize a 48 210 13161215
122+ret 11
123+end
124+if not svout
125+ret 74
126+end
127+ret 0
128+end

aienux/allen/tests/surface.om

new file mode 100644
@@ -0,0 +1,309 @@
1+note Surface tests: removing clipping, using constant background or bypassing drawing must fail.
2+note The surface draws packed 0x00RRGGBB words into the native frame Nfrm (look-paint.om) with
3+note Lg 0..1 as the native size. A 32 x 32 native frame gives scale 1 and no offset, so the
4+note logical geometry equals the former Canvas tests; 70 x 66 and 3840 x 2160 check the scale.
5+global Csave uint 1024
6+global Cmeta ulong 16
7+const CNIGHT ulong 395282
8+fn test ok bool to void
9+check ok add get Checks 0 1
10+end
11+fn cvframe w ulong h ulong to void
12+note The native size and the night background the look leaves; one sentinel word past it.
13+put Lg 0 long w
14+put Lg 1 long h
15+for i ulong mul w h
16+put Nfrm i uint CNIGHT
17+end
18+put Nfrm mul w h 0
19+end
20+fn cvat x ulong y ulong to ulong
21+ret ulong get Nfrm add mul y 32 x
22+end
23+fn cvkeep to void
24+for i ulong 1024
25+put Csave i get Nfrm i
26+end
27+for i ulong 8
28+put Cmeta i get Cv i
29+put Cmeta add i 8 get Cvs i
30+end
31+end
32+fn cvsame to bool
33+for i ulong 1024
34+if ne get Nfrm i get Csave i
35+ret false
36+end
37+end
38+for i ulong 8
39+if ne get Cv i get Cmeta i
40+ret false
41+end
42+if ne get Cvs i get Cmeta add i 8
43+ret false
44+end
45+end
46+ret true
47+end
48+fn cvink to ulong
49+ink = ulong 0
50+for i ulong 1024
51+if ne ulong get Nfrm i CNIGHT
52+ink = add ink 1
53+end
54+end
55+ret ink
56+end
57+fn cvrefclip to bool
58+ink = ulong 0
59+for y ulong 32
60+for x ulong 32
61+at = add mul y 32 x
62+inside = and ge x 8 lt x 16
63+inside = and inside and ge y 8 lt y 16
64+v = ulong get Nfrm at
65+if inside
66+if ne v ulong get Csave at
67+ret false
68+end
69+if ne v CNIGHT
70+ink = add ink 1
71+end
72+else
73+if ne v CNIGHT
74+ret false
75+end
76+end
77+end
78+end
79+ret gt ink 0
80+end
81+fn cvfrac to bool
82+cvframe 32 32
83+b = cvinit 32 32
84+b = afinit 14 900
85+for i ulong 3
86+put Dtext i 65
87+end
88+if not cvspan 0 3 -1 20 15528188
89+ret false
90+end
91+one = get Af 5
92+if ne get Cv 7 mul one 3
93+ret false
94+end
95+cvkeep
96+cvframe 32 32
97+b = cvinit 32 32
98+for i ulong 3
99+x = affloor add long -256 long mul one i
100+if not cvglyph 65 x 20 15528188
101+ret false
102+end
103+end
104+for i ulong 1024
105+if ne get Nfrm i get Csave i
106+ret false
107+end
108+end
109+ret true
110+end
111+fn cvfills to void
112+note A logical fill blends from the current pixel, clamps alpha, refuses an oversized rectangle
113+note and stays inside the clip.
114+cvframe 32 32
115+test cvinit 32 32
116+cvfill 1 1 2 2 15528188 128
117+test eq cvat 1 1 7961735
118+test eq cvat 2 2 7961735
119+test eq cvat 0 0 CNIGHT
120+test eq cvat 3 3 CNIGHT
121+test eq cvat 1 3 CNIGHT
122+test eq cvat 3 1 CNIGHT
123+cvfill 1 1 2 2 15528188 128
124+test eq cvat 1 1 11712193
125+cvfill 1 1 2 2 0 999
126+test eq cvat 2 2 0
127+cvfill 31 0 2 1 15528188 255
128+test eq cvat 31 0 CNIGHT
129+test cvclip 8 8 8 8
130+cvfill 0 0 32 32 15528188 255
131+test eq cvat 7 7 CNIGHT
132+test eq cvat 8 8 15528188
133+test eq cvat 15 15 15528188
134+test eq cvat 16 16 CNIGHT
135+end
136+fn cvscale to void
137+note 70 x 66 native pixels hold the 32 x 32 surface at scale 2, centred at (3, 1).
138+cvframe 70 66
139+test cvinit 32 32
140+test eq get Cvs 0 2
141+test eq get Cvs 2 3
142+test eq get Cvs 3 1
143+test eq get Cvs 4 3
144+test eq get Cvs 5 1
145+test eq get Cvs 6 64
146+test eq get Cvs 7 64
147+cvfill 0 0 1 1 15528188 255
148+test eq get Nfrm 73 15528188
149+test eq get Nfrm 74 15528188
150+test eq get Nfrm 143 15528188
151+test eq get Nfrm 144 15528188
152+test eq ulong get Nfrm 72 CNIGHT
153+test eq ulong get Nfrm 75 CNIGHT
154+test eq ulong get Nfrm 3 CNIGHT
155+test eq ulong get Nfrm 213 CNIGHT
156+test cvfont 10 900
157+test eq get Cvs 1 10
158+cvpixel 2 0 255 0
159+test eq ulong get Nfrm 2 CNIGHT
160+cvpixel 3 1 255 0
161+test eq get Nfrm 73 0
162+put Lg 0 3840
163+put Lg 1 2160
164+test cvinit 768 384
165+test eq get Cv 0 768
166+test eq get Cv 1 384
167+test eq get Cvs 0 5
168+test eq get Cvs 2 0
169+test eq get Cvs 3 120
170+test eq get Cvs 6 3840
171+test eq get Cvs 7 1920
172+end
173+fn main to int
174+test not cvglyph 65 0 0 15528188
175+test not cvinit 0 32
176+test not cvinit 32 0
177+test not cvinit 769 32
178+test not cvinit 32 385
179+cvframe 32 32
180+test cvinit 32 32
181+test eq get Cv 0 32
182+test eq get Cv 1 32
183+test eq get Cv 4 32
184+test eq get Cv 5 32
185+test eq get Cvs 0 1
186+test eq get Cvs 2 0
187+test eq get Cvs 3 0
188+test eq get Cvs 6 32
189+test eq get Cvs 7 32
190+test eq cvat 0 0 CNIGHT
191+test eq cvat 31 31 CNIGHT
192+test eq get Nfrm 1024 0
193+test not cvglyph 65 0 0 15528188
194+test afinit 20 1000
195+note Exact alpha arithmetic and repeated overlap must use current destination.
196+cvpixel 0 0 0 15528188
197+test eq cvat 0 0 CNIGHT
198+cvpixel 0 0 128 15528188
199+test eq cvat 0 0 7961735
200+cvpixel 0 0 128 15528188
201+test eq cvat 0 0 11712193
202+cvpixel 0 0 255 15528188
203+test eq cvat 0 0 15528188
204+cvkeep
205+cvpixel -1 0 255 0
206+cvpixel 0 -1 255 0
207+cvpixel 32 0 255 0
208+cvpixel 0 32 255 0
209+test cvsame
210+test not cvinit 18446744073709551615 1
211+test cvsame
212+test not cvclip 33 0 0 0
213+test not cvclip 0 33 0 0
214+test not cvclip 0 0 33 1
215+test not cvclip 0 0 1 33
216+test not cvclip 1 1 18446744073709551615 1
217+test cvsame
218+test not cvglyph 65 -4097 0 15528188
219+test not cvglyph 65 4097 0 15528188
220+test not cvglyph 65 0 -4097 15528188
221+test not cvglyph 65 0 4097 15528188
222+test not cvglyph 65 0 0 16777216
223+test cvsame
224+note Independent reference crop of the already rendered glyph.
225+cvframe 32 32
226+test cvinit 32 32
227+test cvglyph 65 4 24 15528188
228+test gt get Cv 7 0
229+cvkeep
230+cvframe 32 32
231+test cvinit 32 32
232+test cvclip 8 8 8 8
233+put Nfrm 1024 165
234+test cvglyph 65 4 24 15528188
235+test cvrefclip
236+test eq get Nfrm 1024 165
237+note Zero-area and edge clips cannot draw any pixel.
238+cvframe 32 32
239+test cvinit 32 32
240+test cvclip 32 32 0 0
241+cvkeep
242+test cvglyph 65 -8 6 15528188
243+put Cmeta 7 get Cv 7
244+test cvsame
245+note A negative origin that intersects the surface must draw without wrapping.
246+test cvclip 0 0 32 32
247+test cvglyph 65 -8 6 15528188
248+test gt cvink 0
249+test eq get Nfrm 1024 0
250+note Explicit retained-text span agrees with two separately positioned glyphs.
251+put Dtext 0 65
252+put Dtext 1 65
253+cvframe 32 32
254+test cvinit 32 32
255+put Outb 0 88
256+put Outlen 0 1
257+put Err 0 7
258+put In 8191 99
259+ok = cvspan 0 2 1 24 15528188
260+clean = and eq get Outb 0 88 eq get Outlen 0 1
261+clean = and clean eq get Err 0 7
262+test ok
263+test clean
264+test eq get In 8191 99
265+advance = get Cv 7
266+cvkeep
267+cvframe 32 32
268+test cvinit 32 32
269+test cvglyph 65 1 24 15528188
270+one = get Cv 7
271+x = add long 1 long div one 256
272+test cvglyph 65 x 24 15528188
273+test eq advance mul one 2
274+same = true
275+for i ulong 1024
276+if ne get Nfrm i get Csave i
277+same = false
278+end
279+end
280+test same
281+note Refused spans and extreme offsets preserve pixels and all surface metadata.
282+cvkeep
283+test not cvspan 2305 0 0 0 0
284+test not cvspan 2304 1 0 0 0
285+test not cvspan 1 18446744073709551615 0 0 0
286+test not cvspan 0 1 0 0 18446744073709551615
287+test not cvspan 0 1 -4097 0 0
288+test cvsame
289+test cvspan 2304 0 0 0 0
290+test eq get Cv 7 0
291+test eq get Dtext 0 65
292+test eq get Dtext 1 65
293+test cvfrac
294+for i ulong 2304
295+put Dtext i 65
296+end
297+cvframe 32 32
298+test cvinit 32 32
299+cvkeep
300+test cvspan 0 2304 4096 0 15528188
301+put Cmeta 7 get Cv 7
302+test cvsame
303+cvfills
304+cvscale
305+if ne get Fails 0 0
306+ret 1
307+end
308+ret 0
309+end

aienux/allen/tests/tls-cert-ecdsa.om

new file mode 100644
@@ -0,0 +1,363 @@
1+note Independent ECDSA oracle vectors for tls-p384.om and vendor/cert-p256.om.
2+note Build: base.om vendor/sha256-core.om vendor/cert-sha384.om vendor/cert-p256.om tls-p384.om tests/check.om tests/tls-cert-ecdsa.om
3+note Generated 2026-10-25 with OpenSSL: throwaway test-only keys from openssl ecparam -genkey (secp384r1, prime256v1),
4+note signatures from openssl dgst -sha384/-sha256 -sign, each accepted by openssl dgst -verify before embedding.
5+note Message lengths 0,1,55,111,112,127,128,129,239,1000 cross SHA-256/SHA-384 padding boundaries. No private key here.
6+note Record: public key 04||X||Y, r, s, n-s, message.
7+text Vdat "049d3c71fa72bbd145db340ad61901cc6c0f25df1ffccc232f72ae87e0789e0dba5b91da59058647da8c393c85f78f951014985f2b4b6f6f9ffe779a2fbe6049b2d3446f16be71f4e6b2f269442db381f0956ccafb68d842234cb561599ecc2b39ea0bac594b9669a2fcba7669d49f101774555c17588996f9d43072fe445e89435ad35890f9ec3323cf718b4f26effc4ac2c068608e658a9b9938e8077ae2a55079b82233c3f67dcb06d385edfe85c17faf3005254c98bbc4c42d2ca08516334b3d3f979f719a756466c717f8851d5aaf8647ddcc3c098234c08fc793f5b16c5fa8ea088cfc17ebb628beecca47aef628049d3c71fa72bbd145db340ad61901cc6c0f25df1ffccc232f72ae87e0789e0dba5b91da59058647da8c393c85f78f951014985f2b4b6f6f9ffe779a2fbe6049b2d3446f16be71f4e6b2f269442db381f0956ccafb68d842234cb561599ecc2b394cdb70bf5430717f8abd153e1bf2101c3ce0fdf4f9305d036541d9742085f0e7923df571a44d46fb1d3ba49f911d0b5b92e94c46c65ce95cc613d15f01988d6c40225eaa6a266b6a007cee9a410dc97f98ad9495fdd65b2916e525273fd02e9c6d16b3b939a316a339ec2ea0fe677293bfdda15595d99495c6e65ee7b329645fbf6c791c4ada4c51d606f4438cf4fad7c4049d3c71fa72bbd145db340ad61901cc6c0f25df1ffccc232f72ae87e0789e0dba5b91da59058647da8c393c85f78f951014985f2b4b6f6f9ffe779a2fbe6049b2d3446f16be71f4e6b2f269442db381f0956ccafb68d842234cb561599ecc2b392e6eea36b7787796341a1740f84c7cf61abaa5a38488a4fc8d69f70c708f1b37a2c1ca18face18b990e52551db380c94a76d4454606cde128a8c46edd9b383c528c888658f169ce0acd421d7995a3f14c994066f024ac889a5a998750e80875e5892bbab9f9321ed7573b912264c7c3ad737779a70e9631f1a8f2baa5adceeca8e8607434665def1474280f5be44a215180cbf7ce07e3f77c2911c45c9e45d91dccafcf8cedecf8e8166965fff5ae5e376aaebca8a9d19980ced83a75079760edd2801863dca52049d3c71fa72bbd145db340ad61901cc6c0f25df1ffccc232f72ae87e0789e0dba5b91da59058647da8c393c85f78f951014985f2b4b6f6f9ffe779a2fbe6049b2d3446f16be71f4e6b2f269442db381f0956ccafb68d842234cb561599ecc2b395bfdec8559d052174b81c01adf8de3855e296b4a5acb78bfbd7abf78d7a383d7fd005431c1691fe26e14653d3a60082445b6a7cecc46d18650c5941a0b1dd8064b693372b0d3b8696ebb46589b0fe1546a13e7388b638fcf4fab6beb711b1bebba49583133b92e79af3a6be5f4e227f9b496cc8d4f2c479658a8072959274c8aee062679bd4d17ab9d40ad7f5baa0d88ad8d84bbb956ef82687f39e40791631f673d73a6cacca625b94018a6312d8a107891973582594e98ac6ccc35fe68b175fbf101dba13e32fe673c39315483d0d6b8fe663c458195328ec9884ab686570391c878a68f0f943c2e90789ceb03cad05dd3050d08dda330a75ca588c7e1b5049d3c71fa72bbd145db340ad61901cc6c0f25df1ffccc232f72ae87e0789e0dba5b91da59058647da8c393c85f78f951014985f2b4b6f6f9ffe779a2fbe6049b2d3446f16be71f4e6b2f269442db381f0956ccafb68d842234cb561599ecc2b39b053ab2406d5a9de9b7a1d15f4d353cf205b6bce3d25c0db3848af6b53bb3eb2880762e070f1fe091b56ba3daf841f3d0f7777bd8ba69dcbaad93012b05083346a42a0cbff4bbb0c37caf2da717e261afd960fc1b170807aba50e80749ec563cf0888842745962345526cfed4faf7ccb95bd5f3400b444f38f985aa782b907c45a83fdf097402700329b316382d8d337ccdc59eb1dbe7e916be7c8e098f5eab587fcccad113b436a18c32feb6869b8ac3bbe203e72ee660a8fd7b29bb475189f7dc7e44a5cfed5ae22ed65b32ea8079e6e194514cc371a9768fa9bb3c2cc1b17609c28db59d8bd16cc2ebb2d653bca177461156a49fee0bf48827ee89d56a45b049d3c71fa72bbd145db340ad61901cc6c0f25df1ffccc232f72ae87e0789e0dba5b91da59058647da8c393c85f78f951014985f2b4b6f6f9ffe779a2fbe6049b2d3446f16be71f4e6b2f269442db381f0956ccafb68d842234cb561599ecc2b396c76e957b3ac1e3200f5edc3424b5dca14ff00cceacf4f4c00edc73ca6f72a7eb1477a207a3f12a7f28ad32426a200d29863d44bf5b0ae1f4cb302b1f4b7fdb4c8c28397d7bc622376be9971b6b3c30edfa67350633aa045ebebed511128e168679c2bb40a4f51e0b34cfd4e0b48024b373d7c6828439ddc50a4b4103d836ad078739a61e576073501002c19bb9c480b24886017b27e281a797cf60450c0108dd8b515317ab46ef87cf799e5916be9ed88ac0e69fc43eea30700ee10b787b8fd50b8d1c31c219ae61483a6323871eaa2d01de2bf9e62031de5c2df3219f9d4154909a37c3578ea54503609aa59f1f397f2ecb9e83f6f634ffc74685ac6dd7803c24b3d8beed21c3a8bbddfdc79d843049d3c71fa72bbd145db340ad61901cc6c0f25df1ffccc232f72ae87e0789e0dba5b91da59058647da8c393c85f78f951014985f2b4b6f6f9ffe779a2fbe6049b2d3446f16be71f4e6b2f269442db381f0956ccafb68d842234cb561599ecc2b39af66a8461b836e81fe90434a8fcb88f463f07d647c04dd7123e404ae801109e7cd07c12cdab8ffdc1b4e96fcb7ed92bad7178920e601446cdb6c96bff077e702fc1124dd6c029dcb737835dbbc2d9e2a541b958a8c9d617baa5008ba1b552ddc28e876df19febb93249369400f8818fd03eedb2293fd623453eb17a638098fb503fe7827bc1345ff429c10b0b16ffb97bf28a7dc1f80f8520507fb8d339deefdd5ce6d784a8d7d2799641c7e78df0c58585c0bb183bb54c9a24d5fdb9c0b9e5d3d55f5b11a6e992f2a4f88de399febb5afc7e0e6c0c63b68b3838935485cb77ceb01bcc79fa0eca9232a98fde65c7582d4217c24b5c45cd0b63204c7a651dbed2bbf43cf489627d5175d0bf70d109c4b049d3c71fa72bbd145db340ad61901cc6c0f25df1ffccc232f72ae87e0789e0dba5b91da59058647da8c393c85f78f951014985f2b4b6f6f9ffe779a2fbe6049b2d3446f16be71f4e6b2f269442db381f0956ccafb68d842234cb561599ecc2b39980a4d9bd3d8f0e9b25f9185507293e3adf8532023765e584ead8a8ca70fcf49fdaed3763ab455c2214e803a58062e4338be685831793303f36deb483a7f591bcef25afc783dd2f35045a2cf0a4e7fcb45212c72e6b3b04eeb2ab8a8eeb5f792c74197a7ce86ccfc0c9214b7c580a6e4310da50387c22d0c771daab2e9e8ae1412f8e13f61fcf72c01c160c1de0f31e1714e7c90b7557ae432d456b07aebc401e9ec0fca38313d70a1fb371edf93b8f79e5ae9b642d73917ef784bea13314ea74990e446bb1ce36ca9c1ed66528130a1683f3a3f0ee487d52930ce90930e18bd686d8767d4ffdf21f03e53fdefadc9bf5796dc0a18409b5b833497f0da2d988a07a55089a788eeb10a42700c327f43fcd4049d3c71fa72bbd145db340ad61901cc6c0f25df1ffccc232f72ae87e0789e0dba5b91da59058647da8c393c85f78f951014985f2b4b6f6f9ffe779a2fbe6049b2d3446f16be71f4e6b2f269442db381f0956ccafb68d842234cb561599ecc2b39d8bcb2a6ffc5a44de1d01861f7a0010c3fdbd4854ad8c3d113ae8073a0904db119a0e44dcc4f02049680478d0750a34b96aa4eea05d568a77243187b26daf3556782953d5a939e5c18e80c8ed336b388b09266317e85b6a6abd1e7f6a217253b6955b115fa2a97588dbce784d9250caa987d6ac2a56c61a3ae7b40f321007a56a787a780ca2af0d4411a31742aae043898576156838bdcd99d34a809bb2cd5b79cda357a0f7df1181a8ee33d7f9cfb7ed1af17d7db9cb54b09ca5115aab81173a057e6aa628cedf3c013581b30f4dd863c6d6db838767248139616d41c614a7abbe20d0784a6972c6fc8ca56e9f4f12cb7b376fac9e9e60d6883918bd0766636666cce573f9b556a0bdc29bd3b96dca8ce939c3284a3fdd1fb80f33ff610f2405d9548d1de4614063b454a0e5b3128cec315b1d1ca44c244c80bd80e80f0dce3947e5eb4438506b5185d987adf415ecbefa758137d05bb6492b991fa216361f58e15dd90b0e8641f35307ab674b67c90e8e5c1cbc00285deb9e6e79832fe23049d3c71fa72bbd145db340ad61901cc6c0f25df1ffccc232f72ae87e0789e0dba5b91da59058647da8c393c85f78f951014985f2b4b6f6f9ffe779a2fbe6049b2d3446f16be71f4e6b2f269442db381f0956ccafb68d842234cb561599ecc2b3960351c3697ffadea10098f2dcabd554fe2c7d3019c525fa641b93bfb1ea7ed060ac5547d1c52ade9e5c32212d931e8421de9f9e6001065f169bf4c784fbfdc37a4177ae99e01b135d94d931be93211c5cfe06637fc2e9bdcaa3443bcf59bb763e2160619ffef9a0e9640b387b04023c85be8851661fe4ec9ee15ba660b051c198839a77a4c820b9e42b7d5add7297210be8e52c2f3c0bd0c2b6074d332160fdfa13dc09f82ee1fbef2920715a2eb2abc80bc9ba4c809744d1a9ad979b1b096384b8c352e726a4a75a42fb7057f2c11e74a0c8cf016037bf0028bdcfdebd3e140c57ee56593e7e876bd343653164434212fe9b4e5727873192a821fcde39b7866d2e1cc3752ff24361b661819e1708a24f026bb6aaf95932071c47621cd3b617cd7dc7521a77d46928ff0f8d1adc5e9b9cdc4f6988ff58feb7190799a6d00819fd4ee17230aa671d06fd13bbffb8dd7bb5dc41d5484c84405f7f189967205e7c3272bfe74dbbe935e5fdd9fe9088182f6638a53b093fc704889d4a519a8145729da3f35985114fa14271d9e013a8dd3bd9ad720d3e875a4507257374b697ca70a4fdedb7f38bf1d9222e24d12fb18fc0814085105f97fecd584973de147bc0ca737977fb4b1f5a46de63a2b41d136699ce9e0b0dcb3003a0f940000d467f2050752ffb45f0f22ce82642e49ddcc3c45207780d7428ac708707b1d5873fb64cfac286ef907880b6a048c085068acc0ea9fdb9bf2653548d0bf35a74ed0e43b5e74d2543c4fbb7fff85860b5bc6678409dc6240124e1e85d4132ea4ecf877517f18e209c81bfb510695fe11b641dd64b94dbf0403762a057446365443776104a7f76e60fd9408099a45a4036b62a8a96f2061fed69036187e7b5584d2c8b2daa51fbdaf38fbb21a8e47138de4156d7dfae91c88831da105d070c0320357c9cab1cdb7c1f24815570aa8b2b6f48d1b44652c89baf2dc9b3e1d01a635e79178dcf5a9ab5980478dbd9e76fb9e55f30f62d9dc5f0a1b2a2e30458fcbfce5eae2653b86ad0a3cd91850838fae1b46cb62335e5493b7e2ce3ac11fb64f1f86a9aa318e444a0b5222c8c89da4bbdbb38a7a4df565db9057bf741be13d48efbede9639dbd993d8718f053a011f0ef8308f9c95f899cddebaf96c31408dd153607e97156504a03c734cf25e0b631fecdd10eed9c70346a28bd7847719fe6972d48bdde445d8579a6b1a1ed8e06f3633290d33cf6d7032d14ae1cc844215cc694f775dc7c91b6ab212dc78b4c22a2651086279fe8e6b95882b00b412978c37fd4221c63a136950cdfdc9f2539fdcad02c50e4e0b1ebb6cf733a4f97ebf714832d9f7e755268f826d99eef8eb23b9da0ba9521aae717222594f4c8e1f2f289eba6843ea252bde9dd4702ec6f52686154a9f6ffce0f6edead159b2eaeb02142c7c17fb10178f5404ab32f60893d3fc734fa2a4d3b914a63d63026d4452ff4ede6cbe1adce4db773307f194b429dcfb6400a4559a7437b77232f0e7bc1b21c6e97c4a05acc80ee71694b020d3041cb5656946ea0b73fb841d342d7f926ccaa6ac5022bb839bd973a24c25aea76ce163abf77ad0a54354c2db7490456a552e6a046d496c6cfc0f91a8a3e2518db8a0b17215fce3a9563fa0437d6466e9dc5d59ee7802caa677a8770d99c1d74e174b9abb234060251d590ca2ae5c81ed495bf3542b1645a1d07c80ec49a2f3e8b0ec6019c6a0787b6b98f9e133fab07028919d875b18a395fc88f2d7360be036dc9f7749a7371280ea84561674e20dad37cd990fa4e75c6903770d29c9f41fc9236088b615afe82cbc93486e7ed7bd15c4958c42046d496c6cfc0f91a8a3e2518db8a0b17215fce3a9563fa0437d6466e9dc5d59ee7802caa677a8770d99c1d74e174b9abb234060251d590ca2ae5c81ed495bf35486809306e59dd3858abd5dc17a645773aefa7eb7348a7df8bba5670a63b6dc73b4cd89233e93f39aea5a3f1690f03e15965a913b45fc360d8936d4e844f85fcb4b3276dbc16c0c6615a5c0e96f0fc1ea268c6972611b68776a82f5dab76ac586fa046d496c6cfc0f91a8a3e2518db8a0b17215fce3a9563fa0437d6466e9dc5d59ee7802caa677a8770d99c1d74e174b9abb234060251d590ca2ae5c81ed495bf354125a38862aa393c9ad9de110b0f8a75bfef7f3fca5a52fd534932a186de678b65f627b487369fd347a71bde86363d1d435552e5e0986e9fe8ea5039474ac3273a09d84b68c9602cc858e42179c9c2e2b8791cc4f9d90b4866514c72e87b6f2de9eddbbc014eadd7c5893a3a5a82993528b19ef11ce6e480c85056144d8bcbae490f427529f82ce723adb0720b115548c3a006f6b75cf7e046d496c6cfc0f91a8a3e2518db8a0b17215fce3a9563fa0437d6466e9dc5d59ee7802caa677a8770d99c1d74e174b9abb234060251d590ca2ae5c81ed495bf354b00c789a66a14299d11533cecf63a703057536c5c4646ce59e9c8e0c16aa1fa4480d516ccc4a2595d592e2bfeca0de1c0384df3d3404a35ae27c1f2d66f2deb1b7f2ae9233b5da6b2a6d1d40135f21e3b9621b707312fb2a113dab95957046a0e163a4db18f697b9f90be2ec01bef4e0090ac537c677048f7423093b5637978284086e9370d933467ee162c6afd176be1db9b9fd8061d3f31a0737f19a7cb2a610ef855352697af52f4c414a7e555705f261807418f09d354a174155a80195a3126efed1edf6733632755c7caf0fd5046d496c6cfc0f91a8a3e2518db8a0b17215fce3a9563fa0437d6466e9dc5d59ee7802caa677a8770d99c1d74e174b9abb234060251d590ca2ae5c81ed495bf354970eae111f406bb063265ba8d57641d29314df43c8335996334655a93a3620bf183fa8cc7347674d445904706b4d34aa9fe41f35ec72d86df7ae67ec48352f4ae7c057328cb898b3bba6fb8f94b2cb551d02db77baa4c616fc0b62d6b42df607329b92eb3def931709ef480ea7cc5c54c6b1c8fe15b664cbdcdb1271d5d34c492d12640034df91864ec501fcdd9aa7f73eaeea19464361e67b48357dbfc2131fa85b69d2a5f7f8f07164123998ad0f843085955bd489fc46ae01e2ad521bdede7b19903e96c5f7bb8d53b976749cd829046d496c6cfc0f91a8a3e2518db8a0b17215fce3a9563fa0437d6466e9dc5d59ee7802caa677a8770d99c1d74e174b9abb234060251d590ca2ae5c81ed495bf3540f6142a00b254522602565ff0c0e02fb7646655c145e7d4d408866e9422f0d5d9fdea626afdb6902cb9356ef5ca31acbfb607dbe5a57422beb5d0033dbc11136602159d8502496fe346ca910a35ce533c1867cef4cc05c59085cca8f20a2141b238f121d7d1645eb922bf7bb04a6cc98240ffad65e9d3a8d6640dcd45a99d26759243c1e1b74ff7fdc14a0e51f6925a9ec581ccba3d6ee511da56ba946cb867ec63e3cf677321d8ac59340cfdf1e5defd48542241c195f4fd8b44e9020f01aefad37a502a2b2be27b2596da75bc8dfa8b404015c5ea9d07f01089cbf56b8c5046d496c6cfc0f91a8a3e2518db8a0b17215fce3a9563fa0437d6466e9dc5d59ee7802caa677a8770d99c1d74e174b9abb234060251d590ca2ae5c81ed495bf3549accbc84cdf3c5b13171080f810c4d458df84255f9a4bc915b3ab3acb7d1708240898471e8465a42d9d6761ec4772f018dbb02f1108247bc0af5b96ab527ae0ebf767b8d17b9a5be262989e13b88d0fe2f2bf7bc969556c8e8c41158473b77433c2c87762bb5707281ade2ca67ed5c91a6185c955eae5328b504086b95a1e53272bea6245337af363c79ebaa457c5ef552af4dee7ac687ef9ded79ba590790406f154e8a5566999e304de802db662d9e1b327b63539544956ad6b97aab76a3bd9dab1828e798e72b5dc24e929f5e5e6f01065d84c1c130172850bf2cce01540e046d496c6cfc0f91a8a3e2518db8a0b17215fce3a9563fa0437d6466e9dc5d59ee7802caa677a8770d99c1d74e174b9abb234060251d590ca2ae5c81ed495bf3540fb116a703212a4795cc967502075aeb25a013b431f72565c6bb15cd8aee62892591cae870b97eb3dce0694d2a2a35136b3acebc11b2f38274bdd81d511c0d0eda6e35168f46814d231f96b2d5d5caec51ac2bf19564ab027efbf2a5ab471843eeb98657f8b8d3152d02f299885f7c86c8a1ded048cb791c4cc4181fdfa52dc0da484744605d5dec15aafbffd13078f4ba1be37b63302287871264dd0ba38e89550967a6b73c8066f06cef8dd85b07c662acdfd7d7499efcab64489dee19e7519775d088b613c6f8d319d198174735b6fa8c33b5d89fcaab79598f9df769906440046d496c6cfc0f91a8a3e2518db8a0b17215fce3a9563fa0437d6466e9dc5d59ee7802caa677a8770d99c1d74e174b9abb234060251d590ca2ae5c81ed495bf354684bf58f9e58196a86e7b60c6a4c1a9576297098897e1a817183e32cb5ee651c372b7887f4db030966db2363f105015ba7d5c06de644635d08ff6e7dc8e4ce74c8d487770b24fcf79924dc9c0efafea415113a3fc0d33b27eaba5c45337e56dd789ab3111d7a8699aa2db316e4140664e3b29ee95ad3741b10db34cd8ae8c17dfbdf6067dc06b3c275c47a1dd4049161bdb72aca5d430da0caafa7869c5ce04f41e9f75bf30d0ead9460205b6835891ae3ce07dc9d524670b315c03b58768f7f9816f765e1f0102f25c37c4fec3fc9e49383b340f6575a57ca667ea6e4c379b40585246ae96c047d58404f836f0589f22e507b0398b1020cb36694f821994bf6a08f215874cc9a06ccf71e9463b1ce4e54506a77445b3713084a5a75ec7a84887d4e2bb43cc44c55535ff007a2e625fb599cf17ee9d6f50ad048c45d817beaf3bdb13809260d7b1411957bd6b0798a046d496c6cfc0f91a8a3e2518db8a0b17215fce3a9563fa0437d6466e9dc5d59ee7802caa677a8770d99c1d74e174b9abb234060251d590ca2ae5c81ed495bf354fbf5ed7f6d0d96faf0914a900d502fbd17e68f4cd030d860ae716dca04124d75e005539d3c4de97ff4328c683a517f681d8dbc000847cab54c58ce1e911248e01ffaac61c3b216810bcd7397c5ae80979f593ead9ecfd3cfa760fca46b50dc71986910e2bb1a09a06724361cf3dc40fd2c411634dec22c32a6f00a32eaf611c5ae91b28ad96441fcaa28b6f94c64f78071c62662746793aa78802d10b26f23ef0d0d6f3869c39fa83adafa9ffa8f654c51fd8cfad39fbefa7d995c4411548a076c7071e5917801e4af86045e23b1a30e4922255d12421983149cef79c13502b8f4edb3873fb431c8fab39b1c2364e4411f341a78e65f6262ddca46dc6d7e29515f59bf2c87928f4db175360e591a9c15cf5af3e6f292f2c1c9904c5fa089cb93fc482a906f52162ef3016a480c2854cabf1ccfb83017c642a6d9cba79c663b9ce730157eaf8ef10f11edf1b99f01c0cb48e69c93f7464a5d890b7ac7c5f317bc364a8316285918808b7dec9f6b12d8551e9f2cd3f57464b2256baf348f9baef616d11765960cc45676f26aa8ac2ea6c6e1c64b4e60e20642a7ff77755a7dd8d7d96c58bdefce6ae4c286df319bea566e89986e9fbdc9f10689e047ef49f195a6b2c35a2a18641084101529e0ed424a30ff14266df0c22e38bedf216bed4141d085fc60fe4802f167625c5d7625bd1ecd6a19a6019ec2ad0d422ee02e9a93a5a45000639bfaf89cbdd4cbfe52de58353b6a85a294c1d2a2a1a9875f5bf60bbe3545f2bf06a16e4f1dd38069cd9fbd3c0564b6744123c8effd22e316eb9407e9fbc3de93f923f7962e28663dc3b98a15da633cf2253171049a3ccf102e27d3aa0f274c742a20233300d9ea75f057e982fa6d381aac4dfae2fa09f85af1751d30cf6e673f6bfb79e359eadb13c330aeaed3372bdcca016a0b91dc32853f43555c7b88dbbf2135037e85b8ecc1112e4acdcdf7d44f510c160f960579f4d9f555d09400fb5b52cf1a4741e00f439f5fe272406fef29a4baf68bc1a1603421f7dfd232ab55993b054af2d8d202c8cc1e9563700c728a795831dcf71120da04241c26ed05e3ac0f202d3a35cb8f0409bdf3b58ff6d9633a03ce5ba7c2a1794a1ee9219e6d758d289eb3298634092c74a71a642b14506fa3eeac0f7a9d12c94d12039c67b388646896f535227fbf5549a6b0c39be6278da8224bb32bfc8a6652e8c9fcd8b23a54ed5af9d995a89480523c343c48681b240891530d5654d6512bbde398d7eb36a4b587f244b776b4f7882f60e7e490609537b4beeb0fad737ad27dcf487ff6463369de06273208898689059f572cae7b8906617a5c6ddf68bc62d8562d9de638fa855356614a58f0f62412cdd46547c42b5973513494ebfcc33dc3b0b6b7bbdfeca4ea753e2f9e5c5fabe23ecea089679eaaf691ccdaa3ea9956e009097a8ff7d9321ca462703e9c332f42324db5c76707259a0b10fd99ae221312ce727bf86527b07b16dec44766e2ce275341c922c0725e68984e7134e0c09de158bd6f0a1d7724a34c2820"
8+
9+fn cthexb c uchar to uchar
10+if and ge c 48 le c 57
11+ret sub c 48
12+end
13+if and ge c 97 le c 102
14+ret sub c 87
15+end
16+trap 5
17+end
18+
19+fn tvb i ulong to uchar
20+ret or shl cthexb get Vdat mul i 2 4 cthexb get Vdat add mul i 2 1
21+end
22+
23+note mode 0 as signed, 1 message or digest bit flip, 2 r flip, 3 s flip, 4 public Y flip,
24+note 5 high-s n-s (valid ECDSA), 6 r zero, 7 s replaced by n (out of range).
25+fn tv384 off ulong ml ulong mode ulong to bool
26+w = new ulong 1536 0
27+b = new uchar 4096 0
28+so = add add off 97 48
29+if eq mode 5
30+so = add so 48
31+end
32+mo = add off 241
33+m = new uchar 65536 0
34+d = new uchar 64 0
35+for i ulong ml
36+put m i tvb add mo i
37+end
38+cs384hash m ml d
39+for j ulong 48
40+put b add 3296 j get d j
41+end
42+for k ulong 97
43+put b add 3072 k tvb add off k
44+end
45+for q ulong 48
46+put b add 3200 q tvb add add off 97 q
47+put b add 3248 q tvb add so q
48+end
49+if eq mode 1
50+put b 3296 xor get b 3296 1
51+end
52+if eq mode 2
53+put b 3247 xor get b 3247 1
54+end
55+if eq mode 3
56+put b 3295 xor get b 3295 1
57+end
58+if eq mode 4
59+put b 3168 xor get b 3168 1
60+end
61+if eq mode 6
62+for z ulong 48
63+put b add 3200 z 0
64+end
65+end
66+if eq mode 7
67+put b 3248 255
68+put b 3249 255
69+put b 3250 255
70+put b 3251 255
71+put b 3252 255
72+put b 3253 255
73+put b 3254 255
74+put b 3255 255
75+put b 3256 255
76+put b 3257 255
77+put b 3258 255
78+put b 3259 255
79+put b 3260 255
80+put b 3261 255
81+put b 3262 255
82+put b 3263 255
83+put b 3264 255
84+put b 3265 255
85+put b 3266 255
86+put b 3267 255
87+put b 3268 255
88+put b 3269 255
89+put b 3270 255
90+put b 3271 255
91+put b 3272 199
92+put b 3273 99
93+put b 3274 77
94+put b 3275 129
95+put b 3276 244
96+put b 3277 55
97+put b 3278 45
98+put b 3279 223
99+put b 3280 88
100+put b 3281 26
101+put b 3282 13
102+put b 3283 178
103+put b 3284 72
104+put b 3285 176
105+put b 3286 167
106+put b 3287 122
107+put b 3288 236
108+put b 3289 236
109+put b 3290 25
110+put b 3291 106
111+put b 3292 204
112+put b 3293 197
113+put b 3294 41
114+put b 3295 115
115+end
116+cp3init w
117+ret eq cp3vrfy w b 1
118+end
119+
120+note mode 0 as signed, 1 message or digest bit flip, 2 r flip, 3 s flip, 4 public Y flip,
121+note 5 high-s n-s (valid ECDSA), 6 r zero, 7 s replaced by n (out of range).
122+fn tv256 off ulong ml ulong mode ulong to bool
123+w = new ulong 1024 0
124+b = new uchar 4096 0
125+so = add add off 65 32
126+if eq mode 5
127+so = add so 32
128+end
129+mo = add off 161
130+constants
131+hinit
132+for i ulong ml
133+hbyte tvb add mo i
134+end
135+finish
136+for j ulong 32
137+put b add 3296 j get Hash j
138+end
139+for k ulong 65
140+put b add 3072 k tvb add off k
141+end
142+for q ulong 32
143+put b add 3200 q tvb add add off 65 q
144+put b add 3232 q tvb add so q
145+end
146+if eq mode 1
147+put b 3296 xor get b 3296 1
148+end
149+if eq mode 2
150+put b 3231 xor get b 3231 1
151+end
152+if eq mode 3
153+put b 3263 xor get b 3263 1
154+end
155+if eq mode 4
156+put b 3136 xor get b 3136 1
157+end
158+if eq mode 6
159+for z ulong 32
160+put b add 3200 z 0
161+end
162+end
163+if eq mode 7
164+put b 3232 255
165+put b 3233 255
166+put b 3234 255
167+put b 3235 255
168+put b 3236 0
169+put b 3237 0
170+put b 3238 0
171+put b 3239 0
172+put b 3240 255
173+put b 3241 255
174+put b 3242 255
175+put b 3243 255
176+put b 3244 255
177+put b 3245 255
178+put b 3246 255
179+put b 3247 255
180+put b 3248 188
181+put b 3249 230
182+put b 3250 250
183+put b 3251 173
184+put b 3252 167
185+put b 3253 23
186+put b 3254 158
187+put b 3255 132
188+put b 3256 243
189+put b 3257 185
190+put b 3258 202
191+put b 3259 194
192+put b 3260 252
193+put b 3261 99
194+put b 3262 37
195+put b 3263 81
196+end
197+cp2init w
198+ret eq cp2vrfy w b 1
199+end
200+
201+fn main to int
202+check tv384 0 0 0 100
203+check not tv384 0 0 1 101
204+check not tv384 0 0 2 102
205+check not tv384 0 0 3 103
206+check not tv384 0 0 4 104
207+check tv384 0 0 5 105
208+check not tv384 0 0 6 106
209+check not tv384 0 0 7 107
210+check tv384 241 1 0 108
211+check not tv384 241 1 1 109
212+check not tv384 241 1 2 110
213+check not tv384 241 1 3 111
214+check not tv384 241 1 4 112
215+check tv384 241 1 5 113
216+check not tv384 241 1 6 114
217+check not tv384 241 1 7 115
218+check tv384 483 55 0 116
219+check not tv384 483 55 1 117
220+check not tv384 483 55 2 118
221+check not tv384 483 55 3 119
222+check not tv384 483 55 4 120
223+check tv384 483 55 5 121
224+check not tv384 483 55 6 122
225+check not tv384 483 55 7 123
226+check tv384 779 111 0 124
227+check not tv384 779 111 1 125
228+check not tv384 779 111 2 126
229+check not tv384 779 111 3 127
230+check not tv384 779 111 4 128
231+check tv384 779 111 5 129
232+check not tv384 779 111 6 130
233+check not tv384 779 111 7 131
234+check tv384 1131 112 0 132
235+check not tv384 1131 112 1 133
236+check not tv384 1131 112 2 134
237+check not tv384 1131 112 3 135
238+check not tv384 1131 112 4 136
239+check tv384 1131 112 5 137
240+check not tv384 1131 112 6 138
241+check not tv384 1131 112 7 139
242+check tv384 1484 127 0 140
243+check not tv384 1484 127 1 141
244+check not tv384 1484 127 2 142
245+check not tv384 1484 127 3 143
246+check not tv384 1484 127 4 144
247+check tv384 1484 127 5 145
248+check not tv384 1484 127 6 146
249+check not tv384 1484 127 7 147
250+check tv384 1852 128 0 148
251+check not tv384 1852 128 1 149
252+check not tv384 1852 128 2 150
253+check not tv384 1852 128 3 151
254+check not tv384 1852 128 4 152
255+check tv384 1852 128 5 153
256+check not tv384 1852 128 6 154
257+check not tv384 1852 128 7 155
258+check tv384 2221 129 0 156
259+check not tv384 2221 129 1 157
260+check not tv384 2221 129 2 158
261+check not tv384 2221 129 3 159
262+check not tv384 2221 129 4 160
263+check tv384 2221 129 5 161
264+check not tv384 2221 129 6 162
265+check not tv384 2221 129 7 163
266+check tv384 2591 239 0 164
267+check not tv384 2591 239 1 165
268+check not tv384 2591 239 2 166
269+check not tv384 2591 239 3 167
270+check not tv384 2591 239 4 168
271+check tv384 2591 239 5 169
272+check not tv384 2591 239 6 170
273+check not tv384 2591 239 7 171
274+check tv384 3071 1000 0 172
275+check not tv384 3071 1000 1 173
276+check not tv384 3071 1000 2 174
277+check not tv384 3071 1000 3 175
278+check not tv384 3071 1000 4 176
279+check tv384 3071 1000 5 177
280+check not tv384 3071 1000 6 178
281+check not tv384 3071 1000 7 179
282+check tv256 4312 0 0 180
283+check not tv256 4312 0 1 181
284+check not tv256 4312 0 2 182
285+check not tv256 4312 0 3 183
286+check not tv256 4312 0 4 184
287+check tv256 4312 0 5 185
288+check not tv256 4312 0 6 186
289+check not tv256 4312 0 7 187
290+check tv256 4473 1 0 188
291+check not tv256 4473 1 1 189
292+check not tv256 4473 1 2 190
293+check not tv256 4473 1 3 191
294+check not tv256 4473 1 4 192
295+check tv256 4473 1 5 193
296+check not tv256 4473 1 6 194
297+check not tv256 4473 1 7 195
298+check tv256 4635 55 0 196
299+check not tv256 4635 55 1 197
300+check not tv256 4635 55 2 198
301+check not tv256 4635 55 3 199
302+check not tv256 4635 55 4 200
303+check tv256 4635 55 5 201
304+check not tv256 4635 55 6 202
305+check not tv256 4635 55 7 203
306+check tv256 4851 111 0 204
307+check not tv256 4851 111 1 205
308+check not tv256 4851 111 2 206
309+check not tv256 4851 111 3 207
310+check not tv256 4851 111 4 208
311+check tv256 4851 111 5 209
312+check not tv256 4851 111 6 210
313+check not tv256 4851 111 7 211
314+check tv256 5123 112 0 212
315+check not tv256 5123 112 1 213
316+check not tv256 5123 112 2 214
317+check not tv256 5123 112 3 215
318+check not tv256 5123 112 4 216
319+check tv256 5123 112 5 217
320+check not tv256 5123 112 6 218
321+check not tv256 5123 112 7 219
322+check tv256 5396 127 0 220
323+check not tv256 5396 127 1 221
324+check not tv256 5396 127 2 222
325+check not tv256 5396 127 3 223
326+check not tv256 5396 127 4 224
327+check tv256 5396 127 5 225
328+check not tv256 5396 127 6 226
329+check not tv256 5396 127 7 227
330+check tv256 5684 128 0 228
331+check not tv256 5684 128 1 229
332+check not tv256 5684 128 2 230
333+check not tv256 5684 128 3 231
334+check not tv256 5684 128 4 232
335+check tv256 5684 128 5 233
336+check not tv256 5684 128 6 234
337+check not tv256 5684 128 7 235
338+check tv256 5973 129 0 236
339+check not tv256 5973 129 1 237
340+check not tv256 5973 129 2 238
341+check not tv256 5973 129 3 239
342+check not tv256 5973 129 4 240
343+check tv256 5973 129 5 241
344+check not tv256 5973 129 6 242
345+check not tv256 5973 129 7 243
346+check tv256 6263 239 0 244
347+check not tv256 6263 239 1 245
348+check not tv256 6263 239 2 246
349+check not tv256 6263 239 3 247
350+check not tv256 6263 239 4 248
351+check tv256 6263 239 5 249
352+check not tv256 6263 239 6 250
353+check not tv256 6263 239 7 251
354+check tv256 6663 1000 0 252
355+check not tv256 6663 1000 1 253
356+check not tv256 6663 1000 2 254
357+check not tv256 6663 1000 3 255
358+check not tv256 6663 1000 4 256
359+check tv256 6663 1000 5 257
360+check not tv256 6663 1000 6 258
361+check not tv256 6663 1000 7 259
362+ret int get Fails 0
363+end

aienux/allen/tests/tls-cert.om

new file mode 100644
@@ -0,0 +1,338 @@
1+note Certificate verifier fixtures. Build order: base.om vendor/sha256-core.om vendor/cert-sha384.om
2+note vendor/cert-p256.om tls-p384.om vendor/cert-root.om tls-cert.om tests/check.om tests/tls-cert.om.
3+note Public api.github.com chain observed by parent 2026-10-25 in /tmp/allen-imac-qualification/github-api-fullchain.txt
4+note through an OpenSSL TLS1.3 ChaCha20 handshake. Independent oracle: openssl verify -CAfile system Root E46
5+note -untrusted intermediate -purpose sslserver -verify_hostname api.github.com leaf: OK. Test-only bytes.
6+note Leaf DER SHA256 06e6a4a004329905d4a4e7c0d2c6ec7a632c56443f256424a43cc786951b3149.
7+note Intermediate DER SHA256 873f0ba80e3ac222656dfd04158cc15c2927d42d5d05f01dee4a47eb43a916df.
8+note Cross-signed Root E46 DER SHA256 ea6b89ed6907a209ff9188676fb164e7aced894b8996dfbe5ce5bbcc22de4ddd.
9+note Production code never reads these texts; trust comes from vendor/cert-root.om only.
10+note certsig positive uses the public intermediate key and its real ECDSA-SHA256 over leaf TBS.
11+text Tleaf "308203ee30820394a003020102021078f8ae8f2ae4d74fda13a80568074b6f300a06082a8648ce3d0403023060310b300906035504061302474231183016060355040a130f5365637469676f204c696d69746564313730350603550403132e5365637469676f205075626c6963205365727665722041757468656e7469636174696f6e20434120445620453336301e170d3236303833303030303030305a170d3236313132373233353935395a30173115301306035504030c0c2a2e6769746875622e636f6d3059301306072a8648ce3d020106082a8648ce3d03010703420004d6c33b882041438111d499cbbc698be6be414eeeb0cba06bbfa5216e3474dc32cea9f39feb4f8c08230d8ccf2cddce43ac95b2e83079ca112d9716fa412034f0a382027730820273301f0603551d230418301680141799a804c16fe42d70a80a103d03d3e91ab82663301d0603551d0e04160414c3ee316094e517ebe26296f8081f03c03f7437d0300e0603551d0f0101ff040403020780300c0603551d130101ff0402300030130603551d25040c300a06082b0601050507030130490603551d20044230403034060b2b06010401b231010202073025302306082b06010505070201161768747470733a2f2f7365637469676f2e636f6d2f4350533008060667810c01020130818406082b0601050507010104783076304f06082b060105050730028643687474703a2f2f6372742e7365637469676f2e636f6d2f5365637469676f5075626c696353657276657241757468656e7469636174696f6e434144564533362e637274302306082b060105050730018617687474703a2f2f6f6373702e7365637469676f2e636f6d30820105060a2b06010401d6790204020481f60481f300f1007700d76d7d10d1a7f577c2c7e95fd700bff982c9335a65e1d0b3017317c0c8c56977000001a0501f4ff70000040300483046022100bf8417b321ff4d63069da780ea0c80da79814e122c327d43555da2a91ce3e49902210085dacc1bf48945ba84793afaa16d81ce31c52ce22968c482d4a0a24cf3019ca4007600c8a3c47fc7b3adb9356b013f6a7a126de33a4e43a5c646f997ad3975991dcf9a000001a0501f4ffe0000040300473045022100af24545a95f9858841971cb29838c25a51b8a4fb11f1b8add82a6586dbe6894f02204143eecce1001622a34b8d15a7407eb0bc0e38bfc0f1ff68ee87ea43feeacc1430230603551d11041c301a820c2a2e6769746875622e636f6d820a6769746875622e636f6d300a06082a8648ce3d040302034800304502204d4e9857f70ea04285bbe15853684007b109c5da74be76e8b7eaf721dcfd9172022100c9e9743bced1f6ad830c6ba69b0be117cae6aa5d69deb0ba9615a9704b4e02a8"
12+text Tint "3082035f308202e6a003020102021036e059ed888dd57aedd570b6727f9bda300a06082a8648ce3d040303305f310b300906035504061302474231183016060355040a130f5365637469676f204c696d69746564313630340603550403132d5365637469676f205075626c6963205365727665722041757468656e7469636174696f6e20526f6f7420453436301e170d3231303332323030303030305a170d3336303332313233353935395a3060310b300906035504061302474231183016060355040a130f5365637469676f204c696d69746564313730350603550403132e5365637469676f205075626c6963205365727665722041757468656e7469636174696f6e204341204456204533363059301306072a8648ce3d020106082a8648ce3d0301070342000468a1a76c05270589631c39a7ff2521c5edd32f1298bb2cdcf555e849a08457917bdc585f6bf4a2fd132c9b04c55b747db3b27a269619166bb8768def93f56097a38201813082017d301f0603551d23041830168014d122da4c59f14b5f2638aa9dd6eeeb0dc3fba961301d0603551d0e041604141799a804c16fe42d70a80a103d03d3e91ab82663300e0603551d0f0101ff04040302018630120603551d130101ff040830060101ff020100301d0603551d250416301406082b0601050507030106082b06010505070302301b0603551d200414301230060604551d20003008060667810c01020130540603551d1f044d304b3049a047a0458643687474703a2f2f63726c2e7365637469676f2e636f6d2f5365637469676f5075626c696353657276657241757468656e7469636174696f6e526f6f744534362e63726c30818406082b0601050507010104783076304f06082b060105050730028643687474703a2f2f6372742e7365637469676f2e636f6d2f5365637469676f5075626c696353657276657241757468656e7469636174696f6e526f6f744534362e703763302306082b060105050730018617687474703a2f2f6f6373702e7365637469676f2e636f6d300a06082a8648ce3d040303036700306402305b0a9c140387ae25faff9a5185a30c224a40cc475141a67300180c88c9f696d1608b4c088c79c6ed2851beac21f4d7a902303dd75cb0313829d78bbb58497691e074bbec1c02b7bf28322c6ba3314f7104908369c9114fddd51c4134829a6036a755"
13+text Tcross "30820346308202cba00302010202101a9eafec6de8e19b5c193141b68d90dd300a06082a8648ce3d040303308188310b3009060355040613025553311330110603550408130a4e6577204a6572736579311430120603550407130b4a65727365792043697479311e301c060355040a131554686520555345525452555354204e6574776f726b312e302c06035504031325555345525472757374204543432043657274696669636174696f6e20417574686f72697479301e170d3231303332323030303030305a170d3338303131383233353935395a305f310b300906035504061302474231183016060355040a130f5365637469676f204c696d69746564313630340603550403132d5365637469676f205075626c6963205365727665722041757468656e7469636174696f6e20526f6f74204534363076301006072a8648ce3d020106052b810400220362000476fa99a96e20edf9d777e3073ba8db3d5f38e8ab55a6564fd648eaec7f2daac3b2c579ec99617f1079c7025af90437f534352b77ce7f208f52a30089ecd5a7a26d5be34b9293a080f50194dcf068071ecdeefe2552b520431c1bfeeb19ce43a3a38201203082011c301f0603551d230418301680143ae10986d4cf19c29676744976dce035c663639a301d0603551d0e04160414d122da4c59f14b5f2638aa9dd6eeeb0dc3fba961300e0603551d0f0101ff040403020186300f0603551d130101ff040530030101ff301d0603551d250416301406082b0601050507030106082b0601050507030230110603551d20040a300830060604551d200030500603551d1f044930473045a043a041863f687474703a2f2f63726c2e7573657274727573742e636f6d2f55534552547275737445434343657274696669636174696f6e417574686f726974792e63726c303506082b0601050507010104293027302506082b060105050730018619687474703a2f2f6f6373702e7573657274727573742e636f6d300a06082a8648ce3d04030303690030660231008c0b2062b7df6f5f66daeb11240def983bbbc2d2dc236e4bfd3caa6a186b99eb5259af28c5b29f8316911c942572e27a023100b0bd90d70ff9b62a8d470390649b3ed840e14088d0c3e3d2166b6c1d4fb4770ed3836925c7fc1897bfc7f007db2ee2d5"
14+text Tok1 "api.github.com"
15+text Tok2 "API.GitHub.COM"
16+text Tok3 "*.github.com"
17+text Tbad1 "*.*.github.com"
18+text Tbad2 "x.api.github.com"
19+text Tbad3 "github.com"
20+text Tbad4 "api.github.com."
21+text Tbad5 "a*.github.com"
22+text Tbad6 "api.github.co"
23+text Tutc1 "260230000000Z"
24+text Tgen1 "20491231235959Z"
25+text Tutc2 "2610251200000"
26+text Tutc3 "261025120000Z"
27+global Tpos ulong 1
28+
29+fn thexb w ulong i ulong to uchar
30+if eq w 0
31+ret or shl cthexv get Tleaf mul i 2 4 cthexv get Tleaf add mul i 2 1
32+end
33+if eq w 1
34+ret or shl cthexv get Tint mul i 2 4 cthexv get Tint add mul i 2 1
35+end
36+ret or shl cthexv get Tcross mul i 2 4 cthexv get Tcross add mul i 2 1
37+end
38+
39+fn tlen w ulong to ulong
40+if eq w 0
41+ret div len Tleaf 2
42+end
43+if eq w 1
44+ret div len Tint 2
45+end
46+ret div len Tcross 2
47+end
48+
49+fn tbegin to void
50+for i ulong 65536
51+put Certbuf i 0
52+end
53+put Tpos 0 4
54+end
55+
56+fn tentry w ulong to void
57+p = get Tpos 0
58+n = tlen w
59+put Certbuf p uchar and shr n 16 255
60+put Certbuf add p 1 uchar and shr n 8 255
61+put Certbuf add p 2 uchar and n 255
62+for i ulong n
63+put Certbuf add add p 3 i thexb w i
64+end
65+put Tpos 0 add add p 5 n
66+end
67+
68+fn tend to void
69+e = get Tpos 0
70+n = sub e 4
71+put Certbuf 1 uchar and shr n 16 255
72+put Certbuf 2 uchar and shr n 8 255
73+put Certbuf 3 uchar and n 255
74+put Certlen 0 e
75+end
76+
77+fn tchain to void
78+tbegin
79+tentry 0
80+tentry 1
81+tentry 2
82+tend
83+end
84+
85+fn tkey to bool
86+ok = true
87+for i ulong 65
88+if ne get Certkey i thexb 0 add 224 i
89+ok = false
90+end
91+end
92+ret ok
93+end
94+
95+note Synthetic DER/name bytes are placed at62000 after the fixture chain; ctdns sees only its range.
96+fn tdnsok w ulong to bool
97+n = ulong 0
98+if eq w 0
99+n = len Tok1
100+for i ulong n
101+put Certbuf add 62000 i get Tok1 i
102+end
103+end
104+if eq w 1
105+n = len Tok2
106+for i ulong n
107+put Certbuf add 62000 i get Tok2 i
108+end
109+end
110+if eq w 2
111+n = len Tok3
112+for i ulong n
113+put Certbuf add 62000 i get Tok3 i
114+end
115+end
116+ret ctdns 62000 add 62000 n
117+end
118+
119+fn tdnsbad w ulong to bool
120+n = ulong 0
121+if eq w 0
122+n = len Tbad1
123+for i ulong n
124+put Certbuf add 62000 i get Tbad1 i
125+end
126+end
127+if eq w 1
128+n = len Tbad2
129+for i ulong n
130+put Certbuf add 62000 i get Tbad2 i
131+end
132+end
133+if eq w 2
134+n = len Tbad3
135+for i ulong n
136+put Certbuf add 62000 i get Tbad3 i
137+end
138+end
139+if eq w 3
140+n = len Tbad4
141+for i ulong n
142+put Certbuf add 62000 i get Tbad4 i
143+end
144+end
145+if eq w 4
146+n = len Tbad5
147+for i ulong n
148+put Certbuf add 62000 i get Tbad5 i
149+end
150+end
151+if eq w 5
152+n = len Tbad6
153+for i ulong n
154+put Certbuf add 62000 i get Tbad6 i
155+end
156+end
157+ret ctdns 62000 add 62000 n
158+end
159+
160+fn tder a uchar b uchar c uchar to bool
161+put Certbuf 62000 a
162+put Certbuf 62001 b
163+put Certbuf 62002 c
164+put Certbuf 62003 0
165+put Certbuf 62004 0
166+ret ctder 62000 62005
167+end
168+
169+fn ttime w ulong to bool
170+p = ulong 62002
171+n = ulong 13
172+put Certbuf 62000 23
173+if eq w 0
174+for i ulong 13
175+put Certbuf add p i get Tutc1 i
176+end
177+end
178+if eq w 1
179+put Certbuf 62000 24
180+n = 15
181+for i ulong 15
182+put Certbuf add p i get Tgen1 i
183+end
184+end
185+if eq w 2
186+for i ulong 13
187+put Certbuf add p i get Tutc2 i
188+end
189+end
190+if eq w 3
191+for i ulong 13
192+put Certbuf add p i get Tutc3 i
193+end
194+end
195+put Certbuf 62001 uchar n
196+if not cttime 62000 add p n
197+ret false
198+end
199+ret ne ctepoch 0
200+end
201+
202+note Leaf parse-only mutants: the fixture leaf begins at Certbuf 7 and ends at 1017.
203+fn tmut at ulong v uchar to bool
204+tchain
205+put Certbuf add 7 at v
206+ret ctparse 0 7 1017
207+end
208+
209+fn tsigmsg to void
210+for i ulong 920
211+put Certmsg i thexb 0 add 4 i
212+end
213+for j ulong 71
214+put Certsig j thexb 0 add 939 j
215+end
216+for k ulong 65
217+put Cleaf k thexb 1 add 296 k
218+end
219+end
220+
221+fn main to int
222+put Certnow 0 1792929600
223+tchain
224+check certcheck 1
225+check tkey 2
226+check eq get Ccount 0 3 3
227+check not ctca 1 1 4
228+check ctca 1 0 5
229+tsigmsg
230+check certsig 920 71 6
231+put Certmsg 10 xor get Certmsg 10 1
232+check not certsig 920 71 7
233+put Certmsg 10 xor get Certmsg 10 1
234+check not certsig 920 71 8
235+certreset
236+tsigmsg
237+check not certsig 920 71 9
238+put Certnow 0 1788048000
239+tchain
240+check certcheck 10
241+put Certnow 0 1788047999
242+check not certcheck 11
243+put Certnow 0 1795823999
244+check certcheck 12
245+put Certnow 0 1795824000
246+check not certcheck 13
247+put Certnow 0 0
248+check not certcheck 14
249+put Certnow 0 1792929600
250+tbegin
251+tentry 0
252+tentry 1
253+tend
254+check certcheck 15
255+tbegin
256+tentry 0
257+tend
258+check not certcheck 16
259+tbegin
260+tentry 1
261+tentry 0
262+tend
263+check not certcheck 17
264+tbegin
265+tentry 1
266+tend
267+check not certcheck 18
268+tchain
269+put Certbuf 1016 xor get Certbuf 1016 1
270+check not certcheck 19
271+tchain
272+put Certbuf 22 xor get Certbuf 22 1
273+check not certcheck 20
274+tchain
275+put Certbuf 1888 xor get Certbuf 1888 1
276+check not certcheck 21
277+tchain
278+put Certbuf 1018 1
279+check not certcheck 22
280+tchain
281+put Certbuf 0 1
282+check not certcheck 23
283+tchain
284+put Certlen 0 add get Certlen 0 1
285+check not certcheck 24
286+tchain
287+put Certlen 0 61000
288+check not certcheck 25
289+tchain
290+put Certbuf 3 xor get Certbuf 3 1
291+check not certcheck 26
292+tchain
293+check ctparse 0 7 1017 27
294+check not tmut 336 35 28
295+check not tmut 367 127 29
296+check tmut 336 126 30
297+check not tmut 935 3 31
298+check not tmut 1 0 32
299+check tmut 911 110 33
300+check eq get Cm 18 0 34
301+tchain
302+put Certbuf 918 110
303+check not certcheck 35
304+check tdnsok 0 36
305+check tdnsok 1 37
306+check tdnsok 2 38
307+check not tdnsbad 0 39
308+check not tdnsbad 1 40
309+check not tdnsbad 2 41
310+check not tdnsbad 3 42
311+check not tdnsbad 4 43
312+check not tdnsbad 5 44
313+check not tder 48 128 0 45
314+check not tder 48 129 3 46
315+check not tder 31 1 0 47
316+check not tder 48 4 0 48
317+check tder 48 3 0 49
318+check not ttime 0 50
319+check not ttime 1 51
320+check not ttime 2 52
321+check ttime 3 53
322+put Certnow 0 253402300800
323+tchain
324+check not certcheck 54
325+put Certnow 0 1792929600
326+tchain
327+check certcheck 55
328+certreset
329+check not certsig 920 71 56
330+check eq get Certkey 0 0 57
331+note Leaf policy without signatures: the SAN mutant parses but must fail the identity check.
332+tchain
333+check ctparse 0 7 1017 58
334+check ctleaf 59
335+check tmut 911 110 60
336+check not ctleaf 61
337+ret int get Fails 0
338+end

aienux/allen/tests/tls-crypto-aead.om

new file mode 100644
@@ -0,0 +1,179 @@
1+note SPDX-License-Identifier: AGPL-3.0-or-later
2+note RFC8439 sections2.3.2/2.8.2 official block and AEAD vectors; negative cases mutate those vectors.
3+note https://www.rfc-editor.org/rfc/rfc8439 ; attribution/license in tls-crypto-fixture.om.
4+note Additional zero/partial/full/block-boundary/max-buffer roundtrips are property tests, not oracles.
5+text Vblock "10f1e7e4d13b5915500fdd1fa32071c4c7d1f4c733c068030422aa9ac3d46c4ed2826446079faa0914c2d705d98b02a2b5129cd1de164eb9cbd083e8a2503c4e"
6+text Vplain "Ladies and Gentlemen of the class of '99: If I could offer you only one tip for the future, sunscreen would be it."
7+text Vcipher "d31a8d34648e60db7b86afbc53ef7ec2a4aded51296e08fea9e2b5a736ee62d63dbea45e8ca9671282fafb69da92728b1a71de0a9e060b2905d6a5b67ecd3b3692ddbd7f2d778b8c9803aee328091b58fab324e4fad675945585808b4831d7bc3ff4def08e4b7a9de576d26586cec64b6116"
8+text Vtag "1ae10b594f09e26a7e902ecbd0600691"
9+text Vaad "50515253c0c1c2c3c4c5c6c7"
10+
11+fn tvblock to void
12+tcwipe
13+for i ulong 32
14+put Tckey i uchar i
15+end
16+put Tciv 3 9
17+put Tciv 7 74
18+tccblock 1
19+for i ulong 64
20+p = mul i 2
21+v = tvbyte get Vblock p get Vblock add p 1
22+tvcheck eq get Tccblk i v 1
23+end
24+tccwipe
25+tvscrub
26+end
27+
28+fn tvsetup to void
29+tcwipe
30+for i ulong 32
31+put Tckey i uchar add i 128
32+end
33+put Tciv 0 7
34+for i ulong 8
35+put Tciv add i 4 uchar add i 64
36+end
37+for i ulong 12
38+p = mul i 2
39+put Tcaad i tvbyte get Vaad p get Vaad add p 1
40+end
41+for i ulong len Vplain
42+put Tcbuf i get Vplain i
43+end
44+put Tcbuf len Vplain 221
45+end
46+
47+fn tvcipher to void
48+for i ulong len Vplain
49+p = mul i 2
50+v = tvbyte get Vcipher p get Vcipher add p 1
51+tvcheck eq get Tcbuf i v 2
52+end
53+tvcheck eq get Tcbuf len Vplain 221 3
54+tvscrub
55+end
56+
57+fn tvtag to void
58+for i ulong 16
59+p = mul i 2
60+v = tvbyte get Vtag p get Vtag add p 1
61+tvcheck eq get Tctag i v 4
62+end
63+end
64+
65+fn tvbad to void
66+note Each bit of every tag byte is checked, with ciphertext unchanged after every rejection.
67+for i ulong 16
68+for j ulong 8
69+v = shl uchar 1 j
70+put Tctag i xor get Tctag i v
71+tvcheck not tcopen len Vplain 12 5
72+tvcipher
73+put Tctag i xor get Tctag i v
74+end
75+end
76+for i ulong 12
77+put Tcaad i xor get Tcaad i 1
78+tvcheck not tcopen len Vplain 12 6
79+tvcipher
80+put Tcaad i xor get Tcaad i 1
81+end
82+for i ulong 12
83+put Tciv i xor get Tciv i 1
84+tvcheck not tcopen len Vplain 12 7
85+tvcipher
86+put Tciv i xor get Tciv i 1
87+end
88+for i ulong 32
89+put Tckey i xor get Tckey i 1
90+tvcheck not tcopen len Vplain 12 8
91+tvcipher
92+put Tckey i xor get Tckey i 1
93+end
94+for i ulong len Vplain
95+put Tcbuf i xor get Tcbuf i 1
96+tvcheck not tcopen len Vplain 12 9
97+put Tcbuf i xor get Tcbuf i 1
98+tvcipher
99+end
100+tvcheck not tcopen sub len Vplain 1 12 10
101+tvcipher
102+tvcheck not tcopen len Vplain 11 11
103+tvcipher
104+tvcheck not tcopen 65537 12 12
105+tvcipher
106+tvcheck not tcopen len Vplain 33 12
107+tvcipher
108+tvcheck not tcopen 18446744073709551615 0 12
109+tvcipher
110+tvcheck not tcseal 65537 12 13
111+tvcipher
112+tvcheck not tcseal len Vplain 33 13
113+tvcipher
114+for i ulong 16
115+p = mul i 2
116+put Tctag i tvbyte get Vtag p get Vtag add p 1
117+end
118+end
119+
120+fn tvround n ulong aadlen ulong to void
121+tcwipe
122+for i ulong 32
123+put Tckey i uchar i
124+put Tcaad i uchar add i 32
125+end
126+note Unique deterministic fixture nonce per length/AAD combination; not production randomness.
127+put Tciv 0 uchar and n 255
128+put Tciv 1 uchar and shr n 8 255
129+put Tciv 2 uchar and shr n 16 255
130+put Tciv 3 uchar aadlen
131+for i ulong n
132+put Tcbuf i uchar and i 255
133+end
134+if lt n 65536
135+put Tcbuf n 233
136+end
137+tvcheck tcseal n aadlen 30
138+tvscrub
139+tvcheck tcopen n aadlen 31
140+tvscrub
141+for i ulong n
142+tvcheck eq get Tcbuf i uchar and i 255 32
143+end
144+if lt n 65536
145+tvcheck eq get Tcbuf n 233 33
146+end
147+end
148+
149+fn main to int
150+tvblock
151+tvsetup
152+tvcheck tcseal len Vplain 12 14
153+tvcipher
154+tvtag
155+tvbad
156+tvcheck tcopen len Vplain 12 15
157+for i ulong len Vplain
158+tvcheck eq get Tcbuf i get Vplain i 16
159+end
160+tvscrub
161+tvround 0 0
162+tvround 1 1
163+tvround 15 15
164+tvround 16 16
165+tvround 17 17
166+tvround 63 31
167+tvround 64 32
168+tvround 65 0
169+tvround 65536 32
170+tcwipe
171+tvscrub
172+for i ulong 65536
173+tvcheck eq get Tcbuf i 0 34
174+end
175+for i ulong 32
176+tvcheck eq get Tckey i 0 35
177+end
178+ret 0
179+end

aienux/allen/tests/tls-crypto-fixture.om

new file mode 100644
@@ -0,0 +1,82 @@
1+note SPDX-License-Identifier: AGPL-3.0-or-later
2+note Shared fixture support, concatenate before exactly one tls-crypto-{sha,x25519,aead,poly}.om.
3+note RFC vectors: RFC4231 M.Nystrom (2005 Internet Society), RFC5869 H.Krawczyk/P.Eronen,
4+note RFC7748 A.Langley/M.Hamburg/S.Turner, RFC8439 Y.Nir/A.Langley.
5+note RFC5869/7748/8439 Copyright (c) 2010/2016/2018 IETF Trust and identified authors.
6+note All rights reserved. Source URLs are included in the individual fixtures.
7+note RFC Code Components carry the IETF Trust Simplified BSD License:
8+note Redistribution and use in source and binary forms, with or without modification, are
9+note permitted provided that the following conditions are met:
10+note 1. Redistributions of source code must retain the above copyright notice, this list of
11+note conditions and the following disclaimer.
12+note 2. Redistributions in binary form must reproduce the above copyright notice, this list of
13+note conditions and the following disclaimer in the documentation and/or other materials
14+note provided with the distribution.
15+note THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
16+note EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
17+note MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
18+note THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
19+note SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
20+note OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21+note HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
22+note OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
23+note SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
24+note This harness is first-party Omega. No fixture executes external code or substitutes runtime bytes.
25+
26+fn tvcheck ok bool code int to void
27+if not ok
28+exit code
29+end
30+end
31+
32+fn tvnib c uchar to uchar
33+if and ge c 48 le c 57
34+ret sub c 48
35+end
36+if and ge c 97 le c 102
37+ret sub c 87
38+end
39+tvcheck false 99
40+ret 0
41+end
42+
43+fn tvbyte a uchar b uchar to uchar
44+ret or shl tvnib a 4 tvnib b
45+end
46+
47+fn tvscrub to void
48+for i ulong 8
49+tvcheck eq get H i 0 91
50+tvcheck eq get Vv i 0 91
51+end
52+for i ulong 64
53+tvcheck eq get W i 0 91
54+tvcheck eq get Hb i 0 91
55+tvcheck eq get Tccblk i 0 92
56+end
57+for i ulong 32
58+tvcheck eq get Tchi i 0 91
59+tvcheck eq get Hash i 0 91
60+tvcheck eq get Tcxsc i 0 93
61+tvcheck eq get Tcxres i 0 93
62+tvcheck eq get Tcxt i 0 93
63+tvcheck eq get Tcmkey i 0 92
64+end
65+for i ulong 176
66+tvcheck eq get Tcxf i 0 93
67+end
68+for i ulong 16
69+tvcheck eq get Tccs i 0 92
70+tvcheck eq get Tccw i 0 92
71+tvcheck eq get Tcmblk i 0 92
72+tvcheck eq get Tcmtag i 0 92
73+end
74+for i ulong 10
75+tvcheck eq get Tcmr i 0 92
76+tvcheck eq get Tcmh i 0 92
77+tvcheck eq get Tcmt i 0 92
78+tvcheck eq get Tcmg i 0 92
79+end
80+tvcheck eq get Hs 0 0 91
81+tvcheck eq get Hs 1 0 91
82+end

aienux/allen/tests/tls-crypto-poly.om

new file mode 100644
@@ -0,0 +1,133 @@
1+note SPDX-License-Identifier: AGPL-3.0-or-later
2+note RFC8439 section2.5.2 and Appendix A.3 vectors1,5,6,7,8,9,10,11.
3+note https://www.rfc-editor.org/rfc/rfc8439 ; attribution/license in tls-crypto-fixture.om.
4+note Internal primitive entry points are used to isolate reduction and final-pad carry bugs.
5+text Vpk "85d6be7857556d337f4452fe42d506a80103808afb0db2fd4abff6af4149f51b"
6+text Vpm "Cryptographic Forum Research Group"
7+text Vpt "a8061dc1305136c6c22b8baf0c0127a9"
8+text Vred "e33594d7505e43b900000000000000003394d7505e4379cd0100000000000000"
9+
10+fn tvpoly n ulong to void
11+tcminit
12+p = ulong 0
13+while lt p n bound 4
14+m = sub n p
15+if gt m 16
16+m = 16
17+end
18+for i ulong m
19+put Tcmblk i get Tcbuf add p i
20+end
21+tcmblock m
22+p = add p m
23+end
24+tcmfinish
25+end
26+
27+fn tvsmall first uchar to void
28+tvcheck eq get Tcmtag 0 first 40
29+for i ulong 15
30+tvcheck eq get Tcmtag add i 1 0 41
31+end
32+tccwipe
33+tvscrub
34+end
35+
36+fn tvreduce last bool to void
37+tcwipe
38+put Tcmkey 0 1
39+put Tcmkey 8 4
40+for i ulong 32
41+p = mul i 2
42+put Tcbuf i tvbyte get Vred p get Vred add p 1
43+end
44+if last
45+put Tcbuf 48 1
46+tvpoly 64
47+tvcheck eq get Tcmtag 0 20 50
48+tvcheck eq get Tcmtag 8 85 51
49+for i ulong 16
50+if and ne i 0 ne i 8
51+tvcheck eq get Tcmtag i 0 52
52+end
53+end
54+else
55+tvpoly 48
56+tvsmall 19
57+end
58+end
59+
60+fn main to int
61+tcwipe
62+for i ulong 32
63+p = mul i 2
64+put Tcmkey i tvbyte get Vpk p get Vpk add p 1
65+end
66+for i ulong len Vpm
67+put Tcbuf i get Vpm i
68+end
69+tvpoly len Vpm
70+for i ulong 16
71+p = mul i 2
72+v = tvbyte get Vpt p get Vpt add p 1
73+tvcheck eq get Tcmtag i v 1
74+end
75+tcwipe
76+tvpoly 64
77+tvsmall 0
78+note Appendix A.3 vector5: final 130-bit partial reduction.
79+tcwipe
80+put Tcmkey 0 2
81+for i ulong 16
82+put Tcbuf i 255
83+end
84+tvpoly 16
85+tvsmall 3
86+note Vector6: addition of pad overflows modulo2^128.
87+tcwipe
88+put Tcmkey 0 2
89+for i ulong 16
90+put Tcmkey add i 16 255
91+end
92+put Tcbuf 0 2
93+tvpoly 16
94+tvsmall 3
95+note Vector7: all-ones limbs with a carry.
96+tcwipe
97+put Tcmkey 0 1
98+for i ulong 32
99+put Tcbuf i 255
100+end
101+put Tcbuf 16 240
102+put Tcbuf 32 17
103+tvpoly 48
104+tvsmall 5
105+note Vector8: accumulator exactly p must encode0.
106+tcwipe
107+put Tcmkey 0 1
108+for i ulong 16
109+put Tcbuf i 255
110+put Tcbuf add i 16 254
111+put Tcbuf add i 32 1
112+end
113+put Tcbuf 16 251
114+tvpoly 48
115+tvsmall 0
116+note Vector9: accumulator exactly p-1 must not reduce to0.
117+tcwipe
118+put Tcmkey 0 2
119+for i ulong 16
120+put Tcbuf i 255
121+end
122+put Tcbuf 0 253
123+tvpoly 16
124+tvcheck eq get Tcmtag 0 250 60
125+for i ulong 15
126+tvcheck eq get Tcmtag add i 1 255 61
127+end
128+tvreduce true
129+tvreduce false
130+tcwipe
131+tvscrub
132+ret 0
133+end

aienux/allen/tests/tls-crypto-sha.om

new file mode 100644
@@ -0,0 +1,158 @@
1+note SPDX-License-Identifier: AGPL-3.0-or-later
2+note SHA256 empty/abc/56-byte standard FIPS180-4 examples; RFC4231 sections4.2..4.5 HMAC.
3+note HKDF RFC5869 Appendix A.1/A.3 extract and both expand blocks via public HMAC API.
4+note https://www.rfc-editor.org/rfc/rfc4231 https://www.rfc-editor.org/rfc/rfc5869
5+note Attribution/license in required tls-crypto-fixture.om. Return0 means every assertion matched.
6+text Vhash "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad248d6a61d20638b8e5c026930c3e6039a33ce45964ff2167f6ecedd419db06c1b0344c61d8db38535ca8afceaf0bf12b881dc200c9833da726e9376c2e32cff75bdcc146bf60754e6a042426089575c75a003f089d2739839dec58b964ec3843773ea91e36800e46854db8ebd09181a72959098b3ef8c122d9635514ced565fe82558a389a443c0ea4cc819899f2083a85f0faa3e578f8077a2e3ff46729665b077709362c2e32df0ddc3f0dc47bba6390b6c73bb50f9c3122ec844ad7c2b3e519ef24a32c717b167f33a91d6f648bdf96596776afdb6377ac434c1c293ccb04"
7+text Vokm "3cb25f25faacd57a90434f64d0362f2a2d2d0a90cf1a5a4c5db02d56ecc4c5bf34007208d5b8871858658da4e775a563c18f715f802a063c5a31b8a11f5c5ee1879ec3454e5f3c738d2d9d201395faa4b61a96c8"
8+text Vabc "abc"
9+text Vlong "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq"
10+text Vhi "Hi There"
11+text Vjefe "Jefe"
12+text Vwhat "what do ya want for nothing?"
13+
14+fn tvhash slot ulong to void
15+for i ulong 32
16+p = add mul slot 64 mul i 2
17+v = tvbyte get Vhash p get Vhash add p 1
18+tvcheck eq get Tcdigest i v 20
19+end
20+tvscrub
21+end
22+
23+fn tvwipe to void
24+tcwipe
25+tvscrub
26+end
27+
28+fn tvsha to void
29+tvwipe
30+tvcheck tcsha 0 1
31+tvhash 0
32+for i ulong 3
33+put Tcbuf i get Vabc i
34+end
35+put Tcbuf 3 201
36+tvcheck tcsha 3 2
37+tvhash 1
38+for i ulong 3
39+tvcheck eq get Tcbuf i get Vabc i 3
40+end
41+tvcheck eq get Tcbuf 3 201 3
42+for i ulong len Vlong
43+put Tcbuf i get Vlong i
44+end
45+tvcheck tcsha len Vlong 4
46+tvhash 2
47+tvcheck not tcsha 65537 5
48+for i ulong 32
49+tvcheck eq get Tcdigest i 0 5
50+end
51+tvcheck not tcsha 18446744073709551615 5
52+tvscrub
53+end
54+
55+fn tvhmac to void
56+tvwipe
57+for i ulong 20
58+put Tckey i 11
59+end
60+for i ulong len Vhi
61+put Tcbuf i get Vhi i
62+end
63+tvcheck tchmac 20 len Vhi 6
64+tvhash 3
65+for i ulong len Vhi
66+tvcheck eq get Tcbuf i get Vhi i 7
67+end
68+for i ulong 4
69+put Tckey i get Vjefe i
70+end
71+tvcheck tchmac 4 0 8
72+for i ulong len Vwhat
73+put Tcbuf i get Vwhat i
74+end
75+tvcheck tchmac 4 len Vwhat 9
76+tvhash 4
77+for i ulong 20
78+put Tckey i 170
79+end
80+for i ulong 50
81+put Tcbuf i 221
82+end
83+tvcheck tchmac 20 50 10
84+tvhash 5
85+for i ulong 25
86+put Tckey i uchar add i 1
87+end
88+for i ulong 50
89+put Tcbuf i 205
90+end
91+tvcheck tchmac 25 50 11
92+tvhash 6
93+tvcheck not tchmac 33 50 12
94+tvcheck not tchmac 32 65537 12
95+tvcheck not tchmac 18446744073709551615 0 12
96+for i ulong 32
97+tvcheck eq get Tcdigest i 0 13
98+end
99+tvcheck eq get Tcbuf 0 205 13
100+tvscrub
101+end
102+
103+fn tvhkdf empty bool to void
104+tvwipe
105+for i ulong 22
106+put Tcbuf i 11
107+end
108+n = ulong 13
109+z = ulong 10
110+slot = ulong 7
111+base = ulong 0
112+if empty
113+n = 0
114+z = 0
115+slot = 8
116+base = 84
117+else
118+for i ulong 13
119+put Tckey i uchar i
120+end
121+end
122+tvcheck tchmac n 22 14
123+tvhash slot
124+for i ulong 32
125+put Tckey i get Tcdigest i
126+end
127+for i ulong z
128+put Tcbuf i uchar add i 240
129+end
130+put Tcbuf z 1
131+tvcheck tchmac 32 add z 1 15
132+for i ulong 32
133+p = add base mul i 2
134+v = tvbyte get Vokm p get Vokm add p 1
135+tvcheck eq get Tcdigest i v 16
136+put Tcbuf i get Tcdigest i
137+end
138+for i ulong z
139+put Tcbuf add i 32 uchar add i 240
140+end
141+put Tcbuf add z 32 2
142+tvcheck tchmac 32 add z 33 17
143+for i ulong 10
144+p = add add base 64 mul i 2
145+v = tvbyte get Vokm p get Vokm add p 1
146+tvcheck eq get Tcdigest i v 18
147+end
148+tvscrub
149+end
150+
151+fn main to int
152+tvsha
153+tvhmac
154+tvhkdf false
155+tvhkdf true
156+tvwipe
157+ret 0
158+end

aienux/allen/tests/tls-crypto-x25519-iter.om

new file mode 100644
@@ -0,0 +1,24 @@
1+note SPDX-License-Identifier: AGPL-3.0-or-later
2+note RFC7748 section5.2 official 1000-iteration X25519 vector, separate from short fixtures.
3+note https://www.rfc-editor.org/rfc/rfc7748 ; attribution/license in tls-crypto-fixture.om.
4+text Viter "684cf59ba83309552800ef566f2f4d3c1c3887c49360e3875f2eb94d99532c51"
5+fn main to int
6+tcwipe
7+put Tcxpriv 0 9
8+put Tcxpeer 0 9
9+for j ulong 1000
10+tvcheck tcx25519 1
11+for i ulong 32
12+put Tcxpeer i get Tcxpriv i
13+put Tcxpriv i get Tcxshare i
14+end
15+end
16+for i ulong 32
17+p = mul i 2
18+v = tvbyte get Viter p get Viter add p 1
19+tvcheck eq get Tcxpriv i v 2
20+end
21+tcwipe
22+tvscrub
23+ret 0
24+end

aienux/allen/tests/tls-crypto-x25519.om

new file mode 100644
@@ -0,0 +1,106 @@
1+note SPDX-License-Identifier: AGPL-3.0-or-later
2+note RFC7748 sections5.2/6.1 official scalar/u/public/shared vectors.
3+note https://www.rfc-editor.org/rfc/rfc7748 ; attribution/license in tls-crypto-fixture.om.
4+note Negative/metamorphic cases exercise specified clamping, top-bit masking, noncanonical input,
5+note small-order rejection, preserved input buffers, and cleared internal scalar/field scratch.
6+text Vs "a546e36bf0527c9d3b16154b82465edd62144c0ac1fc5a18506a2244ba449ac44b66e9d4d1b4673c5ad22691957d6af5c11b6421e0ea01d42ca4169e7918ba0d77076d0a7318a57d3c16c17251b26645df4c2f87ebc0992ab177fba51db92c2a5dab087e624a8a4b79e17f8b83800ee66f3bb1292618b6fd1c2f8b27ff88e0eb"
7+text Vu "e6db6867583030db3594c1a424b15f7c726624ec26b3353b10a903a6d0ab1c4ce5210f12786811d3f4b7959d0538ae2c31dbe7106fc03c3efc4cd549c715a4938520f0098930a754748b7ddcb43ef75a0dbf3a0d26381af4eba4a98eaa9b4e6ade9edb7d7b7dc1b4d35b61c2ece435373f8343c85b78674dadfc7e146f882b4f"
8+text Vx "c3da55379de9c6908e94ea4df28d084f32eccf03491c71f754b4075577a2855295cbde9476e8907d7aade45cb4b873f88b595a68799fa152e6f8f7647aac79574a5d9d5ba4ce2de1728e3bf480350f25e07e21c947d19e3376f09b3c1e161742422c8e7a6227d7bca1350b3e2bb7279f7897b87bb6854b783c60e80311ae3079"
9+
10+fn tvxload slot ulong peer ulong to void
11+for i ulong 32
12+p = add mul slot 64 mul i 2
13+put Tcxpriv i tvbyte get Vs p get Vs add p 1
14+p = add mul peer 64 mul i 2
15+put Tcxpeer i tvbyte get Vu p get Vu add p 1
16+end
17+end
18+
19+fn tvxwant slot ulong to void
20+for i ulong 32
21+p = add mul slot 64 mul i 2
22+v = tvbyte get Vx p get Vx add p 1
23+tvcheck eq get Tcxshare i v 10
24+end
25+tvscrub
26+end
27+
28+fn tvxpub slot ulong to void
29+for i ulong 32
30+p = add mul slot 64 mul i 2
31+v = tvbyte get Vu p get Vu add p 1
32+tvcheck eq get Tcxpub i v 11
33+p = add mul slot 64 mul i 2
34+v = tvbyte get Vs p get Vs add p 1
35+tvcheck eq get Tcxpriv i v 12
36+end
37+tvscrub
38+end
39+
40+fn tvxzero to void
41+tvcheck not tcx25519 20
42+for i ulong 32
43+tvcheck eq get Tcxshare i 0 21
44+end
45+tvscrub
46+end
47+
48+fn main to int
49+tcwipe
50+tvxload 0 0
51+tvcheck tcx25519 1
52+tvxwant 0
53+put Tcxpeer 31 xor get Tcxpeer 31 128
54+tvcheck tcx25519 2
55+tvxwant 0
56+put Tcxpriv 0 xor get Tcxpriv 0 7
57+put Tcxpriv 31 xor get Tcxpriv 31 192
58+tvcheck tcx25519 3
59+tvxwant 0
60+tvxload 1 1
61+tvcheck tcx25519 4
62+tvxwant 1
63+tvxload 2 3
64+tvcheck tcxpublic 5
65+tvxpub 2
66+tvcheck tcx25519 6
67+tvxwant 2
68+tvxload 3 2
69+tvcheck tcxpublic 7
70+tvxpub 3
71+tvcheck tcx25519 8
72+tvxwant 2
73+for i ulong 32
74+put Tcxpeer i 0
75+end
76+tvxzero
77+put Tcxpeer 0 1
78+tvxzero
79+note p and p+1 are noncanonical encodings of small-order u=0 and u=1.
80+for i ulong 32
81+put Tcxpeer i 255
82+end
83+put Tcxpeer 31 127
84+put Tcxpeer 0 237
85+tvxzero
86+put Tcxpeer 0 238
87+tvxzero
88+note p+9 is a valid noncanonical encoding of the base point u=9.
89+put Tcxpeer 0 246
90+tvcheck tcx25519 22
91+for i ulong 32
92+tvcheck eq get Tcxshare i get Tcxpub i 23
93+end
94+tcwipe
95+put Tcxpriv 0 9
96+put Tcxpeer 0 9
97+tvcheck tcx25519 24
98+tvxwant 3
99+tcwipe
100+tvscrub
101+for i ulong 32
102+tvcheck eq get Tcxshare i 0 25
103+tvcheck eq get Tcxpriv i 0 25
104+end
105+ret 0
106+end

aienux/allen/tests/tls-session-records.om

new file mode 100644
@@ -0,0 +1,256 @@
1+note Independent protocol construction per RFC8446 sections5,6; real AEAD, no substituted APIs.
2+note These isolate record/lifecycle logic with provisioned epoch keys, not certificate authentication.
3+global Vrec uchar 1024
4+global Vhold uchar 256
5+global Vn ulong 1
6+fn vreset to void
7+tsclear
8+put Tlsstate 0 2
9+put Tsctl 6 5
10+for i ulong 32
11+put Tskey add i 96 uchar i
12+put Tskey add i 64 uchar add i 64
13+end
14+for i ulong 12
15+put Tsiv add i 36 uchar add i 32
16+put Tsiv add i 24 uchar add i 48
17+end
18+end
19+note Encode server wire independently of tsseal/tsnonce; Tcbuf content supplied by fixture.
20+fn vrecord off ulong n ulong typ uchar seq ulong to bool
21+for i ulong 32
22+put Tckey i uchar i
23+end
24+for i ulong 12
25+put Tciv i uchar add i 32
26+end
27+for i ulong 8
28+p = sub ulong 11 i
29+b = uchar and shr seq mul i 8 255
30+put Tciv p xor get Tciv p b
31+end
32+put Tcbuf n typ
33+put Tcaad 0 23
34+put Tcaad 1 3
35+put Tcaad 2 3
36+put Tcaad 3 uchar shr add n 17 8
37+put Tcaad 4 uchar and add n 17 255
38+if not tcseal add n 1 5
39+ret false
40+end
41+for i ulong 5
42+put Vrec add off i get Tcaad i
43+end
44+for i ulong add n 1
45+put Vrec add add off 5 i get Tcbuf i
46+end
47+for i ulong 16
48+p = add add off n 6
49+put Vrec add p i get Tctag i
50+end
51+put Vn 0 add add off n 22
52+ret true
53+end
54+fn vfeed off ulong n ulong to void
55+for i ulong n
56+put Tlsin i get Vrec add off i
57+end
58+tlsinput n
59+end
60+fn vabc to void
61+put Tcbuf 0 97
62+put Tcbuf 1 98
63+put Tcbuf 2 99
64+end
65+fn main to int
66+vreset
67+vabc
68+if not vrecord 0 3 23 0
69+ret 1
70+end
71+for cut ulong 26
72+vreset
73+vfeed 0 cut
74+if lt cut 25
75+if ne get Tlsappn 0 0
76+ret 2
77+end
78+end
79+vfeed cut sub ulong 25 cut
80+if or ne get Tlsstate 0 2 ne get Tlsappn 0 3
81+ret 3
82+end
83+if or ne get Tlsapp 0 97 ne get Tlsapp 2 99
84+ret 4
85+end
86+tlsconsume 2
87+if or ne get Tlsappn 0 1 ne get Tlsapp 0 99
88+ret 5
89+end
90+if ne get Tlsapp 2 0
91+ret 6
92+end
93+end
94+note Coalesced records have independent sequence nonces and accumulate application data.
95+vreset
96+vabc
97+if not vrecord 0 3 23 0
98+ret 7
99+end
100+put Tcbuf 0 100
101+put Tcbuf 1 101
102+if not vrecord 25 2 23 1
103+ret 8
104+end
105+vfeed 0 get Vn 0
106+if or ne get Tlsappn 0 5 ne get Tlsapp 4 101
107+ret 9
108+end
109+note Tampered tag exposes no plaintext and wipes previously queued authenticated bytes too.
110+vreset
111+put Vrec 24 xor get Vrec 24 1
112+vfeed 0 25
113+if or ne get Tlsstate 0 4 ne get Tlsstate 1 6
114+ret 10
115+end
116+if ne get Tlsappn 0 0
117+ret 11
118+end
119+for i ulong 128
120+if ne get Tskey i 0
121+ret 12
122+end
123+end
124+note A fragmented handshake cannot be interleaved with application data.
125+vreset
126+put Tcbuf 0 4
127+put Tcbuf 1 0
128+if not vrecord 0 2 22 0
129+ret 13
130+end
131+vabc
132+if not vrecord 24 3 23 1
133+ret 14
134+end
135+vfeed 0 get Vn 0
136+if or ne get Tlsstate 0 4 ne get Tlsstate 1 5
137+ret 15
138+end
139+note Valid NewSessionTicket split across two records is discarded without resumption.
140+vreset
141+for i ulong 8
142+put Tcbuf i 0
143+end
144+put Tcbuf 0 4
145+put Tcbuf 3 14
146+put Tcbuf 7 1
147+if not vrecord 0 8 22 0
148+ret 16
149+end
150+for i ulong 10
151+put Tcbuf i 0
152+end
153+put Tcbuf 6 1
154+put Tcbuf 7 99
155+if not vrecord 30 10 22 1
156+ret 17
157+end
158+vabc
159+if not vrecord 62 3 23 2
160+ret 18
161+end
162+vfeed 0 get Vn 0
163+if or ne get Tlsstate 0 2 ne get Tlsappn 0 3
164+ret 19
165+end
166+if ne get Tsctl 1 0
167+ret 20
168+end
169+note KeyUpdate is explicitly refused, never interpreted under stale keys.
170+vreset
171+put Tcbuf 0 24
172+put Tcbuf 1 0
173+put Tcbuf 2 0
174+put Tcbuf 3 1
175+put Tcbuf 4 0
176+if not vrecord 0 5 22 0
177+ret 21
178+end
179+vfeed 0 get Vn 0
180+if or ne get Tlsstate 0 4 ne get Tlsstate 1 17
181+ret 22
182+end
183+note Inner zero padding is removed; an all-zero inner plaintext has no type and is refused.
184+vreset
185+vabc
186+put Tcbuf 3 23
187+put Tcbuf 4 0
188+if not vrecord 0 5 0 0
189+ret 33
190+end
191+vfeed 0 get Vn 0
192+if or ne get Tlsstate 0 2 ne get Tlsappn 0 3
193+ret 34
194+end
195+vreset
196+for i ulong 3
197+put Tcbuf i 0
198+end
199+if not vrecord 0 3 0 0
200+ret 35
201+end
202+vfeed 0 get Vn 0
203+if or ne get Tlsstate 0 4 ne get Tlsstate 1 5
204+ret 36
205+end
206+note Authenticated close_notify, unlike transport EOF, sets cleanClose and queues response.
207+vreset
208+put Tcbuf 0 1
209+put Tcbuf 1 0
210+if not vrecord 0 2 21 0
211+ret 23
212+end
213+vfeed 0 get Vn 0
214+if or ne get Tlsstate 0 3 ne get Tlsstate 2 1
215+ret 24
216+end
217+if ne get Tlsoutn 0 24
218+ret 25
219+end
220+note New writes and close requests do not overwrite an undelivered record.
221+vreset
222+put Tlsplain 0 65
223+if not tlswrite 1
224+ret 26
225+end
226+for i ulong get Tlsoutn 0
227+put Vhold i get Tlsout i
228+end
229+put Tlsplain 0 66
230+if tlswrite 1
231+ret 27
232+end
233+tlsclose
234+if ne get Tlsoutn 0 23
235+ret 28
236+end
237+for i ulong 23
238+if ne get Tlsout i get Vhold i
239+ret 29
240+end
241+end
242+tlssent
243+if or ne get Tlsoutn 0 24 ne get Tlsstate 2 0
244+ret 30
245+end
246+note Sequence use is refused before overflow; no nonce wraps.
247+vreset
248+put Tsseq 0 4294967295
249+if tlswrite 0
250+ret 31
251+end
252+if or ne get Tlsstate 0 4 ne get Tlsstate 1 13
253+ret 32
254+end
255+ret 0
256+end

aienux/allen/tests/tls-session-schedule.om

new file mode 100644
@@ -0,0 +1,128 @@
1+note RFC8448 section3 independent published SHA256 schedule values.
2+note Concatenate production crypto, cert, tls modules then this fixture. No replacement APIs.
3+note RFC trace suite1301 uses the same SHA256 schedule; only its 12-byte IV is checked here.
4+text Vhs "1dc826e93606aa6fdc0aadc12f741b01046aa6b99f691ed221a9f0ca043fbeac"
5+text Vhash "860c06edc07858ee8e78f0e7428c58edd6b43f2ca3e6e95f02ed063cf0e1cad8"
6+text Vchs "b3eddb126e067f35a780b3abf45e2d8f3b1a950738f52e9600746a0e27a55a21"
7+text Vshs "b67b7d690cc16c4e75e54213cb2d37b4e9c912bcded9105d42befd59d391ad38"
8+text Vder "43de77e0c77713859a944db9db2590b53190a65b3ee2e4f12dd7a0bb7ce254b4"
9+text Vmaster "18df06843d13a08bf2a449844c5f8a478001bc4d4c627984d5a41da8d0402919"
10+text Vfkey "008d3b66f816ea559f96b537e885c31fc068bf492c652f01f288a1d8cdc19fc8"
11+text Vempty "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"
12+text Viv "5d313eb2671276ee13000b30"
13+fn vhex c uchar to uchar
14+if le c 57
15+ret sub c 48
16+end
17+ret add sub c 97 10
18+end
19+fn main to int
20+tsclear
21+for i ulong 32
22+p = mul i 2
23+put Tssec i or shl vhex get Vhs p 4 vhex get Vhs add p 1
24+put Tshash i or shl vhex get Vhash p 4 vhex get Vhash add p 1
25+end
26+if not tsexpand 1 0 true 32
27+ret 1
28+end
29+for i ulong 32
30+p = mul i 2
31+b = or shl vhex get Vchs p 4 vhex get Vchs add p 1
32+if ne get Tcdigest i b
33+ret 2
34+end
35+end
36+if not tsexpand 2 0 true 32
37+ret 3
38+end
39+for i ulong 32
40+p = mul i 2
41+b = or shl vhex get Vshs p 4 vhex get Vshs add p 1
42+if ne get Tcdigest i b
43+ret 4
44+end
45+put Tssec add i 64 b
46+end
47+if not tsexpand 6 64 false 12
48+ret 5
49+end
50+for i ulong 12
51+p = mul i 2
52+b = or shl vhex get Viv p 4 vhex get Viv add p 1
53+if ne get Tcdigest i b
54+ret 6
55+end
56+end
57+if not tsexpand 7 64 false 32
58+ret 7
59+end
60+for i ulong 32
61+p = mul i 2
62+b = or shl vhex get Vfkey p 4 vhex get Vfkey add p 1
63+if ne get Tcdigest i b
64+ret 8
65+end
66+end
67+if not tsempty
68+ret 9
69+end
70+for i ulong 32
71+p = mul i 2
72+b = or shl vhex get Vempty p 4 vhex get Vempty add p 1
73+if ne get Tshash i b
74+ret 10
75+end
76+end
77+if not tsexpand 0 0 true 32
78+ret 11
79+end
80+for i ulong 32
81+p = mul i 2
82+b = or shl vhex get Vder p 4 vhex get Vder add p 1
83+if ne get Tcdigest i b
84+ret 12
85+end
86+put Tckey i get Tcdigest i
87+put Tcbuf i 0
88+end
89+if not tchmac 32 32
90+ret 13
91+end
92+for i ulong 32
93+p = mul i 2
94+b = or shl vhex get Vmaster p 4 vhex get Vmaster add p 1
95+if ne get Tcdigest i b
96+ret 14
97+end
98+end
99+note RFC8446 section5.3 sequence is big endian, left-padded to IV length, XOR.
100+for i ulong 12
101+put Tsiv i uchar i
102+end
103+tsnonce 0 0 72623859790382856
104+for i ulong 4
105+if ne get Tciv i uchar i
106+ret 15
107+end
108+end
109+for i ulong 8
110+b = xor uchar add i 4 uchar add i 1
111+if ne get Tciv add i 4 b
112+ret 16
113+end
114+end
115+if tsexpand 5 0 false 33
116+ret 17
117+end
118+if tsexpand 5 0 false 0
119+ret 18
120+end
121+tswipe
122+for i ulong 192
123+if ne get Tssec i 0
124+ret 19
125+end
126+end
127+ret 0
128+end

aienux/allen/tests/view.om

new file mode 100644
@@ -0,0 +1,25 @@
1+text Vtext "one two three\nfour\n\nfive"
2+fn main to int
3+codebeg 1
4+put C 1 1
5+put C 2 len Vtext
6+put C 4 1
7+for i ulong len Vtext
8+put Code i get Vtext i
9+end
10+put C 3 ulong codecrc
11+check rows 8 4096 901
12+check eq get View 0 5 902
13+check eq get Rowlen 0 8 903
14+check eq get Rowlen 1 5 904
15+check eq get Rowline 0 1 905
16+check eq get Rowline 1 0 906
17+check eq get Rowline 2 2 907
18+check eq get Rowlen 3 0 908
19+check eq scroll 100 2 3 909
20+check eq scroll -1 2 2 910
21+check eq scroll -99 2 0 911
22+check not rows 0 4096 912
23+check eq get View 0 5 913
24+ret int get Fails 0
25+end

aienux/allen/tls-cert.om

new file mode 100644
@@ -0,0 +1,1299 @@
1+note SPDX-License-Identifier: Apache-2.0
2+note Bounded X509/TLS1.3 verifier for api.github.com; RFC5280,5480,5758,8446,9525.
3+note Supports uncompressed named P256/P384 and ECDSA-SHA256/P256 or ECDSA-SHA384/P384.
4+note No AIA, CRL/OCSP fetching, RSA, SHA1, explicit curves, policy/name constraints or fallback.
5+note Unsupported critical extensions and constrained CA paths fail closed, even if noncritical.
6+note Up to8 peer certificates, each <=8192 bytes, TLS body <=60000,32 extensions/certificate.
7+note Exact DER issuer/subject matching is deliberately conservative; no ambiguous normalization.
8+note Trust anchor is the local OS Sectigo Public Server Authentication Root E46 certificate.
9+note Source /etc/ssl/certs/Sectigo_Public_Server_Authentication_Root_E46.pem, read2026-10-25.
10+note DER SHA256 C90F26F0FB1B4018B22227519B5CA2B53E2CA5B3BE5CF18EFE1BEF47380C5383.
11+note Trust is in this root, never in a downloaded self-signed or leaf certificate.
12+note Root cross-signatures need not validate: path terminates at the locally trusted subject/key.
13+note Caller must supply trustworthy current Unix seconds. No network time or zero-time bypass.
14+global Certbuf uchar 65536
15+global Certlen ulong 1
16+global Certnow ulong 1
17+global Certkey uchar 65
18+global Cleaf uchar 65
19+global Certmsg uchar 4096
20+global Certsig uchar 128
21+global Cready ulong 1
22+global Cd ulong 4
23+global Cm ulong 288
24+global Ce ulong 64
25+global Cen ulong 1
26+global Ckey uchar 97
27+global Csig uchar 96
28+global Chash uchar 48
29+global Ctime ulong 8
30+global Cchain ulong 8
31+global Ccount ulong 1
32+text Chost "api.github.com"
33+text Cwild "*.github.com"
34+
35+note Cd: tag,value-start,end. Definite minimal DER only, bounds checked before every access.
36+fn ctder p ulong e ulong to bool
37+if or gt e 65536 ge p e
38+ret false
39+end
40+if lt sub e p 2
41+ret false
42+end
43+t = get Certbuf p
44+if or eq and t 31 31 eq t 0
45+ret false
46+end
47+p = add p 1
48+n = ulong get Certbuf p
49+p = add p 1
50+if ge n 128
51+k = sub n 128
52+if or eq k 0 gt k 3
53+ret false
54+end
55+if gt k sub e p
56+ret false
57+end
58+if eq get Certbuf p 0
59+ret false
60+end
61+n = 0
62+for j ulong k
63+n = or shl n 8 ulong get Certbuf add p j
64+end
65+p = add p k
66+if lt n 128
67+ret false
68+end
69+end
70+if gt n sub e p
71+ret false
72+end
73+put Cd 0 ulong t
74+put Cd 1 p
75+put Cd 2 add p n
76+ret true
77+end
78+
79+fn cttake p ulong e ulong t ulong to bool
80+if not ctder p e
81+ret false
82+end
83+ret eq get Cd 0 t
84+end
85+
86+fn ctequal a ulong ae ulong b ulong be ulong to bool
87+if ne sub ae a sub be b
88+ret false
89+end
90+x = uchar 0
91+for i ulong sub ae a
92+u = get Certbuf add a i
93+v = get Certbuf add b i
94+x = or x xor u v
95+end
96+ret eq x 0
97+end
98+
99+note Minimal nonnegative DER INTEGER; zero optionally allowed by caller.
100+fn ctint p ulong e ulong to bool
101+if ge p e
102+ret false
103+end
104+if ge get Certbuf p 128
105+ret false
106+end
107+if gt sub e p 1
108+if eq get Certbuf p 0
109+if lt get Certbuf add p 1 128
110+ret false
111+end
112+end
113+end
114+ret true
115+end
116+
117+note OIDs are canonical base128 subidentifiers; max32 octets in this bounded profile.
118+fn ctoid p ulong e ulong to bool
119+if or ge p e gt sub e p 32
120+ret false
121+end
122+fresh = true
123+for i ulong sub e p
124+c = get Certbuf add p i
125+if and fresh eq c 128
126+ret false
127+end
128+fresh = eq and c 128 0
129+end
130+ret fresh
131+end
132+
133+fn ctnum p ulong n ulong to ulong
134+v = ulong 0
135+for i ulong n
136+c = get Certbuf add p i
137+if or lt c 48 gt c 57
138+ret 10000
139+end
140+v = add mul v 10 sub ulong c 48
141+end
142+ret v
143+end
144+
145+fn ctleap y ulong to bool
146+ret and eq rem y 4 0 or ne rem y 100 0 eq rem y 400 0
147+end
148+
149+fn ctmonth y ulong m ulong to ulong
150+if eq m 2
151+if ctleap y
152+ret 29
153+end
154+ret 28
155+end
156+if or or eq m 4 eq m 6 or eq m 9 eq m 11
157+ret 30
158+end
159+ret 31
160+end
161+
162+note Absolute Gregorian seconds since 0001-01-01 avoids negative Unix conversions.
163+fn cttime p ulong e ulong to bool
164+if not ctder p e
165+ret false
166+end
167+p = get Cd 1
168+n = sub get Cd 2 p
169+y = ulong 0
170+if eq get Cd 0 23
171+if ne n 13
172+ret false
173+end
174+y = ctnum p 2
175+if gt y 99
176+ret false
177+end
178+if lt y 50
179+y = add y 2000
180+else
181+y = add y 1900
182+end
183+p = add p 2
184+else
185+if ne get Cd 0 24
186+ret false
187+end
188+if ne n 15
189+ret false
190+end
191+y = ctnum p 4
192+if or lt y 2050 gt y 9999
193+ret false
194+end
195+p = add p 4
196+end
197+if ne get Certbuf add p 10 90
198+ret false
199+end
200+put Ctime 0 y
201+for i ulong 5
202+put Ctime add i 1 ctnum add p mul i 2 2
203+end
204+ret true
205+end
206+
207+fn ctepoch to ulong
208+y = get Ctime 0
209+m = get Ctime 1
210+d = get Ctime 2
211+if or lt m 1 gt m 12
212+ret 0
213+end
214+if or lt d 1 gt d ctmonth y m
215+ret 0
216+end
217+if gt get Ctime 3 23
218+ret 0
219+end
220+if gt get Ctime 4 59
221+ret 0
222+end
223+if gt get Ctime 5 59
224+ret 0
225+end
226+y = sub y 1
227+days = add mul y 365 div y 4
228+days = sub days div y 100
229+days = add days div y 400
230+y = add y 1
231+for i ulong sub m 1
232+days = add days ctmonth y add i 1
233+end
234+days = add days sub d 1
235+v = add mul days 24 get Ctime 3
236+v = add mul v 60 get Ctime 4
237+ret add mul v 60 get Ctime 5
238+end
239+
240+fn ctvalid b ulong p ulong e ulong to bool
241+if not cttake p e 48
242+ret false
243+end
244+p = get Cd 1
245+e = get Cd 2
246+if not cttime p e
247+ret false
248+end
249+p = get Cd 2
250+put Cm add b 11 ctepoch
251+if eq get Cm add b 11 0
252+ret false
253+end
254+if not cttime p e
255+ret false
256+end
257+if ne get Cd 2 e
258+ret false
259+end
260+put Cm add b 12 ctepoch
261+ret ge get Cm add b 12 get Cm add b 11
262+end
263+
264+note Signature AlgorithmIdentifier requires absent parameters (RFC5758 section3.2).
265+fn ctalg p ulong e ulong to ulong
266+if not cttake p e 48
267+ret 0
268+end
269+p = get Cd 1
270+e = get Cd 2
271+if not cttake p e 6
272+ret 0
273+end
274+p = get Cd 1
275+if or ne get Cd 2 e ne sub e p 8
276+ret 0
277+end
278+if ne get Certbuf p 42
279+ret 0
280+end
281+if or ne get Certbuf add p 1 134 ne get Certbuf add p 2 72
282+ret 0
283+end
284+if or ne get Certbuf add p 3 206 ne get Certbuf add p 4 61
285+ret 0
286+end
287+if or ne get Certbuf add p 5 4 ne get Certbuf add p 6 3
288+ret 0
289+end
290+if eq get Certbuf add p 7 2
291+ret 32
292+end
293+if eq get Certbuf add p 7 3
294+ret 48
295+end
296+ret 0
297+end
298+
299+note Name RDN/ATV syntax is checked; supported directory strings only. Empty subject is handled by SAN.
300+fn ctattr p ulong e ulong to bool
301+if not cttake p e 6
302+ret false
303+end
304+if not ctoid get Cd 1 get Cd 2
305+ret false
306+end
307+p = get Cd 2
308+if not ctder p e
309+ret false
310+end
311+if ne get Cd 2 e
312+ret false
313+end
314+t = get Cd 0
315+if not or or eq t 12 eq t 19 or eq t 20 or eq t 22 eq t 30
316+ret false
317+end
318+ret gt get Cd 2 get Cd 1
319+end
320+
321+fn ctname p ulong e ulong to bool
322+if not cttake p e 48
323+ret false
324+end
325+p = get Cd 1
326+e = get Cd 2
327+while lt p e bound 4096
328+if not cttake p e 49
329+ret false
330+end
331+q = get Cd 1
332+r = get Cd 2
333+if eq q r
334+ret false
335+end
336+p = r
337+while lt q r bound 4096
338+if not cttake q r 48
339+ret false
340+end
341+q = get Cd 2
342+if not ctattr get Cd 1 q
343+ret false
344+end
345+end
346+end
347+ret eq p e
348+end
349+
350+note Exact ecPublicKey OID and named curves; no explicit/implicit parameters.
351+fn ctcurve p ulong e ulong to ulong
352+if not cttake p e 48
353+ret 0
354+end
355+p = get Cd 1
356+e = get Cd 2
357+if not cttake p e 6
358+ret 0
359+end
360+p = get Cd 1
361+if ne sub get Cd 2 p 7
362+ret 0
363+end
364+if or ne get Certbuf p 42 ne get Certbuf add p 1 134
365+ret 0
366+end
367+if or ne get Certbuf add p 2 72 ne get Certbuf add p 3 206
368+ret 0
369+end
370+if or ne get Certbuf add p 4 61 ne get Certbuf add p 5 2
371+ret 0
372+end
373+if ne get Certbuf add p 6 1
374+ret 0
375+end
376+p = get Cd 2
377+if not cttake p e 6
378+ret 0
379+end
380+p = get Cd 1
381+if ne get Cd 2 e
382+ret 0
383+end
384+if eq sub e p 5
385+if or ne get Certbuf p 43 ne get Certbuf add p 1 129
386+ret 0
387+end
388+if or ne get Certbuf add p 2 4 ne get Certbuf add p 3 0
389+ret 0
390+end
391+if eq get Certbuf add p 4 34
392+ret 48
393+end
394+ret 0
395+end
396+if ne sub e p 8
397+ret 0
398+end
399+if or ne get Certbuf p 42 ne get Certbuf add p 1 134
400+ret 0
401+end
402+if or ne get Certbuf add p 2 72 ne get Certbuf add p 3 206
403+ret 0
404+end
405+if or ne get Certbuf add p 4 61 ne get Certbuf add p 5 3
406+ret 0
407+end
408+if or ne get Certbuf add p 6 1 ne get Certbuf add p 7 7
409+ret 0
410+end
411+ret 32
412+end
413+
414+fn ctspki b ulong p ulong e ulong to bool
415+if not cttake p e 48
416+ret false
417+end
418+p = get Cd 1
419+e = get Cd 2
420+k = ctcurve p e
421+if eq k 0
422+ret false
423+end
424+p = get Cd 2
425+if not cttake p e 3
426+ret false
427+end
428+p = get Cd 1
429+if ne get Cd 2 e
430+ret false
431+end
432+if ne sub e p add mul k 2 2
433+ret false
434+end
435+if ne get Certbuf p 0
436+ret false
437+end
438+p = add p 1
439+if ne get Certbuf p 4
440+ret false
441+end
442+put Cm add b 7 p
443+put Cm add b 8 sub e p
444+put Cm add b 24 k
445+ret true
446+end
447+
448+note Canonical BIT STRING with at most9 defined KeyUsage bits, named-bit trailing zeros trimmed.
449+fn ctusage b ulong p ulong e ulong to bool
450+if not cttake p e 3
451+ret false
452+end
453+p = get Cd 1
454+if ne get Cd 2 e
455+ret false
456+end
457+n = sub e p
458+if or lt n 2 gt n 3
459+ret false
460+end
461+u = ulong get Certbuf p
462+if gt u 7
463+ret false
464+end
465+last = ulong get Certbuf sub e 1
466+if eq last 0
467+ret false
468+end
469+if ne and last sub shl ulong 1 u 1 0
470+ret false
471+end
472+if eq and shr last u 1 0
473+ret false
474+end
475+if eq n 3
476+if or ne u 7 ne last 128
477+ret false
478+end
479+end
480+put Cm add b 15 ulong get Certbuf add p 1
481+put Cm add b 16 1
482+ret true
483+end
484+
485+fn ctbasic b ulong p ulong e ulong crit bool to bool
486+if not cttake p e 48
487+ret false
488+end
489+p = get Cd 1
490+if ne get Cd 2 e
491+ret false
492+end
493+put Cm add b 20 1
494+if crit
495+put Cm add b 21 1
496+end
497+if eq p e
498+ret true
499+end
500+if not cttake p e 1
501+ret false
502+end
503+if ne sub get Cd 2 get Cd 1 1
504+ret false
505+end
506+if ne get Certbuf get Cd 1 255
507+ret false
508+end
509+put Cm add b 13 1
510+p = get Cd 2
511+if eq p e
512+ret true
513+end
514+if not cttake p e 2
515+ret false
516+end
517+p = get Cd 1
518+if ne get Cd 2 e
519+ret false
520+end
521+if not ctint p e
522+ret false
523+end
524+if gt sub e p 2
525+ret false
526+end
527+v = ulong 0
528+for i ulong sub e p
529+v = or shl v 8 ulong get Certbuf add p i
530+end
531+put Cm add b 14 v
532+ret true
533+end
534+
535+fn ctdns p ulong e ulong to bool
536+n = sub e p
537+if or eq n 0 gt n 253
538+ret false
539+end
540+for i ulong n
541+c = get Certbuf add p i
542+if or eq c 0 ge c 128
543+ret false
544+end
545+end
546+if eq n len Chost
547+ok = true
548+for j ulong n
549+c = get Certbuf add p j
550+if and ge c 65 le c 90
551+c = add c 32
552+end
553+if ne c get Chost j
554+ok = false
555+end
556+end
557+ret ok
558+end
559+if eq n len Cwild
560+ok = true
561+for j ulong n
562+c = get Certbuf add p j
563+if and ge c 65 le c 90
564+c = add c 32
565+end
566+if ne c get Cwild j
567+ok = false
568+end
569+end
570+ret ok
571+end
572+ret false
573+end
574+
575+note GeneralName CHOICE tags other than dNSName: [0] [1] [3]-[8] (RFC5280 4.2.1.6).
576+fn ctgname t ulong to bool
577+if or eq t 160 eq t 129
578+ret true
579+end
580+if and ge t 163 le t 165
581+ret true
582+end
583+ret and ge t 134 le t 136
584+end
585+
586+fn ctsan b ulong p ulong e ulong to bool
587+if not cttake p e 48
588+ret false
589+end
590+p = get Cd 1
591+if or ne get Cd 2 e eq p e
592+ret false
593+end
594+put Cm add b 23 1
595+while lt p e bound 4096
596+if not ctder p e
597+ret false
598+end
599+p = get Cd 2
600+t = get Cd 0
601+if eq t 130
602+if ctdns get Cd 1 p
603+put Cm add b 18 1
604+end
605+else
606+note The required identity is DNS. Other legal GeneralName alternatives never match it.
607+if not ctgname t
608+ret false
609+end
610+end
611+end
612+ret eq p e
613+end
614+
615+fn cteku b ulong p ulong e ulong to bool
616+if not cttake p e 48
617+ret false
618+end
619+p = get Cd 1
620+if or ne get Cd 2 e eq p e
621+ret false
622+end
623+put Cm add b 22 1
624+put Cm add b 17 0
625+while lt p e bound 4096
626+if not cttake p e 6
627+ret false
628+end
629+p = get Cd 1
630+q = get Cd 2
631+if not ctoid p q
632+ret false
633+end
634+if eq sub q p 8
635+if and eq get Certbuf p 43 eq get Certbuf add p 1 6
636+if and eq get Certbuf add p 2 1 eq get Certbuf add p 3 5
637+if and eq get Certbuf add p 4 5 eq get Certbuf add p 5 7
638+if and eq get Certbuf add p 6 3 eq get Certbuf add p 7 1
639+put Cm add b 17 1
640+end
641+end
642+end
643+end
644+end
645+p = q
646+end
647+ret eq p e
648+end
649+
650+note Duplicate extension OIDs, including unknown ones, are refused before interpretation.
651+fn ctunique p ulong e ulong to bool
652+if not ctoid p e
653+ret false
654+end
655+n = get Cen 0
656+if ge n 32
657+ret false
658+end
659+for i ulong n
660+if ctequal p e get Ce mul i 2 get Ce add mul i 2 1
661+ret false
662+end
663+end
664+put Ce mul n 2 p
665+put Ce add mul n 2 1 e
666+put Cen 0 add n 1
667+ret true
668+end
669+
670+fn ctextval b ulong id ulong p ulong e ulong crit bool to bool
671+if eq id 19
672+ret ctbasic b p e crit
673+end
674+if eq id 15
675+ret ctusage b p e
676+end
677+if eq id 17
678+ret ctsan b p e
679+end
680+if eq id 37
681+ret cteku b p e
682+end
683+note Constraints needing further path processing cannot be silently ignored even if noncritical.
684+if or or eq id 30 eq id 33 or eq id 36 eq id 54
685+ret false
686+end
687+if crit
688+ret false
689+end
690+ret true
691+end
692+
693+fn ctextone b ulong p ulong e ulong to bool
694+if not cttake p e 6
695+ret false
696+end
697+p = get Cd 1
698+q = get Cd 2
699+if not ctunique p q
700+ret false
701+end
702+id = ulong 0
703+if eq sub q p 3
704+if and eq get Certbuf p 85 eq get Certbuf add p 1 29
705+id = ulong get Certbuf add p 2
706+end
707+end
708+p = q
709+crit = false
710+if not ctder p e
711+ret false
712+end
713+if eq get Cd 0 1
714+if ne sub get Cd 2 get Cd 1 1
715+ret false
716+end
717+if ne get Certbuf get Cd 1 255
718+ret false
719+end
720+crit = true
721+p = get Cd 2
722+end
723+if not cttake p e 4
724+ret false
725+end
726+p = get Cd 1
727+if ne get Cd 2 e
728+ret false
729+end
730+ret ctextval b id p e crit
731+end
732+
733+fn ctexts b ulong p ulong e ulong to bool
734+if not cttake p e 163
735+ret false
736+end
737+p = get Cd 1
738+if ne get Cd 2 e
739+ret false
740+end
741+if not cttake p e 48
742+ret false
743+end
744+p = get Cd 1
745+if or ne get Cd 2 e eq p e
746+ret false
747+end
748+put Cen 0 0
749+while lt p e bound 4096
750+if not cttake p e 48
751+ret false
752+end
753+p = get Cd 2
754+if not ctextone b get Cd 1 p
755+ret false
756+end
757+end
758+ret eq p e
759+end
760+
761+fn ctfront b ulong p ulong e ulong to ulong
762+if not cttake p e 160
763+ret 0
764+end
765+q = get Cd 1
766+p = get Cd 2
767+if not cttake q p 2
768+ret 0
769+end
770+if or ne get Cd 2 p ne sub p get Cd 1 1
771+ret 0
772+end
773+if ne get Certbuf get Cd 1 2
774+ret 0
775+end
776+if not cttake p e 2
777+ret 0
778+end
779+q = get Cd 1
780+p = get Cd 2
781+if not ctint q p
782+ret 0
783+end
784+if or gt sub p q 21 eq sub p q 0
785+ret 0
786+end
787+if and eq sub p q 21 ne get Certbuf q 0
788+ret 0
789+end
790+v = uchar 0
791+for i ulong sub p q
792+v = or v get Certbuf add q i
793+end
794+if eq v 0
795+ret 0
796+end
797+put Cm add b 2 ctalg p e
798+if eq get Cm add b 2 0
799+ret 0
800+end
801+ret get Cd 2
802+end
803+
804+fn ctfields b ulong p ulong e ulong to ulong
805+put Cm add b 3 p
806+if not cttake p e 48
807+ret 0
808+end
809+p = get Cd 2
810+put Cm add b 4 p
811+if not ctname get Cm add b 3 p
812+ret 0
813+end
814+if not cttake p e 48
815+ret 0
816+end
817+q = get Cd 2
818+if not ctvalid b p q
819+ret 0
820+end
821+p = q
822+put Cm add b 5 p
823+if not cttake p e 48
824+ret 0
825+end
826+p = get Cd 2
827+put Cm add b 6 p
828+if not ctname get Cm add b 5 p
829+ret 0
830+end
831+if not cttake p e 48
832+ret 0
833+end
834+q = get Cd 2
835+if not ctspki b p q
836+ret 0
837+end
838+ret q
839+end
840+
841+fn ctparse idx ulong p ulong e ulong to bool
842+b = mul idx 32
843+for i ulong 32
844+put Cm add b i 0
845+end
846+put Cm add b 14 8
847+put Cm add b 17 1
848+if not cttake p e 48
849+ret false
850+end
851+if ne get Cd 2 e
852+ret false
853+end
854+p = get Cd 1
855+put Cm b p
856+if not cttake p e 48
857+ret false
858+end
859+q = get Cd 2
860+put Cm add b 1 q
861+p = ctfront b get Cd 1 q
862+if eq p 0
863+ret false
864+end
865+p = ctfields b p q
866+if eq p 0
867+ret false
868+end
869+if lt p q
870+if not ctexts b p q
871+ret false
872+end
873+end
874+p = q
875+if ne ctalg p e get Cm add b 2
876+ret false
877+end
878+p = get Cd 2
879+if not cttake p e 3
880+ret false
881+end
882+p = get Cd 1
883+if or ne get Cd 2 e ge p e
884+ret false
885+end
886+if ne get Certbuf p 0
887+ret false
888+end
889+put Cm add b 9 add p 1
890+put Cm add b 10 e
891+put Cm add b 25 1
892+ret true
893+end
894+
895+fn ctrawint p ulong e ulong width ulong off ulong to bool
896+if not ctint p e
897+ret false
898+end
899+if eq get Certbuf p 0
900+p = add p 1
901+end
902+n = sub e p
903+if or eq n 0 gt n width
904+ret false
905+end
906+for i ulong n
907+put Csig add off add sub width n i get Certbuf add p i
908+end
909+ret true
910+end
911+
912+fn ctrawsig p ulong e ulong width ulong to bool
913+for i ulong 96
914+put Csig i 0
915+end
916+if not cttake p e 48
917+ret false
918+end
919+p = get Cd 1
920+if ne get Cd 2 e
921+ret false
922+end
923+if not cttake p e 2
924+ret false
925+end
926+p = get Cd 1
927+q = get Cd 2
928+if not ctrawint p q width 0
929+ret false
930+end
931+if not cttake q e 2
932+ret false
933+end
934+p = get Cd 1
935+if ne get Cd 2 e
936+ret false
937+end
938+ret ctrawint p e width width
939+end
940+
941+fn ctsha256 p ulong e ulong to void
942+constants
943+hinit
944+for i ulong sub e p
945+hbyte get Certbuf add p i
946+end
947+finish
948+for j ulong 32
949+put Chash j get Hash j
950+end
951+end
952+
953+fn ctsha384 p ulong e ulong to void
954+m = new uchar 65536 0
955+d = new uchar 64 0
956+for i ulong sub e p
957+put m i get Certbuf add p i
958+end
959+cs384hash m sub e p d
960+for j ulong 48
961+put Chash j get d j
962+end
963+end
964+
965+fn ctvp256 to bool
966+w = new ulong 1024 0
967+b = new uchar 4096 0
968+for i ulong 65
969+put b add 3072 i get Ckey i
970+end
971+for j ulong 64
972+put b add 3200 j get Csig j
973+end
974+for k ulong 32
975+put b add 3296 k get Chash k
976+end
977+cp2init w
978+ret eq cp2vrfy w b 1
979+end
980+
981+fn ctvp384 to bool
982+w = new ulong 1536 0
983+b = new uchar 4096 0
984+for i ulong 97
985+put b add 3072 i get Ckey i
986+end
987+for j ulong 96
988+put b add 3200 j get Csig j
989+end
990+for k ulong 48
991+put b add 3296 k get Chash k
992+end
993+cp3init w
994+ret eq cp3vrfy w b 1
995+end
996+
997+fn ctchecksig child ulong issuer ulong to bool
998+c = mul child 32
999+b = mul issuer 32
1000+width = get Cm add c 2
1001+if ne width get Cm add b 24
1002+ret false
1003+end
1004+if not ctrawsig get Cm add c 9 get Cm add c 10 width
1005+ret false
1006+end
1007+ko = get Cm add b 7
1008+kn = get Cm add b 8
1009+for i ulong kn
1010+put Ckey i get Certbuf add ko i
1011+end
1012+if eq width 32
1013+ctsha256 get Cm c get Cm add c 1
1014+ret ctvp256
1015+end
1016+ctsha384 get Cm c get Cm add c 1
1017+ret ctvp384
1018+end
1019+
1020+fn ctclock idx ulong to bool
1021+b = mul idx 32
1022+if gt get Certnow 0 253402300799
1023+ret false
1024+end
1025+now = add get Certnow 0 62135596800
1026+ret and ge now get Cm add b 11 le now get Cm add b 12
1027+end
1028+
1029+fn ctca idx ulong below ulong to bool
1030+b = mul idx 32
1031+if not ctclock idx
1032+ret false
1033+end
1034+if or ne get Cm add b 13 1 ne get Cm add b 21 1
1035+ret false
1036+end
1037+if or ne get Cm add b 16 1 eq and get Cm add b 15 4 0
1038+ret false
1039+end
1040+if gt below get Cm add b 14
1041+ret false
1042+end
1043+ret eq get Cm add b 17 1
1044+end
1045+
1046+fn ctleaf to bool
1047+if not ctclock 0
1048+ret false
1049+end
1050+if ne get Cm 24 32
1051+ret false
1052+end
1053+if ne get Cm 13 0
1054+ret false
1055+end
1056+if or ne get Cm 16 1 eq and get Cm 15 128 0
1057+ret false
1058+end
1059+if ne and get Cm 15 4 0
1060+ret false
1061+end
1062+if or ne get Cm 22 1 ne get Cm 17 1
1063+ret false
1064+end
1065+if or ne get Cm 23 1 ne get Cm 18 1
1066+ret false
1067+end
1068+w = new ulong 1024 0
1069+b = new uchar 4096 0
1070+cp2init w
1071+for i ulong 65
1072+put b add 3072 i get Certbuf add get Cm 7 i
1073+end
1074+cp2ld w C2X b 3073
1075+cp2ld w C2Y b 3105
1076+ret cp2oncv w
1077+end
1078+
1079+fn certreset to void
1080+put Cready 0 0
1081+for i ulong 65
1082+put Certkey i 0
1083+put Cleaf i 0
1084+end
1085+for i ulong 97
1086+put Ckey i 0
1087+end
1088+for i ulong 96
1089+put Csig i 0
1090+end
1091+for i ulong 48
1092+put Chash i 0
1093+end
1094+for i ulong 4096
1095+put Certmsg i 0
1096+end
1097+for i ulong 128
1098+put Certsig i 0
1099+end
1100+for i ulong 288
1101+put Cm i 0
1102+end
1103+for i ulong 64
1104+put Ce i 0
1105+end
1106+for i ulong 8
1107+put Cchain i 0
1108+put Ctime i 0
1109+end
1110+put Cen 0 0
1111+put Ccount 0 0
1112+end
1113+
1114+fn ctbe p ulong n ulong to ulong
1115+v = ulong 0
1116+for i ulong n
1117+v = or shl v 8 ulong get Certbuf add p i
1118+end
1119+ret v
1120+end
1121+
1122+note Certificate-entry extensions are not negotiated by this client; unsolicited ones fail closed.
1123+fn ctlist to bool
1124+e = get Certlen 0
1125+if or lt e 4 gt e 60000
1126+ret false
1127+end
1128+if ne get Certbuf 0 0
1129+ret false
1130+end
1131+if ne ctbe 1 3 sub e 4
1132+ret false
1133+end
1134+p = ulong 4
1135+n = ulong 0
1136+while lt p e bound 9
1137+if or ge n 8 lt sub e p 5
1138+ret false
1139+end
1140+k = ctbe p 3
1141+p = add p 3
1142+if or eq k 0 gt k 8192
1143+ret false
1144+end
1145+if gt k sub e p
1146+ret false
1147+end
1148+q = add p k
1149+note Unused extra certificates may use unsupported algorithms; only parsed ones can be issuers.
1150+if not ctparse n p q
1151+if eq n 0
1152+ret false
1153+end
1154+end
1155+p = q
1156+if lt sub e p 2
1157+ret false
1158+end
1159+if ne ctbe p 2 0
1160+ret false
1161+end
1162+p = add p 2
1163+n = add n 1
1164+end
1165+put Ccount 0 n
1166+ret and eq p e gt n 0
1167+end
1168+
1169+note Path building uses only supplied certificates plus the local root. Anchor is tried first.
1170+note Child's exact issuer Name DER equals candidate parent's subject Name DER.
1171+fn ctissued child ulong parent ulong to bool
1172+c = mul child 32
1173+q = mul parent 32
1174+ret ctequal get Cm add c 3 get Cm add c 4 get Cm add q 5 get Cm add q 6
1175+end
1176+
1177+fn ctpath to bool
1178+if not ctleaf
1179+ret false
1180+end
1181+idx = ulong 0
1182+below = ulong 0
1183+for depth ulong 8
1184+if ne get Cchain idx 0
1185+ret false
1186+end
1187+put Cchain idx 1
1188+if ctissued idx 8
1189+if not ctca 8 below
1190+ret false
1191+end
1192+ret ctchecksig idx 8
1193+end
1194+next = ulong 8
1195+for j ulong get Ccount 0
1196+ok = eq get Cm add mul j 32 25 1
1197+if and ok ctissued idx j
1198+if ne next 8
1199+ret false
1200+end
1201+next = j
1202+end
1203+end
1204+if eq next 8
1205+ret false
1206+end
1207+if not ctca next below
1208+ret false
1209+end
1210+if not ctchecksig idx next
1211+ret false
1212+end
1213+idx = next
1214+below = add below 1
1215+end
1216+ret false
1217+end
1218+
1219+fn cthexv c uchar to uchar
1220+if and ge c 48 le c 57
1221+ret sub c 48
1222+end
1223+if and ge c 97 le c 102
1224+ret sub c 87
1225+end
1226+trap 5
1227+end
1228+
1229+note Decode vendor/cert-root.om Croot to Certbuf 64000..64574, above every accepted peer byte.
1230+fn ctroot to bool
1231+if ne len Croot 1148
1232+ret false
1233+end
1234+for i ulong 574
1235+h = cthexv get Croot mul i 2
1236+l = cthexv get Croot add mul i 2 1
1237+put Certbuf add 64000 i or shl h 4 l
1238+end
1239+ret true
1240+end
1241+
1242+fn certcheck to bool
1243+certreset
1244+if not ctroot
1245+ret false
1246+end
1247+note The DER root is local and already trusted; parsing only exposes its subject, key and limits.
1248+if not ctparse 8 64000 64574
1249+ret false
1250+end
1251+if not ctlist
1252+ret false
1253+end
1254+if not ctpath
1255+ret false
1256+end
1257+for i ulong 65
1258+put Certkey i get Certbuf add get Cm 7 i
1259+put Cleaf i get Certkey i
1260+end
1261+put Cready 0 1
1262+ret true
1263+end
1264+
1265+note TLS CertificateVerify: current validated leaf required, DER signature and SHA256 message.
1266+fn certsig n ulong siglen ulong to bool
1267+if ne get Cready 0 1
1268+ret false
1269+end
1270+if or gt n 4096 or eq siglen 0 gt siglen 128
1271+certreset
1272+ret false
1273+end
1274+for i ulong siglen
1275+put Certbuf add 60000 i get Certsig i
1276+end
1277+if not ctrawsig 60000 add 60000 siglen 32
1278+certreset
1279+ret false
1280+end
1281+constants
1282+hinit
1283+for j ulong n
1284+hbyte get Certmsg j
1285+end
1286+finish
1287+for k ulong 32
1288+put Chash k get Hash k
1289+end
1290+note Private copy: later caller writes to exported Certkey cannot change the authenticated key.
1291+for m ulong 65
1292+put Ckey m get Cleaf m
1293+end
1294+ok = ctvp256
1295+if not ok
1296+certreset
1297+end
1298+ret ok
1299+end

aienux/allen/tls-crypto.om

new file mode 100644
@@ -0,0 +1,628 @@
1+note SPDX-License-Identifier: AGPL-3.0-or-later
2+note Allen bounded TLS cryptography. Concatenate vendor/sha256-core.om before this unit.
3+note SHA256 reuses the existing first-party core and its provenance/license unchanged.
4+note X25519 follows RFC7748 sections 5/6 and native/net/x25519.c's Montgomery ladder.
5+note Unsigned radix-65536 field representation follows the first-party omnet field bounds;
6+note no verification-only branches, allocations, or point routines are reused.
7+note ChaCha20/Poly1305 are implemented from RFC8439 sections 2.1/2.3/2.5/2.8 equations.
8+note uint arithmetic wraps modulo 2^32 per OMEGESE 9.3; narrowing conversions are masked.
9+note No secret-indexed accesses or secret-dependent loop counts. Compiler/machine timing is unaudited.
10+note Single caller, nonreentrant; all input/output arrays are disjoint fixed globals, no caller aliases.
11+note Caller owns key/nonce uniqueness and entropy. Public calls preserve key/private input until tcwipe.
12+note tcsha/tchmac preserve Tcbuf; tcopen verifies the full tag BEFORE touching ciphertext.
13+note All public bool functions reject invalid lengths. HMAC accepts keys of 0..32 bytes only.
14+note HKDF-Extract/Expand RFC5869 is composed by tls.om using tchmac.
15+note Scratch globals are wiped after calls. tcwipe also clears caller-visible secrets and plaintext.
16+
17+global Tcbuf uchar 65536
18+global Tckey uchar 32
19+global Tciv uchar 12
20+global Tcaad uchar 32
21+global Tctag uchar 16
22+global Tcdigest uchar 32
23+global Tcxpriv uchar 32
24+global Tcxpub uchar 32
25+global Tcxpeer uchar 32
26+global Tcxshare uchar 32
27+
28+global Tchi uchar 32
29+global Tcxf ulong 176
30+global Tcxt ulong 32
31+global Tcxsc uchar 32
32+global Tcxres uchar 32
33+global Tccs uint 16
34+global Tccw uint 16
35+global Tccblk uchar 64
36+global Tcmkey uchar 32
37+global Tcmblk uchar 16
38+global Tcmtag uchar 16
39+global Tcmr ulong 10
40+global Tcmh ulong 10
41+global Tcmt ulong 10
42+global Tcmg ulong 10
43+
44+fn tcshwipe to void
45+for i ulong 8
46+put H i 0
47+put Vv i 0
48+end
49+for i ulong 64
50+put W i 0
51+put Hb i 0
52+end
53+put Hs 0 0
54+put Hs 1 0
55+for i ulong 32
56+put Hash i 0
57+put Tchi i 0
58+end
59+end
60+
61+fn tcsha n ulong to bool
62+for i ulong 32
63+put Tcdigest i 0
64+end
65+tcshwipe
66+if gt n 65536
67+ret false
68+end
69+constants
70+hinit
71+for i ulong n
72+hbyte get Tcbuf i
73+end
74+finish
75+for i ulong 32
76+put Tcdigest i get Hash i
77+end
78+tcshwipe
79+ret true
80+end
81+
82+fn tchmac keylen ulong n ulong to bool
83+for i ulong 32
84+put Tcdigest i 0
85+end
86+tcshwipe
87+if or gt keylen 32 gt n 65536
88+ret false
89+end
90+constants
91+hinit
92+for i ulong 64
93+v = uchar 54
94+if lt i keylen
95+v = xor v get Tckey i
96+end
97+hbyte v
98+end
99+for i ulong n
100+hbyte get Tcbuf i
101+end
102+finish
103+for i ulong 32
104+put Tchi i get Hash i
105+end
106+hinit
107+for i ulong 64
108+v = uchar 92
109+if lt i keylen
110+v = xor v get Tckey i
111+end
112+hbyte v
113+end
114+for i ulong 32
115+hbyte get Tchi i
116+end
117+finish
118+for i ulong 32
119+put Tcdigest i get Hash i
120+end
121+tcshwipe
122+ret true
123+end
124+
125+note Field slots: x0,a16,b32,c48,d64,e80,f96,k112,inverse128,canonical144,subtract160.
126+note A mul input limb is below 2^21; folded convolution below 2^52, so ulong never overflows.
127+note Mul gives limbs <=65535 except limb0<=65573. Sub adds 8p, keeping intermediates positive.
128+fn tcxwipe to void
129+for i ulong 176
130+put Tcxf i 0
131+end
132+for i ulong 32
133+put Tcxt i 0
134+put Tcxsc i 0
135+put Tcxres i 0
136+end
137+end
138+
139+fn tcfcopy o ulong a ulong to void
140+for i ulong 16
141+put Tcxf add o i get Tcxf add a i
142+end
143+end
144+
145+fn tcfadd o ulong a ulong b ulong to void
146+for i ulong 16
147+v = add get Tcxf add a i get Tcxf add b i
148+put Tcxf add o i v
149+end
150+end
151+
152+fn tcfprime i ulong to ulong
153+if eq i 0
154+ret 65517
155+end
156+if eq i 15
157+ret 32767
158+end
159+ret 65535
160+end
161+
162+fn tcfsub o ulong a ulong b ulong to void
163+for i ulong 16
164+v = add get Tcxf add a i mul tcfprime i 8
165+put Tcxf add o i sub v get Tcxf add b i
166+end
167+end
168+
169+fn tcfcarry o ulong to void
170+for i ulong 15
171+p = add o i
172+v = get Tcxf p
173+put Tcxf add p 1 add get Tcxf add p 1 shr v 16
174+put Tcxf p and v 65535
175+end
176+v = get Tcxf add o 15
177+put Tcxf add o 15 and v 65535
178+put Tcxf o add get Tcxf o mul shr v 16 38
179+end
180+
181+fn tcfmul o ulong a ulong b ulong to void
182+for i ulong 32
183+put Tcxt i 0
184+end
185+for i ulong 16
186+x = get Tcxf add a i
187+for j ulong 16
188+p = add i j
189+v = mul x get Tcxf add b j
190+put Tcxt p add get Tcxt p v
191+end
192+end
193+for i ulong 15
194+v = add get Tcxt i mul 38 get Tcxt add i 16
195+put Tcxf add o i v
196+end
197+put Tcxf add o 15 get Tcxt 15
198+tcfcarry o
199+tcfcarry o
200+end
201+
202+fn tcfswap a ulong b ulong bit ulong to void
203+mask = sub ulong 0 bit
204+for i ulong 16
205+x = get Tcxf add a i
206+y = get Tcxf add b i
207+v = and mask xor x y
208+put Tcxf add a i xor x v
209+put Tcxf add b i xor y v
210+end
211+end
212+
213+fn tcflad bit ulong to void
214+tcfswap 16 32 bit
215+tcfswap 48 64 bit
216+tcfadd 80 16 48
217+tcfsub 16 16 48
218+tcfadd 48 32 64
219+tcfsub 32 32 64
220+tcfmul 64 80 80
221+tcfmul 96 16 16
222+tcfmul 16 48 16
223+tcfmul 48 32 80
224+tcfadd 80 16 48
225+tcfsub 16 16 48
226+tcfmul 32 16 16
227+tcfsub 48 64 96
228+tcfmul 16 48 112
229+tcfadd 16 16 64
230+tcfmul 48 48 16
231+tcfmul 16 64 96
232+tcfmul 64 32 0
233+tcfmul 32 80 80
234+tcfswap 16 32 bit
235+tcfswap 48 64 bit
236+end
237+
238+fn tcfinv to void
239+tcfcopy 128 48
240+for i ulong 254
241+j = sub 253 i
242+tcfmul 128 128 128
243+note Branch uses fixed public exponent p-2, not any secret bit.
244+if and ne j 2 ne j 4
245+tcfmul 128 128 48
246+end
247+end
248+tcfmul 16 16 128
249+end
250+
251+fn tcfpack to void
252+tcfcopy 144 16
253+tcfcarry 144
254+tcfcarry 144
255+tcfcarry 144
256+for j ulong 2
257+borrow = ulong 0
258+for i ulong 16
259+v = add get Tcxf add 144 i 65536
260+v = sub sub v tcfprime i borrow
261+put Tcxf add 160 i and v 65535
262+borrow = sub 1 shr v 16
263+end
264+tcfswap 144 160 sub 1 borrow
265+end
266+for i ulong 16
267+v = get Tcxf add 144 i
268+put Tcxres mul i 2 uchar and v 255
269+put Tcxres add mul i 2 1 uchar and shr v 8 255
270+end
271+end
272+
273+fn tcxrun base bool to bool
274+tcxwipe
275+for i ulong 32
276+put Tcxsc i get Tcxpriv i
277+end
278+put Tcxsc 0 and get Tcxsc 0 248
279+put Tcxsc 31 or and get Tcxsc 31 127 64
280+if base
281+put Tcxf 0 9
282+else
283+for i ulong 16
284+v = ulong get Tcxpeer mul i 2
285+v = or v shl ulong get Tcxpeer add mul i 2 1 8
286+put Tcxf i v
287+end
288+put Tcxf 15 and get Tcxf 15 32767
289+end
290+tcfcopy 32 0
291+put Tcxf 16 1
292+put Tcxf 64 1
293+put Tcxf 112 56129
294+put Tcxf 113 1
295+for i ulong 255
296+j = sub 254 i
297+v = ulong get Tcxsc div j 8
298+tcflad and shr v rem j 8 1
299+end
300+tcfinv
301+tcfpack
302+acc = uchar 0
303+for i ulong 32
304+acc = or acc get Tcxres i
305+end
306+ret ne acc 0
307+end
308+
309+fn tcx25519 to bool
310+ok = tcxrun false
311+for i ulong 32
312+put Tcxshare i get Tcxres i
313+end
314+tcxwipe
315+ret ok
316+end
317+
318+fn tcxpublic to bool
319+ok = tcxrun true
320+for i ulong 32
321+put Tcxpub i get Tcxres i
322+end
323+tcxwipe
324+ret ok
325+end
326+
327+fn tccwipe to void
328+for i ulong 16
329+put Tccs i 0
330+put Tccw i 0
331+put Tcmblk i 0
332+put Tcmtag i 0
333+end
334+for i ulong 64
335+put Tccblk i 0
336+end
337+for i ulong 32
338+put Tcmkey i 0
339+end
340+for i ulong 10
341+put Tcmr i 0
342+put Tcmh i 0
343+put Tcmt i 0
344+put Tcmg i 0
345+end
346+end
347+
348+fn tclrot x uint n uint to uint
349+ret or shl x n shr x sub 32 n
350+end
351+
352+fn tccqr a ulong b ulong c ulong d ulong to void
353+put Tccw a add get Tccw a get Tccw b
354+put Tccw d tclrot xor get Tccw d get Tccw a 16
355+put Tccw c add get Tccw c get Tccw d
356+put Tccw b tclrot xor get Tccw b get Tccw c 12
357+put Tccw a add get Tccw a get Tccw b
358+put Tccw d tclrot xor get Tccw d get Tccw a 8
359+put Tccw c add get Tccw c get Tccw d
360+put Tccw b tclrot xor get Tccw b get Tccw c 7
361+end
362+
363+fn tccinit to void
364+put Tccs 0 1634760805
365+put Tccs 1 857760878
366+put Tccs 2 2036477234
367+put Tccs 3 1797285236
368+for i ulong 8
369+v = uint 0
370+for j ulong 4
371+b = uint get Tckey add mul i 4 j
372+v = or v shl b mul j 8
373+end
374+put Tccs add i 4 v
375+end
376+for i ulong 3
377+v = uint 0
378+for j ulong 4
379+b = uint get Tciv add mul i 4 j
380+v = or v shl b mul j 8
381+end
382+put Tccs add i 13 v
383+end
384+end
385+
386+fn tccgen ctr uint to void
387+put Tccs 12 ctr
388+for i ulong 16
389+put Tccw i get Tccs i
390+end
391+for i ulong 10
392+tccqr 0 4 8 12
393+tccqr 1 5 9 13
394+tccqr 2 6 10 14
395+tccqr 3 7 11 15
396+tccqr 0 5 10 15
397+tccqr 1 6 11 12
398+tccqr 2 7 8 13
399+tccqr 3 4 9 14
400+end
401+for i ulong 16
402+v = add get Tccw i get Tccs i
403+for j ulong 4
404+put Tccblk add mul i 4 j uchar and shr v mul j 8 255
405+end
406+end
407+end
408+
409+note Standalone block entry for primitive qualification; AEAD initializes the key only once.
410+fn tccblock ctr uint to void
411+tccinit
412+tccgen ctr
413+end
414+
415+note At most 1024 payload blocks: counters 1..1024, never 0 or a wrapped uint.
416+fn tccxor n ulong to void
417+p = ulong 0
418+ctr = uint 1
419+while lt p n bound 1024
420+tccgen ctr
421+m = sub n p
422+if gt m 64
423+m = 64
424+end
425+for i ulong m
426+v = xor get Tcbuf add p i get Tccblk i
427+put Tcbuf add p i v
428+end
429+p = add p m
430+ctr = add ctr 1
431+end
432+end
433+
434+note Poly1305 radix 2^13: 10 limbs, B^10 = 5 mod p. Folded products <2^40.
435+note Tcmkey is the one-time key, Tcmblk a block, Tcmh the accumulator. No secret tables.
436+fn tcminit to void
437+for i ulong 10
438+put Tcmr i 0
439+put Tcmh i 0
440+end
441+for i ulong 16
442+v = ulong get Tcmkey i
443+if eq rem i 4 3
444+v = and v 15
445+end
446+if and ne i 0 eq rem i 4 0
447+v = and v 252
448+end
449+j = div mul i 8 13
450+v = shl v rem mul i 8 13
451+put Tcmr j or get Tcmr j and v 8191
452+if lt j 9
453+put Tcmr add j 1 or get Tcmr add j 1 shr v 13
454+end
455+end
456+end
457+
458+fn tcmcarry to void
459+for i ulong 9
460+v = get Tcmh i
461+put Tcmh i and v 8191
462+put Tcmh add i 1 add get Tcmh add i 1 shr v 13
463+end
464+v = get Tcmh 9
465+put Tcmh 9 and v 8191
466+put Tcmh 0 add get Tcmh 0 mul shr v 13 5
467+end
468+
469+fn tcmblock n ulong to void
470+for i ulong n
471+j = div mul i 8 13
472+v = shl ulong get Tcmblk i rem mul i 8 13
473+put Tcmh j add get Tcmh j and v 8191
474+if lt j 9
475+put Tcmh add j 1 add get Tcmh add j 1 shr v 13
476+end
477+end
478+top = div mul n 8 13
479+v = shl ulong 1 rem mul n 8 13
480+put Tcmh top add get Tcmh top v
481+for i ulong 10
482+put Tcmt i 0
483+end
484+for i ulong 10
485+for j ulong 10
486+p = add i j
487+v = mul get Tcmh i get Tcmr j
488+if ge p 10
489+p = sub p 10
490+v = mul v 5
491+end
492+put Tcmt p add get Tcmt p v
493+end
494+end
495+for i ulong 10
496+put Tcmh i get Tcmt i
497+end
498+tcmcarry
499+tcmcarry
500+tcmcarry
501+end
502+
503+fn tcmfinish to void
504+note h is normalized below B^10; h+5 overflows exactly when h >= p.
505+v = ulong 5
506+for i ulong 10
507+v = add v get Tcmh i
508+put Tcmg i and v 8191
509+v = shr v 13
510+end
511+mask = sub ulong 0 v
512+for i ulong 10
513+v = xor get Tcmg i get Tcmh i
514+put Tcmh i xor get Tcmh i and mask v
515+end
516+carry = ulong 0
517+for i ulong 16
518+j = div mul i 8 13
519+s = rem mul i 8 13
520+v = shr get Tcmh j s
521+if lt j 9
522+v = or v shl get Tcmh add j 1 sub 13 s
523+end
524+v = add and v 255 carry
525+v = add v ulong get Tcmkey add i 16
526+put Tcmtag i uchar and v 255
527+carry = shr v 8
528+end
529+end
530+
531+fn tcmauth n ulong aadlen ulong to void
532+tccgen 0
533+for i ulong 32
534+put Tcmkey i get Tccblk i
535+end
536+tcminit
537+p = ulong 0
538+while lt p aadlen bound 2
539+for i ulong 16
540+put Tcmblk i 0
541+if lt add p i aadlen
542+put Tcmblk i get Tcaad add p i
543+end
544+end
545+tcmblock 16
546+p = add p 16
547+end
548+p = 0
549+while lt p n bound 4096
550+for i ulong 16
551+put Tcmblk i 0
552+if lt add p i n
553+put Tcmblk i get Tcbuf add p i
554+end
555+end
556+tcmblock 16
557+p = add p 16
558+end
559+for i ulong 8
560+put Tcmblk i uchar and shr aadlen mul i 8 255
561+put Tcmblk add i 8 uchar and shr n mul i 8 255
562+end
563+tcmblock 16
564+tcmfinish
565+end
566+
567+fn tcseal n ulong aadlen ulong to bool
568+tccwipe
569+for i ulong 16
570+put Tctag i 0
571+end
572+if or gt n 65536 gt aadlen 32
573+ret false
574+end
575+tccinit
576+tccxor n
577+tcmauth n aadlen
578+for i ulong 16
579+put Tctag i get Tcmtag i
580+end
581+tccwipe
582+ret true
583+end
584+
585+fn tcopen n ulong aadlen ulong to bool
586+tccwipe
587+if or gt n 65536 gt aadlen 32
588+ret false
589+end
590+tccinit
591+tcmauth n aadlen
592+v = uchar 0
593+for i ulong 16
594+v = or v xor get Tctag i get Tcmtag i
595+end
596+note Only the final accumulated authentication result branches; no partial tag comparison.
597+if ne v 0
598+tccwipe
599+ret false
600+end
601+tccxor n
602+tccwipe
603+ret true
604+end
605+
606+fn tcwipe to void
607+tcshwipe
608+tcxwipe
609+tccwipe
610+for i ulong 65536
611+put Tcbuf i 0
612+end
613+for i ulong 32
614+put Tckey i 0
615+put Tcaad i 0
616+put Tcdigest i 0
617+put Tcxpriv i 0
618+put Tcxpub i 0
619+put Tcxpeer i 0
620+put Tcxshare i 0
621+end
622+for i ulong 12
623+put Tciv i 0
624+end
625+for i ulong 16
626+put Tctag i 0
627+end
628+end

aienux/allen/tls-p384.om

new file mode 100644
@@ -0,0 +1,471 @@
1+note SPDX-License-Identifier: Apache-2.0
2+note Modified 2026-10-25: public verification subset of aien-dev/spark-rsi-mv om/p256/p256.om (P256 arithmetic adapted to P384).
3+note Source commit bba3877510daeb8a0e070a781a689bcf1952b6f6, SHA256
4+note 92da68007af091ccfbe01aa845be779502130e02bf57e9550332d669905db958.
5+note Adapted to P384, names prefixed cp3/C3, digest supplied by caller; signing, HMAC, nonce and private-key APIs removed.
6+note Public ECDSA inputs only. 32-bit-limb Montgomery arithmetic and complete a=-3 point addition.
7+note Renes-Costello-Batina 2015 algorithm 4; SEC2 v2 section 2.5.1 parameters.
8+note Byte buffer: key3072 (97 bytes), raw signature3200 (96), prehash3296 (48).
9+note No secret-key or constant-time compiler claim. Apache license in CERT-APACHE-LICENSE.
10+
11+const C3MP ulong 0
12+const C3MN ulong 72
13+const C3ONE1 ulong 144
14+const C3BM ulong 156
15+const C3GX ulong 180
16+const C3W1 ulong 240
17+const C3W2 ulong 252
18+const C3XX ulong 264
19+const C3YY ulong 276
20+const C3ZZ ulong 288
21+const C3XY ulong 300
22+const C3YZ ulong 312
23+const C3XZ ulong 324
24+const C3U ulong 336
25+const C3V ulong 348
26+const C3YM ulong 360
27+const C3YP ulong 372
28+const C3BX3 ulong 384
29+const C3XX3 ulong 396
30+const C3ZZ3 ulong 408
31+const C3RX ulong 420
32+const C3ACC ulong 456
33+const C3TMP ulong 492
34+const C3BASE ulong 528
35+const C3ZI ulong 564
36+const C3Z ulong 792
37+const C3R ulong 804
38+const C3S ulong 816
39+const C3U1 ulong 828
40+const C3U2 ulong 840
41+const C3T1 ulong 864
42+const C3T2 ulong 876
43+const C3T3 ulong 888
44+const C3X ulong 912
45+const C3Y ulong 924
46+const C3Q ulong 960
47+const C3P1 ulong 996
48+const C3P2 ulong 1032
49+const C3BPUB ulong 3072
50+const C3BSIG ulong 3200
51+const C3BDIG ulong 3296
52+
53+fn cp3cpy w edit ulong 1536 o ulong a ulong to void
54+for i ulong 12
55+put w add o i get w add a i
56+end
57+end
58+
59+fn cp3pcpy w edit ulong 1536 o ulong a ulong to void
60+for i ulong 36
61+put w add o i get w add a i
62+end
63+end
64+
65+fn cp3set w edit ulong 1536 o ulong v ulong to void
66+put w o v
67+for i ulong 11
68+put w add o add i 1 0
69+end
70+end
71+
72+fn cp3red w edit ulong 1536 o ulong t view ulong 14 m ulong to void
73+u = new ulong 12 0
74+bw = ulong 0
75+x = ulong 0
76+for i ulong 12
77+x = sub sub get t i get w add m i bw
78+put u i and x 4294967295
79+bw = shr x 63
80+end
81+sel = or get t 12 xor bw 1
82+mk = sub 0 sel
83+for j ulong 12
84+y = and get u j mk
85+put w add o j or y and get t j not mk
86+end
87+end
88+
89+fn cp3mrow t edit ulong 14 w edit ulong 1536 a ulong bi ulong to void
90+c = ulong 0
91+x = ulong 0
92+for j ulong 12
93+x = add add get t j mul get w add a j bi c
94+put t j and x 4294967295
95+c = shr x 32
96+end
97+x = add get t 12 c
98+put t 12 and x 4294967295
99+put t 13 shr x 32
100+end
101+
102+fn cp3mred t edit ulong 14 w edit ulong 1536 m ulong to void
103+q = and mul get t 0 get w add m 12 4294967295
104+x = add get t 0 mul q get w m
105+c = shr x 32
106+j1 = ulong 0
107+for k ulong 11
108+j1 = add k 1
109+x = add add get t j1 mul q get w add m j1 c
110+put t k and x 4294967295
111+c = shr x 32
112+end
113+x = add get t 12 c
114+put t 11 and x 4294967295
115+put t 12 add get t 13 shr x 32
116+end
117+
118+fn cp3mul w edit ulong 1536 o ulong a ulong b ulong m ulong to void
119+t = new ulong 14 0
120+for i ulong 12
121+cp3mrow t w a get w add b i
122+cp3mred t w m
123+end
124+cp3red w o t m
125+end
126+
127+fn cp3add w edit ulong 1536 o ulong a ulong b ulong m ulong to void
128+t = new ulong 14 0
129+c = ulong 0
130+x = ulong 0
131+for i ulong 12
132+x = add add get w add a i get w add b i c
133+put t i and x 4294967295
134+c = shr x 32
135+end
136+put t 12 c
137+cp3red w o t m
138+end
139+
140+fn cp3sub w edit ulong 1536 o ulong a ulong b ulong m ulong to void
141+t = new ulong 12 0
142+bw = ulong 0
143+x = ulong 0
144+for i ulong 12
145+x = sub sub get w add a i get w add b i bw
146+put t i and x 4294967295
147+bw = shr x 63
148+end
149+mk = sub 0 bw
150+c = ulong 0
151+for j ulong 12
152+x = add add get t j and get w add m j mk c
153+put w add o j and x 4294967295
154+c = shr x 32
155+end
156+end
157+
158+fn cp3modr w edit ulong 1536 o ulong m ulong to void
159+t = new ulong 14 0
160+for i ulong 12
161+put t i get w add o i
162+end
163+cp3red w o t m
164+end
165+
166+fn cp3lt w edit ulong 1536 a ulong m ulong to bool
167+bw = ulong 0
168+x = ulong 0
169+for i ulong 12
170+x = sub sub get w add a i get w add m i bw
171+bw = shr x 63
172+end
173+ret eq bw 1
174+end
175+
176+fn cp3isz w edit ulong 1536 a ulong to bool
177+v = ulong 0
178+for i ulong 12
179+v = or v get w add a i
180+end
181+ret eq v 0
182+end
183+
184+fn cp3eqv w edit ulong 1536 a ulong b ulong to bool
185+v = ulong 0
186+for i ulong 12
187+v = or v xor get w add a i get w add b i
188+end
189+ret eq v 0
190+end
191+
192+fn cp3rng w edit ulong 1536 a ulong to bool
193+ret and not cp3isz w a cp3lt w a C3MN
194+end
195+
196+fn cp3pow w edit ulong 1536 o ulong a ulong e ulong m ulong to void
197+cp3cpy w C3W2 a
198+cp3cpy w C3W1 add m 36
199+i = ulong 0
200+bit = ulong 0
201+for j ulong 384
202+i = sub 383 j
203+cp3mul w C3W1 C3W1 C3W1 m
204+bit = and shr get w add e shr i 5 and i 31 1
205+if eq bit 1
206+cp3mul w C3W1 C3W1 C3W2 m
207+end
208+end
209+cp3cpy w o C3W1
210+end
211+
212+fn cp3inv w edit ulong 1536 o ulong a ulong m ulong to void
213+cp3pow w o a add m 48 m
214+end
215+
216+fn cp3tom w edit ulong 1536 o ulong a ulong m ulong to void
217+cp3mul w o a add m 24 m
218+end
219+
220+fn cp3frm w edit ulong 1536 o ulong a ulong m ulong to void
221+cp3mul w o a C3ONE1 m
222+end
223+
224+fn cp3mod w edit ulong 1536 m ulong to void
225+m0 = get w m
226+x = m0
227+for i ulong 5
228+x = mul x sub 2 mul m0 x
229+end
230+put w add m 12 and sub 0 x 4294967295
231+cp3set w add m 24 1
232+for j ulong 768
233+cp3add w add m 24 add m 24 add m 24 m
234+end
235+cp3mul w add m 36 C3ONE1 add m 24 m
236+cp3cpy w add m 48 m
237+put w add m 48 sub get w add m 48 2
238+end
239+
240+fn cp3init w edit ulong 1536 to void
241+for i ulong 1536
242+put w i 0
243+end
244+put w 0 4294967295
245+put w 1 0
246+put w 2 0
247+put w 3 4294967295
248+put w 4 4294967294
249+put w 5 4294967295
250+put w 6 4294967295
251+put w 7 4294967295
252+put w 8 4294967295
253+put w 9 4294967295
254+put w 10 4294967295
255+put w 11 4294967295
256+put w 72 3435473267
257+put w 73 3974895978
258+put w 74 1219536762
259+put w 75 1478102450
260+put w 76 4097256927
261+put w 77 3345173889
262+put w 78 4294967295
263+put w 79 4294967295
264+put w 80 4294967295
265+put w 81 4294967295
266+put w 82 4294967295
267+put w 83 4294967295
268+put w C3ONE1 1
269+cp3mod w C3MP
270+cp3mod w C3MN
271+put w 864 3555470063
272+put w 865 713410797
273+put w 866 2318324125
274+put w 867 3327539597
275+put w 868 1343457114
276+put w 869 51644559
277+put w 870 4269883666
278+put w 871 404593774
279+put w 872 3824692505
280+put w 873 2559444331
281+put w 874 3795773412
282+put w 875 3006345127
283+cp3tom w C3BM C3T1 C3MP
284+put w 864 1920338615
285+put w 865 978607672
286+put w 866 3210029420
287+put w 867 1426256477
288+put w 868 2186553912
289+put w 869 1509376480
290+put w 870 2343017368
291+put w 871 1847409506
292+put w 872 4079005044
293+put w 873 2394015518
294+put w 874 3196781879
295+put w 875 2861025826
296+cp3tom w C3GX C3T1 C3MP
297+put w 864 2431258207
298+put w 865 2051218812
299+put w 866 494829981
300+put w 867 174109134
301+put w 868 3052452032
302+put w 869 3923390739
303+put w 870 681186428
304+put w 871 4176747965
305+put w 872 2459098153
306+put w 873 1570674879
307+put w 874 2519084143
308+put w 875 907533898
309+cp3tom w add C3GX 12 C3T1 C3MP
310+cp3cpy w add C3GX 24 add C3MP 36
311+cp3set w C3T1 0
312+end
313+
314+fn cp3padd w edit ulong 1536 o ulong a ulong q ulong to void
315+cp3mul w C3XX a q C3MP
316+cp3mul w C3YY add a 12 add q 12 C3MP
317+cp3mul w C3ZZ add a 24 add q 24 C3MP
318+cp3add w C3U a add a 12 C3MP
319+cp3add w C3V q add q 12 C3MP
320+cp3mul w C3XY C3U C3V C3MP
321+cp3add w C3U C3XX C3YY C3MP
322+cp3sub w C3XY C3XY C3U C3MP
323+cp3add w C3U add a 12 add a 24 C3MP
324+cp3add w C3V add q 12 add q 24 C3MP
325+cp3mul w C3YZ C3U C3V C3MP
326+cp3add w C3U C3YY C3ZZ C3MP
327+cp3sub w C3YZ C3YZ C3U C3MP
328+cp3add w C3U a add a 24 C3MP
329+cp3add w C3V q add q 24 C3MP
330+cp3mul w C3XZ C3U C3V C3MP
331+cp3add w C3U C3XX C3ZZ C3MP
332+cp3sub w C3XZ C3XZ C3U C3MP
333+note bzz3 = 3 (xz - b zz); ym = yy - bzz3; yp = yy + bzz3
334+cp3mul w C3U C3BM C3ZZ C3MP
335+cp3sub w C3U C3XZ C3U C3MP
336+cp3add w C3V C3U C3U C3MP
337+cp3add w C3U C3V C3U C3MP
338+cp3sub w C3YM C3YY C3U C3MP
339+cp3add w C3YP C3YY C3U C3MP
340+note zz3 = 3 zz; bxz3 = 3 (b xz - (zz3 + xx)); xx3 = 3 xx - zz3
341+cp3add w C3ZZ3 C3ZZ C3ZZ C3MP
342+cp3add w C3ZZ3 C3ZZ3 C3ZZ C3MP
343+cp3mul w C3U C3BM C3XZ C3MP
344+cp3add w C3V C3ZZ3 C3XX C3MP
345+cp3sub w C3U C3U C3V C3MP
346+cp3add w C3V C3U C3U C3MP
347+cp3add w C3BX3 C3V C3U C3MP
348+cp3add w C3V C3XX C3XX C3MP
349+cp3add w C3V C3V C3XX C3MP
350+cp3sub w C3XX3 C3V C3ZZ3 C3MP
351+note X3 = yp xy - yz bxz3; Y3 = yp ym + xx3 bxz3; Z3 = ym yz + xy xx3
352+cp3mul w C3U C3YP C3XY C3MP
353+cp3mul w C3V C3YZ C3BX3 C3MP
354+cp3sub w C3RX C3U C3V C3MP
355+cp3mul w C3U C3YP C3YM C3MP
356+cp3mul w C3V C3XX3 C3BX3 C3MP
357+cp3add w add C3RX 12 C3U C3V C3MP
358+cp3mul w C3U C3YM C3YZ C3MP
359+cp3mul w C3V C3XY C3XX3 C3MP
360+cp3add w add C3RX 24 C3U C3V C3MP
361+cp3pcpy w o C3RX
362+end
363+
364+fn cp3psel w edit ulong 1536 bit ulong to void
365+mk = sub 0 bit
366+nm = not mk
367+for c ulong 36

The diff is too large to show in full here; it was cut.