nixlbench: create CUDA context when either side is VRAM #2713
All Vouch review confidence checks passed
Residual risk 0.16 = Change Risk (0.41) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.41 · 195 lines diff across 2 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.316
Shallow Review Depth
shallow_review_depth
0.289
Ai Authored
ai_authored
0.050
Real PR Conversation Timeline
1 comments
"Review active on #2713"
general
weight: 0.35
tvegas1
What?
When either side is VRAM, create a CUDA context in both nixlbench processes before the backend is created, if a GPU is visible.
Internal: https://nvbugspro.nvidia.com/bug/7115526
Why?
Without it, mixed DRAM/VRAM runs cannot exercise the
cuda_ipcpath ofget/rndvandput/rndv. Also UCX initiator cannot easily anticipate that the target will not be able to use a CUDA buffer.In that path, the RTR publishes the VRAM user buffer and the DRAM process writes into it through
cuda_ipc, with no bounce on the VRAM side. A DRAM-only process never creates a CUDA context, so UCX there cannot usecuda_ipcand falls back to single-rail active messages.With MLOPart, intra-node VRAM_DRAM_READ drops from 29 GB/s at 1 MiB to 0.95 GB/s from 2 MiB. With the context, the
cuda_ipcpath reaches 54 GB/s at 2 MiB and 302 GB/s at 64 MiB.How?
initCudaContext()callscudaFree(nullptr)and does nothing when no GPU is visible.<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
<!-- coderabbit-ai-generated:v1 -->
Summary by CodeRabbit
Bug Fixes
Improved startup reliability for NIXL benchmarks configured to use VRAM segments. CUDA context setup now occurs before backend initialization when a CUDA device is available, and systems with no enumerated CUDA devices can continue without a context. CUDA initialization errors are also checked and handled, helping prevent unexpected failures during benchmark startup.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->