code wiki / _hdl_build / nx_sovgit_pack_gate.nx
nx_sovgit_pack_gate.nx
buildroot/runtime/_hdl_build/nx_sovgit_pack_gate.nx
about
nx_sovgit_pack_gate.nx -- ★SOVGIT rung X1b: generate a valid git PACKFILE (PACK v2, object-format=sha256) from the
X0 objects, so STOCK `git index-pack` / `git unpack-objects` reads + verifies it. The packfile is the core of the
git wire (smart-HTTP git-upload-pack streams one on clone/fetch) AND git's efficient storage. Pure reuse of X0:
sha256_digest (trailer) + sg_zwrap (per-object zlib). Pack entry = varint(type<<4|rawsize) + zlib(RAW content)
(the "type size\0" frame is NOT in the pack -- type+size live in the entry header). license_tier: ORIGINAL expect_exit: 0
dependencies 1 imports · 0 importers
imports: nx_sovgit_obj.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
| none |
functions
| 8 | func hw(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } sys_write(1, s, n); return 0 } called by 1: main |
| 9 | func pn(v: i64) -> i64 { let b: *u8 = sys_mmap(32); var x: i64 = v; var i: i64 = 31; if x == 0 { b[i] = 48 as u8; i = i - 1 } while x > 0 { b[i] = (48 + x % 10) as u8; x = x / 10; i = i - 1 } sys_write(1, (b as i64 + i + 1) as *u8, 31 - i); return 0 } called by 1: main |
| 11 | func pk_be32(out: *u8, at: i64, v: i64) -> i64 called by 1: main |
| 20 | func pk_objhdr(out: *u8, at: i64, typ: i64, size: i64) -> i64 called by 1: pk_object |
| 30 | func pk_object(out: *u8, at: i64, typ: i64, content: *u8, clen: i64) -> i64 |
| 37 | func main() -> i64 |