CUDApp
CUDA++: AIEN’s GPU machine-code toolchain, runtime and driver client for NVIDIA GPUs without the CUDA toolkit. Hardware coverage and driver replacement limits are explicit.
Brought by drakestapleton
CUDApp / docs / speculation / NATIVE-KERNEL.md
| 1 | # Native Omega compute launch |
| 2 | |
| 3 | `native/blackwell/vector.om` emits the existing seeded SM121 integer vector |
| 4 | program in handwritten Omega. Its 512 bytes match Omega `57f5f425`'s |
| 5 | `seed/sm121/vecadd.bin` exactly. It adds two uint32 arrays, with wraparound, |
| 6 | and exits out-of-range threads before memory access. |
| 7 | |
| 8 | `native/blackwell/launch.om` continues CUDApp `349913f1`'s VECTOR_1D launch |
| 9 | contract over the native NVRM connection. It builds the driver constants, |
| 10 | two launch descriptors, argument upload, completion markers and final cache |
| 11 | flush. The host waits for completion before reading every result. No C or |
| 12 | Rust runtime, foreign assembler, CUDA library or lab-only capsule is used. |
| 13 | |
| 14 | The current interface is deliberately one bounded vector operation, with |
| 15 | 64 threads per block and at most 1,048,576 elements. It is not a generic |
| 16 | unvalidated program loader. There is one context and one outstanding packet. |
| 17 | The caller must close the context after a failed open or launch. |
| 18 | |
| 19 | The physical test passes sizes 1, 63, 64, 65, 257, 4097, 65537 and 1048576, |
| 20 | compares every uint32 result, and checks up to 64 words beyond the output. |
| 21 | A fresh program allocation that omits one addend must produce a mismatch. |
| 22 | A subsequent fresh correct program must pass again. Invalid zero and |
| 23 | oversized requests are refused, and final context cleanup succeeds. |
| 24 | |
| 25 | Host checks compare the emitted program byte for byte with the seed artifact. |
| 26 | For five address/size fixtures, all 2,115 driver/descriptor/argument words |
| 27 | match an independently compiled copy of the pinned C QMD builder. That C |
| 28 | program is a test-only oracle and is never part of the native execution path. |
| 29 | |
| 30 | The first physical attempt exited 104 when the test's dynamic CPU loop |
| 31 | exceeded the seeded one-million-iteration guard. A CPU-only reproduction |
| 32 | passed at 1,000,000 and failed at 1,000,001. The shared checker now processes |
| 33 | at most 65,536 values per loop. Its host regression checks 999,999, 1,000,000, |
| 34 | 1,000,001 and 1,048,576 elements plus a one-element case. The guard remains |
| 35 | unchanged. The initial failed attempt is retained privately and is not a pass. |
| 36 | |
| 37 | Build the GPU test by concatenating `context.om`, `vector.om`, `launch.om`, |
| 38 | the declarations and `ck` function before `fn trial` in |
| 39 | `native-kernel-test.om`, `vector-checks.om`, and the remainder of the kernel |
| 40 | test. Build the CPU regression from the declarations and `ck` before |
| 41 | `fn supply` in `vector-checks-test.om`, `vector-checks.om`, then its remainder. |
| 42 | Compile with the pinned seeded compiler; require successful compilation |
| 43 | before execution. Hardware tests require a confirmed admitted window. |
| 44 | |
| 45 | The evidence is a shared-window correctness result, with no performance |
| 46 | claim. FP8 arithmetic, the complete 27B model, speculative-state recovery, |
| 47 | AIENOS attachment and the four-arm comparison remain unfinished. Issues |
| 48 | 63 through 66 remain open. Independent final-source review is still pending. |