Expand description
The canonical trace-event record.
TraceEvent is the input atom of the DSFB-GPU-Debug pipeline. Each
record represents one observable point in the debug catalog — a span
emitted by a tracing system, a latency sample, an error stamp. The shape
is intentionally narrow: we keep only the fields the downstream pipeline
actually reads, so the canonical byte form is small and the hash chain
stays cheap to compute.
Layout decisions:
#[repr(C)]so the struct can cross the FFI boundary into CUDA without per-field marshaling. The CUDA-side mirror incuda/layout.cuh(introduced in Section H) lays the fields out identically.- Field order is part of the in-crate canonical trace contract. Changing this order would change the catalog hash and therefore the case-file hash, so the order is not to be reshuffled.
- Widths chosen for the bounded v0 demo:
latency_us: u32covers up to ~71 minutes of latency (way beyond the contract clamp of 32 767 ms),entity_idandroute_idareu32to leave room without paying foru64, and the 16-bit status/error/kind/flags fields keep the total record size small.
Stability: this type is deserialized from the canonical JSON fixture and
re-serialized into the case file’s input_catalog_hash. The
serialization order is fixed by serialize::write_event (canonical key
ordering); modifying field names or order requires bumping the contract
version.
Structs§
- GpuTrace
Event Compact - R.11c — compact GPU-ingest projection of
TraceEvent. Carries only the four fields thewindow_feature_kernel_structuredkernel actually reads (ts_ns,entity_id,latency_us, and theerror_code != 0flag), packed into 16 bytes. Throughput dispatches H2D this projection instead of the 48-byte audit- gradeTraceEvent, cutting PCIe payload ~3× at full scale (192 MB → 64 MB at K=128 256×4096). - Trace
Event - A single observable trace point.