code wiki / (root) / nx_h264_cavlc_rt_gate.nx

nx_h264_cavlc_rt_gate.nx

buildroot/runtime/nx_h264_cavlc_rt_gate.nx

5107 B120 linesdepth 4pulls 6 transitivereach 0 importersview sourcekind gate/prooftopic h264
docsdependenciesstructsconstsfunctions

about

nx_h264_cavlc_rt_gate.nx -- SOVEREIGN round-trip oracle for CAVLC level codec. No third-party reference: the ENCODER (nx_h264_cavlc_enc) and DECODER (nx_h264_cavlc_level) are gated as an inverse pair. (a) BitWriter sanity: write bits, read them back identically. (b) ANCHOR vs canonical code words: encode(+1,sl0) -> "1" (0x80, 1 bit); encode(-1,sl0) -> "01" (0x40, 2 bits). Pins the encoder to the spec. (c) ROUND-TRIP: for many (level, suffixLength) pairs, encode -> decode -> must recover the exact level. Proves both codecs correct (anchor (b) rules out a shared wrong table on these entries). Every value PRINTED. stdout + knowledge/status/h264_cavlc_rt_gate.log. Exit 0/1. Sovereign: nx_syscalls + nx_h264_bitwriter + nx_h264_cavlc_enc + nx_h264_bits + nx_h264_cavlc_level. license_tier: ORIGINAL

dependencies 5 imports · 0 importers

nx_syscalls.nx nx_h264_bitwriter.nx nx_h264_cavlc_enc.nx nx_h264_bits.nx nx_h264_cavlc_level.nx nx_h264_cavlc_rt_gate.nx

imports: nx_syscalls.nxnx_h264_bitwriter.nxnx_h264_cavlc_enc.nxnx_h264_bits.nxnx_h264_cavlc_level.nx

imported by: nobody (leaf or entry point)

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main sys_openat_append gp sys_write sys_mmap bw_init bw_write_bits bw_write_bit bw_write_bit ↻ bw_total_bits br_init sys_mmap ↻ br_read_bits br_read_bit gn sys_mmap ↻ sys_write ↻ nx_cavlc_encode_level nx_cavlc_encode_level_off bw_write_bit ↻ bw_write_bits ↻ nx_cavlc_read_level nx_cavlc_read_level_off br_read_bit ↻ br_read_bits ↻ nx_cavlc_levelcode_to_leve sys_close sys_exit

structs

none

consts

none

functions

19func gp(logfd: i64, s: *u8) -> i64
called by 1: main calls 1: sys_write
26func gn(logfd: i64, v: i64) -> i64
called by 1: main calls 2: sys_mmapsys_write
41func main() -> i64