通过主动内存调度实现全面的GPU多任务处理
Towards Fully-fledged GPU Multitasking via Proactive Memory Scheduling
AI总结:
MSched通过主动内存调度技术,提升GPU多任务处理效率,显著减少页面故障,优化内存使用。
摘要:
有限的HBM容量已成为容纳越来越多大规模GPU任务的主要瓶颈。尽管需求分页通过主机DRAM扩展了容量,但由于巨大的工作集和GPU工作负载的较差局部性,导致速度降低高达78倍。然而,我们发现GPU内存访问模式可以通过内核启动参数及其异步执行性质内在地预测。利用这一点,我们提出了MSched,一个操作系统级别的调度器,将GPU上下文切换扩展到包括主动的工作集准备,从而将碎片化、最终和昂贵的页面故障合并为一次高效的迁移。MSched采用基于模板的方法来预测工作集,其准确性接近完美,并提出一种任务调度器与内存管理器之间的协同设计,以强制实施全局最优的页面放置策略。评估表明,MSched在科学计算和深度学习工作负载中比需求分页快多达11.05倍,在内存过预订情况下,对于LLM快57.88倍。
英文摘要:
Limited HBM capacity has become the primary bottleneck for hosting a growing number of increasingly larger-scale GPU tasks. While demand paging extends capacity via host DRAM, it can incur order-of-magnitude slowdowns due to the massive working sets of GPU workloads. However, we observe that GPU memory accesses are inherently predictable from kernel launch arguments, prior executions, and the asynchronous execution nature. Leveraging this opportunity, we propose MSched, an OS-level scheduler that extends GPU context switching to include proactive working set preparation. This approach coalesces fragmented, eventual, and expensive page faults into a single efficient migration. MSched combines parameterized templates with page fault feedback to accurately predict working sets, and co-designs the task scheduler and memory manager to resolve global access order and enforce near-optimal page replacement. Across scientific, deep learning, and LLM workloads, MSched outperforms demand paging by up to 186.69x and whole-process swapping by up to 8.63x. MSched is open-source and has been integrated into https://github.com/XpuOS/nvxsched.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。