15 #ifdef ETL_EGBLAS_MODE 17 #include "etl/impl/cublas/cuda.hpp" 25 #ifdef EGBLAS_HAS_SAPXDBPY_3 26 static constexpr
bool has_sapxdbpy_3 =
true;
28 static constexpr
bool has_sapxdbpy_3 =
false;
40 inline void apxdbpy_3([[maybe_unused]]
size_t n, [[maybe_unused]]
float alpha, [[maybe_unused]]
float* A, [[maybe_unused]]
size_t lda, [[maybe_unused]]
float beta, [[maybe_unused]]
float* B, [[maybe_unused]]
size_t ldb, [[maybe_unused]]
float* C, [[maybe_unused]]
size_t ldc) {
41 #ifdef EGBLAS_HAS_SAPXDBPY_3 43 egblas_sapxdbpy_3(n, alpha, A, lda, beta, B, ldb, C, ldc);
45 cpp_unreachable(
"Invalid call to egblas::apxdbpy_3");
49 #ifdef EGBLAS_HAS_DAPXDBPY_3 50 static constexpr
bool has_dapxdbpy_3 =
true;
52 static constexpr
bool has_dapxdbpy_3 =
false;
64 inline void apxdbpy_3([[maybe_unused]]
size_t n, [[maybe_unused]]
double alpha, [[maybe_unused]]
double* A, [[maybe_unused]]
size_t lda, [[maybe_unused]]
double beta, [[maybe_unused]]
double* B, [[maybe_unused]]
size_t ldb, [[maybe_unused]]
double* C, [[maybe_unused]]
size_t ldc) {
65 #ifdef EGBLAS_HAS_DAPXDBPY_3 67 egblas_dapxdbpy_3(n, alpha, A, lda, beta, B, ldb, C, ldc);
69 cpp_unreachable(
"Invalid call to egblas::apxdbpy_3");
73 #ifdef EGBLAS_HAS_CAPXDBPY_3 74 static constexpr
bool has_capxdbpy_3 =
true;
76 static constexpr
bool has_capxdbpy_3 =
false;
89 [[maybe_unused]] std::complex<float> alpha,
90 [[maybe_unused]] std::complex<float>* A,
91 [[maybe_unused]]
size_t lda,
92 [[maybe_unused]] std::complex<float> beta,
93 [[maybe_unused]] std::complex<float>* B,
94 [[maybe_unused]]
size_t ldb,
95 [[maybe_unused]] std::complex<float>* C,
96 [[maybe_unused]]
size_t ldc) {
97 #ifdef EGBLAS_HAS_CAPXDBPY_3 99 egblas_capxdbpy_3(n, complex_cast(alpha), reinterpret_cast<cuComplex*>(A), lda, complex_cast(beta), reinterpret_cast<cuComplex*>(B), ldb,
100 reinterpret_cast<cuComplex*>(C), ldc);
102 cpp_unreachable(
"Invalid call to egblas::apxdbpy_3");
118 [[maybe_unused]]
size_t lda,
121 [[maybe_unused]]
size_t ldb,
123 [[maybe_unused]]
size_t ldc) {
124 #ifdef EGBLAS_HAS_CAPXDBPY_3 126 egblas_capxdbpy_3(n, complex_cast(alpha), reinterpret_cast<cuComplex*>(A), lda, complex_cast(beta), reinterpret_cast<cuComplex*>(B), ldb,
127 reinterpret_cast<cuComplex*>(C), ldc);
129 cpp_unreachable(
"Invalid call to egblas::apxdbpy");
133 #ifdef EGBLAS_HAS_ZAPXDBPY_3 134 static constexpr
bool has_zapxdbpy_3 =
true;
136 static constexpr
bool has_zapxdbpy_3 =
false;
149 [[maybe_unused]] std::complex<double> alpha,
150 [[maybe_unused]] std::complex<double>* A,
151 [[maybe_unused]]
size_t lda,
152 [[maybe_unused]] std::complex<double> beta,
153 [[maybe_unused]] std::complex<double>* B,
154 [[maybe_unused]]
size_t ldb,
155 [[maybe_unused]] std::complex<double>* C,
156 [[maybe_unused]]
size_t ldc) {
157 #ifdef EGBLAS_HAS_ZAPXDBPY_3 159 egblas_zapxdbpy_3(n, complex_cast(alpha), reinterpret_cast<cuDoubleComplex*>(A), lda, complex_cast(beta), reinterpret_cast<cuDoubleComplex*>(B), ldb,
160 reinterpret_cast<cuDoubleComplex*>(C), ldc);
162 cpp_unreachable(
"Invalid call to egblas::apxdbpy_3");
178 [[maybe_unused]]
size_t lda,
181 [[maybe_unused]]
size_t ldb,
183 [[maybe_unused]]
size_t ldc) {
184 #ifdef EGBLAS_HAS_ZAPXDBPY_3 186 egblas_zapxdbpy_3(n, complex_cast(alpha), reinterpret_cast<cuDoubleComplex*>(A), lda, complex_cast(beta), reinterpret_cast<cuDoubleComplex*>(B), ldb,
187 reinterpret_cast<cuDoubleComplex*>(C), ldc);
189 cpp_unreachable(
"Invalid call to egblas::apxdbpy_3");
Complex number implementation.
Definition: complex.hpp:31
void apxdbpy_3([[maybe_unused]] size_t n, [[maybe_unused]] float alpha, [[maybe_unused]] float *A, [[maybe_unused]] size_t lda, [[maybe_unused]] float beta, [[maybe_unused]] float *B, [[maybe_unused]] size_t ldb, [[maybe_unused]] float *C, [[maybe_unused]] size_t ldc)
Wrappers for single-precision egblas apxdbpy operation.
Definition: apxdbpy_3.hpp:40
void inc_counter([[maybe_unused]] const char *name)
Increase the given counter.
Definition: counters.hpp:25