Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ endif()
if (ENABLE_CUSPARSE)
set(SPBLAS_GPU_BACKEND ON)
find_package(CUDAToolkit REQUIRED)
enable_language(CUDA)
target_link_libraries(spblas INTERFACE CUDA::cudart CUDA::cusparse CUDA::cublas)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DSPBLAS_ENABLE_CUSPARSE")
endif()
Expand Down
1 change: 1 addition & 0 deletions include/spblas/vendor/cusparse/cusparse.hpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#pragma once

#include "multiply.hpp"
#include "multiply_spgemm.hpp"
4 changes: 2 additions & 2 deletions include/spblas/vendor/cusparse/exception.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ namespace spblas {
namespace __cusparse {

// Throw an exception if the cudaError_t is not cudaSuccess.
void throw_if_error(cudaError_t error_code, std::string prefix = "") {
inline void throw_if_error(cudaError_t error_code, std::string prefix = "") {
if (error_code == cudaSuccess) {
return;
}
Expand All @@ -21,7 +21,7 @@ void throw_if_error(cudaError_t error_code, std::string prefix = "") {
}

// Throw an exception if the cusparseStatus_t is not CUSPARSE_STATUS_SUCCESS.
void throw_if_error(cusparseStatus_t error_code) {
inline void throw_if_error(cusparseStatus_t error_code) {
if (error_code == CUSPARSE_STATUS_SUCCESS) {
return;
} else if (error_code == CUSPARSE_STATUS_NOT_INITIALIZED) {
Expand Down
Loading
Loading