开销overhead
开销延迟是指未执行有用工作所花费的时间。
与在 计算受限 或 内存受限 下的 性能瓶颈 时 GPU 以最大速度工作的情况不同,由开销引起的延迟代表 GPU 处于等待接收任务的状态。
开销通常来自 CPU 端的瓶颈,这些瓶颈阻止 GPU 及时接收任务。例如,每个内核启动的 CUDA API 调用开销大约为 10 微秒。此外,像 PyTorch 或 TensorFlow 这样的框架需要时间决定启动哪个 内核,这可能花费许多微秒。我们通常将这类开销通常被称为 (主机开销) "host overhead" 尽管术语尚未完全标准化。 CUDA Graphs 是解决此类开销的常用方案,它将多个设备端 内核 整合为单次主机端启动。更多信息,请参阅 GTC 2025 上的《最大化并发和系统利用率的 CUDA 技术》演讲。
"内存开销" 或 "通信开销" 是在 CPU 与 GPU 之间或 GPU 与 GPU 之间来回搬运数据所产生的延迟。但当通信带宽成为限制因素时,更适合将其视为一种 内存受限 的形式,其中"内存"分布在多台机器上。
英文原文(Modal GPU Glossary)
Overhead latency is the time spent with no useful work being done.
Unlike time spent bottlenecked on compute or memory, during which the GPU is working as fast as possible, latency from overhead represents time where the GPU is instead waiting to receive work.
Overhead often comes from CPU-side bottlenecks that prevent the GPU from receiving work fast enough. For example, CUDA API call overhead adds on the order of 10 μs per kernel launch. Moreover, frameworks like PyTorch or TensorFlow spend time deciding which kernel to launch, which can take many microseconds. We generally use the term "host overhead" here, though it's not entirely standardized. CUDA Graphs, which can collect a number of device-side kernels together into a single host-side launch, are a common solution to these overheads. For more, see the _CUDA Techniques to Maximize Concurrency and System Utilization_ talk at GTC 2025.
"Memory overhead" or "communications overhead" is overhead latency incurred moving data back and forth from the CPU to the GPU or from one GPU to another. But when communication bandwidth is the limiting factor, it's often better to think of it as a form of memory-boundedness where the "memory" is distributed across machines.
相关词条
本词条改编自 Modal GPU Glossary(CC BY 4.0)· 中文翻译 miter6/gpu-glossary-zh,MAE 整理排版。