Sparse CSR CPU: add addmv_out#61536
Closed
IvanYashchuk wants to merge 51 commits intogh/ivanyashchuk/29/basefrom
Closed
Sparse CSR CPU: add addmv_out#61536IvanYashchuk wants to merge 51 commits intogh/ivanyashchuk/29/basefrom
addmv_out#61536IvanYashchuk wants to merge 51 commits intogh/ivanyashchuk/29/basefrom
Conversation
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). [ghstack-poisoned]
This was referenced Jul 12, 2021
Contributor
🔗 Helpful links
💊 CI failures summary and remediationsAs of commit a3fed53 (more details on the Dr. CI page): 💚 💚 Looks good so far! There are no failures yet. 💚 💚 This comment was automatically generated by Dr. CI (expand for details).Please report bugs/suggestions to the (internal) Dr. CI Users group. |
IvanYashchuk
added a commit
that referenced
this pull request
Jul 12, 2021
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). ghstack-source-id: 97cf0d3 Pull Request resolved: #61536
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). [ghstack-poisoned]
IvanYashchuk
added a commit
that referenced
this pull request
Jul 13, 2021
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). ghstack-source-id: bfaec37 Pull Request resolved: #61536
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). [ghstack-poisoned]
This was referenced Jul 19, 2021
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). [ghstack-poisoned]
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). [ghstack-poisoned]
IvanYashchuk
added a commit
to IvanYashchuk/pytorch
that referenced
this pull request
Jul 26, 2021
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). ghstack-source-id: 862b4b9 Pull Request resolved: pytorch#61536
This was referenced Jul 26, 2021
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). [ghstack-poisoned]
This was referenced Aug 18, 2021
IvanYashchuk
added a commit
to IvanYashchuk/pytorch
that referenced
this pull request
Aug 18, 2021
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). ghstack-source-id: 7d72cca Pull Request resolved: pytorch#61536
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). [ghstack-poisoned]
IvanYashchuk
added a commit
to IvanYashchuk/pytorch
that referenced
this pull request
Aug 19, 2021
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). ghstack-source-id: 11a18f5 Pull Request resolved: pytorch#61536
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). cc nikitaved pearu cpuhrsch IvanYashchuk [ghstack-poisoned]
IvanYashchuk
added a commit
to IvanYashchuk/pytorch
that referenced
this pull request
Oct 26, 2021
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). ghstack-source-id: 6c20256 Pull Request resolved: pytorch#61536
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). cc nikitaved pearu cpuhrsch IvanYashchuk [ghstack-poisoned]
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). cc nikitaved pearu cpuhrsch IvanYashchuk [ghstack-poisoned]
IvanYashchuk
added a commit
to IvanYashchuk/pytorch
that referenced
this pull request
Oct 27, 2021
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). ghstack-source-id: 1530562 Pull Request resolved: pytorch#61536
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). cc nikitaved pearu cpuhrsch IvanYashchuk [ghstack-poisoned]
IvanYashchuk
added a commit
to IvanYashchuk/pytorch
that referenced
this pull request
Oct 28, 2021
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). ghstack-source-id: 92ac146 Pull Request resolved: pytorch#61536
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). cc nikitaved pearu cpuhrsch IvanYashchuk [ghstack-poisoned]
IvanYashchuk
added a commit
to IvanYashchuk/pytorch
that referenced
this pull request
Nov 2, 2021
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). ghstack-source-id: 65032d5 Pull Request resolved: pytorch#61536
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). cc nikitaved pearu cpuhrsch IvanYashchuk [ghstack-poisoned]
IvanYashchuk
added a commit
to IvanYashchuk/pytorch
that referenced
this pull request
Nov 2, 2021
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). ghstack-source-id: efed9f8 Pull Request resolved: pytorch#61536
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). cc nikitaved pearu cpuhrsch IvanYashchuk [ghstack-poisoned]
IvanYashchuk
added a commit
to IvanYashchuk/pytorch
that referenced
this pull request
Nov 3, 2021
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). ghstack-source-id: d8818d5 Pull Request resolved: pytorch#61536
Contributor
|
@cpuhrsch has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator. |
cpuhrsch
approved these changes
Nov 3, 2021
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). cc nikitaved pearu cpuhrsch IvanYashchuk Differential Revision: [D32141787](https://our.internmc.facebook.com/intern/diff/D32141787) [ghstack-poisoned]
IvanYashchuk
added a commit
to IvanYashchuk/pytorch
that referenced
this pull request
Nov 8, 2021
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). ghstack-source-id: dc85dfc Pull Request resolved: pytorch#61536
Contributor
|
@IvanYashchuk - could you rebase please |
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). cc nikitaved pearu cpuhrsch IvanYashchuk Differential Revision: [D32141787](https://our.internmc.facebook.com/intern/diff/D32141787) [ghstack-poisoned]
IvanYashchuk
added a commit
to IvanYashchuk/pytorch
that referenced
this pull request
Nov 9, 2021
This PR adds CPU dispatch for `addmv_out` with Sparse CSR matrix. The implementation uses MKL Sparse library. If it's not available then a runtime error is thrown. Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated. MKL descriptor of sparse matrices is implemented in `at::mkl::sparse::MklSparseCsrDescriptor`. MKL Sparse doesn't allow switching indices type in runtime, it's predetermined in build time. Only 32-bit version of MKL was tested locally, but I expect 64-bit version to work correctly as well. When indices type of PyTorch CSR tensor doesn't match with MKL's, indices tensor is converted to MKL compatible type (`int` vs `int64_t`). ghstack-source-id: 0584a75 Pull Request resolved: pytorch#61536
Contributor
|
Had to make small internal-only change to make it pass CI (add extra header search path), trying to merge now. |
Contributor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stack from ghstack:
triangular_solve_out#62180torch.addmm#65606torch.addwith all inputs sparse #64391addmv_out#61536This PR adds CPU dispatch for
addmv_outwith Sparse CSR matrix.The implementation uses MKL Sparse library. If it's not available then a
runtime error is thrown.
Since structured_delegate is used we only need to implement the out variant, the in-place and normal variants are autogenerated.
MKL descriptor of sparse matrices is implemented in
at::mkl::sparse::MklSparseCsrDescriptor.MKL Sparse doesn't allow switching indices type in runtime, it's
predetermined in build time. Only 32-bit version of MKL was tested
locally, but I expect 64-bit version to work correctly as well.
When indices type of PyTorch CSR tensor doesn't match with MKL's,
indices tensor is converted to MKL compatible type (
intvsint64_t).cc @nikitaved @pearu @cpuhrsch @IvanYashchuk
Differential Revision: D32141787