Created
January 20, 2013 20:57
-
-
Save zchothia/4581699 to your computer and use it in GitHub Desktop.
First draft of patch for OpenBLAS #185 (add const to <cblas.h>).
This file contains 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
From e4ef9352795f04865352d1ddcda7e6ac5371348b Mon Sep 17 00:00:00 2001 | |
From: Zaheer Chothia <[email protected]> | |
Date: Sun, 20 Jan 2013 21:53:52 +0100 | |
Subject: [PATCH] Refs #185. Add missing 'const' to declarations in <cblas.h>. | |
Thanks to Dan Povey! | |
The 'const' modifications were done automatically using this scripts: | |
https://kaldi.svn.sourceforge.net/svnroot/kaldi/sandbox/dan/tools/for_openblas | |
--- | |
Makefile | 2 +- | |
Makefile.getarch => Makefile.prebuild | 7 +- | |
Makefile.system | 2 +- | |
cblas.h | 587 +++++++++++++++++----------------- | |
common.h | 2 +- | |
5 files changed, 302 insertions(+), 298 deletions(-) | |
rename Makefile.getarch => Makefile.prebuild (81%) | |
rewrite cblas.h (95%) | |
diff --git a/Makefile b/Makefile | |
index 39e3bbd..a84b54d 100644 | |
--- a/Makefile | |
+++ b/Makefile | |
@@ -314,7 +314,7 @@ clean :: | |
#endif | |
@$(MAKE) -C reference clean | |
@rm -f *.$(LIBSUFFIX) *.so *~ *.exe getarch getarch_2nd *.dll *.lib *.$(SUFFIX) *.dwf $(LIBPREFIX).$(LIBSUFFIX) $(LIBPREFIX)_p.$(LIBSUFFIX) $(LIBPREFIX).so.$(MAJOR_VERSION) *.lnk myconfig.h | |
- @rm -f Makefile.conf config.h Makefile_kernel.conf config_kernel.h st* *.dylib | |
+ @rm -f Makefile.conf config.h cblas_noconst.h Makefile_kernel.conf config_kernel.h st* *.dylib | |
@if test -d $(NETLIB_LAPACK_DIR); then \ | |
echo deleting $(NETLIB_LAPACK_DIR); \ | |
rm -rf $(NETLIB_LAPACK_DIR) ;\ | |
diff --git a/Makefile.getarch b/Makefile.prebuild | |
similarity index 81% | |
rename from Makefile.getarch | |
rename to Makefile.prebuild | |
index dadfb5b..ce143d7 100644 | |
--- a/Makefile.getarch | |
+++ b/Makefile.prebuild | |
@@ -1,3 +1,5 @@ | |
+# This is triggered by Makefile.system and runs any of the code is built. | |
+ | |
export BINARY | |
export USE_OPENMP | |
@@ -15,7 +17,7 @@ ifdef CPUIDEMU | |
EXFLAGS = -DCPUIDEMU -DVENDOR=99 | |
endif | |
-all: getarch_2nd | |
+all: getarch_2nd cblas_noconst.h | |
./getarch_2nd 0 >> $(TARGET_MAKE) | |
./getarch_2nd 1 >> $(TARGET_CONF) | |
@@ -36,4 +38,7 @@ else | |
$(HOSTCC) -I. $(CFLAGS) -DBUILD_KERNEL -o $(@F) getarch_2nd.c | |
endif | |
+cblas_noconst.h : cblas.h | |
+ sed -e "s/\bconst\b\s*//g" cblas.h > cblas_noconst.h | |
+ | |
dummy: | |
diff --git a/Makefile.system b/Makefile.system | |
index 27f30fa..239047f 100644 | |
--- a/Makefile.system | |
+++ b/Makefile.system | |
@@ -70,7 +70,7 @@ ifndef GOTOBLAS_MAKEFILE | |
export GOTOBLAS_MAKEFILE = 1 | |
# Generating Makefile.conf and config.h | |
-DUMMY := $(shell $(MAKE) -C $(TOPDIR) -f Makefile.getarch CC="$(CC)" FC="$(FC)" HOSTCC="$(HOSTCC)" CFLAGS="$(GETARCH_FLAGS)" BINARY=$(BINARY) USE_OPENMP=$(USE_OPENMP) TARGET_CORE=$(TARGET_CORE) all) | |
+DUMMY := $(shell $(MAKE) -C $(TOPDIR) -f Makefile.prebuild CC="$(CC)" FC="$(FC)" HOSTCC="$(HOSTCC)" CFLAGS="$(GETARCH_FLAGS)" BINARY=$(BINARY) USE_OPENMP=$(USE_OPENMP) TARGET_CORE=$(TARGET_CORE) all) | |
ifndef TARGET_CORE | |
include $(TOPDIR)/Makefile.conf | |
diff --git a/cblas.h b/cblas.h | |
dissimilarity index 95% | |
index 5d50238..501e7d0 100644 | |
--- a/cblas.h | |
+++ b/cblas.h | |
@@ -1,294 +1,293 @@ | |
-#ifndef CBLAS_H | |
-#define CBLAS_H | |
- | |
-#ifdef __cplusplus | |
-extern "C" { | |
- /* Assume C declarations for C++ */ | |
-#endif /* __cplusplus */ | |
- | |
-#include <stddef.h> | |
-#include "common.h" | |
- | |
-/*Set the number of threads on runtime.*/ | |
-void openblas_set_num_threads(int num_threads); | |
-void goto_set_num_threads(int num_threads); | |
- | |
-/*Get the build configure on runtime.*/ | |
-char* openblas_get_config(void); | |
- | |
-#define CBLAS_INDEX size_t | |
- | |
-typedef enum CBLAS_ORDER {CblasRowMajor=101, CblasColMajor=102} CBLAS_ORDER; | |
-typedef enum CBLAS_TRANSPOSE {CblasNoTrans=111, CblasTrans=112, CblasConjTrans=113, CblasConjNoTrans=114} CBLAS_TRANSPOSE; | |
-typedef enum CBLAS_UPLO {CblasUpper=121, CblasLower=122} CBLAS_UPLO; | |
-typedef enum CBLAS_DIAG {CblasNonUnit=131, CblasUnit=132} CBLAS_DIAG; | |
-typedef enum CBLAS_SIDE {CblasLeft=141, CblasRight=142} CBLAS_SIDE; | |
- | |
-float cblas_sdsdot(blasint n, float, float *x, blasint incx, float *y, blasint incy); | |
-double cblas_dsdot (blasint n, float *x, blasint incx, float *y, blasint incy); | |
-float cblas_sdot(blasint n, float *x, blasint incx, float *y, blasint incy); | |
-double cblas_ddot(blasint n, double *x, blasint incx, double *y, blasint incy); | |
- | |
-openblas_complex_float cblas_cdotu(blasint n, float *x, blasint incx, float *y, blasint incy); | |
-openblas_complex_float cblas_cdotc(blasint n, float *x, blasint incx, float *y, blasint incy); | |
-openblas_complex_double cblas_zdotu(blasint n, double *x, blasint incx, double *y, blasint incy); | |
-openblas_complex_double cblas_zdotc(blasint n, double *x, blasint incx, double *y, blasint incy); | |
- | |
-void cblas_cdotu_sub(blasint n, float *x, blasint incx, float *y, blasint incy, openblas_complex_float *ret); | |
-void cblas_cdotc_sub(blasint n, float *x, blasint incx, float *y, blasint incy, openblas_complex_float *ret); | |
-void cblas_zdotu_sub(blasint n, double *x, blasint incx, double *y, blasint incy, openblas_complex_double *ret); | |
-void cblas_zdotc_sub(blasint n, double *x, blasint incx, double *y, blasint incy, openblas_complex_double *ret); | |
- | |
-float cblas_sasum (blasint n, float *x, blasint incx); | |
-double cblas_dasum (blasint n, double *x, blasint incx); | |
-float cblas_scasum(blasint n, float *x, blasint incx); | |
-double cblas_dzasum(blasint n, double *x, blasint incx); | |
- | |
-float cblas_snrm2 (blasint N, float *X, blasint incX); | |
-double cblas_dnrm2 (blasint N, double *X, blasint incX); | |
-float cblas_scnrm2(blasint N, float *X, blasint incX); | |
-double cblas_dznrm2(blasint N, double *X, blasint incX); | |
- | |
-CBLAS_INDEX cblas_isamax(blasint n, float *x, blasint incx); | |
-CBLAS_INDEX cblas_idamax(blasint n, double *x, blasint incx); | |
-CBLAS_INDEX cblas_icamax(blasint n, float *x, blasint incx); | |
-CBLAS_INDEX cblas_izamax(blasint n, double *x, blasint incx); | |
- | |
-void cblas_saxpy(blasint n, float, float *x, blasint incx, float *y, blasint incy); | |
-void cblas_daxpy(blasint n, double, double *x, blasint incx, double *y, blasint incy); | |
-void cblas_caxpy(blasint n, float *, float *x, blasint incx, float *y, blasint incy); | |
-void cblas_zaxpy(blasint n, double *, double *x, blasint incx, double *y, blasint incy); | |
- | |
-void cblas_scopy(blasint n, float *x, blasint incx, float *y, blasint incy); | |
-void cblas_dcopy(blasint n, double *x, blasint incx, double *y, blasint incy); | |
-void cblas_ccopy(blasint n, float *x, blasint incx, float *y, blasint incy); | |
-void cblas_zcopy(blasint n, double *x, blasint incx, double *y, blasint incy); | |
- | |
-void cblas_sswap(blasint n, float *x, blasint incx, float *y, blasint incy); | |
-void cblas_dswap(blasint n, double *x, blasint incx, double *y, blasint incy); | |
-void cblas_cswap(blasint n, float *x, blasint incx, float *y, blasint incy); | |
-void cblas_zswap(blasint n, double *x, blasint incx, double *y, blasint incy); | |
- | |
-void cblas_srot(blasint N, float *X, blasint incX, float *Y, blasint incY, float c, float s); | |
-void cblas_drot(blasint N, double *X, blasint incX, double *Y, blasint incY, double c, double s); | |
- | |
-void cblas_srotg(float *a, float *b, float *c, float *s); | |
-void cblas_drotg(double *a, double *b, double *c, double *s); | |
- | |
-void cblas_srotm(blasint N, float *X, blasint incX, float *Y, blasint incY, float *P); | |
-void cblas_drotm(blasint N, double *X, blasint incX, double *Y, blasint incY, double *P); | |
- | |
-void cblas_srotmg(float *d1, float *d2, float *b1, float b2, float *P); | |
-void cblas_drotmg(double *d1, double *d2, double *b1, double b2, double *P); | |
- | |
-void cblas_sscal(blasint N, float alpha, float *X, blasint incX); | |
-void cblas_dscal(blasint N, double alpha, double *X, blasint incX); | |
-void cblas_cscal(blasint N, float *alpha, float *X, blasint incX); | |
-void cblas_zscal(blasint N, double *alpha, double *X, blasint incX); | |
-void cblas_csscal(blasint N, float alpha, float *X, blasint incX); | |
-void cblas_zdscal(blasint N, double alpha, double *X, blasint incX); | |
- | |
-void cblas_sgemv(enum CBLAS_ORDER order, enum CBLAS_TRANSPOSE trans, blasint m, blasint n, | |
- float alpha, float *a, blasint lda, float *x, blasint incx, float beta, float *y, blasint incy); | |
-void cblas_dgemv(enum CBLAS_ORDER order, enum CBLAS_TRANSPOSE trans, blasint m, blasint n, | |
- double alpha, double *a, blasint lda, double *x, blasint incx, double beta, double *y, blasint incy); | |
-void cblas_cgemv(enum CBLAS_ORDER order, enum CBLAS_TRANSPOSE trans, blasint m, blasint n, | |
- float *alpha, float *a, blasint lda, float *x, blasint incx, float *beta, float *y, blasint incy); | |
-void cblas_zgemv(enum CBLAS_ORDER order, enum CBLAS_TRANSPOSE trans, blasint m, blasint n, | |
- double *alpha, double *a, blasint lda, double *x, blasint incx, double *beta, double *y, blasint incy); | |
- | |
-void cblas_sger (enum CBLAS_ORDER order, blasint M, blasint N, float alpha, float *X, blasint incX, float *Y, blasint incY, float *A, blasint lda); | |
-void cblas_dger (enum CBLAS_ORDER order, blasint M, blasint N, double alpha, double *X, blasint incX, double *Y, blasint incY, double *A, blasint lda); | |
-void cblas_cgeru(enum CBLAS_ORDER order, blasint M, blasint N, float *alpha, float *X, blasint incX, float *Y, blasint incY, float *A, blasint lda); | |
-void cblas_cgerc(enum CBLAS_ORDER order, blasint M, blasint N, float *alpha, float *X, blasint incX, float *Y, blasint incY, float *A, blasint lda); | |
-void cblas_zgeru(enum CBLAS_ORDER order, blasint M, blasint N, double *alpha, double *X, blasint incX, double *Y, blasint incY, double *A, blasint lda); | |
-void cblas_zgerc(enum CBLAS_ORDER order, blasint M, blasint N, double *alpha, double *X, blasint incX, double *Y, blasint incY, double *A, blasint lda); | |
- | |
-void cblas_strsv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, blasint N, float *A, blasint lda, float *X, blasint incX); | |
-void cblas_dtrsv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, blasint N, double *A, blasint lda, double *X, blasint incX); | |
-void cblas_ctrsv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, blasint N, float *A, blasint lda, float *X, blasint incX); | |
-void cblas_ztrsv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, blasint N, double *A, blasint lda, double *X, blasint incX); | |
- | |
-void cblas_strmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, blasint N, float *A, blasint lda, float *X, blasint incX); | |
-void cblas_dtrmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, blasint N, double *A, blasint lda, double *X, blasint incX); | |
-void cblas_ctrmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, blasint N, float *A, blasint lda, float *X, blasint incX); | |
-void cblas_ztrmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, blasint N, double *A, blasint lda, double *X, blasint incX); | |
- | |
-void cblas_ssyr(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, float alpha, float *X, blasint incX, float *A, blasint lda); | |
-void cblas_dsyr(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, double alpha, double *X, blasint incX, double *A, blasint lda); | |
-void cblas_cher(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, float alpha, float *X, blasint incX, float *A, blasint lda); | |
-void cblas_zher(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, double alpha, double *X, blasint incX, double *A, blasint lda); | |
- | |
-void cblas_ssyr2(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo,blasint N, float alpha, float *X, | |
- blasint incX, float *Y, blasint incY, float *A, blasint lda); | |
-void cblas_dsyr2(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, double alpha, double *X, | |
- blasint incX, double *Y, blasint incY, double *A, blasint lda); | |
-void cblas_cher2(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, float *alpha, float *X, blasint incX, | |
- float *Y, blasint incY, float *A, blasint lda); | |
-void cblas_zher2(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, double *alpha, double *X, blasint incX, | |
- double *Y, blasint incY, double *A, blasint lda); | |
- | |
-void cblas_sgbmv(enum CBLAS_ORDER order, enum CBLAS_TRANSPOSE TransA, blasint M, blasint N, | |
- blasint KL, blasint KU, float alpha, float *A, blasint lda, float *X, blasint incX, float beta, float *Y, blasint incY); | |
-void cblas_dgbmv(enum CBLAS_ORDER order, enum CBLAS_TRANSPOSE TransA, blasint M, blasint N, | |
- blasint KL, blasint KU, double alpha, double *A, blasint lda, double *X, blasint incX, double beta, double *Y, blasint incY); | |
-void cblas_cgbmv(enum CBLAS_ORDER order, enum CBLAS_TRANSPOSE TransA, blasint M, blasint N, | |
- blasint KL, blasint KU, float *alpha, float *A, blasint lda, float *X, blasint incX, float *beta, float *Y, blasint incY); | |
-void cblas_zgbmv(enum CBLAS_ORDER order, enum CBLAS_TRANSPOSE TransA, blasint M, blasint N, | |
- blasint KL, blasint KU, double *alpha, double *A, blasint lda, double *X, blasint incX, double *beta, double *Y, blasint incY); | |
- | |
-void cblas_ssbmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, blasint K, float alpha, float *A, | |
- blasint lda, float *X, blasint incX, float beta, float *Y, blasint incY); | |
-void cblas_dsbmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, blasint K, double alpha, double *A, | |
- blasint lda, double *X, blasint incX, double beta, double *Y, blasint incY); | |
- | |
- | |
-void cblas_stbmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, | |
- blasint N, blasint K, float *A, blasint lda, float *X, blasint incX); | |
-void cblas_dtbmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, | |
- blasint N, blasint K, double *A, blasint lda, double *X, blasint incX); | |
-void cblas_ctbmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, | |
- blasint N, blasint K, float *A, blasint lda, float *X, blasint incX); | |
-void cblas_ztbmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, | |
- blasint N, blasint K, double *A, blasint lda, double *X, blasint incX); | |
- | |
-void cblas_stbsv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, | |
- blasint N, blasint K, float *A, blasint lda, float *X, blasint incX); | |
-void cblas_dtbsv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, | |
- blasint N, blasint K, double *A, blasint lda, double *X, blasint incX); | |
-void cblas_ctbsv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, | |
- blasint N, blasint K, float *A, blasint lda, float *X, blasint incX); | |
-void cblas_ztbsv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, | |
- blasint N, blasint K, double *A, blasint lda, double *X, blasint incX); | |
- | |
-void cblas_stpmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, | |
- blasint N, float *Ap, float *X, blasint incX); | |
-void cblas_dtpmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, | |
- blasint N, double *Ap, double *X, blasint incX); | |
-void cblas_ctpmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, | |
- blasint N, float *Ap, float *X, blasint incX); | |
-void cblas_ztpmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, | |
- blasint N, double *Ap, double *X, blasint incX); | |
- | |
-void cblas_stpsv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, | |
- blasint N, float *Ap, float *X, blasint incX); | |
-void cblas_dtpsv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, | |
- blasint N, double *Ap, double *X, blasint incX); | |
-void cblas_ctpsv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, | |
- blasint N, float *Ap, float *X, blasint incX); | |
-void cblas_ztpsv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, enum CBLAS_DIAG Diag, | |
- blasint N, double *Ap, double *X, blasint incX); | |
- | |
-void cblas_ssymv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, float alpha, float *A, | |
- blasint lda, float *X, blasint incX, float beta, float *Y, blasint incY); | |
-void cblas_dsymv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, double alpha, double *A, | |
- blasint lda, double *X, blasint incX, double beta, double *Y, blasint incY); | |
-void cblas_chemv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, float *alpha, float *A, | |
- blasint lda, float *X, blasint incX, float *beta, float *Y, blasint incY); | |
-void cblas_zhemv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, double *alpha, double *A, | |
- blasint lda, double *X, blasint incX, double *beta, double *Y, blasint incY); | |
- | |
- | |
-void cblas_sspmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, float alpha, float *Ap, | |
- float *X, blasint incX, float beta, float *Y, blasint incY); | |
-void cblas_dspmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, double alpha, double *Ap, | |
- double *X, blasint incX, double beta, double *Y, blasint incY); | |
- | |
-void cblas_sspr(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, float alpha, float *X, blasint incX, float *Ap); | |
-void cblas_dspr(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, double alpha, double *X, blasint incX, double *Ap); | |
- | |
-void cblas_chpr(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, float alpha, float *X, blasint incX, float *A); | |
-void cblas_zhpr(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, double alpha, double *X,blasint incX, double *A); | |
- | |
-void cblas_sspr2(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, float alpha, float *X, blasint incX, float *Y, blasint incY, float *A); | |
-void cblas_dspr2(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, double alpha, double *X, blasint incX, double *Y, blasint incY, double *A); | |
-void cblas_chpr2(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, float *alpha, float *X, blasint incX, float *Y, blasint incY, float *Ap); | |
-void cblas_zhpr2(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, double *alpha, double *X, blasint incX, double *Y, blasint incY, double *Ap); | |
- | |
-void cblas_chbmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, blasint K, | |
- float *alpha, float *A, blasint lda, float *X, blasint incX, float *beta, float *Y, blasint incY); | |
-void cblas_zhbmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, blasint K, | |
- double *alpha, double *A, blasint lda, double *X, blasint incX, double *beta, double *Y, blasint incY); | |
- | |
-void cblas_chpmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, | |
- float *alpha, float *Ap, float *X, blasint incX, float *beta, float *Y, blasint incY); | |
-void cblas_zhpmv(enum CBLAS_ORDER order, enum CBLAS_UPLO Uplo, blasint N, | |
- double *alpha, double *Ap, double *X, blasint incX, double *beta, double *Y, blasint incY); | |
- | |
-void cblas_sgemm(enum CBLAS_ORDER Order, enum CBLAS_TRANSPOSE TransA, enum CBLAS_TRANSPOSE TransB, blasint M, blasint N, blasint K, | |
- float alpha, float *A, blasint lda, float *B, blasint ldb, float beta, float *C, blasint ldc); | |
-void cblas_dgemm(enum CBLAS_ORDER Order, enum CBLAS_TRANSPOSE TransA, enum CBLAS_TRANSPOSE TransB, blasint M, blasint N, blasint K, | |
- double alpha, double *A, blasint lda, double *B, blasint ldb, double beta, double *C, blasint ldc); | |
-void cblas_cgemm(enum CBLAS_ORDER Order, enum CBLAS_TRANSPOSE TransA, enum CBLAS_TRANSPOSE TransB, blasint M, blasint N, blasint K, | |
- float *alpha, float *A, blasint lda, float *B, blasint ldb, float *beta, float *C, blasint ldc); | |
-void cblas_zgemm(enum CBLAS_ORDER Order, enum CBLAS_TRANSPOSE TransA, enum CBLAS_TRANSPOSE TransB, blasint M, blasint N, blasint K, | |
- double *alpha, double *A, blasint lda, double *B, blasint ldb, double *beta, double *C, blasint ldc); | |
- | |
-void cblas_ssymm(enum CBLAS_ORDER Order, enum CBLAS_SIDE Side, enum CBLAS_UPLO Uplo, blasint M, blasint N, | |
- float alpha, float *A, blasint lda, float *B, blasint ldb, float beta, float *C, blasint ldc); | |
-void cblas_dsymm(enum CBLAS_ORDER Order, enum CBLAS_SIDE Side, enum CBLAS_UPLO Uplo, blasint M, blasint N, | |
- double alpha, double *A, blasint lda, double *B, blasint ldb, double beta, double *C, blasint ldc); | |
-void cblas_csymm(enum CBLAS_ORDER Order, enum CBLAS_SIDE Side, enum CBLAS_UPLO Uplo, blasint M, blasint N, | |
- float *alpha, float *A, blasint lda, float *B, blasint ldb, float *beta, float *C, blasint ldc); | |
-void cblas_zsymm(enum CBLAS_ORDER Order, enum CBLAS_SIDE Side, enum CBLAS_UPLO Uplo, blasint M, blasint N, | |
- double *alpha, double *A, blasint lda, double *B, blasint ldb, double *beta, double *C, blasint ldc); | |
- | |
-void cblas_ssyrk(enum CBLAS_ORDER Order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE Trans, | |
- blasint N, blasint K, float alpha, float *A, blasint lda, float beta, float *C, blasint ldc); | |
-void cblas_dsyrk(enum CBLAS_ORDER Order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE Trans, | |
- blasint N, blasint K, double alpha, double *A, blasint lda, double beta, double *C, blasint ldc); | |
-void cblas_csyrk(enum CBLAS_ORDER Order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE Trans, | |
- blasint N, blasint K, float *alpha, float *A, blasint lda, float *beta, float *C, blasint ldc); | |
-void cblas_zsyrk(enum CBLAS_ORDER Order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE Trans, | |
- blasint N, blasint K, double *alpha, double *A, blasint lda, double *beta, double *C, blasint ldc); | |
- | |
-void cblas_ssyr2k(enum CBLAS_ORDER Order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE Trans, | |
- blasint N, blasint K, float alpha, float *A, blasint lda, float *B, blasint ldb, float beta, float *C, blasint ldc); | |
-void cblas_dsyr2k(enum CBLAS_ORDER Order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE Trans, | |
- blasint N, blasint K, double alpha, double *A, blasint lda, double *B, blasint ldb, double beta, double *C, blasint ldc); | |
-void cblas_csyr2k(enum CBLAS_ORDER Order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE Trans, | |
- blasint N, blasint K, float *alpha, float *A, blasint lda, float *B, blasint ldb, float *beta, float *C, blasint ldc); | |
-void cblas_zsyr2k(enum CBLAS_ORDER Order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE Trans, | |
- blasint N, blasint K, double *alpha, double *A, blasint lda, double *B, blasint ldb, double *beta, double *C, blasint ldc); | |
- | |
-void cblas_strmm(enum CBLAS_ORDER Order, enum CBLAS_SIDE Side, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, | |
- enum CBLAS_DIAG Diag, blasint M, blasint N, float alpha, float *A, blasint lda, float *B, blasint ldb); | |
-void cblas_dtrmm(enum CBLAS_ORDER Order, enum CBLAS_SIDE Side, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, | |
- enum CBLAS_DIAG Diag, blasint M, blasint N, double alpha, double *A, blasint lda, double *B, blasint ldb); | |
-void cblas_ctrmm(enum CBLAS_ORDER Order, enum CBLAS_SIDE Side, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, | |
- enum CBLAS_DIAG Diag, blasint M, blasint N, float *alpha, float *A, blasint lda, float *B, blasint ldb); | |
-void cblas_ztrmm(enum CBLAS_ORDER Order, enum CBLAS_SIDE Side, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, | |
- enum CBLAS_DIAG Diag, blasint M, blasint N, double *alpha, double *A, blasint lda, double *B, blasint ldb); | |
- | |
-void cblas_strsm(enum CBLAS_ORDER Order, enum CBLAS_SIDE Side, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, | |
- enum CBLAS_DIAG Diag, blasint M, blasint N, float alpha, float *A, blasint lda, float *B, blasint ldb); | |
-void cblas_dtrsm(enum CBLAS_ORDER Order, enum CBLAS_SIDE Side, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, | |
- enum CBLAS_DIAG Diag, blasint M, blasint N, double alpha, double *A, blasint lda, double *B, blasint ldb); | |
-void cblas_ctrsm(enum CBLAS_ORDER Order, enum CBLAS_SIDE Side, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, | |
- enum CBLAS_DIAG Diag, blasint M, blasint N, float *alpha, float *A, blasint lda, float *B, blasint ldb); | |
-void cblas_ztrsm(enum CBLAS_ORDER Order, enum CBLAS_SIDE Side, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE TransA, | |
- enum CBLAS_DIAG Diag, blasint M, blasint N, double *alpha, double *A, blasint lda, double *B, blasint ldb); | |
- | |
-void cblas_chemm(enum CBLAS_ORDER Order, enum CBLAS_SIDE Side, enum CBLAS_UPLO Uplo, blasint M, blasint N, | |
- float *alpha, float *A, blasint lda, float *B, blasint ldb, float *beta, float *C, blasint ldc); | |
-void cblas_zhemm(enum CBLAS_ORDER Order, enum CBLAS_SIDE Side, enum CBLAS_UPLO Uplo, blasint M, blasint N, | |
- double *alpha, double *A, blasint lda, double *B, blasint ldb, double *beta, double *C, blasint ldc); | |
- | |
-void cblas_cherk(enum CBLAS_ORDER Order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE Trans, blasint N, blasint K, | |
- float alpha, float *A, blasint lda, float beta, float *C, blasint ldc); | |
-void cblas_zherk(enum CBLAS_ORDER Order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE Trans, blasint N, blasint K, | |
- double alpha, double *A, blasint lda, double beta, double *C, blasint ldc); | |
- | |
-void cblas_cher2k(enum CBLAS_ORDER Order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE Trans, blasint N, blasint K, | |
- float *alpha, float *A, blasint lda, float *B, blasint ldb, float beta, float *C, blasint ldc); | |
-void cblas_zher2k(enum CBLAS_ORDER Order, enum CBLAS_UPLO Uplo, enum CBLAS_TRANSPOSE Trans, blasint N, blasint K, | |
- double *alpha, double *A, blasint lda, double *B, blasint ldb, double beta, double *C, blasint ldc); | |
- | |
-void cblas_xerbla(blasint p, char *rout, char *form, ...); | |
- | |
-#ifdef __cplusplus | |
-} | |
- | |
-#endif /* __cplusplus */ | |
- | |
-#endif | |
+#ifndef CBLAS_H | |
+#define CBLAS_H | |
+ | |
+#ifdef __cplusplus | |
+extern "C" { | |
+ /* Assume C declarations for C++ */ | |
+#endif /* __cplusplus */ | |
+ | |
+#include <stddef.h> | |
+#include "common.h" | |
+ | |
+/*Set the number of threads on runtime.*/ | |
+void openblas_set_num_threads(int num_threads); | |
+void goto_set_num_threads(int num_threads); | |
+ | |
+/*Get the build configure on runtime.*/ | |
+char* openblas_get_config(void); | |
+ | |
+#define CBLAS_INDEX size_t | |
+ | |
+typedef enum CBLAS_ORDER {CblasRowMajor=101, CblasColMajor=102} CBLAS_ORDER; | |
+typedef enum CBLAS_TRANSPOSE {CblasNoTrans=111, CblasTrans=112, CblasConjTrans=113, CblasConjNoTrans=114} CBLAS_TRANSPOSE; | |
+typedef enum CBLAS_UPLO {CblasUpper=121, CblasLower=122} CBLAS_UPLO; | |
+typedef enum CBLAS_DIAG {CblasNonUnit=131, CblasUnit=132} CBLAS_DIAG; | |
+typedef enum CBLAS_SIDE {CblasLeft=141, CblasRight=142} CBLAS_SIDE; | |
+ | |
+float cblas_sdsdot(const blasint n, const float alpha, const float *x, const blasint incx, const float *y, const blasint incy); | |
+double cblas_dsdot (const blasint n, const float *x, const blasint incx, const float *y, const blasint incy); | |
+float cblas_sdot(const blasint n, const float *x, const blasint incx, const float *y, const blasint incy); | |
+double cblas_ddot(const blasint n, const double *x, const blasint incx, const double *y, const blasint incy); | |
+ | |
+openblas_complex_float cblas_cdotu(const blasint n, const float *x, const blasint incx, const float *y, const blasint incy); | |
+openblas_complex_float cblas_cdotc(const blasint n, const float *x, const blasint incx, const float *y, const blasint incy); | |
+openblas_complex_double cblas_zdotu(const blasint n, const double *x, const blasint incx, const double *y, const blasint incy); | |
+openblas_complex_double cblas_zdotc(const blasint n, const double *x, const blasint incx, const double *y, const blasint incy); | |
+ | |
+void cblas_cdotu_sub(const blasint n, const float *x, const blasint incx, const float *y, const blasint incy, openblas_complex_float *ret); | |
+void cblas_cdotc_sub(const blasint n, const float *x, const blasint incx, const float *y, const blasint incy, openblas_complex_float *ret); | |
+void cblas_zdotu_sub(const blasint n, const double *x, const blasint incx, const double *y, const blasint incy, openblas_complex_double *ret); | |
+void cblas_zdotc_sub(const blasint n, const double *x, const blasint incx, const double *y, const blasint incy, openblas_complex_double *ret); | |
+ | |
+float cblas_sasum (const blasint n, const float *x, const blasint incx); | |
+double cblas_dasum (const blasint n, const double *x, const blasint incx); | |
+float cblas_scasum(const blasint n, const float *x, const blasint incx); | |
+double cblas_dzasum(const blasint n, const double *x, const blasint incx); | |
+ | |
+float cblas_snrm2 (const blasint N, const float *X, const blasint incX); | |
+double cblas_dnrm2 (const blasint N, const double *X, const blasint incX); | |
+float cblas_scnrm2(const blasint N, const float *X, const blasint incX); | |
+double cblas_dznrm2(const blasint N, const double *X, const blasint incX); | |
+ | |
+CBLAS_INDEX cblas_isamax(const blasint n, const float *x, const blasint incx); | |
+CBLAS_INDEX cblas_idamax(const blasint n, const double *x, const blasint incx); | |
+CBLAS_INDEX cblas_icamax(const blasint n, const float *x, const blasint incx); | |
+CBLAS_INDEX cblas_izamax(const blasint n, const double *x, const blasint incx); | |
+ | |
+void cblas_saxpy(const blasint n, const float alpha, const float *x, const blasint incx, float *y, const blasint incy); | |
+void cblas_daxpy(const blasint n, const double alpha, const double *x, const blasint incx, double *y, const blasint incy); | |
+void cblas_caxpy(const blasint n, const float *alpha, const float *x, const blasint incx, float *y, const blasint incy); | |
+void cblas_zaxpy(const blasint n, const double *alpha, const double *x, const blasint incx, double *y, const blasint incy); | |
+ | |
+void cblas_scopy(const blasint n, const float *x, const blasint incx, float *y, const blasint incy); | |
+void cblas_dcopy(const blasint n, const double *x, const blasint incx, double *y, const blasint incy); | |
+void cblas_ccopy(const blasint n, const float *x, const blasint incx, float *y, const blasint incy); | |
+void cblas_zcopy(const blasint n, const double *x, const blasint incx, double *y, const blasint incy); | |
+ | |
+void cblas_sswap(const blasint n, float *x, const blasint incx, float *y, const blasint incy); | |
+void cblas_dswap(const blasint n, double *x, const blasint incx, double *y, const blasint incy); | |
+void cblas_cswap(const blasint n, float *x, const blasint incx, float *y, const blasint incy); | |
+void cblas_zswap(const blasint n, double *x, const blasint incx, double *y, const blasint incy); | |
+ | |
+void cblas_srot(const blasint N, float *X, const blasint incX, float *Y, const blasint incY, const float c, const float s); | |
+void cblas_drot(const blasint N, double *X, const blasint incX, double *Y, const blasint incY, const double c, const double s); | |
+ | |
+void cblas_srotg(float *a, float *b, float *c, float *s); | |
+void cblas_drotg(double *a, double *b, double *c, double *s); | |
+ | |
+void cblas_srotm(const blasint N, float *X, const blasint incX, float *Y, const blasint incY, const float *P); | |
+void cblas_drotm(const blasint N, double *X, const blasint incX, double *Y, const blasint incY, const double *P); | |
+ | |
+void cblas_srotmg(float *d1, float *d2, float *b1, const float b2, float *P); | |
+void cblas_drotmg(double *d1, double *d2, double *b1, const double b2, double *P); | |
+ | |
+void cblas_sscal(const blasint N, const float alpha, float *X, const blasint incX); | |
+void cblas_dscal(const blasint N, const double alpha, double *X, const blasint incX); | |
+void cblas_cscal(const blasint N, const float *alpha, float *X, const blasint incX); | |
+void cblas_zscal(const blasint N, const double *alpha, double *X, const blasint incX); | |
+void cblas_csscal(const blasint N, const float alpha, float *X, const blasint incX); | |
+void cblas_zdscal(const blasint N, const double alpha, double *X, const blasint incX); | |
+ | |
+void cblas_sgemv(const enum CBLAS_ORDER order, const enum CBLAS_TRANSPOSE trans, const blasint m, const blasint n, | |
+ const float alpha, const float *a, const blasint lda, const float *x, const blasint incx, const float beta, float *y, const blasint incy); | |
+void cblas_dgemv(const enum CBLAS_ORDER order, const enum CBLAS_TRANSPOSE trans, const blasint m, const blasint n, | |
+ const double alpha, const double *a, const blasint lda, const double *x, const blasint incx, const double beta, double *y, const blasint incy); | |
+void cblas_cgemv(const enum CBLAS_ORDER order, const enum CBLAS_TRANSPOSE trans, const blasint m, const blasint n, | |
+ const float *alpha, const float *a, const blasint lda, const float *x, const blasint incx, const float *beta, float *y, const blasint incy); | |
+void cblas_zgemv(const enum CBLAS_ORDER order, const enum CBLAS_TRANSPOSE trans, const blasint m, const blasint n, | |
+ const double *alpha, const double *a, const blasint lda, const double *x, const blasint incx, const double *beta, double *y, const blasint incy); | |
+ | |
+void cblas_sger (const enum CBLAS_ORDER order, const blasint M, const blasint N, const float alpha, const float *X, const blasint incX, const float *Y, const blasint incY, float *A, const blasint lda); | |
+void cblas_dger (const enum CBLAS_ORDER order, const blasint M, const blasint N, const double alpha, const double *X, const blasint incX, const double *Y, const blasint incY, double *A, const blasint lda); | |
+void cblas_cgeru(const enum CBLAS_ORDER order, const blasint M, const blasint N, const float *alpha, const float *X, const blasint incX, const float *Y, const blasint incY, float *A, const blasint lda); | |
+void cblas_cgerc(const enum CBLAS_ORDER order, const blasint M, const blasint N, const float *alpha, const float *X, const blasint incX, const float *Y, const blasint incY, float *A, const blasint lda); | |
+void cblas_zgeru(const enum CBLAS_ORDER order, const blasint M, const blasint N, const double *alpha, const double *X, const blasint incX, const double *Y, const blasint incY, double *A, const blasint lda); | |
+void cblas_zgerc(const enum CBLAS_ORDER order, const blasint M, const blasint N, const double *alpha, const double *X, const blasint incX, const double *Y, const blasint incY, double *A, const blasint lda); | |
+ | |
+void cblas_strsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const blasint N, const float *A, const blasint lda, float *X, const blasint incX); | |
+void cblas_dtrsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const blasint N, const double *A, const blasint lda, double *X, const blasint incX); | |
+void cblas_ctrsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const blasint N, const float *A, const blasint lda, float *X, const blasint incX); | |
+void cblas_ztrsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const blasint N, const double *A, const blasint lda, double *X, const blasint incX); | |
+ | |
+void cblas_strmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const blasint N, const float *A, const blasint lda, float *X, const blasint incX); | |
+void cblas_dtrmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const blasint N, const double *A, const blasint lda, double *X, const blasint incX); | |
+void cblas_ctrmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const blasint N, const float *A, const blasint lda, float *X, const blasint incX); | |
+void cblas_ztrmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, const blasint N, const double *A, const blasint lda, double *X, const blasint incX); | |
+ | |
+void cblas_ssyr(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const float alpha, const float *X, const blasint incX, float *A, const blasint lda); | |
+void cblas_dsyr(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const double alpha, const double *X, const blasint incX, double *A, const blasint lda); | |
+void cblas_cher(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const float alpha, const float *X, const blasint incX, float *A, const blasint lda); | |
+void cblas_zher(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const double alpha, const double *X, const blasint incX, double *A, const blasint lda); | |
+ | |
+void cblas_ssyr2(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo,const blasint N, const float alpha, const float *X, | |
+ const blasint incX, const float *Y, const blasint incY, float *A, const blasint lda); | |
+void cblas_dsyr2(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const double alpha, const double *X, | |
+ const blasint incX, const double *Y, const blasint incY, double *A, const blasint lda); | |
+void cblas_cher2(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const float *alpha, const float *X, const blasint incX, | |
+ const float *Y, const blasint incY, float *A, const blasint lda); | |
+void cblas_zher2(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const double *alpha, const double *X, const blasint incX, | |
+ const double *Y, const blasint incY, double *A, const blasint lda); | |
+ | |
+void cblas_sgbmv(const enum CBLAS_ORDER order, const enum CBLAS_TRANSPOSE TransA, const blasint M, const blasint N, | |
+ const blasint KL, const blasint KU, const float alpha, const float *A, const blasint lda, const float *X, const blasint incX, const float beta, float *Y, const blasint incY); | |
+void cblas_dgbmv(const enum CBLAS_ORDER order, const enum CBLAS_TRANSPOSE TransA, const blasint M, const blasint N, | |
+ const blasint KL, const blasint KU, const double alpha, const double *A, const blasint lda, const double *X, const blasint incX, const double beta, double *Y, const blasint incY); | |
+void cblas_cgbmv(const enum CBLAS_ORDER order, const enum CBLAS_TRANSPOSE TransA, const blasint M, const blasint N, | |
+ const blasint KL, const blasint KU, const float *alpha, const float *A, const blasint lda, const float *X, const blasint incX, const float *beta, float *Y, const blasint incY); | |
+void cblas_zgbmv(const enum CBLAS_ORDER order, const enum CBLAS_TRANSPOSE TransA, const blasint M, const blasint N, | |
+ const blasint KL, const blasint KU, const double *alpha, const double *A, const blasint lda, const double *X, const blasint incX, const double *beta, double *Y, const blasint incY); | |
+ | |
+void cblas_ssbmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const blasint K, const float alpha, const float *A, | |
+ const blasint lda, const float *X, const blasint incX, const float beta, float *Y, const blasint incY); | |
+void cblas_dsbmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const blasint K, const double alpha, const double *A, | |
+ const blasint lda, const double *X, const blasint incX, const double beta, double *Y, const blasint incY); | |
+ | |
+ | |
+void cblas_stbmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, | |
+ const blasint N, const blasint K, const float *A, const blasint lda, float *X, const blasint incX); | |
+void cblas_dtbmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, | |
+ const blasint N, const blasint K, const double *A, const blasint lda, double *X, const blasint incX); | |
+void cblas_ctbmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, | |
+ const blasint N, const blasint K, const float *A, const blasint lda, float *X, const blasint incX); | |
+void cblas_ztbmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, | |
+ const blasint N, const blasint K, const double *A, const blasint lda, double *X, const blasint incX); | |
+ | |
+void cblas_stbsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, | |
+ const blasint N, const blasint K, const float *A, const blasint lda, float *X, const blasint incX); | |
+void cblas_dtbsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, | |
+ const blasint N, const blasint K, const double *A, const blasint lda, double *X, const blasint incX); | |
+void cblas_ctbsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, | |
+ const blasint N, const blasint K, const float *A, const blasint lda, float *X, const blasint incX); | |
+void cblas_ztbsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, | |
+ const blasint N, const blasint K, const double *A, const blasint lda, double *X, const blasint incX); | |
+ | |
+void cblas_stpmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, | |
+ const blasint N, const float *Ap, float *X, const blasint incX); | |
+void cblas_dtpmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, | |
+ const blasint N, const double *Ap, double *X, const blasint incX); | |
+void cblas_ctpmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, | |
+ const blasint N, const float *Ap, float *X, const blasint incX); | |
+void cblas_ztpmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, | |
+ const blasint N, const double *Ap, double *X, const blasint incX); | |
+ | |
+void cblas_stpsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, | |
+ const blasint N, const float *Ap, float *X, const blasint incX); | |
+void cblas_dtpsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, | |
+ const blasint N, const double *Ap, double *X, const blasint incX); | |
+void cblas_ctpsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, | |
+ const blasint N, const float *Ap, float *X, const blasint incX); | |
+void cblas_ztpsv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_DIAG Diag, | |
+ const blasint N, const double *Ap, double *X, const blasint incX); | |
+ | |
+void cblas_ssymv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const float alpha, const float *A, | |
+ const blasint lda, const float *X, const blasint incX, const float beta, float *Y, const blasint incY); | |
+void cblas_dsymv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const double alpha, const double *A, | |
+ const blasint lda, const double *X, const blasint incX, const double beta, double *Y, const blasint incY); | |
+void cblas_chemv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const float *alpha, const float *A, | |
+ const blasint lda, const float *X, const blasint incX, const float *beta, float *Y, const blasint incY); | |
+void cblas_zhemv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const double *alpha, const double *A, | |
+ const blasint lda, const double *X, const blasint incX, const double *beta, double *Y, const blasint incY); | |
+ | |
+ | |
+void cblas_sspmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const float alpha, const float *Ap, | |
+ const float *X, const blasint incX, const float beta, float *Y, const blasint incY); | |
+void cblas_dspmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const double alpha, const double *Ap, | |
+ const double *X, const blasint incX, const double beta, double *Y, const blasint incY); | |
+ | |
+void cblas_sspr(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const float alpha, const float *X, const blasint incX, float *Ap); | |
+void cblas_dspr(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const double alpha, const double *X, const blasint incX, double *Ap); | |
+ | |
+void cblas_chpr(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const float alpha, const float *X, const blasint incX, float *A); | |
+void cblas_zhpr(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const double alpha, const double *X,const blasint incX, double *A); | |
+ | |
+void cblas_sspr2(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const float alpha, const float *X, const blasint incX, const float *Y, const blasint incY, float *A); | |
+void cblas_dspr2(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const double alpha, const double *X, const blasint incX, const double *Y, const blasint incY, double *A); | |
+void cblas_chpr2(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const float *alpha, const float *X, const blasint incX, const float *Y, const blasint incY, float *Ap); | |
+void cblas_zhpr2(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const double *alpha, const double *X, const blasint incX, const double *Y, const blasint incY, double *Ap); | |
+ | |
+void cblas_chbmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const blasint K, | |
+ const float *alpha, const float *A, const blasint lda, const float *X, const blasint incX, const float *beta, float *Y, const blasint incY); | |
+void cblas_zhbmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, const blasint K, | |
+ const double *alpha, const double *A, const blasint lda, const double *X, const blasint incX, const double *beta, double *Y, const blasint incY); | |
+ | |
+void cblas_chpmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, | |
+ const float *alpha, const float *Ap, const float *X, const blasint incX, const float *beta, float *Y, const blasint incY); | |
+void cblas_zhpmv(const enum CBLAS_ORDER order, const enum CBLAS_UPLO Uplo, const blasint N, | |
+ const double *alpha, const double *Ap, const double *X, const blasint incX, const double *beta, double *Y, const blasint incY); | |
+ | |
+void cblas_sgemm(const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_TRANSPOSE TransB, const blasint M, const blasint N, const blasint K, | |
+ const float alpha, const float *A, const blasint lda, const float *B, const blasint ldb, const float beta, float *C, const blasint ldc); | |
+void cblas_dgemm(const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_TRANSPOSE TransB, const blasint M, const blasint N, const blasint K, | |
+ const double alpha, const double *A, const blasint lda, const double *B, const blasint ldb, const double beta, double *C, const blasint ldc); | |
+void cblas_cgemm(const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_TRANSPOSE TransB, const blasint M, const blasint N, const blasint K, | |
+ const float *alpha, const float *A, const blasint lda, const float *B, const blasint ldb, const float *beta, float *C, const blasint ldc); | |
+void cblas_zgemm(const enum CBLAS_ORDER Order, const enum CBLAS_TRANSPOSE TransA, const enum CBLAS_TRANSPOSE TransB, const blasint M, const blasint N, const blasint K, | |
+ const double *alpha, const double *A, const blasint lda, const double *B, const blasint ldb, const double *beta, double *C, const blasint ldc); | |
+ | |
+void cblas_ssymm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const blasint M, const blasint N, | |
+ const float alpha, const float *A, const blasint lda, const float *B, const blasint ldb, const float beta, float *C, const blasint ldc); | |
+void cblas_dsymm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const blasint M, const blasint N, | |
+ const double alpha, const double *A, const blasint lda, const double *B, const blasint ldb, const double beta, double *C, const blasint ldc); | |
+void cblas_csymm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const blasint M, const blasint N, | |
+ const float *alpha, const float *A, const blasint lda, const float *B, const blasint ldb, const float *beta, float *C, const blasint ldc); | |
+void cblas_zsymm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const blasint M, const blasint N, | |
+ const double *alpha, const double *A, const blasint lda, const double *B, const blasint ldb, const double *beta, double *C, const blasint ldc); | |
+ | |
+void cblas_ssyrk(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, | |
+ const blasint N, const blasint K, const float alpha, const float *A, const blasint lda, const float beta, float *C, const blasint ldc); | |
+void cblas_dsyrk(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, | |
+ const blasint N, const blasint K, const double alpha, const double *A, const blasint lda, const double beta, double *C, const blasint ldc); | |
+void cblas_csyrk(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, | |
+ const blasint N, const blasint K, const float *alpha, const float *A, const blasint lda, const float *beta, float *C, const blasint ldc); | |
+void cblas_zsyrk(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, | |
+ const blasint N, const blasint K, const double *alpha, const double *A, const blasint lda, const double *beta, double *C, const blasint ldc); | |
+ | |
+void cblas_ssyr2k(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, | |
+ const blasint N, const blasint K, const float alpha, const float *A, const blasint lda, const float *B, const blasint ldb, const float beta, float *C, const blasint ldc); | |
+void cblas_dsyr2k(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, | |
+ const blasint N, const blasint K, const double alpha, const double *A, const blasint lda, const double *B, const blasint ldb, const double beta, double *C, const blasint ldc); | |
+void cblas_csyr2k(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, | |
+ const blasint N, const blasint K, const float *alpha, const float *A, const blasint lda, const float *B, const blasint ldb, const float *beta, float *C, const blasint ldc); | |
+void cblas_zsyr2k(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, | |
+ const blasint N, const blasint K, const double *alpha, const double *A, const blasint lda, const double *B, const blasint ldb, const double *beta, double *C, const blasint ldc); | |
+ | |
+void cblas_strmm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, | |
+ const enum CBLAS_DIAG Diag, const blasint M, const blasint N, const float alpha, const float *A, const blasint lda, float *B, const blasint ldb); | |
+void cblas_dtrmm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, | |
+ const enum CBLAS_DIAG Diag, const blasint M, const blasint N, const double alpha, const double *A, const blasint lda, double *B, const blasint ldb); | |
+void cblas_ctrmm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, | |
+ const enum CBLAS_DIAG Diag, const blasint M, const blasint N, const float *alpha, const float *A, const blasint lda, float *B, const blasint ldb); | |
+void cblas_ztrmm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, | |
+ const enum CBLAS_DIAG Diag, const blasint M, const blasint N, const double *alpha, const double *A, const blasint lda, double *B, const blasint ldb); | |
+ | |
+void cblas_strsm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, | |
+ const enum CBLAS_DIAG Diag, const blasint M, const blasint N, const float alpha, const float *A, const blasint lda, float *B, const blasint ldb); | |
+void cblas_dtrsm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, | |
+ const enum CBLAS_DIAG Diag, const blasint M, const blasint N, const double alpha, const double *A, const blasint lda, double *B, const blasint ldb); | |
+void cblas_ctrsm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, | |
+ const enum CBLAS_DIAG Diag, const blasint M, const blasint N, const float *alpha, const float *A, const blasint lda, float *B, const blasint ldb); | |
+void cblas_ztrsm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE TransA, | |
+ const enum CBLAS_DIAG Diag, const blasint M, const blasint N, const double *alpha, const double *A, const blasint lda, double *B, const blasint ldb); | |
+ | |
+void cblas_chemm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const blasint M, const blasint N, | |
+ const float *alpha, const float *A, const blasint lda, const float *B, const blasint ldb, const float *beta, float *C, const blasint ldc); | |
+void cblas_zhemm(const enum CBLAS_ORDER Order, const enum CBLAS_SIDE Side, const enum CBLAS_UPLO Uplo, const blasint M, const blasint N, | |
+ const double *alpha, const double *A, const blasint lda, const double *B, const blasint ldb, const double *beta, double *C, const blasint ldc); | |
+ | |
+void cblas_cherk(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, const blasint N, const blasint K, | |
+ const float alpha, const float *A, const blasint lda, const float beta, float *C, const blasint ldc); | |
+void cblas_zherk(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, const blasint N, const blasint K, | |
+ const double alpha, const double *A, const blasint lda, const double beta, double *C, const blasint ldc); | |
+ | |
+void cblas_cher2k(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, const blasint N, const blasint K, | |
+ const float *alpha, const float *A, const blasint lda, const float *B, const blasint ldb, const float beta, float *C, const blasint ldc); | |
+void cblas_zher2k(const enum CBLAS_ORDER Order, const enum CBLAS_UPLO Uplo, const enum CBLAS_TRANSPOSE Trans, const blasint N, const blasint K, | |
+ const double *alpha, const double *A, const blasint lda, const double *B, const blasint ldb, const double beta, double *C, const blasint ldc); | |
+ | |
+void cblas_xerbla(blasint p, char *rout, char *form, ...); | |
+ | |
+#ifdef __cplusplus | |
+} | |
+#endif /* __cplusplus */ | |
+ | |
+#endif | |
diff --git a/common.h b/common.h | |
index 003fde7..1446a4e 100644 | |
--- a/common.h | |
+++ b/common.h | |
@@ -557,7 +557,7 @@ typedef struct { | |
#include "common_level3.h" | |
#include "common_lapack.h" | |
#ifdef CBLAS | |
-#include "cblas.h" | |
+#include "cblas_noconst.h" | |
#endif | |
#ifndef ASSEMBLER | |
-- | |
1.8.0.msysgit.0 | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment