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

branch main Branches Tags History

omega-mv / seed / ng / bench / evidence / 20261109T0156Z-d1b-fix / README.md

38 lines · 2794 bytes Raw Blame History Source

D1b fix: absent vs present-but-unusable files (HOST_TESTED, core 1)

Review finding F1 on 70168d58 (factory bay 6, MERGE_AFTER_FIX): hashpb returned 2^63 both for a file that is absent and for one that is present but cannot be used, and run mode reads 2^63 as "absent". A stdin file DIR/in/CASE of 16 MiB or more, or a directory there, silently lost its I row (rc 0); a present unlisted arm binary of 16 MiB or more was silently skipped (rc 0).

Fix (one commit): hashpb (seed/ng/bench/ngbench-sha.om) returns 2^63 only when open fails with ENOENT (errno 2), and 2^63 + 1 for every other open failure, a failed read (a directory: EISDIR) or 16 MiB or more. Run mode refuses 2^63 + 1 as R input CASE (stdin, ngbench.om wants) or R label CASE ARM (arm binary, identone). Callers that test ge 2^63 (sum, outok, recheck) are unchanged. This takes bay 6's proposal (8a9b6acd, which split only the read and size failures) and closes the case it left open: a present file that open refuses (EACCES, mode 000) was still reported as absent (rows nc-*-mode000 bay6 below: rc 0, the I row or the pair silently gone).

Binaries (seed/out/omc cfd96b48, cat seed/ng/ngbench.om seed/ng/sha256.om seed/ng/bench/ngbench-sha.om | omc):

controls.sh.txt (sha256 a0d5ab40...) built the fixture and ran every case with all three binaries, uid 1000; controls-log.txt (sha256 15a8ac54...) is its output. Result for the fixed binary:

casefixedD1bbay 6
no stdin; 6-byte stdin; 16 MiB - 1 stdinrc 0, I row as expectedsamesame
stdin 16 MiBrc 1 R inputrc 0, no I rowrc 1
stdin is a directoryrc 1 R inputrc 0, no I rowrc 1
stdin mode 000rc 1 R inputrc 0, no I rowrc 0, no I row
binary 16 MiB, listedrc 1 R labelrc 1 R missing (wrong reason)rc 1 R label
binary 16 MiB, unlistedrc 1 R labelrc 0, pair skippedrc 1
binary mode 000, listedrc 1 R labelrc 1 R missingrc 1 R missing
binary mode 000, unlistedrc 1 R labelrc 0, pair skippedrc 0, pair skipped
binary absent, unlisted (allowed)rc 0, pair skippedsamesame
binary absent, listedrc 1 R missingsamesame
sum: 18 sizes 0..16 MiB-1 + 3 binariesequals coreutils sha256sum (21 files)same-
sum: 16 MiB, missing, mode 000, directoryrc 1 eachsame-

No timing round: hashing stays outside the fork..waitpid interval (runone), so timed numbers are unaffected.