[core][pruning][feature] cuSPARSELt build integration (#103700)

Summary:

This stack of PR's integrates cuSPARSELt into PyTorch.

This PR adds support for cuSPARSELt into the build process.
It adds in a new flag, USE_CUSPARSELT that defaults to false.

When USE_CUSPASRELT=1 is specified, the user can also specify
CUSPASRELT_ROOT, which defines the path to the library.

Compiling pytorch with cusparselt support can be done as follows:

``
USE_CUSPARSELT=1
CUSPARSELT_ROOT=/path/to/cusparselt

python setup.py develop
```

Test Plan:

Reviewers:

Subscribers:

Tasks:

Tags:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/103700
Approved by: https://github.com/albanD
This commit is contained in:
Jesse Cai
2023-08-01 12:23:21 -07:00
committed by PyTorch MergeBot
parent d83b887f2a
commit f81f9093ec
11 changed files with 119 additions and 2 deletions

View File

@ -29,10 +29,13 @@
# if used in conjunction with DEBUG or REL_WITH_DEB_INFO, will also
# build CUDA kernels with -lineinfo --source-in-ptx. Note that
# on CUDA 12 this may cause nvcc to OOM, so this is disabled by default.
#
# USE_CUDNN=0
# disables the cuDNN build
#
# USE_CUSPARSELT=0
# disables the cuSPARSELt build
#
# USE_FBGEMM=0
# disables the FBGEMM build
#