# BLAS Wrapper Structs Document of BLAS wrappers is on-going work. Terms of the following table is - **Prototype**: Prototype of BLAS wrappers. - For users, prototype is **NOT** designed to be used by API caller. One may wish to call generic structs (such as `GEMM`) or directly call specialization (such as `DGEMM`). - For documents and structure of BLAS wrapper, please refer to hyperlinks of prototype (on docs.rs). We also refer [LAPACK document](https://netlib.org/lapack/explore-html/index.html). - **Num Trait**: Trait bound that could be applied on generics. - **Generic**: Generic structs of BLAS wrapper. This is designed to be called by API user. For example of `GEMM`, this is type alias of `GEMM_Builder`. - **Specialization**: Specialization structs of BLAS wrapper. This is designed to be called by API user, and have the same subroutine name to (legacy) BLAS. Abbrivations - symm: Symmetric - hermi: Hermitian - tri: Triangular ## Level 3 BLAS | BLAS | Prototype | Num Trait | Generic | f32 | f64 | c32 | c64 | Description | |--|--|--|--|--|--|--|--|--| | gemm | [`GEMM_`] | [`GEMMNum`] | [`GEMM`] | [`SGEMM`] | [`DGEMM`] | [`CGEMM`] | [`ZGEMM`] | general matrix-matrix multiply | | symm | [`SYMM_`] | [`SYMMNum`] | [`SYMM`] | [`SSYMM`] | [`DSYMM`] | [`CSYMM`] | [`ZSYMM`] | symm matrix-matrix multiply | | hemm | [`HEMM_`] | [`HEMMNum`] | [`HEMM`] | | | [`CHEMM`] | [`ZHEMM`] | hermi matrix-matrix multiply | | syrk | [`SYRK_`] | [`SYRKNum`] | [`SYRK`] | [`SSYRK`] | [`DSYRK`] | [`CSYRK`] | [`ZSYRK`] | symm rank-k update | | herk | [`HERK_`] | [`HERKNum`] | [`HERK`] | | | [`CHERK`] | [`ZHERK`] | hermi rank-k update | | syr2k | [`SYR2K_`] | [`SYR2KNum`] | [`SYR2K`] | [`SSYR2K`] | [`DSYR2K`] | [`CSYR2K`] | [`ZSYR2K`] | symm rank-2k update | | her2k | [`HER2K_`] | [`HER2KNum`] | [`HER2K`] | | | [`CHER2K`] | [`ZHER2K`] | hermi rank-2k update | | trmm | [`TRMM_`] | [`TRMMNum`] | [`TRMM`] | [`STRMM`] | [`DTRMM`] | [`CTRMM`] | [`ZTRMM`] | tri matrix-matrix multiply | | trsm | [`TRSM_`] | [`TRSMNum`] | [`TRSM`] | [`STRSM`] | [`DTRSM`] | [`CTRSM`] | [`ZTRSM`] | tri matrix-matrix solve | ## Level 3 BLAS (extensions) | BLAS | Prototype | Num Trait | Generic | f32 | f64 | c32 | c64 | Description | |--|--|--|--|--|--|--|--|--| | gemmt | [`GEMMT_`] | [`GEMMTNum`] | [`GEMMT`] | [`SGEMMT`] | [`DGEMMT`] | [`CGEMMT`] | [`ZGEMMT`] | general matrix-matrix multiply, tri update | ## Level 2 BLAS (full) | BLAS | Prototype | Num Trait | Generic | f32 | f64 | c32 | c64 | Description | |--|--|--|--|--|--|--|--|--| | gemv | [`GEMV_`] | [`GEMVNum`] | [`GEMV`] | [`SGEMV`] | [`DGEMV`] | [`CGEMV`] | [`ZGEMV`] | general matrix-vector multiply | | ger | [`GER_`] | [`GERNum`] | [`GER`] | [`SGER`] | [`DGER`] | [`CGERU`] | [`ZGERU`] | general matrix rank-1 update | | gerc | [`GERC_`] | [`GERCNum`] | [`GERC`] | | | [`CGERC`] | [`ZGERC`] | general matrix rank-1 update | | {sy,he}mv | [`HEMV_`] | [`HEMVNum`] | [`HEMV`] | [`SSYMV`] | [`DSYMV`] | [`CHEMV`] | [`ZHEMV`] | symm/hermi matrix-vector multiply | | {sy,he}r | [`HER_`] | [`HERNum`] | [`HER`] | [`SSYR`] | [`DSYR`] | [`CHER`] | [`ZHER`] | symm/hermi rank-1 update | | {sy,he}r2 | [`HER2_`] | [`HER2Num`] | [`HER2`] | [`SSYR2`] | [`DSYR2`] | [`CHER2`] | [`ZHER2`] | symm/hermi rank-2 update | | trmv | [`TRMV_`] | [`TRMVNum`] | [`TRMV`] | [`STRMV`] | [`DTRMV`] | [`CTRMV`] | [`ZTRMV`] | tri matrix-vector multiply | | trsv | [`TRSV_`] | [`TRSVNum`] | [`TRSV`] | [`STRSV`] | [`DTRSV`] | [`CTRSV`] | [`ZTRSV`] | tri matrix-vector solve | ## Level 2 BLAS (packed) | BLAS | Prototype | Num Trait | Generic | f32 | f64 | c32 | c64 | Description | |--|--|--|--|--|--|--|--|--| | {sp,hp}mv | [`HPMV_`] | [`HPMVNum`] | [`HPMV`] | [`SSPMV`] | [`DSPMV`] | [`CHPMV`] | [`ZHPMV`] | symm/hermi matrix-vector multiply | | {sp,hp}r | [`HPR_`] | [`HPRNum`] | [`HPR`] | [`SSPR`] | [`DSPR`] | [`CHPR`] | [`ZHPR`] | symm/hermi rank-1 update | | {sp,hp}r2 | [`HPR2_`] | [`HPR2Num`] | [`HPR2`] | [`SSPR2`] | [`DSPR2`] | [`CHPR2`] | [`ZHPR2`] | symm/hermi rank-2 update | | tpmv | [`TPMV_`] | [`TPMVNum`] | [`TPMV`] | [`STPMV`] | [`DTPMV`] | [`CTPMV`] | [`ZTPMV`] | tri matrix-vector multiply | | tpsv | [`TPSV_`] | [`TPSVNum`] | [`TPSV`] | [`STPSV`] | [`DTPSV`] | [`CTPSV`] | [`ZTPSV`] | tri matrix-vector solve | ## Level 2 BLAS (banded) | BLAS | Prototype | Num Trait | Generic | f32 | f64 | c32 | c64 | Description | |--|--|--|--|--|--|--|--|--| | gbmv | [`GBMV_`] | [`GBMVNum`] | [`GBMV`] | [`SGBMV`] | [`DGBMV`] | [`CGBMV`] | [`ZGBMV`] | general matrix-vector multiply | | {sb,hb}mv | [`HBMV_`] | [`HBMVNum`] | [`HBMV`] | [`SSBMV`] | [`DSBMV`] | [`CHBMV`] | [`ZHBMV`] | symm/hermi matrix-vector multiply | | tbmv | [`TBMV_`] | [`TBMVNum`] | [`TBMV`] | [`STBMV`] | [`DTBMV`] | [`CTBMV`] | [`ZTBMV`] | tri matrix-vector multiply | | tbsv | [`TBSV_`] | [`TBSVNum`] | [`TBSV`] | [`STBSV`] | [`DTBSV`] | [`CTBSV`] | [`ZTBSV`] | tri matrix-vector solve | ## Level 1 BLAS | BLAS | Prototype | Num Trait | Generic | f32 | f64 | c32 | c64 | Description | |--|--|--|--|--|--|--|--|--| | asum | [`ASUM_`] | [`ASUMNum`] | [`ASUM`] | [`SASUM`] | [`DASUM`] | [`SCASUM`] | [`DZASUM`] | $\sum_i \big( \vert \mathrm{re} ( x_i ) \vert + \vert \mathrm{im} ( x_i ) \vert \big)$ | | nrm2 | [`NRM2_`] | [`NRM2Num`] | [`NRM2`] | [`SNRM2`] | [`DNRM2`] | [`SCNRM2`] | [`DZASUM`] | $\Vert \boldsymbol{x} \Vert_2$ | | iamax | [`IAMAX_`] | [`IAMAXNum`] | [`IAMAX`] | [`ISAMAX`] | [`IDAMAX`] | [`ICAMAX`] | [`IZAMAX`] | $\arg \max_i \big( \vert \mathrm{re} ( x_i ) \vert + \vert \mathrm{im} ( x_i ) \vert \big)$ |