code wiki / (root) / nx_uv_worker_liveness_t280.nx

nx_uv_worker_liveness_t280.nx source

↩ module page · 7 lines · 476 B

1import "nx_proc_snapshot.nx" 2import "nx_gate_verdict.nx" 3func main()->i64{ 4 let count:i64=ps_refresh();let alive:i64=ps_alive_snap("knowledge/gates/gram-native-t280.elf" as *u8) 5 gv_puts("UV retained worker snapshot count=");gv_num(count);gv_puts(" valid=");gv_num(ps_valid());gv_puts(" ageMs=");gv_num(ps_age_ms());gv_puts(" matchingCmdline=");gv_num(alive);gv_puts("\n") 6 if count<0{return 2};if ps_valid()!=1{return 2};if alive<0{return 2};if alive==1{return 3};return 0 7}