Is CUDA 10.2 still supported by the latest AMGX commit?
Nobody has claimed this yet.
- Dominant language
- Cuda
- Stars
- 692
- Forks
- 197
- PR merge metrics
- No merged PRs in 30d
Description
Description
Compilation errors when using NVIDIA's CUDA 10.2 Docker image (Container OS: Ubuntu 10.2; gcc 7.5) and the latest CMake (cmake 3.23.1). The error message is nvcc fatal : redefinition of argument 'optimize'. The cause of the error is the multiple -O3 flags in the compilation flags.
It seems nvcc 10.2 does not support multiple -O3 flags? Using the Docker image of CUDA 11.4.3/Ubuntu 20.04/gcc 9.4/Cmake 3.23.1 does not give any error even though the compilation flags also have multiple -O3.
To reproduce
Using NVIDIA's CUDA Docker image (CUDA 10.2; Ubuntu 18.04):
$ docker run -it --rm --gpus all nvidia/cuda:10.2-devel-ubuntu18.04 /bin/bash
Once inside the container, in the interactive shell:
# apt-get update && apt-get install -y curl
# curl -L https://github.com/Kitware/CMake/releases/download/v3.23.1/cmake-3.23.1-linux-x86_64.sh -o /cmake-installer.sh
# sh /cmake-installer.sh --prefix=/usr --exclude-subdir --skip-license
# curl -L https://github.com/NVIDIA/AMGX/tarball/6f14016e420617b4d57580f77b5a2ab4c28a162d -o /amgx.tar.gz
# mkdir /amgx
# tar -xf /amgx.tar.gz -C /amgx --strip-component=1
# cd /amgx
# mkdir build && cd build
# cmake -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -DCMAKE_VERBOSE_MAKEFILE=ON ..
# make
It will show the error message (simplified and organized):
[ 1%] Building CUDA object CMakeFiles/amgx_libs.dir/base/src/aggregation/coarseAgenerators/coarse_A_generator.cu.o
/usr/local/cuda/bin/nvcc
-forward-unknown-to-host-compiler -I/amgx/external/rapidjson/include -I/amgx/base/include -I/amgx/core/include
-I/amgx/core/../base/include -I/amgx/template_plugin/include -I/amgx/template_plugin/../base/include
-I/amgx/template_plugin/../core/include
-O3 -DNDEBUG
--generate-code=arch=compute_35,code=[compute_35,sm_35]
--generate-code=arch=compute_52,code=[compute_52,sm_52]
--generate-code=arch=compute_60,code=[compute_60,sm_60]
--generate-code=arch=compute_70,code=[compute_70,sm_70]
-O3 -DNDEBUG --Werror cross-execution-space-call -DNVTX_RANGES
-Xcompiler=-rdynamic -Xcompiler=-fPIC
-Xcompiler=-fvisibility=default -DDISABLE_MIXED_PRECISION -DCUSPARSE_GENERIC_INTERFACES
-Xcompiler " -Wno-terminate -static-libgcc -fopenmp -DRAPIDJSON_DEFINED"
-std=c++14 -MD
-MT CMakeFiles/amgx_libs.dir/base/src/aggregation/coarseAgenerators/coarse_A_generator.cu.o
-MF CMakeFiles/amgx_libs.dir/base/src/aggregation/coarseAgenerators/coarse_A_generator.cu.o.d
-x cu -c /amgx/base/src/aggregation/coarseAgenerators/coarse_A_generator.cu
-o CMakeFiles/amgx_libs.dir/base/src/aggregation/coarseAgenerators/coarse_A_generator.cu.o
nvcc fatal : redefinition of argument 'optimize'
The error was caused by multiple -O3 flags.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the build in NVIDIA's CUDA 10.2 Ubuntu 18.04 Docker image using CMake 3.23.1 and the referenced AMGX commit. Start with the verbose nvcc command shown in the report and trace where its duplicate -O3 flags are generated; done means the AMGX build completes without the nvcc optimize-argument error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cmake, cpp, docker
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100