hpc-gpu-stack
Build, review, debug, and launch CUDA- and GPU-accelerated HPC workflows. Use when working with `nvcc`, host-compiler compatibility, CUDA-aware MPI, rank-to-GPU mapping, `CUDA_VISIBLE_DEVICES`, Slurm GPU scheduling, GPU memory or stream behavior, or CUDA build and runtime failures.
- License 许可
- MIT
- 最近更新
- 2026-11-09
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- hpc-gpu-stack
- risk
- low
- domain
- high-performance-computing
- source
- { "commit": "4ea8069188", "license": "MIT", "repository": "SciMate-AI/HPC-Skills", "imported_at": "2026-09-20" }
- license
- MIT
- version
- 1.0.0
- category
- high-performance-computing
- platforms
- [ "claude-code", "cursor", "codex", "gemini", "antigravity", "copilot" ]
- subdomain
- general
- description
- Build, review, debug, and launch CUDA- and GPU-accelerated HPC workflows. Use when working with `nvcc`, host-compiler compatibility, CUDA-aware MPI, rank-to-GPU mapping, `CUDA_VISIBLE_DEVICES`, Slurm GPU scheduling, GPU memory or stream behavior, or CUDA build and runtime failures.
02 资源文件 12
- 脚本assets/templates/cuda_mpi_gpu_slurm.sh463 B
- 脚本assets/templates/cuda_single_gpu_slurm.sh399 B
- 资产文件assets/templates/cuda_vector_add_minimal.cu1.1 KB
- 脚本assets/templates/nvcc_build_example.sh297 B
- 参考文档references/build-and-launch-workflow.md807 B
- 参考文档references/cuda-and-host-compiler-matrix.md1.4 KB
- 参考文档references/device-visibility-and-scheduler-integration.md1.2 KB
- 参考文档references/error-pattern-dictionary.md1.2 KB
- 参考文档references/error-recovery.md756 B
- 参考文档references/gpu-aware-mpi-and-rank-mapping.md1.2 KB
- 参考文档references/memory-streams-and-overlap-playbook.md1016 B
- 参考文档references/runtime-debugging-and-profiling.md804 B
03 SKILL.md 正文
HPC GPU Stack
Treat GPU execution as one coherent stack: CUDA toolchain, host compiler, launcher, scheduler mapping, and device visibility must agree before kernel tuning matters.
Start
- Read
references/cuda-and-host-compiler-matrix.mdbefore choosingnvcc, host compiler, or a CUDA build baseline. - Read
references/gpu-aware-mpi-and-rank-mapping.mdwhen the workflow spans MPI ranks, one-rank-per-GPU layouts, or CUDA-aware MPI. - Read
references/device-visibility-and-scheduler-integration.mdwhen Slurm,CUDA_VISIBLE_DEVICES, MIG, or scheduler-provided GPU allocation is involved. - Read
references/memory-streams-and-overlap-playbook.mdwhen debugging device memory pressure, pinned-memory transfers, streams, or overlap assumptions. - Read
references/build-and-launch-workflow.mdwhen turning a CUDA code path into a reproducible compile-and-run workflow. - Read
references/runtime-debugging-and-profiling.mdwhen kernels fail at runtime, ranks see the wrong device, or performance is unexpectedly poor. - Read
references/error-recovery.mdwhen configure, compile, launch, or runtime CUDA behavior fails. - Read
references/error-pattern-dictionary.mdwhen a GPU failure needs a fast pattern match.
Work sequence
- Confirm the execution model first:
- single GPU
- one MPI rank per GPU
- hybrid MPI plus threads with explicit rank-to-GPU placement
- Keep CUDA toolkit, host compiler, and MPI stack mutually compatible.
- Let the scheduler expose the intended GPU allocation before forcing manual device selection.
- Get a minimal kernel and launch baseline working before tuning streams, overlap, or transport variables.
- Reproduce failures on one node and the smallest GPU count that still shows the issue before scaling out.
Guardrails
- Do not assume
nvccaccepts any host compiler visible inPATH. - Do not mix rank-to-GPU mapping logic from Open MPI, MPICH-family, and Slurm without checking which environment variables are actually set.
- Do not tune streams or overlap to compensate for a broken device-mapping or memory-capacity issue.
- Do not debug multi-node GPU failures before a single-node baseline is trustworthy.
Additional References
Load these on demand:
references/cuda-and-host-compiler-matrix.mdfor compiler-compatibility and build-baseline decisionsreferences/gpu-aware-mpi-and-rank-mapping.mdfor CUDA-aware MPI and rank placement rulesreferences/device-visibility-and-scheduler-integration.mdfor scheduler-exposed GPU visibility and Slurm integrationreferences/memory-streams-and-overlap-playbook.mdfor memory hierarchy, streams, and transfer overlapreferences/build-and-launch-workflow.mdfor reproducible build and launch sequencingreferences/runtime-debugging-and-profiling.mdfor runtime inspection and performance triagereferences/error-pattern-dictionary.mdfor common GPU failure signatures
Reusable Templates
Use assets/templates/ when a concrete starting point is faster than rebuilding the GPU workflow from scratch, especially:
cuda_vector_add_minimal.cunvcc_build_example.shcuda_single_gpu_slurm.shcuda_mpi_gpu_slurm.sh
Outputs
Summarize:
- CUDA toolkit and host-compiler path chosen
- rank-to-GPU mapping or single-GPU launch path
- scheduler or visibility assumptions
- memory and stream model if relevant
- the exact build or runtime failure class if the workflow is being repaired
04 同仓库更多 Skills
dei-assessment
Assess diversity, equity, and inclusion with metrics. TRIGGERS - Use when user needs help with dei-assessment related tasks.
dei-action-plan
Create DEI action plans with goals and initiatives. TRIGGERS - Use when user needs help with dei-action-plan related tasks.
culture-fit-assessment
Design culture add assessment processes. TRIGGERS - Use when user needs help with culture-fit-assessment related tasks.
cowork-to-code-bridge
Use an already-installed, independently verified cowork-to-code bridge to run narrowly approved actions on the user's own macOS, Linux, or WSL2 machine through a local file queue.
counter-offer-response
Draft counter-offer responses for retention. TRIGGERS - Use when user needs help with counter-offer-response related tasks.
continuous-feedback-system
Design continuous feedback systems. TRIGGERS - Use when user needs help with continuous-feedback-system related tasks.