java - 如何导出CUDA(jcuda)程序

标签 java eclipse cuda executable jcuda

我刚刚使用 JCUDA 开发了我的第一个程序(在 eclipse 上),我想在其他没有我用来开发它的 nvidia 驱动程序和编译器的计算机上执行它。

如何将可执行文件导出到另一台计算机并执行它而不重新编译代码?

任何帮助将不胜感激

最佳答案

(抱歉,如果您希望获得分步手册,这可能无法完全回答您的问题。我会考虑在这里做一些实验,也许会扩展这个答案或在网站上添加信息)

<小时/>

对于驱动程序 API,目标系统上的 CUDA 版本必须至少是相应的 JCuda 版本 - 否则,将根本不支持较新的 CUDA 功能。

关于运行时库,引用CUDA FAQ :

Q: What do I need to distribute my CUDA application?

Applications that use the driver API only need the CUDA driver library ("nvcuda.dll" under Windows), which is included as part of the standard NVIDIA driver install.

Applications that use the runtime API also require the runtime library ("cudart.dll" under Windows), which is included in the CUDA Toolkit. It is permissible to distribute this library with your application under the terms of the End User License Agreement included with the CUDA Toolkit.

因此,如果有疑问,您可以将用于编译应用程序的“cudart.dll”包含到分发包中。

较新版本的 CUDA 还支持针对运行时 DLL 的静态链接,但这对于 JCuda 运行时库还没有完成。

关于java - 如何导出CUDA(jcuda)程序,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/30304658/

相关文章:

java - 受限玻尔兹曼机中的自由能近似方程

java - 在 Eclipse 中将外部 .class 文件链接到包结构中?

java - 从 Netbeans 转移到 Eclipse,现在 "Severe: PWC6117: File "null“未找到”

java - 我可以在创建类(class)后将它们组织到文件夹中并且它们仍然有效吗?

c++ - 具有文件夹结构的 CUDA 和 C++ - 通用 makefile

c - 计时 CUDA 操作

java - 定义用于多种方法的变量

java - 最好的 DRY if 语句?

java - 将csv文件读取到arraylist对象

c++11 - 使用 CMake 在 NVCC 中触发 C++11 支持