5#include <hip/hip_runtime_api.h>
6#include <hip/hip_version.h>
9#define HIP_CHECK(STAT) \
11 const hipError_t stat = (STAT); \
12 if(stat != hipSuccess) \
14 std::ostringstream oss; \
15 oss << "rocsparseSolverBackend::hip "; \
16 oss << "error: " << hipGetErrorString(stat); \
17 OPM_THROW(std::logic_error, oss.str()); \
21#define ROCSPARSE_CHECK(STAT) \
23 const rocsparse_status stat = (STAT); \
24 if(stat != rocsparse_status_success) \
26 std::ostringstream oss; \
27 oss << "rocsparseSolverBackend::rocsparse "; \
28 oss << "error: " << stat; \
29 OPM_THROW(std::logic_error, oss.str()); \
33#define ROCBLAS_CHECK(STAT) \
35 const rocblas_status stat = (STAT); \
36 if(stat != rocblas_status_success) \
38 std::ostringstream oss; \
39 oss << "rocsparseSolverBackend::rocblas "; \
40 oss << "error: " << stat; \
41 OPM_THROW(std::logic_error, oss.str()); \
49 const unsigned int B);
Definition: amgclSolverBackend.hpp:44
void solve_transposed_3x3(const Scalar *A, const Scalar *b, Scalar *x)
unsigned int ceilDivision(const unsigned int A, const unsigned int B)
Scalar get_absmax(const Scalar *data, const int N)