def_atlas.hpp (armadillo-10.8.2.tar.xz) | : | def_atlas.hpp (armadillo-11.0.0.tar.xz) | ||
---|---|---|---|---|
skipping to change at line 18 | skipping to change at line 18 | |||
// You may obtain a copy of the License at | // You may obtain a copy of the License at | |||
// http://www.apache.org/licenses/LICENSE-2.0 | // http://www.apache.org/licenses/LICENSE-2.0 | |||
// | // | |||
// Unless required by applicable law or agreed to in writing, software | // Unless required by applicable law or agreed to in writing, software | |||
// distributed under the License is distributed on an "AS IS" BASIS, | // distributed under the License is distributed on an "AS IS" BASIS, | |||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | |||
// See the License for the specific language governing permissions and | // See the License for the specific language governing permissions and | |||
// limitations under the License. | // limitations under the License. | |||
// ------------------------------------------------------------------------ | // ------------------------------------------------------------------------ | |||
#ifdef ARMA_USE_ATLAS | // TODO: remove support for ATLAS in next major version | |||
//! \namespace atlas namespace for ATLAS functions (imported from the global nam | #if defined(ARMA_USE_ATLAS) | |||
espace) | ||||
namespace atlas | typedef enum | |||
{ | { | |||
using ::CblasColMajor; | atlas_CblasRowMajor = 101, | |||
using ::CblasNoTrans; | atlas_CblasColMajor = 102 | |||
using ::CblasTrans; | } | |||
using ::CblasConjTrans; | atlas_CBLAS_LAYOUT; | |||
using ::CblasLower; | ||||
using ::CblasUpper; | typedef enum | |||
{ | ||||
#if defined(ARMA_USE_WRAPPER) | atlas_CblasNoTrans = 111, | |||
extern "C" | atlas_CblasTrans = 112, | |||
{ | atlas_CblasConjTrans = 113 | |||
float wrapper_cblas_sasum(const int N, const float *X, const int incX); | } | |||
double wrapper_cblas_dasum(const int N, const double *X, const int incX); | atlas_CBLAS_TRANS; | |||
float wrapper_cblas_snrm2(const int N, const float *X, const int incX); | typedef enum | |||
double wrapper_cblas_dnrm2(const int N, const double *X, const int incX); | { | |||
atlas_CblasUpper = 121, | ||||
float wrapper_cblas_sdot(const int N, const float *X, const int incX, cons | atlas_CblasLower = 122 | |||
t float *Y, const int incY); | } | |||
double wrapper_cblas_ddot(const int N, const double *X, const int incX, cons | atlas_CBLAS_UPLO; | |||
t double *Y, const int incY); | ||||
extern "C" | ||||
void wrapper_cblas_cdotu_sub(const int N, const void *X, const int incX, con | { | |||
st void *Y, const int incY, void *dotu); | float arma_wrapper(cblas_sasum)(const int N, const float *X, const int incX) | |||
void wrapper_cblas_zdotu_sub(const int N, const void *X, const int incX, con | ; | |||
st void *Y, const int incY, void *dotu); | double arma_wrapper(cblas_dasum)(const int N, const double *X, const int incX) | |||
; | ||||
void wrapper_cblas_sgemv(const enum CBLAS_ORDER Order, const enum CBLAS_TRAN | ||||
SPOSE TransA, const int M, const int N, const float alpha, | float arma_wrapper(cblas_snrm2)(const int N, const float *X, const int incX) | |||
const float *A, const int lda, const float *X, cons | ; | |||
t int incX, const float beta, float *Y, const int incY); | double arma_wrapper(cblas_dnrm2)(const int N, const double *X, const int incX) | |||
; | ||||
void wrapper_cblas_dgemv(const enum CBLAS_ORDER Order, const enum CBLAS_TRAN | ||||
SPOSE TransA, const int M, const int N, const double alpha, | float arma_wrapper(cblas_sdot)(const int N, const float *X, const int incX, | |||
const double *A, const int lda, const double *X, co | const float *Y, const int incY); | |||
nst int incX, const double beta, double *Y, const int incY); | double arma_wrapper(cblas_ddot)(const int N, const double *X, const int incX, | |||
const double *Y, const int incY); | ||||
void wrapper_cblas_cgemv(const enum CBLAS_ORDER Order, const enum CBLAS_TRAN | ||||
SPOSE TransA, const int M, const int N, const void *alpha, | void arma_wrapper(cblas_cdotu_sub)(const int N, const void *X, const int incX, | |||
const void *A, const int lda, const void *X, const | const void *Y, const int incY, void *dotu); | |||
int incX, const void *beta, void *Y, const int incY); | void arma_wrapper(cblas_zdotu_sub)(const int N, const void *X, const int incX, | |||
const void *Y, const int incY, void *dotu); | ||||
void wrapper_cblas_zgemv(const enum CBLAS_ORDER Order, const enum CBLAS_TRAN | ||||
SPOSE TransA, const int M, const int N, const void *alpha, | void arma_wrapper(cblas_sgemv)(const atlas_CBLAS_LAYOUT layout, const atlas_CB | |||
const void *A, const int lda, const void *X, const | LAS_TRANS TransA, const int M, const int N, const float alpha, const float *A | |||
int incX, const void *beta, void *Y, const int incY); | , const int lda, const float *X, const int incX, const float beta, float *Y, | |||
const int incY); | ||||
void wrapper_cblas_sgemm(const enum CBLAS_ORDER Order, const enum CBLAS_TRAN | void arma_wrapper(cblas_dgemv)(const atlas_CBLAS_LAYOUT layout, const atlas_CB | |||
SPOSE TransA, const enum CBLAS_TRANSPOSE TransB, | LAS_TRANS TransA, const int M, const int N, const double alpha, const double *A | |||
const int M, const int N, const int K, const float | , const int lda, const double *X, const int incX, const double beta, double *Y, | |||
alpha, | const int incY); | |||
const float *A, const int lda, const float *B, cons | void arma_wrapper(cblas_cgemv)(const atlas_CBLAS_LAYOUT layout, const atlas_CB | |||
t int ldb, const float beta, float *C, const int ldc); | LAS_TRANS TransA, const int M, const int N, const void *alpha, const void *A | |||
, const int lda, const void *X, const int incX, const void *beta, void *Y, | ||||
void wrapper_cblas_dgemm(const enum CBLAS_ORDER Order, const enum CBLAS_TRAN | const int incY); | |||
SPOSE TransA, const enum CBLAS_TRANSPOSE TransB, | void arma_wrapper(cblas_zgemv)(const atlas_CBLAS_LAYOUT layout, const atlas_CB | |||
const int M, const int N, const int K, const double | LAS_TRANS TransA, const int M, const int N, const void *alpha, const void *A | |||
alpha, | , const int lda, const void *X, const int incX, const void *beta, void *Y, | |||
const double *A, const int lda, const double *B, co | const int incY); | |||
nst int ldb, const double beta, double *C, const int ldc); | ||||
void arma_wrapper(cblas_sgemm)(const atlas_CBLAS_LAYOUT layout, const atlas_CB | ||||
void wrapper_cblas_cgemm(const enum CBLAS_ORDER Order, const enum CBLAS_TRAN | LAS_TRANS TransA, const atlas_CBLAS_TRANS TransB, const int M, const int N, cons | |||
SPOSE TransA, const enum CBLAS_TRANSPOSE TransB, | t int K, const float alpha, const float *A, const int lda, const float *B, c | |||
const int M, const int N, const int K, const void * | onst int ldb, const float beta, float *C, const int ldc); | |||
alpha, | void arma_wrapper(cblas_dgemm)(const atlas_CBLAS_LAYOUT layout, const atlas_CB | |||
const void *A, const int lda, const void *B, const | LAS_TRANS TransA, const atlas_CBLAS_TRANS TransB, const int M, const int N, cons | |||
int ldb, const void *beta, void *C, const int ldc); | t int K, const double alpha, const double *A, const int lda, const double *B, c | |||
onst int ldb, const double beta, double *C, const int ldc); | ||||
void wrapper_cblas_zgemm(const enum CBLAS_ORDER Order, const enum CBLAS_TRAN | void arma_wrapper(cblas_cgemm)(const atlas_CBLAS_LAYOUT layout, const atlas_CB | |||
SPOSE TransA, const enum CBLAS_TRANSPOSE TransB, | LAS_TRANS TransA, const atlas_CBLAS_TRANS TransB, const int M, const int N, cons | |||
const int M, const int N, const int K, const void * | t int K, const void *alpha, const void *A, const int lda, const void *B, c | |||
alpha, | onst int ldb, const void *beta, void *C, const int ldc); | |||
const void *A, const int lda, const void *B, const | void arma_wrapper(cblas_zgemm)(const atlas_CBLAS_LAYOUT layout, const atlas_CB | |||
int ldb, const void *beta, void *C, const int ldc); | LAS_TRANS TransA, const atlas_CBLAS_TRANS TransB, const int M, const int N, cons | |||
t int K, const void *alpha, const void *A, const int lda, const void *B, c | ||||
void wrapper_cblas_ssyrk(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO | onst int ldb, const void *beta, void *C, const int ldc); | |||
Uplo, const enum CBLAS_TRANSPOSE Trans, | ||||
const int N, const int K, const float alpha, | void arma_wrapper(cblas_ssyrk)(const atlas_CBLAS_LAYOUT layout, const atlas_CB | |||
const float *A, const int lda, const float beta, fl | LAS_UPLO Uplo, const atlas_CBLAS_TRANS Trans, const int N, const int K, const fl | |||
oat *C, const int ldc); | oat alpha, const float *A, const int lda, const float beta, float *C, const | |||
int ldc); | ||||
void wrapper_cblas_dsyrk(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO | void arma_wrapper(cblas_dsyrk)(const atlas_CBLAS_LAYOUT layout, const atlas_CB | |||
Uplo, const enum CBLAS_TRANSPOSE Trans, | LAS_UPLO Uplo, const atlas_CBLAS_TRANS Trans, const int N, const int K, const do | |||
const int N, const int K, const double alpha, | uble alpha, const double *A, const int lda, const double beta, double *C, const | |||
const double *A, const int lda, const double beta, | int ldc); | |||
double *C, const int ldc); | ||||
void arma_wrapper(cblas_cherk)(const atlas_CBLAS_LAYOUT layout, const atlas_CB | ||||
void wrapper_cblas_cherk(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO | LAS_UPLO Uplo, const atlas_CBLAS_TRANS Trans, const int N, const int K, const fl | |||
Uplo, const enum CBLAS_TRANSPOSE Trans, | oat alpha, const void *A, const int lda, const float beta, void *C, const int | |||
const int N, const int K, const float alpha, | ldc); | |||
const void *A, const int lda, const float beta, voi | void arma_wrapper(cblas_zherk)(const atlas_CBLAS_LAYOUT layout, const atlas_CB | |||
d *C, const int ldc); | LAS_UPLO Uplo, const atlas_CBLAS_TRANS Trans, const int N, const int K, const do | |||
uble alpha, const void *A, const int lda, const double beta, void *C, const int | ||||
void wrapper_cblas_zherk(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO | ldc); | |||
Uplo, const enum CBLAS_TRANSPOSE Trans, | ||||
const int N, const int K, const double alpha, | ||||
const void *A, const int lda, const double beta, vo | ||||
id *C, const int ldc); | ||||
int wrapper_clapack_sgetrf(const enum CBLAS_ORDER Order, const int M, const | ||||
int N, float *A, const int lda, int *ipiv); | ||||
int wrapper_clapack_dgetrf(const enum CBLAS_ORDER Order, const int M, const | ||||
int N, double *A, const int lda, int *ipiv); | ||||
int wrapper_clapack_cgetrf(const enum CBLAS_ORDER Order, const int M, const | ||||
int N, void *A, const int lda, int *ipiv); | ||||
int wrapper_clapack_zgetrf(const enum CBLAS_ORDER Order, const int M, const | ||||
int N, void *A, const int lda, int *ipiv); | ||||
int wrapper_clapack_sgetri(const enum CBLAS_ORDER Order, const int N, float | ||||
*A, const int lda, const int *ipiv); | ||||
int wrapper_clapack_dgetri(const enum CBLAS_ORDER Order, const int N, double | ||||
*A, const int lda, const int *ipiv); | ||||
int wrapper_clapack_cgetri(const enum CBLAS_ORDER Order, const int N, void | ||||
*A, const int lda, const int *ipiv); | ||||
int wrapper_clapack_zgetri(const enum CBLAS_ORDER Order, const int N, void | ||||
*A, const int lda, const int *ipiv); | ||||
int wrapper_clapack_sgesv(const enum CBLAS_ORDER Order, const int N, const i | ||||
nt NRHS, float *A, const int lda, int *ipiv, float *B, const int ldb); | ||||
int wrapper_clapack_dgesv(const enum CBLAS_ORDER Order, const int N, const i | ||||
nt NRHS, double *A, const int lda, int *ipiv, double *B, const int ldb); | ||||
int wrapper_clapack_cgesv(const enum CBLAS_ORDER Order, const int N, const i | ||||
nt NRHS, void *A, const int lda, int *ipiv, void *B, const int ldb); | ||||
int wrapper_clapack_zgesv(const enum CBLAS_ORDER Order, const int N, const i | ||||
nt NRHS, void *A, const int lda, int *ipiv, void *B, const int ldb); | ||||
int wrapper_clapack_spotrf(const enum CBLAS_ORDER Order, const enum CBLAS_UP | ||||
LO Uplo, const int N, float *A, const int lda); | ||||
int wrapper_clapack_dpotrf(const enum CBLAS_ORDER Order, const enum CBLAS_UP | ||||
LO Uplo, const int N, double *A, const int lda); | ||||
int wrapper_clapack_cpotrf(const enum CBLAS_ORDER Order, const enum CBLAS_UP | ||||
LO Uplo, const int N, void *A, const int lda); | ||||
int wrapper_clapack_zpotrf(const enum CBLAS_ORDER Order, const enum CBLAS_UP | ||||
LO Uplo, const int N, void *A, const int lda); | ||||
int wrapper_clapack_spotri(const enum CBLAS_ORDER Order, const enum CBLAS_UP | ||||
LO Uplo, const int N, float *A, const int lda); | ||||
int wrapper_clapack_dpotri(const enum CBLAS_ORDER Order, const enum CBLAS_UP | ||||
LO Uplo, const int N, double *A, const int lda); | ||||
int wrapper_clapack_cpotri(const enum CBLAS_ORDER Order, const enum CBLAS_UP | ||||
LO Uplo, const int N, void *A, const int lda); | ||||
int wrapper_clapack_zpotri(const enum CBLAS_ORDER Order, const enum CBLAS_UP | ||||
LO Uplo, const int N, void *A, const int lda); | ||||
int wrapper_clapack_sposv(const enum CBLAS_ORDER Order, const enum CBLAS_UPL | ||||
O Uplo, const int N, const int NRHS, float *A, const int lda, float *B, const | ||||
int ldb); | ||||
int wrapper_clapack_dposv(const enum CBLAS_ORDER Order, const enum CBLAS_UPL | ||||
O Uplo, const int N, const int NRHS, double *A, const int lda, double *B, const | ||||
int ldb); | ||||
int wrapper_clapack_cposv(const enum CBLAS_ORDER Order, const enum CBLAS_UPL | ||||
O Uplo, const int N, const int NRHS, void *A, const int lda, void *B, const | ||||
int ldb); | ||||
int wrapper_clapack_zposv(const enum CBLAS_ORDER Order, const enum CBLAS_UPL | ||||
O Uplo, const int N, const int NRHS, void *A, const int lda, void *B, const | ||||
int ldb); | ||||
} | ||||
#endif | ||||
} | } | |||
#endif | #endif | |||
End of changes. 3 change blocks. | ||||
161 lines changed or deleted | 97 lines changed or added |