RegDem:通过共享存储器寄存器溢出提高GPU性能
RegDem: Increasing GPU Performance via Shared Memory Register Spilling
摘要:
GPU利用率(以占用率衡量)受到并行线程对片上资源(如寄存器和程序员管理的共享内存)的组合使用的限制。更高的资源需求意味着更低的有效并行线程数,从而降低程序性能。我们的调查发现,登记册往往是占用限制器。事实上,基于nvcc编译器的方法将过多的寄存器溢出到片外存储器,忽略了共享存储器,使片内资源未得到充分利用。为了减轻寄存器的需求,本文提出了一种二进制翻译技术,称为RegDem,溢出过多的寄存器,未充分利用的共享内存通过转换GPU汇编代码(SASS)。大多数GPU程序不完全使用共享内存,因此允许RegDem使用它进行寄存器溢出。RegDem实现的更高占用率超过了访问共享内存而不是将数据放置在寄存器中的略高成本。本文还提出了一个编译时的性能预测模型,从一组程序变量中选择最佳版本的指令失速。累积起来,这些技术以9%的几何平均值优于nvcc编译器,最高观察到18%。
英文摘要:
GPU utilization, measured as occupancy, is limited by the parallel threads' combined usage of on-chip resources, such as registers and the programmer-managed shared memory. Higher resource demand means lower effective parallel thread count, and therefore lower program performance. Our investigation found that registers are often the occupancy limiters. The de-facto nvcc compiler-based approach spills excessive registers to the off-chip memory, ignoring the shared memory and leaving the on-chip resources underutilized. To mitigate the register demand, this paper presents a binary translation technique, called RegDem, that spills excessive registers to the underutilized shared memory by transforming the GPU assembly code (SASS). Most GPU programs do not fully use shared memory, thus allowing RegDem to use it for register spilling. The higher occupancy achieved by RegDem outweighs the slightly higher cost of accessing shared memory instead of placing data in registers. The paper also presents a compile-time performance predictor that models instructions stalls to choose the best version from a set of program variants. Cumulatively, these techniques outperform the nvcc compiler with a 9% geometric mean, the highest observed being 18%.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。