CUDA编程指南指出:
the driver API is backward compatible, meaning that applications, plug-ins, and libraries (including the C runtime) compiled against a particular version of the driver API will continue to work on subsequent device driver releases我的理解是,如果我的代码是在CUDA4上编译的,那么二进制文件就会在CUDA5上运行。然而,事实证明,在CUDA5上运行CUDA5编译的二进制文件会导致:
error while loading shared libraries: libcudart.so.4: cannot open shared object file: No such file or directory请注意,我正在使用Linux中的"module“工具在不同的cuda版本之间进行切换。
module load cuda4
compile
module unload cuda4
module load cuda5
run发布于 2013-02-15 09:07:09
开发人员负责将libcudart.so.4与应用程序打包在一起。module命令可能会更改LD_LIBRARY_PATH或PATH变量,因此LDD找不到libcudart.so.4。我建议您添加一个构建后步骤,将所需的.so复制到您的应用程序目录中。
CUDA工具包目录根目录下的EULA.txt中的附件A列出了可再发行软件。这包括libcudart.so (以及在文件名中嵌入了版本号信息的变体)。这也包括libcufft,libcublas,...
https://stackoverflow.com/questions/14886550
复制相似问题