摘要: 统一计算设备架构(CUDA)程序移植到其他异构众核架构时的线程数不匹配。为此,提出一种层次化的线程映射模型。在第1个映射层次上,将CUDA主机端线程和设备端线程分别映射到目标平台的主核和从核阵列上,在第2个映射层次上,采用线程循环的方法消除协作线程阵列(CTA)中线程间同步操作,将整个CTA映射到从核阵列的一个从核上。实验结果表明,该模型能使CUDA程序在其他异构众核系统上得到有效运行。
关键词:
代码移植,
图形处理器,
统一计算设备架构,
异构众核架构,
流式多处理器,
线程循环
Abstract: Aiming at the problem that the number of threads is not matched when migrating Compute Unified Device Architecture(CUDA) programs to other heterogeneous many-core architecture, the paper proposes a hierarchical thread mapping model. In the first level, the model maps the host threads and device threads of CUDA to the target platform’s master core and slave core array respectively. In the second level, the model removes synchronization operations of Cooperative Threads Array(CTA) threads by thread loop, and maps the whole CTA to a slave core. Experimental results show that the model allows CUDA programs to be implemented effectively in other heterogeneous many-core systems.
Key words:
code transplantation,
Graphics Processing Unit(GPU),
Compute Unified Device Architecture(CUDA),
heterogeneous many-core architecture,
Streaming Multiprocessor(SM),
thread cycle
中图分类号:
余勇, 庞建民, 单征, 刘晓楠. CUDA到异构众核架构的线程映射模型[J]. 计算机工程, 2012, 38(9): 282-284,287.
TU Yong, LONG Jian-Min, CHAN Zheng, LIU Xiao-Nan. Thread Mapping Model from CUDA to Heterogeneous Many-core Architecture[J]. Computer Engineering, 2012, 38(9): 282-284,287.