G
Member
When a GPU evaluation shows intermittent latency spikes, avoid assigning the difference to model or agent policy until you can prove where the request waited. A useful split is between accelerator execution, host-to-device transport, and virtual-memory behavior. Unified memory or oversubscribed allocations can produce device page faults, migration traffic, and replayable stalls that look like policy delay if the trace only records end-to-end request time. The same caveat applies to managed allocations whose residency changes between prefill and decode phases.
Run a controlled A/B with the same binary, model, input tokens, batch size, CUDA stream setup, and allocation policy. First collect a baseline using explicit device-resident buffers sized below HBM capacity. Then repeat with the allocation path used by the failing workload, keeping clocks, power cap, MIG placement, CPU affinity, and concurrent processes fixed. Record per-stage timestamps around submission, synchronization, copy or migration calls, and kernel completion; correlate those with device fault counters, memory-controller bandwidth, PCIe bandwidth, and per-process GPU utilization. If the policy comparison changes after residency is pinned or the working set is reduced, the original result was confounded by memory migration rather than decision quality.
For a reproducible report, include the allocation mode, total reserved and active memory, fault counts before and after each run, kernel names around the stall, and whether the delay occurred before launch, during copy-engine activity, or inside device execution. Keep the interpretation limited: this procedure identifies migration or residency pressure, but it does not by itself distinguish NUMA effects, fabric contention, allocator fragmentation, or an external process consuming memory bandwidth. Those require separate controls and counter attribution.
Run a controlled A/B with the same binary, model, input tokens, batch size, CUDA stream setup, and allocation policy. First collect a baseline using explicit device-resident buffers sized below HBM capacity. Then repeat with the allocation path used by the failing workload, keeping clocks, power cap, MIG placement, CPU affinity, and concurrent processes fixed. Record per-stage timestamps around submission, synchronization, copy or migration calls, and kernel completion; correlate those with device fault counters, memory-controller bandwidth, PCIe bandwidth, and per-process GPU utilization. If the policy comparison changes after residency is pinned or the working set is reduced, the original result was confounded by memory migration rather than decision quality.
For a reproducible report, include the allocation mode, total reserved and active memory, fault counts before and after each run, kernel names around the stall, and whether the delay occurred before launch, during copy-engine activity, or inside device execution. Keep the interpretation limited: this procedure identifies migration or residency pressure, but it does not by itself distinguish NUMA effects, fabric contention, allocator fragmentation, or an external process consuming memory bandwidth. Those require separate controls and counter attribution.