RLWS:一种基于强化学习的GPU Warp神经网络
RLWS: A Reinforcement Learning based GPU Warp Scheduler
摘要:
图形处理单元(GPU)的流式多处理器(SM)执行来自一组连续线程(称为线程束)的指令。在每个周期,SM调度来自一组活动线程束的线程束,并且可以在活动线程束之间进行上下文切换以隐藏各种停顿。因此,线程调度器的性能对GPU的性能至关重要。已经提出了几种启发式翘曲调度算法,它们只适用于它们所设计的情况。GPU工作负载在本质上变得非常多样化,因此一种启发式算法可能不适用于所有情况。为了在不同的工作负载范围内工作,这可能会表现出迄今为止看不见的特点,翘曲调度算法必须能够适应在线。我们提出了一种基于强化学习的Warp调度器(RLWS),它根据内核的当前状态和调度动作的长期利益来学习调度Warp,不仅适应不同类型的工作负载,还适应每个工作负载中的不同执行阶段。由于RLWS所使用的状态变量和参数(如学习率和探索率、奖励值和惩罚值)的设计空间很大,我们使用遗传算法来识别状态变量和参数值的有用子集。我们使用GPGPU-SIM模拟器对Rodinia、Parboil、CUDA-SDK和GPGPGPU-SIM基准套件中的大量工作负载进行了评估,并与其他最先进的翘曲调度方法进行了比较。我们的基于RL的实现在80%的内核中实现了最佳或非常接近最佳性能,平均加速比为1.06倍于松散轮循策略和1.07倍于两级策略。
英文摘要:
The Streaming Multiprocessors (SMs) of a Graphics Processing Unit (GPU) execute instructions from a group of consecutive threads, called warps. At each cycle, an SM schedules a warp from a group of active warps and can context switch among the active warps to hide various stalls. Hence the performance of warp scheduler is critical to the performance of GPU. Several heuristic warp scheduling algorithms have been proposed which work well only for the situations they are designed for. GPU workloads are becoming very diverse in nature and hence one heuristic may not work for all cases. To work well over a diverse range of workloads, which might exhibit hitherto unseen characteristics, a warp scheduling algorithm must be able to adapt on-line. We propose a Reinforcement Learning based Warp Scheduler (RLWS) which learns to schedule warps based on the current state of the core and the long-term benefits of scheduling actions, adapting not only to different types of workloads, but also to different execution phases in each workload. As the design space involving the state variables and the parameters (such as learning and exploration rates, reward and penalty values) used by RLWS is large, we use Genetic Algorithm to identify the useful subset of state variables and parameter values. We evaluated the proposed RLWS using the GPGPU-SIM simulator on a large number of workloads from the Rodinia, Parboil, CUDA-SDK and GPGPU-SIM benchmark suites and compared with other state-of-the-art warp scheduling methods. Our RL based implementation achieved either the best or very close to the best performance in 80\% of kernels with an average speedup of 1.06x over the Loose Round Robin strategy and 1.07x over the Two-Level strategy.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。