具有 Cuda Thrust 的多个 GPU?

发布于 2024-12-18 02:19:50 字数 84 浏览 2 评论 0原文

如何将 Thrust 与多个 GPU 一起使用? 这只是使用 cudaSetDevice(deviceId) 的问题吗 然后运行相关的Thrust代码?

How do I use Thrust with multiple GPUs?
Is it simply a matter of using cudaSetDevice(deviceId)
and then running the relevant Thrust code?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

银河中√捞星星 2024-12-25 02:19:51

对于 CUDA 4.0 或更高版本,cudaSetDevice(deviceId) 后跟您的推力代码应该可以工作。

请记住,您需要在每个设备上创建和操作单独的向量(除非您的设备支持对等内存访问并且 PCI Express 带宽足以完成您的任务)。

With CUDA 4.0 or later, cudaSetDevice(deviceId) followed by your thrust code should work.

Just keep in mind that you will need to create and operate on separate vectors on each device (unless you have devices that support peer-to-peer memory access and PCI-express bandwidth is sufficient for your task).

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文