nvcc致命错误:'--ptxas-options=-v':预期为数字

3
当我尝试构建 Faster-RCNN 的 Windows 版本,遇到了nvcc fatal : '--ptxas-options=-v': expected a number错误。您可以直接从这里访问设置文件(一个Python脚本)。
软件环境:
- CUDA v10.1
- VS 2019
- Python 3.7
- Windows 10
1个回答

3

这个配置行在CUDA 10.1中已经不再正确:

nvcc_compile_args = ['-O', '--ptxas-options=-v', '-arch=sm_35', '-c', '--compiler-options=-fPIC']

这将生成一个类似于以下命令的nvcc编译命令:

nvcc -O ...

在CUDA 10.0及以前的版本中,这样的命令是合法的。但在CUDA 10.1中不再合法。这个开关会传递宿主代码的优化级别,因此除非有特殊原因,建议在此处传递-O3

nvcc_compile_args = ['-O3', '--ptxas-options=-v', '-arch=sm_35', '-c', '--compiler-options=-fPIC']

相关文档链接在这里


网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接