|
53 | 53 | if [[ -n "$build_with_cuda" ]]; then
|
54 | 54 | export TORCH_NVCC_FLAGS="-Xfatbin -compress-all"
|
55 | 55 | TORCH_CUDA_ARCH_LIST="5.0;6.0;6.1;7.0;7.5;8.0;8.6"
|
56 |
| - export USE_STATIC_CUDNN=1 # links cudnn statically (driven by tools/setup_helpers/cudnn.py) |
| 56 | + export USE_STATIC_CUDNN=0 # link with cudnn dynamically |
| 57 | + export USE_CUSPARSELT=1 # link with cusparselt |
57 | 58 |
|
58 | 59 | if [[ $CUDA_VERSION == 11.8* ]]; then
|
59 |
| - TORCH_CUDA_ARCH_LIST="$TORCH_CUDA_ARCH_LIST;3.7+PTX;9.0" |
60 |
| - #for cuda 11.8 we use cudnn 8.7 |
61 |
| - #which does not have single static libcudnn_static.a deliverable to link with |
62 |
| - export USE_STATIC_CUDNN=0 |
63 |
| - #for cuda 11.8 include all dynamic loading libraries |
64 |
| - DEPS_LIST=(/usr/local/cuda/lib64/libcudnn*.so.8 /usr/local/cuda-11.8/extras/CUPTI/lib64/libcupti.so.11.8) |
| 60 | + TORCH_CUDA_ARCH_LIST="$TORCH_CUDA_ARCH_LIST;3.7+PTX;9.0" |
| 61 | + #for cuda 11.8 include all dynamic loading libraries |
| 62 | + DEPS_LIST=(/usr/local/cuda/lib64/libcudnn*.so.8 /usr/local/cuda-11.8/extras/CUPTI/lib64/libcupti.so.11.8 /usr/local/cuda/lib64/libcusparseLt.so.0) |
65 | 63 | elif [[ $CUDA_VERSION == 12.1* ]]; then
|
66 |
| - # cuda 12 does not support sm_3x |
67 |
| - TORCH_CUDA_ARCH_LIST="$TORCH_CUDA_ARCH_LIST;9.0" |
68 |
| - # for cuda 12.1 we use cudnn 8.8 and include all dynamic loading libraries |
69 |
| - export USE_STATIC_CUDNN=0 |
70 |
| - DEPS_LIST=(/usr/local/cuda/lib64/libcudnn*.so.8 /usr/local/cuda-12.1/extras/CUPTI/lib64/libcupti.so.12) |
| 64 | + # cuda 12 does not support sm_3x |
| 65 | + TORCH_CUDA_ARCH_LIST="$TORCH_CUDA_ARCH_LIST;9.0" |
| 66 | + # for cuda 12.1 we use cudnn 8.8 and include all dynamic loading libraries |
| 67 | + DEPS_LIST=(/usr/local/cuda/lib64/libcudnn*.so.8 /usr/local/cuda-12.1/extras/CUPTI/lib64/libcupti.so.12 /usr/local/cuda/lib64/libcusparseLt.so.0) |
71 | 68 | fi
|
72 | 69 | if [[ -n "$OVERRIDE_TORCH_CUDA_ARCH_LIST" ]]; then
|
73 | 70 | TORCH_CUDA_ARCH_LIST="$OVERRIDE_TORCH_CUDA_ARCH_LIST"
|
|
0 commit comments