code wiki / _hdl_build / nx_voice_codec_v2_gate.nx

nx_voice_codec_v2_gate.nx

buildroot/runtime/_hdl_build/nx_voice_codec_v2_gate.nx

3590 B65 linesdepth 6pulls 10 transitivereach 0 importersview sourcekind gate/prooftopic voice
docsdependenciesstructsconstsfunctions

about

nx_voice_codec_v2_gate.nx -- proves the v2 voice codec (nx_voice_codec_v2) as a real encode/decode PAIR: PCM frame -> v2_encode -> wire bytes -> v2_decode -> PCM, reconstructed faithfully and smaller than raw PCM. This is the v1 skeleton's "v2 path" realised as an actual codec.

dependencies 3 imports · 0 importers

nx_syscalls_x86_64.nx nx_voice_codec_v2.nx nx_gate_verdict.nx nx_voice_codec_v2_gate.nx

imports: nx_syscalls_x86_64.nxnx_voice_codec_v2.nxnx_gate_verdict.nx

imported by: nobody (leaf or entry point)

structs

none

consts

none

functions

8func g_puts(s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} sys_write(1,s,n); return 0 }
9func g_pn(v: i64) -> i64
19func g_check(name: *u8, cond: i64) -> i64
23func g_abs(v: i64) -> i64 { if v < 0 { return 0 - v } return v }
24func ld16(buf: *u8, idx: i64) -> i64 { var v: i64 = buf[idx*2] | (buf[idx*2+1] << 8); if v >= 32768 { v = v - 65536 } return v }
25func st16(buf: *u8, idx: i64, v: i64) -> i64 { var x: i64 = v; if x < 0 { x = x + 65536 } buf[idx*2] = x & 0xff; buf[idx*2+1] = (x >> 8) & 0xff; return 0 }
27func main() -> i64