fastllm icon indicating copy to clipboard operation
fastllm copied to clipboard

编译问题

Open chestnut111 opened this issue 2 years ago • 9 comments

cmake .. -DUSE_CUDA=ON -- The CUDA compiler identification is unknown CMake Error at ..a/share/cmake-3.26/Modules/CMakeDetermineCUDACompiler.cmake:603 (message): Compiler output: Call Stack (most recent call first): CMakeLists.txt:39 (enable_language) -- Configuring incomplete, errors occurred!

chestnut111 avatar Jul 26 '23 06:07 chestnut111

NVCC正常吗?这个报错看起来是没找到CUDA编译器

ztxz16 avatar Jul 26 '23 07:07 ztxz16

cmake .. -DUSE_CUDA=ON -D CMAKE_CUDA_COMPILER=/usr/local/cuda/bin/nvcc ===> CMake Error at ... lib/python3.8/site-packages/cmake/data/share/cmake-3.26/Modules/CMakeDetermineCUDACompiler.cmake:277 CMAKE_CUDA_ARCHITECTURES must be non-empty if set. Call Stack (most recent call first): CMakeLists.txt:39 (enable_language)

chestnut111 avatar Jul 26 '23 09:07 chestnut111

@ztxz16 可以指定NVCC,但是会报上面的问题,CMAKE_CUDA_ARCHITECTURES 指定的话,不知道要设置多少

chestnut111 avatar Jul 27 '23 07:07 chestnut111

刚发现cmake可以成功 但是make -j 时报错 nvcc fatal : Unsupported gpu architecture 'compute_86'

chestnut111 avatar Jul 27 '23 07:07 chestnut111

是CUDA版本问题吗、我这边是 10.1

chestnut111 avatar Jul 27 '23 07:07 chestnut111

https://forums.developer.nvidia.com/t/nvcc-fatal-unsupported-gpu-architecture-compute-86/161424 根据这里的说明,应该是你的cuda版本过低

kiranosora avatar Jul 29 '23 03:07 kiranosora

sudo cmake .. -DUSE_CUDA=ON -D CMAKE_CUDA_COMPILER=/usr/local/cuda/bin/nvcc -DCMAKE_CUDA_ARCHITECTURES=75

luosiwu avatar Sep 15 '23 13:09 luosiwu

cmake的时候报下面错误,怎么解决: -- The CXX compiler identification is GNU 7.5.0 -- Check for working CXX compiler: /usr/bin/c++ -- Check for working CXX compiler: /usr/bin/c++ -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Detecting CXX compile features -- Detecting CXX compile features - done -- USE_CUDA: ON -- PYTHON_API: OFF -- USE_SENTENCEPIECE: OFF -- CMAKE_CXX_FLAGS -pthread --std=c++17 -O2 -march=native -- The CUDA compiler identification is NVIDIA 11.3.109 -- Check for working CUDA compiler: /usr/local/cuda/bin/nvcc -- Check for working CUDA compiler: /usr/local/cuda/bin/nvcc -- works -- Detecting CUDA compiler ABI info -- Detecting CUDA compiler ABI info - done CMake Error at CMakeLists.txt:50 (add_compile_definitions): Unknown CMake command "add_compile_definitions".

PeterXiaTian avatar Dec 18 '23 08:12 PeterXiaTian

是CUDA版本问题吗、我这边是 10.1

这个问题解决了吗?我也碰到了

nvcc fatal : Unsupported gpu architecture 'compute_native'

PeterXiaTian avatar Dec 19 '23 07:12 PeterXiaTian