Repository navigation
native: the execution witness's stamps, weight read and hash thread move to weights_witness.zig, and CUDA keeps its kernels, GPU and components - #4907
Conversation
|
I tested zig build test-execution-witness-cuda-host test-execution-witness-host test-disk-identity-host -Dfixed-cpu --summary allAll 117 tests passed: 22 CUDA witness, 55 execution witness and 40 disk identity. The CUDA host run included the pinned Igor Lessio - AIFLOW LABS |
|
Thank you, @kotevcode. The extraction retains the CUDA digest field order and lifecycle, and the compatibility fixture remains covered by the recorded host results. The default path still avoids witness file reads and workers. This looks ready to land.
|
…ove to weights_witness.zig, and CUDA keeps its kernels, GPU and components
1705275 to
b376ecc
Compare
|
Thank you @kotevcode. This is merged into main with your commits under your own name, so you're listed as a TensorFold contributor. It ships in the next release, credited to you in the changelog and the release notes. |
What this changes
The execution witness's backend-neutral half moves out of
cuda_witness.zigintoweights_witness.zig, aWitness(B)that a backend fills with its owndomain,stamp,keepandtail. The neutral half is the stamps before the load, every shard byte read once the server is ready, the hash thread and its reasons. CUDA keeps its kernels, GPU facts and kept-state components in aCudabackend, and its digest is the same bytes, so nothing a user sees changes. This is the base the Metal path (#4630) builds on.weights_witness.zig(202 lines):Witness(B)withopen,openOrFailed,start,wait,close,release,sourceOfanddigest, pluswanted(api.Open), the conditions every path shares (the flag, one rank, text, no drafter,--slide,--record,--learn,--recallor MTP drafts). It also hasfield, the length-prefixed update both backends hash with.cuda_witness.ziggoes from 247 lines to 101.wanted(F, o)keeps its dense-Qwen check and then asksweights_witness.wanted.Cuda.keepcallscuda_disk.componentsas before, andopen,openOrFailed,bind,set,bound,releaseandsourcekeep their meaning.cuda.zigchanges one call (cuda_witness.openOrFailed).New test: a fixed checkpoint, captured kernel set, device and profile pin the CUDA digest to
c1692f38…, the value main's single-file witness gives. I computed it on 2558607 and on 3993128 before the move, and checked it is the same on both. Host builds hash no embedded images, so the pin holds there; a build with nvcc or prebuilt fatbins skips it, because the images go into the digest.Issue: Refs Execution witness: Qwen3.5-2B on Metal #4630 (part 1 of 2: the shared half; the Metal path is the next PR).
Stacked on: main at ea57d96; this PR adds 1705275.
atc overlap --json: run on this head against main;complete: false(otherPullRequestsLimit,pullFilesUnavailable,pullRequestsLimit,timeLimit). MoE route tap: optional TF_ROUTE_TAP trace of global top-k #1886 and Unlimited-OCR-2 on CUDA: the family's steps on NVIDIA GPUs (sm_89 and up) #2077 sharecuda.zigand reportunknown.Checks on this head
python3 tools/pr_check.py --base upstream/main --pr 4907: lean 165 and 165 on the base and this head, 0 new; 0 errors.zig build test-execution-witness-cuda-host: 22 passed, 0 failed, 0 skipped, including the pinned digest.zig build test-execution-witness-host: 54 passed.zig build test-disk-identity-host: 39 passed.zig build check-native-cuda-host: 8 of 8 steps.digesthashing the tail before the kept components, it fails, and it passes again with them restored.Receipt
Checklist