nx_enginelab_gate.nx
buildroot/runtime/nx_enginelab_gate.nx
about
nx_enginelab_gate.nx -- END-TO-END gate for the sovereign engine instrument.
WHAT A GREEN HERE MEANS, AND WHAT IT DOES NOT. Every tooth below asserts an ARITHMETIC property of
the instrument on a fixture built at runtime inside this process. A green says the five instrument
classes compute what they claim on data whose right answer is known by construction. It says
NOTHING about any engine's real performance -- that is the instrument's job, not the gate's.
FIXTURES ARE BUILT IN MEMORY, NEVER ON DISK AND NEVER SHARED. A gate that shares scratch with a
production beat measures the fixture instead of the code (this estate has the receipt: a segguard
fold took a gate RED while the same code went 24/24 GREEN on private scratch). Nothing here opens
a file, so there is no teardown to skip and no run that can poison the next one.
NEGATIVE CONTROLS ARE NAMED neg-control-* so a census can COUNT them. A control nobody can find is
a control nobody maintains.
dependencies 6 imports · 0 importers
imports: nx_syscalls.nxnx_gate_verdict.nxnx_visual_diff.nxnx_enginelab_lib.nxnx_enginelab_golden.nxnx_enginelab_store.nx
imported by: nobody (leaf or entry point)
call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown
structs
| none |
consts
| 22 | const EG_SCRATCH: i64 = 32 // i64 slots for any out-buffer used below |
| 23 | const EG_STORE_CAP: i64 = 96 |
| 24 | const EG_IMG_W: i64 = 8 |
| 25 | const EG_IMG_H: i64 = 8 |
| 26 | const EG_IMG_NC: i64 = 3 |
| 27 | const EG_GRID: i64 = 4 // 4x4 cells over the 8x8 fixture = 2x2 px per cell |
| 28 | const EG_THRESH: i64 = 4 // per-cell mean tolerance |
| 29 | const EG_BASE_VAL: i64 = 100 // fixture background level |
| 30 | const EG_ALTER_VAL: i64 = 200 // a level far outside EG_THRESH, so the change cannot be a rounding artefact |
| 31 | const EG_TARGET_FPS: i64 = 60 |
| 38 | const EG_DROP_CAP: i64 = 2 |
| 39 | const EG_SMALL_BUF: i64 = 8 |
| 40 | const EG_Q_PERMIL: i64 = 354 |
| 41 | const EG_TRIS: i64 = 2419200 |
| 42 | const EG_ASCII_9: i64 = 57 |
| 43 | const EG_DEC_BASE: i64 = 10 |
| 47 | const EG_FRAME_US: i64 = 16000 |
| 51 | const EG_NOT_OUR_MAGIC: i64 = 12345 |
functions
| 53 | func eg_buf() -> *i64 { return sys_mmap(EG_SCRATCH * EL_I64) as *i64 } |
| 55 | func eg_mk_img(val: i64) -> *VdImg |
| 69 | func eg_alter(im: *VdImg, val: i64) -> i64 called by 1: main |
| 86 | func eg_mk_capture(verts_last: i64) -> *i64 |
| 95 | func eg_mk_frames(spike: i64) -> *i64 |
| 106 | func main() -> i64 |
| 565 | func eg_eq(a: i64, b: i64) -> i64 { if a == b { return 1 } return 0 } called by 1: main |
| 566 | func eg_zero(a: i64) -> i64 { if a == 0 { return 1 } return 0 } called by 1: main |
| 567 | func eg_pos(a: i64) -> i64 { if a > 0 { return 1 } return 0 } called by 1: main |
| 568 | func eg_eq2(a: i64, b: i64, c: i64, d: i64) -> i64 { if a == b { if c == d { return 1 } } return 0 } called by 1: main |
| 569 | func eg_eq3(a: i64, b: i64, c: i64, d: i64, e: i64, f: i64) -> i64 |
| 572 | func eg_eq4(a: i64, b: i64, c: i64, d: i64, e: i64, f: i64, g: i64, h: i64) -> i64 called by 1: main |
| 575 | func eg_eq5(a: i64, b: i64, c: i64, d: i64, e: i64, f: i64, g: i64, h: i64, i: i64, j: i64) -> i64 called by 1: main |
| 578 | func eg_eq6(a: i64, b: i64, c: i64, d: i64, e: i64, f: i64) -> i64 { return eg_eq3(a,b,c,d,e,f) } |
| 583 | func eg_copy_trunc(src: *u8, dst: *u8, drop: i64) -> i64 |
| 596 | func eg_copy_corrupt(src: *u8, dst: *u8, off: i64) -> i64 |
| 609 | func eg_write_raw(dst: *u8, first: i64, slots: i64) -> i64 |