nvidia GTS 450 有多少个线程
亲爱的朋友们: 我想学习CUDA编程,我买了一辆Nvidia GTS 450 PCI_E汽车。它有192个SM,那么它有多少个线程。 192 个线程?还是192*512线程? 问候
Dear friends:
i am want to study the CUDA programming, i bought a Nvidia GTS 450 PCI_E car. it has 192 SMs, then how many threads does it has. 192 threads? or 192*512 threads?
Regards
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
在 CUDA 中,术语
线程
指的是特定内核调用的属性,而不是硬件的属性。例如,在此 CUDA 调用中:
2 个块中有 32 个线程,因此总共有 64 个线程。
硬件自动将线程调度到处理器。
in CUDA the term
threads
refers to the a property of a specific kernel invocation, not of a property of the hardware.For instance in this CUDA invocation:
you have 32 threads in 2 blocks so 64 threads in total.
The hardware schedules threads to processors automatically.
根据规格,您的设备有 192 “处理器核心” - 这些与 SM 不同。在 CUDA 中,SM 是一个多处理器,它以锁步方式执行多个线程(1.3 系列设备有 8 个线程,更高版本的设备有更多线程)。
正如 shoosh 指出的那样,使用的线程数是内核调用的函数。
通常,为了在 CUDA 中获得良好的性能,您应该运行比 CUDA 处理器核心多得多的线程 - 这是为了隐藏全局内存访问的延迟。
According to the specs, your device has 192 "processor cores" - these are not the same as SMs. In CUDA, a SM is a multiprocessor that executes multiple threads in lockstep (8 for the 1.3 family of devices, more for later devices).
As shoosh pointed out, the number of threads used is a function of your kernel invocation.
Typically to get good performance in CUDA, you should run many more threads than you have CUDA processor cores - this is to hide the latency of your global memory accesses.