NVIDIA 推出 Green Contexts 实现 GPU 资源显式分区
原标题:Control How Your GPU Shares Work with Green Contexts
AI 摘要
NVIDIA 在技术博客中介绍了 Green Contexts 功能,允许应用显式选择 GPU 执行资源子集并将工作定向到这些资源。该功能自 CUDA 12.4 起在 Driver API 中可用,CUDA 13.1 起通过 Runtime API 开放。它支持 SM 分区和 workqueue 资源分配,可减少多组件 GPU 应用间的资源竞争和意外串行化,且创建销毁轻量、不隐式同步无关工作。
正文节选
GPU applications increasingly consist of multiple independent components running at the same time within a single process: a latency-sensitive operator alongside a throughput-oriented background kernel; a data preprocessing stage alongside model inference; or multiple stages of a processing workflow sharing a single GPU. Controlling how GPU resources are shared between them remains difficult. Components can interfere unpredictably, and existing tools offer limited ability to partition resources.