Goal and authority
User-requested, 2026-10-25: implement our own NVTXD-like device-side markers and begin/end ranges, written in seeded Omega .om, inside CUDA++ (canonical repository aien-dev/CUDApp). This is an independent native facility, not NVIDIA NVTXD ABI/Nsight compatibility, and not an external profiler recommendation.
First slice: one bounded, existing native vector kernel; one selected lane per CTA or explicit fixed producer slots. General source-language instrumentation, nesting/push-pop, SM attribution and whole-model tracing are later qualified extensions, not implicit MVP claims.
Audited source, not a greenfield runtime
Audit snapshot: CUDApp a520cd30e54c3b0ddd553ee3ccb3f5e673345cd6, Omega 55f9b0af47de70a3d06357985cf99ae3e45c016f. Resolve heads/owners again before editing.
- native/blackwell/vector.om:
gbword,gbquad,gbvecemit raw words for fixed uint32 vector add. This is not a generic GPU frontend. - launch.om:
gbopen/gbbuild/gblaunch; context.om:nvsend/nvwait; existing completion and visibility protocol; native test readback usesmapget. - Committed GB10 receipt binds candidate
2e2421694f6110bd84885ae0b2d3caf249809d34; current native vector/launch/context blobs match it. Bounded vector correctness is recorded; tracing/performance/full-model qualification is NOT_RUN. - Omega's historical resident-seat generator already emits S2R register
0x52and stores low-32-bit timer stamps. Consult as migration evidence, do not add a C kernel. - Command-list stamps are launch-boundary PTIMER reports, not inner-kernel ranges. Independent launch stamps can precede completion; never relabel host submit/wait as device execution.
Ownership and dependency order
Reuse #5 canonical runtime/integration, #17 measurement/reporting, #22 emitted-byte/control validation, #35 lowering and #52/#53 learning/evaluator ownership. No invented personal assignment; reconcile the live ledger and one-writer ownership first. Omega #638 / #632 own compiler-device integration.
- Freeze a narrow trace/clock/buffer/symbol contract with the linked Omega consumer.
- Add failing native host fixtures and emitted-byte negative controls.
- Extend the existing
.omemitter/launcher and decoder, no parallel encoder/runtime. - Independent host/source review, then a separately authorized GB10 window.
- Only after that, measured consumer integration and optional broader language lowering.
MVP acceptance
- Versioned event layout: run/generation, kernel/code identity, numeric site ID, mark/begin/end kind, producer sequence, logical CTA/thread/warp identity where actually available, timestamp bits/clock domain, bounded payload and explicit loss status. Keep strings/source symbols in an offline manifest; no raw pointers, prompts or tensor content by default.
- Checked, separately owned trace allocation and per-producer capacity. Prove extent arithmetic and stores stay within it. Deterministic producer sampling/filtering is recorded. Overflow drops diagnostics with saturating loss accounting; no wrap overwrite, spin for space, task veto or output-buffer corruption. Decode incomplete/unmatched ranges as incomplete.
- Default off at generation/compile time: unchanged kernel instruction bytes, no trace allocation/argument/stores and no trace-induced completion work when disabled. Enabled mode preserves math, output canaries and resource/lifetime invariants.
- Qualify timer instruction encoding and scheduling on sm_121. Historical low32 is not a 64-bit API. A short-capture MVP must declare wrap/maximum-duration rules and refuse ambiguous intervals; a later 64-bit implementation needs coherent-read/rollover tests. Clock units/resolution, cross-SM comparison and CPU-clock correlation are UNKNOWN until established for the actual chip.
clock64cycles are not automatically nanoseconds. NVIDIA PTX special-register contract is semantic reference, not a PTX product dependency or proof of our SASS encoding. - Preserve instruction data/predicate/register/control dependencies and ordinary completion/cache visibility. Do not insert barriers merely to make ranges look orderly; label asynchronous issue versus actual completion. A selected lane is not automatically representative of every lane.
- Reuse the existing host readback only after qualified completion/visibility. Timeouts/cancellation keep allocation lifetimes safe and trace status partial/failed; never recycle storage while work may still write.
- Host controls: zero/exact/full capacity, extent overflow, dropped-counter saturation, stale generation, truncated/wrong-version records, unmatched events, timer rollover, disabled byte identity, malformed timer/store/control-field mutants. Use native
.omproject-owned tests; external independent oracles remain outside the delivered closure. - Scheduled GB10 controls on exact final artifacts: known marked work, ordering/range checks within declared clock scope, math/tail-canary parity, forced overflow, bad timestamp/store/control mutants, repeated runs. Separate host/simulator/chip results.
- Paired tracing off/on measurements report raw samples, extra instructions/registers/memory, perturbation and loss rate; no promised overhead percentage. Include setup/readback/export costs separately. No model-speed claim from vector timing.
Scope and completion rules
All new first-party implementation/tests/automation are handwritten seeded .om. Existing C is migration/reference evidence, not a new production path; do not weaken the C freeze or add CUDA toolkit, PTX, libcuda, NVTX/Nsight, Python or third-party tracing dependencies. Retain OS/driver/firmware limitations honestly.
This issue authorizes bounded implementation preparation, not GPU use, driver changes, live-model disruption, deployment or merge. Coordinate authorized hardware windows separately. Preserve immutable receipts and failures. Record source/seed/compiler/binary/code/QMD/launch/config hashes, commands/exits, independent review and explicit PASS/FAIL/NOT_RUN. Do not close from host-only checks or a PR merge.
Linked consumer
Omega #778 owns source manifests and offline decoding/query integration. Freeze their shared contract before either side implements it. No GPU run is authorized by either issue.