libflame revision_anchor
|
Go to the source code of this file.
Functions | |
void | bli_sgemv (char transa, char conjx, int m, int n, float *alpha, float *a, int a_rs, int a_cs, float *x, int incx, float *beta, float *y, int incy) |
void | bli_dgemv (char transa, char conjx, int m, int n, double *alpha, double *a, int a_rs, int a_cs, double *x, int incx, double *beta, double *y, int incy) |
void | bli_cgemv (char transa, char conjx, int m, int n, scomplex *alpha, scomplex *a, int a_rs, int a_cs, scomplex *x, int incx, scomplex *beta, scomplex *y, int incy) |
void | bli_zgemv (char transa, char conjx, int m, int n, dcomplex *alpha, dcomplex *a, int a_rs, int a_cs, dcomplex *x, int incx, dcomplex *beta, dcomplex *y, int incy) |
void | bli_sgemv_blas (char transa, int m, int n, float *alpha, float *a, int lda, float *x, int incx, float *beta, float *y, int incy) |
void | bli_dgemv_blas (char transa, int m, int n, double *alpha, double *a, int lda, double *x, int incx, double *beta, double *y, int incy) |
void | bli_cgemv_blas (char transa, int m, int n, scomplex *alpha, scomplex *a, int lda, scomplex *x, int incx, scomplex *beta, scomplex *y, int incy) |
void | bli_zgemv_blas (char transa, int m, int n, dcomplex *alpha, dcomplex *a, int lda, dcomplex *x, int incx, dcomplex *beta, dcomplex *y, int incy) |
void | bli_sger (char conjx, char conjy, int m, int n, float *alpha, float *x, int incx, float *y, int incy, float *a, int a_rs, int a_cs) |
void | bli_dger (char conjx, char conjy, int m, int n, double *alpha, double *x, int incx, double *y, int incy, double *a, int a_rs, int a_cs) |
void | bli_cger (char conjx, char conjy, int m, int n, scomplex *alpha, scomplex *x, int incx, scomplex *y, int incy, scomplex *a, int a_rs, int a_cs) |
void | bli_zger (char conjx, char conjy, int m, int n, dcomplex *alpha, dcomplex *x, int incx, dcomplex *y, int incy, dcomplex *a, int a_rs, int a_cs) |
void | bli_sger_blas (int m, int n, float *alpha, float *x, int incx, float *y, int incy, float *a, int lda) |
void | bli_dger_blas (int m, int n, double *alpha, double *x, int incx, double *y, int incy, double *a, int lda) |
void | bli_cgerc_blas (int m, int n, scomplex *alpha, scomplex *x, int incx, scomplex *y, int incy, scomplex *a, int lda) |
void | bli_cgeru_blas (int m, int n, scomplex *alpha, scomplex *x, int incx, scomplex *y, int incy, scomplex *a, int lda) |
void | bli_zgerc_blas (int m, int n, dcomplex *alpha, dcomplex *x, int incx, dcomplex *y, int incy, dcomplex *a, int lda) |
void | bli_zgeru_blas (int m, int n, dcomplex *alpha, dcomplex *x, int incx, dcomplex *y, int incy, dcomplex *a, int lda) |
void | bli_shemv (char uplo, char conj, int m, float *alpha, float *a, int a_rs, int a_cs, float *x, int incx, float *beta, float *y, int incy) |
void | bli_dhemv (char uplo, char conj, int m, double *alpha, double *a, int a_rs, int a_cs, double *x, int incx, double *beta, double *y, int incy) |
void | bli_chemv (char uplo, char conj, int m, scomplex *alpha, scomplex *a, int a_rs, int a_cs, scomplex *x, int incx, scomplex *beta, scomplex *y, int incy) |
void | bli_zhemv (char uplo, char conj, int m, dcomplex *alpha, dcomplex *a, int a_rs, int a_cs, dcomplex *x, int incx, dcomplex *beta, dcomplex *y, int incy) |
void | bli_chemv_blas (char uplo, int m, scomplex *alpha, scomplex *a, int lda, scomplex *x, int incx, scomplex *beta, scomplex *y, int incy) |
void | bli_zhemv_blas (char uplo, int m, dcomplex *alpha, dcomplex *a, int lda, dcomplex *x, int incx, dcomplex *beta, dcomplex *y, int incy) |
void | bli_sher (char uplo, char conj, int m, float *alpha, float *x, int incx, float *a, int a_rs, int a_cs) |
void | bli_dher (char uplo, char conj, int m, double *alpha, double *x, int incx, double *a, int a_rs, int a_cs) |
void | bli_cher (char uplo, char conj, int m, float *alpha, scomplex *x, int incx, scomplex *a, int a_rs, int a_cs) |
void | bli_zher (char uplo, char conj, int m, double *alpha, dcomplex *x, int incx, dcomplex *a, int a_rs, int a_cs) |
void | bli_cher_blas (char uplo, int m, float *alpha, scomplex *x, int incx, scomplex *a, int lda) |
void | bli_zher_blas (char uplo, int m, double *alpha, dcomplex *x, int incx, dcomplex *a, int lda) |
void | bli_sher2 (char uplo, char conj, int m, float *alpha, float *x, int incx, float *y, int incy, float *a, int a_rs, int a_cs) |
void | bli_dher2 (char uplo, char conj, int m, double *alpha, double *x, int incx, double *y, int incy, double *a, int a_rs, int a_cs) |
void | bli_cher2 (char uplo, char conj, int m, scomplex *alpha, scomplex *x, int incx, scomplex *y, int incy, scomplex *a, int a_rs, int a_cs) |
void | bli_zher2 (char uplo, char conj, int m, dcomplex *alpha, dcomplex *x, int incx, dcomplex *y, int incy, dcomplex *a, int a_rs, int a_cs) |
void | bli_cher2_blas (char uplo, int m, scomplex *alpha, scomplex *x, int incx, scomplex *y, int incy, scomplex *a, int lda) |
void | bli_zher2_blas (char uplo, int m, dcomplex *alpha, dcomplex *x, int incx, dcomplex *y, int incy, dcomplex *a, int lda) |
void | bli_ssymv (char uplo, int m, float *alpha, float *a, int a_rs, int a_cs, float *x, int incx, float *beta, float *y, int incy) |
void | bli_dsymv (char uplo, int m, double *alpha, double *a, int a_rs, int a_cs, double *x, int incx, double *beta, double *y, int incy) |
void | bli_csymv (char uplo, int m, scomplex *alpha, scomplex *a, int a_rs, int a_cs, scomplex *x, int incx, scomplex *beta, scomplex *y, int incy) |
void | bli_zsymv (char uplo, int m, dcomplex *alpha, dcomplex *a, int a_rs, int a_cs, dcomplex *x, int incx, dcomplex *beta, dcomplex *y, int incy) |
void | bli_ssymv_blas (char uplo, int m, float *alpha, float *a, int lda, float *x, int incx, float *beta, float *y, int incy) |
void | bli_dsymv_blas (char uplo, int m, double *alpha, double *a, int lda, double *x, int incx, double *beta, double *y, int incy) |
void | bli_csymv_blas (char uplo, int m, scomplex *alpha, scomplex *a, int lda, scomplex *x, int incx, scomplex *beta, scomplex *y, int incy) |
void | bli_zsymv_blas (char uplo, int m, dcomplex *alpha, dcomplex *a, int lda, dcomplex *x, int incx, dcomplex *beta, dcomplex *y, int incy) |
void | bli_ssyr (char uplo, int m, float *alpha, float *x, int incx, float *a, int a_rs, int a_cs) |
void | bli_dsyr (char uplo, int m, double *alpha, double *x, int incx, double *a, int a_rs, int a_cs) |
void | bli_csyr (char uplo, int m, scomplex *alpha, scomplex *x, int incx, scomplex *a, int a_rs, int a_cs) |
void | bli_zsyr (char uplo, int m, dcomplex *alpha, dcomplex *x, int incx, dcomplex *a, int a_rs, int a_cs) |
void | bli_ssyr_blas (char uplo, int m, float *alpha, float *x, int incx, float *a, int lda) |
void | bli_dsyr_blas (char uplo, int m, double *alpha, double *x, int incx, double *a, int lda) |
void | bli_csyr_blas (char uplo, int m, scomplex *alpha, scomplex *x, int incx, scomplex *a, int lda) |
void | bli_zsyr_blas (char uplo, int m, dcomplex *alpha, dcomplex *x, int incx, dcomplex *a, int lda) |
void | bli_ssyr2 (char uplo, int m, float *alpha, float *x, int incx, float *y, int incy, float *a, int a_rs, int a_cs) |
void | bli_dsyr2 (char uplo, int m, double *alpha, double *x, int incx, double *y, int incy, double *a, int a_rs, int a_cs) |
void | bli_csyr2 (char uplo, int m, scomplex *alpha, scomplex *x, int incx, scomplex *y, int incy, scomplex *a, int a_rs, int a_cs) |
void | bli_zsyr2 (char uplo, int m, dcomplex *alpha, dcomplex *x, int incx, dcomplex *y, int incy, dcomplex *a, int a_rs, int a_cs) |
void | bli_ssyr2_blas (char uplo, int m, float *alpha, float *x, int incx, float *y, int incy, float *a, int lda) |
void | bli_dsyr2_blas (char uplo, int m, double *alpha, double *x, int incx, double *y, int incy, double *a, int lda) |
void | bli_csyr2_blas (char uplo, int m, scomplex *alpha, scomplex *x, int incx, scomplex *y, int incy, scomplex *a, int lda) |
void | bli_zsyr2_blas (char uplo, int m, dcomplex *alpha, dcomplex *x, int incx, dcomplex *y, int incy, dcomplex *a, int lda) |
void | bli_strmv (char uplo, char trans, char diag, int m, float *a, int a_rs, int a_cs, float *x, int incx) |
void | bli_dtrmv (char uplo, char trans, char diag, int m, double *a, int a_rs, int a_cs, double *x, int incx) |
void | bli_ctrmv (char uplo, char trans, char diag, int m, scomplex *a, int a_rs, int a_cs, scomplex *x, int incx) |
void | bli_ztrmv (char uplo, char trans, char diag, int m, dcomplex *a, int a_rs, int a_cs, dcomplex *x, int incx) |
void | bli_strmv_blas (char uplo, char trans, char diag, int m, float *a, int lda, float *x, int incx) |
void | bli_dtrmv_blas (char uplo, char trans, char diag, int m, double *a, int lda, double *x, int incx) |
void | bli_ctrmv_blas (char uplo, char trans, char diag, int m, scomplex *a, int lda, scomplex *x, int incx) |
void | bli_ztrmv_blas (char uplo, char trans, char diag, int m, dcomplex *a, int lda, dcomplex *x, int incx) |
void | bli_strsv (char uplo, char trans, char diag, int m, float *a, int a_rs, int a_cs, float *x, int incx) |
void | bli_dtrsv (char uplo, char trans, char diag, int m, double *a, int a_rs, int a_cs, double *x, int incx) |
void | bli_ctrsv (char uplo, char trans, char diag, int m, scomplex *a, int a_rs, int a_cs, scomplex *x, int incx) |
void | bli_ztrsv (char uplo, char trans, char diag, int m, dcomplex *a, int a_rs, int a_cs, dcomplex *x, int incx) |
void | bli_strsv_blas (char uplo, char trans, char diag, int m, float *a, int lda, float *x, int incx) |
void | bli_dtrsv_blas (char uplo, char trans, char diag, int m, double *a, int lda, double *x, int incx) |
void | bli_ctrsv_blas (char uplo, char trans, char diag, int m, scomplex *a, int lda, scomplex *x, int incx) |
void | bli_ztrsv_blas (char uplo, char trans, char diag, int m, dcomplex *a, int lda, dcomplex *x, int incx) |
void | bli_strmvsx (char uplo, char trans, char diag, int m, float *alpha, float *a, int a_rs, int a_cs, float *x, int incx, float *beta, float *y, int incy) |
void | bli_dtrmvsx (char uplo, char trans, char diag, int m, double *alpha, double *a, int a_rs, int a_cs, double *x, int incx, double *beta, double *y, int incy) |
void | bli_ctrmvsx (char uplo, char trans, char diag, int m, scomplex *alpha, scomplex *a, int a_rs, int a_cs, scomplex *x, int incx, scomplex *beta, scomplex *y, int incy) |
void | bli_ztrmvsx (char uplo, char trans, char diag, int m, dcomplex *alpha, dcomplex *a, int a_rs, int a_cs, dcomplex *x, int incx, dcomplex *beta, dcomplex *y, int incy) |
void | bli_strsvsx (char uplo, char trans, char diag, int m, float *alpha, float *a, int a_rs, int a_cs, float *x, int incx, float *beta, float *y, int incy) |
void | bli_dtrsvsx (char uplo, char trans, char diag, int m, double *alpha, double *a, int a_rs, int a_cs, double *x, int incx, double *beta, double *y, int incy) |
void | bli_ctrsvsx (char uplo, char trans, char diag, int m, scomplex *alpha, scomplex *a, int a_rs, int a_cs, scomplex *x, int incx, scomplex *beta, scomplex *y, int incy) |
void | bli_ztrsvsx (char uplo, char trans, char diag, int m, dcomplex *alpha, dcomplex *a, int a_rs, int a_cs, dcomplex *x, int incx, dcomplex *beta, dcomplex *y, int incy) |
void bli_cgemv | ( | char | transa, |
char | conjx, | ||
int | m, | ||
int | n, | ||
scomplex * | alpha, | ||
scomplex * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | beta, | ||
scomplex * | y, | ||
int | incy | ||
) |
References bli_c0(), bli_c1(), bli_callocv(), bli_caxpyv(), bli_cconjv(), bli_ccopyv(), bli_ccreate_contigm(), bli_cfree(), bli_cfree_contigm(), bli_cgemv_blas(), bli_cscalv(), bli_does_trans(), bli_is_conj(), bli_is_conjnotrans(), bli_is_row_storage(), and bli_zero_dim2().
Referenced by FLA_Accum_T_UT_fc_opc_var1(), FLA_Accum_T_UT_fr_opc_var1(), FLA_Apply_H2_UT_l_opc_var1(), FLA_Apply_H2_UT_r_opc_var1(), FLA_Apply_HUD_UT_l_opc_var1(), FLA_Bidiag_UT_u_step_ofc_var2(), FLA_Bidiag_UT_u_step_ofc_var3(), FLA_Bidiag_UT_u_step_ofc_var4(), FLA_Bidiag_UT_u_step_opc_var1(), FLA_Bidiag_UT_u_step_opc_var2(), FLA_Bidiag_UT_u_step_opc_var3(), FLA_Bidiag_UT_u_step_opc_var4(), FLA_Bidiag_UT_u_step_opc_var5(), FLA_Chol_l_opc_var2(), FLA_Chol_u_opc_var2(), FLA_Eig_gest_il_opc_var2(), FLA_Eig_gest_il_opc_var3(), FLA_Eig_gest_iu_opc_var2(), FLA_Eig_gest_iu_opc_var3(), FLA_Eig_gest_nl_opc_var2(), FLA_Eig_gest_nu_opc_var2(), FLA_Gemv_external(), FLA_Gemvc_external(), FLA_Hess_UT_step_ofc_var2(), FLA_Hess_UT_step_ofc_var3(), FLA_Hess_UT_step_ofc_var4(), FLA_Hess_UT_step_opc_var1(), FLA_Hess_UT_step_opc_var2(), FLA_Hess_UT_step_opc_var3(), FLA_Hess_UT_step_opc_var4(), FLA_Hess_UT_step_opc_var5(), FLA_LQ_UT_opc_var2(), FLA_LU_nopiv_opc_var2(), FLA_LU_nopiv_opc_var3(), FLA_LU_nopiv_opc_var4(), FLA_LU_piv_opc_var3(), FLA_LU_piv_opc_var4(), FLA_Lyap_h_opc_var2(), FLA_Lyap_h_opc_var3(), FLA_Lyap_n_opc_var2(), FLA_Lyap_n_opc_var3(), FLA_QR2_UT_opc_var1(), FLA_QR_UT_opc_var2(), FLA_Tridiag_UT_l_step_ofc_var2(), FLA_Tridiag_UT_l_step_ofc_var3(), FLA_Tridiag_UT_l_step_opc_var1(), FLA_Tridiag_UT_l_step_opc_var2(), FLA_Tridiag_UT_l_step_opc_var3(), FLA_Ttmm_l_opc_var2(), and FLA_Ttmm_u_opc_var2().
{ scomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; scomplex zero = bli_c0(); scomplex one = bli_c1(); scomplex* x_conj; scomplex* ax; int lda, inca; int n_x; int incx_conj; int incax; // Return early if possible. if ( bli_zero_dim2( m, n ) ) { int n_elem; if ( bli_does_trans( transa ) ) n_elem = n; else n_elem = m; bli_cscalv( BLIS_NO_CONJUGATE, n_elem, beta, y, incy ); return; } // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_ccreate_contigm( m, n, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( m, n ); bli_swap_ints( lda, inca ); bli_toggle_trans( transa ); } // Initialize with values assuming no conjugation of x. x_conj = x; incx_conj = incx; // We need a temporary vector for the cases when x is conjugated, and // also for the cases where A is conjugated. if ( bli_is_conj( conjx ) || bli_is_conjnotrans( transa ) ) { if ( bli_does_trans( transa ) ) n_x = m; else n_x = n; x_conj = bli_callocv( n_x ); incx_conj = 1; bli_ccopyv( conjx, n_x, x, incx, x_conj, incx_conj ); } // We want to handle the conjnotrans case, but without explicitly // conjugating A. To do so, we leverage the fact that computing the // product conj(A) * x is equivalent to computing conj( A * conj(x) ). if ( bli_is_conjnotrans( transa ) ) { // We need a temporary vector for the product A * conj(x), which is // conformal to y. We know we are not transposing, so y is length m. ax = bli_callocv( m ); incax = 1; // Start by conjugating the contents of the temporary copy of x. bli_cconjv( n, x_conj, incx_conj ); // Compute A * conj(x) where x is the temporary copy of x created above. bli_cgemv_blas( BLIS_NO_TRANSPOSE, m, n, &one, a, lda, x_conj, incx_conj, &zero, ax, incax ); // Scale y by beta. bli_cscalv( BLIS_NO_CONJUGATE, m, beta, y, incy ); // And finally, accumulate alpha * conj( A * conj(x) ) into y. bli_caxpyv( BLIS_CONJUGATE, m, alpha, ax, incax, y, incy); // Free the temporary vector for Ax. bli_cfree( ax ); } else // notrans, trans, or conjtrans { bli_cgemv_blas( transa, m, n, alpha, a, lda, x_conj, incx_conj, beta, y, incy ); } // Free the temporary conjugated x vector. if ( bli_is_conj( conjx ) || bli_is_conjnotrans( transa ) ) bli_cfree( x_conj ); // Free the temporary contiguous matrix. bli_cfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_cgemv_blas | ( | char | transa, |
int | m, | ||
int | n, | ||
scomplex * | alpha, | ||
scomplex * | a, | ||
int | lda, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | beta, | ||
scomplex * | y, | ||
int | incy | ||
) |
References bli_param_map_to_netlib_trans(), cblas_cgemv(), CblasColMajor, and F77_cgemv().
Referenced by bli_cgemv().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_TRANSPOSE cblas_transa; bli_param_map_to_netlib_trans( transa, &cblas_transa ); cblas_cgemv( cblas_order, cblas_transa, m, n, alpha, a, lda, x, incx, beta, y, incy ); #else char blas_transa; bli_param_map_to_netlib_trans( transa, &blas_transa ); F77_cgemv( &blas_transa, &m, &n, alpha, a, &lda, x, &incx, beta, y, &incy ); #endif }
void bli_cger | ( | char | conjx, |
char | conjy, | ||
int | m, | ||
int | n, | ||
scomplex * | alpha, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | y, | ||
int | incy, | ||
scomplex * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_callocv(), bli_ccopyv(), bli_ccreate_contigm(), bli_cfree(), bli_cfree_saved_contigm(), bli_cgerc_blas(), bli_cgeru_blas(), bli_is_conj(), bli_is_row_storage(), and bli_zero_dim2().
Referenced by FLA_Apply_H2_UT_l_opc_var1(), FLA_Apply_H2_UT_r_opc_var1(), FLA_Apply_HUD_UT_l_opc_var1(), FLA_Bidiag_UT_u_step_ofc_var3(), FLA_Bidiag_UT_u_step_opc_var2(), FLA_Bidiag_UT_u_step_opc_var3(), FLA_Eig_gest_il_opc_var3(), FLA_Eig_gest_il_opc_var4(), FLA_Eig_gest_iu_opc_var3(), FLA_Eig_gest_iu_opc_var4(), FLA_Eig_gest_nl_opc_var4(), FLA_Eig_gest_nu_opc_var4(), FLA_Ger_external(), FLA_Gerc_external(), FLA_Hess_UT_step_ofc_var2(), FLA_Hess_UT_step_ofc_var3(), FLA_Hess_UT_step_ofc_var4(), FLA_Hess_UT_step_opc_var2(), FLA_Hess_UT_step_opc_var3(), FLA_Hess_UT_step_opc_var4(), FLA_LU_nopiv_opc_var5(), FLA_LU_piv_opc_var5(), FLA_Lyap_h_opc_var2(), FLA_Lyap_n_opc_var2(), FLA_SA_LU_unb(), FLA_Trinv_ln_opc_var3(), FLA_Trinv_ln_opc_var4(), FLA_Trinv_lu_opc_var3(), FLA_Trinv_lu_opc_var4(), FLA_Trinv_un_opc_var3(), FLA_Trinv_un_opc_var4(), FLA_Trinv_uu_opc_var3(), and FLA_Trinv_uu_opc_var4().
{ int m_save = m; int n_save = n; scomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; scomplex* x_conj; int incx_conj; int lda, inca; // Return early if possible. if ( bli_zero_dim2( m, n ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_ccreate_contigm( m, n, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( m, n ); bli_swap_ints( lda, inca ); bli_swap_ints( incx, incy ); bli_swap_chars( conjx, conjy ); bli_cswap_pointers( x, y ); } // Initialize with values assuming no conjugation of x. x_conj = x; incx_conj = incx; // We need a temporary vector for the cases when x is conjugated. if ( bli_is_conj( conjx ) ) { x_conj = bli_callocv( m ); incx_conj = 1; bli_ccopyv( BLIS_CONJUGATE, m, x, incx, x_conj, incx_conj ); } // Conjugation of y is supported in the BLAS. if ( bli_is_conj( conjy ) ) { bli_cgerc_blas( m, n, alpha, x_conj, incx_conj, y, incy, a, lda ); } else { bli_cgeru_blas( m, n, alpha, x_conj, incx_conj, y, incy, a, lda ); } // Free the temporary conjugated x vector. if ( bli_is_conj( conjx ) ) bli_cfree( x_conj ); // Free the temporary contiguous matrix. bli_cfree_saved_contigm( m_save, n_save, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_cgerc_blas | ( | int | m, |
int | n, | ||
scomplex * | alpha, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | y, | ||
int | incy, | ||
scomplex * | a, | ||
int | lda | ||
) |
References cblas_cgerc(), CblasColMajor, and F77_cgerc().
Referenced by bli_cger().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; cblas_cgerc( cblas_order, m, n, alpha, x, incx, y, incy, a, lda ); #else F77_cgerc ( &m, &n, alpha, x, &incx, y, &incy, a, &lda ); #endif }
void bli_cgeru_blas | ( | int | m, |
int | n, | ||
scomplex * | alpha, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | y, | ||
int | incy, | ||
scomplex * | a, | ||
int | lda | ||
) |
References cblas_cgeru(), CblasColMajor, and F77_cgeru().
Referenced by bli_cger().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; cblas_cgeru( cblas_order, m, n, alpha, x, incx, y, incy, a, lda ); #else F77_cgeru ( &m, &n, alpha, x, &incx, y, &incy, a, &lda ); #endif }
void bli_chemv | ( | char | uplo, |
char | conj, | ||
int | m, | ||
scomplex * | alpha, | ||
scomplex * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | beta, | ||
scomplex * | y, | ||
int | incy | ||
) |
References bli_c0(), bli_c1(), bli_callocv(), bli_caxpyv(), bli_ccopyv(), bli_ccreate_contigmr(), bli_cfree(), bli_cfree_contigm(), bli_chemv_blas(), bli_cscalv(), bli_is_conj(), bli_is_row_storage(), and bli_zero_dim1().
Referenced by FLA_Eig_gest_il_opc_var1(), FLA_Eig_gest_il_opc_var2(), FLA_Eig_gest_iu_opc_var1(), FLA_Eig_gest_iu_opc_var2(), FLA_Eig_gest_nl_opc_var1(), FLA_Eig_gest_nl_opc_var2(), FLA_Eig_gest_nu_opc_var1(), FLA_Eig_gest_nu_opc_var2(), FLA_Hemv_external(), FLA_Hemvc_external(), FLA_Lyap_h_opc_var1(), FLA_Lyap_n_opc_var1(), FLA_Tridiag_UT_l_step_ofc_var2(), FLA_Tridiag_UT_l_step_ofc_var3(), FLA_Tridiag_UT_l_step_opc_var1(), FLA_Tridiag_UT_l_step_opc_var2(), and FLA_Tridiag_UT_l_step_opc_var3().
{ scomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; scomplex zero = bli_c0(); scomplex one = bli_c1(); scomplex* x_conj; scomplex* ax; int lda, inca; int incx_conj; int incax; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_ccreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); bli_toggle_conj( conj ); } // We want to handle the case where A is conjugated, but without // explicitly or conjugating A. To do so, we leverage the fact that // computing the product conj(A) * x is equivalent to computing // conj( A * conj(x) ). if ( bli_is_conj( conj ) ) { // We need a temporary vector so we can create a conjugated copy of x. x_conj = bli_callocv( m ); incx_conj = 1; bli_ccopyv( BLIS_CONJUGATE, m, x, incx, x_conj, incx_conj ); // We need a temporary vector for the product A * conj(x), which is // conformal to y (and x). ax = bli_callocv( m ); incax = 1; // Compute A * conj(x) where x is the temporary copy of x created above. bli_chemv_blas( uplo, m, &one, a, lda, x_conj, incx_conj, &zero, ax, incax ); // Scale y by beta. bli_cscalv( BLIS_NO_CONJUGATE, m, beta, y, incy ); // And finally, accumulate alpha * conj( A * conj(x) ) into y. bli_caxpyv( BLIS_CONJUGATE, m, alpha, ax, incax, y, incy); // Free the temporary vectors for x and Ax. bli_cfree( x_conj ); bli_cfree( ax ); } else // noconj { bli_chemv_blas( uplo, m, alpha, a, lda, x, incx, beta, y, incy ); } // Free the temporary contiguous matrix. bli_cfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_chemv_blas | ( | char | uplo, |
int | m, | ||
scomplex * | alpha, | ||
scomplex * | a, | ||
int | lda, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | beta, | ||
scomplex * | y, | ||
int | incy | ||
) |
References bli_param_map_to_netlib_uplo(), cblas_chemv(), CblasColMajor, and F77_chemv().
Referenced by bli_chemv().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); cblas_chemv( cblas_order, cblas_uplo, m, alpha, a, lda, x, incx, beta, y, incy ); #else char blas_uplo; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); F77_chemv( &blas_uplo, &m, alpha, a, &lda, x, &incx, beta, y, &incy ); #endif }
void bli_cher | ( | char | uplo, |
char | conj, | ||
int | m, | ||
float * | alpha, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_callocv(), bli_ccopyv(), bli_ccreate_contigmr(), bli_cfree(), bli_cfree_saved_contigm(), bli_cher_blas(), bli_is_conj(), bli_is_row_storage(), and bli_zero_dim1().
Referenced by FLA_Chol_l_opc_var3(), FLA_Chol_u_opc_var3(), FLA_Her_external(), FLA_Herc_external(), FLA_Ttmm_l_opc_var1(), and FLA_Ttmm_u_opc_var1().
{ int m_save = m; scomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; scomplex* x_conj; int incx_conj; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_ccreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); bli_toggle_conj( conj ); } // Initialize with values assuming no conjugation of ( x * x' ). x_conj = x; incx_conj = incx; // We want to handle the case where ( x * x' ) is conjugated, but // without explicitly conjugating the matrix. To do so, we leverage // the fact that computing the product conj( x * x' ) is equivalent // to computing ( conj(x) * conj(x)' ), since ( x * x' ) is Hermitian. if ( bli_is_conj( conj ) ) { x_conj = bli_callocv( m ); incx_conj = 1; bli_ccopyv( BLIS_CONJUGATE, m, x, incx, x_conj, incx_conj ); } bli_cher_blas( uplo, m, alpha, x_conj, incx_conj, a, lda ); // Free the temporary conjugated x vector. if ( bli_is_conj( conj ) ) bli_cfree( x_conj ); // Free the temporary contiguous matrix. bli_cfree_saved_contigm( m_save, m_save, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_cher2 | ( | char | uplo, |
char | conj, | ||
int | m, | ||
scomplex * | alpha, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | y, | ||
int | incy, | ||
scomplex * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_callocv(), bli_ccopyv(), bli_ccreate_contigmr(), bli_cfree(), bli_cfree_saved_contigm(), bli_cher2_blas(), bli_is_conj(), bli_is_row_storage(), and bli_zero_dim1().
Referenced by FLA_Eig_gest_il_opc_var4(), FLA_Eig_gest_il_opc_var5(), FLA_Eig_gest_iu_opc_var4(), FLA_Eig_gest_iu_opc_var5(), FLA_Eig_gest_nl_opc_var4(), FLA_Eig_gest_nl_opc_var5(), FLA_Eig_gest_nu_opc_var4(), FLA_Eig_gest_nu_opc_var5(), FLA_Her2_external(), FLA_Her2c_external(), FLA_Lyap_h_opc_var4(), FLA_Lyap_n_opc_var4(), FLA_Tridiag_UT_l_step_ofc_var2(), FLA_Tridiag_UT_l_step_opc_var1(), and FLA_Tridiag_UT_l_step_opc_var2().
{ int m_save = m; scomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; scomplex* x_conj; scomplex* y_conj; int incx_conj; int incy_conj; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_ccreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); bli_toggle_conj( conj ); } // Initialize with values assuming no conjugation of ( x * y' ) or // ( y * x' ). x_conj = x; incx_conj = incx; y_conj = y; incy_conj = incy; // We want to handle the case where ( x * y' ) and ( y * x' ) are // conjugated, but without explicitly conjugating the matrices. To do // so, we leverage the fact that computing the products conj( x * y' ) // and conj( y * x' ) is equivalent to computing ( conj(x) * conj(y)' ) // and ( conj(y) * conj(x)' ), respectively. if ( bli_is_conj( conj ) ) { x_conj = bli_callocv( m ); incx_conj = 1; y_conj = bli_callocv( m ); incy_conj = 1; bli_ccopyv( BLIS_CONJUGATE, m, x, incx, x_conj, incx_conj ); bli_ccopyv( BLIS_CONJUGATE, m, y, incy, y_conj, incy_conj ); } bli_cher2_blas( uplo, m, alpha, x_conj, incx_conj, y_conj, incy_conj, a, lda ); // Free the temporary conjugated x and y vectors. if ( bli_is_conj( conj ) ) { bli_cfree( x_conj ); bli_cfree( y_conj ); } // Free the temporary contiguous matrix. bli_cfree_saved_contigm( m_save, m_save, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_cher2_blas | ( | char | uplo, |
int | m, | ||
scomplex * | alpha, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | y, | ||
int | incy, | ||
scomplex * | a, | ||
int | lda | ||
) |
References bli_param_map_to_netlib_uplo(), cblas_cher2(), CblasColMajor, and F77_cher2().
Referenced by bli_cher2().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); cblas_cher2( cblas_order, cblas_uplo, m, alpha, x, incx, y, incy, a, lda ); #else char blas_uplo; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); F77_cher2( &uplo, &m, alpha, x, &incx, y, &incy, a, &lda ); #endif }
void bli_cher_blas | ( | char | uplo, |
int | m, | ||
float * | alpha, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | a, | ||
int | lda | ||
) |
References bli_param_map_to_netlib_uplo(), cblas_cher(), CblasColMajor, and F77_cher().
Referenced by bli_cher().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); cblas_cher( cblas_order, cblas_uplo, m, *alpha, x, incx, a, lda ); #else char blas_uplo; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); F77_cher( &uplo, &m, alpha, x, &incx, a, &lda ); #endif }
void bli_csymv | ( | char | uplo, |
int | m, | ||
scomplex * | alpha, | ||
scomplex * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | beta, | ||
scomplex * | y, | ||
int | incy | ||
) |
References bli_ccreate_contigmr(), bli_cfree_contigm(), bli_csymv_blas(), bli_is_row_storage(), and bli_zero_dim1().
Referenced by FLA_Symv_external().
{ scomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_ccreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); } bli_csymv_blas( uplo, m, alpha, a, lda, x, incx, beta, y, incy ); // Free the temporary contiguous matrix. bli_cfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_csymv_blas | ( | char | uplo, |
int | m, | ||
scomplex * | alpha, | ||
scomplex * | a, | ||
int | lda, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | beta, | ||
scomplex * | y, | ||
int | incy | ||
) |
References bli_callocv(), bli_ccopyv(), bli_cfree(), bli_param_map_to_netlib_side(), bli_param_map_to_netlib_uplo(), cblas_csymm(), CblasColMajor, and F77_csymm().
Referenced by bli_csymv().
{ scomplex* x_copy; scomplex* y_copy; int n = 1; int ldx = m; int ldy = m; #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_SIDE cblas_side; enum CBLAS_UPLO cblas_uplo; bli_param_map_to_netlib_side( BLIS_LEFT, &cblas_side ); bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); x_copy = bli_callocv( m ); y_copy = bli_callocv( m ); bli_ccopyv( BLIS_NO_CONJUGATE, m, x, incx, x_copy, 1 ); bli_ccopyv( BLIS_NO_CONJUGATE, m, y, incy, y_copy, 1 ); cblas_csymm( cblas_order, cblas_side, cblas_uplo, m, n, alpha, a, lda, x_copy, ldx, beta, y_copy, ldy ); bli_ccopyv( BLIS_NO_CONJUGATE, m, y_copy, 1, y, incy ); bli_cfree( x_copy ); bli_cfree( y_copy ); #else char blas_side; char blas_uplo; bli_param_map_to_netlib_side( BLIS_LEFT, &blas_side ); bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); x_copy = bli_callocv( m ); y_copy = bli_callocv( m ); bli_ccopyv( BLIS_NO_CONJUGATE, m, x, incx, x_copy, 1 ); bli_ccopyv( BLIS_NO_CONJUGATE, m, y, incy, y_copy, 1 ); F77_csymm ( &blas_side, &blas_uplo, &m, &n, alpha, a, &lda, x_copy, &ldx, beta, y_copy, &ldy ); bli_ccopyv( BLIS_NO_CONJUGATE, m, y_copy, 1, y, incy ); bli_cfree( x_copy ); bli_cfree( y_copy ); #endif }
void bli_csyr | ( | char | uplo, |
int | m, | ||
scomplex * | alpha, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_ccreate_contigmr(), bli_cfree_saved_contigm(), bli_csyr_blas(), bli_is_row_storage(), and bli_zero_dim1().
Referenced by FLA_Syr_external().
{ int m_save = m; scomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_ccreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); } bli_csyr_blas( uplo, m, alpha, x, incx, a, lda ); // Free the temporary contiguous matrix. bli_cfree_saved_contigm( m_save, m_save, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_csyr2 | ( | char | uplo, |
int | m, | ||
scomplex * | alpha, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | y, | ||
int | incy, | ||
scomplex * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_ccreate_contigmr(), bli_cfree_saved_contigm(), bli_csyr2_blas(), bli_is_row_storage(), and bli_zero_dim1().
Referenced by FLA_Syr2_external().
{ int m_save = m; scomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_ccreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); } bli_csyr2_blas( uplo, m, alpha, x, incx, y, incy, a, lda ); // Free the temporary contiguous matrix. bli_cfree_saved_contigm( m_save, m_save, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_csyr2_blas | ( | char | uplo, |
int | m, | ||
scomplex * | alpha, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | y, | ||
int | incy, | ||
scomplex * | a, | ||
int | lda | ||
) |
References bli_callocv(), bli_ccopyv(), bli_cfree(), bli_param_map_to_netlib_trans(), bli_param_map_to_netlib_uplo(), cblas_csyr2k(), CblasColMajor, F77_csyr2k(), scomplex::imag, and scomplex::real.
Referenced by bli_csyr2().
{ scomplex* x_copy; scomplex* y_copy; scomplex beta; int k = 1; int ldx = m; int ldy = m; #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; enum CBLAS_TRANSPOSE cblas_trans; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); bli_param_map_to_netlib_trans( BLIS_NO_TRANSPOSE, &cblas_trans ); x_copy = bli_callocv( m ); y_copy = bli_callocv( m ); bli_ccopyv( BLIS_NO_CONJUGATE, m, x, incx, x_copy, 1 ); bli_ccopyv( BLIS_NO_CONJUGATE, m, y, incy, y_copy, 1 ); beta.real = 1.0; beta.imag = 0.0; cblas_csyr2k( cblas_order, cblas_uplo, cblas_trans, m, k, alpha, x_copy, ldx, y_copy, ldy, &beta, a, lda ); bli_cfree( x_copy ); bli_cfree( y_copy ); #else char blas_uplo; char blas_trans; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); bli_param_map_to_netlib_trans( BLIS_NO_TRANSPOSE, &blas_trans ); x_copy = bli_callocv( m ); y_copy = bli_callocv( m ); bli_ccopyv( BLIS_NO_CONJUGATE, m, x, incx, x_copy, 1 ); bli_ccopyv( BLIS_NO_CONJUGATE, m, y, incy, y_copy, 1 ); beta.real = 1.0; beta.imag = 0.0; F77_csyr2k ( &blas_uplo, &blas_trans, &m, &k, alpha, x_copy, &ldx, y_copy, &ldy, &beta, a, &lda ); bli_cfree( x_copy ); bli_cfree( y_copy ); #endif }
void bli_csyr_blas | ( | char | uplo, |
int | m, | ||
scomplex * | alpha, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | a, | ||
int | lda | ||
) |
References bli_callocv(), bli_ccopyv(), bli_cfree(), bli_param_map_to_netlib_trans(), bli_param_map_to_netlib_uplo(), cblas_csyrk(), CblasColMajor, F77_csyrk(), scomplex::imag, and scomplex::real.
Referenced by bli_csyr().
{ scomplex* x_copy; scomplex beta; int k = 1; int ldx = m; #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; enum CBLAS_TRANSPOSE cblas_trans; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); bli_param_map_to_netlib_trans( BLIS_NO_TRANSPOSE, &cblas_trans ); x_copy = bli_callocv( m ); bli_ccopyv( BLIS_NO_CONJUGATE, m, x, incx, x_copy, 1 ); beta.real = 1.0; beta.imag = 0.0; cblas_csyrk( cblas_order, cblas_uplo, cblas_trans, m, k, alpha, x_copy, ldx, &beta, a, lda ); bli_cfree( x_copy ); #else char blas_uplo; char blas_trans; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); bli_param_map_to_netlib_trans( BLIS_NO_TRANSPOSE, &blas_trans ); x_copy = bli_callocv( m ); bli_ccopyv( BLIS_NO_CONJUGATE, m, x, incx, x_copy, 1 ); beta.real = 1.0; beta.imag = 0.0; F77_csyrk ( &blas_uplo, &blas_trans, &m, &k, alpha, x_copy, &ldx, &beta, a, &lda ); bli_cfree( x_copy ); #endif }
void bli_ctrmv | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
scomplex * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
scomplex * | x, | ||
int | incx | ||
) |
References bli_callocv(), bli_ccopyv(), bli_ccreate_contigmr(), bli_cfree(), bli_cfree_contigm(), bli_ctrmv_blas(), bli_is_conjnotrans(), bli_is_row_storage(), and bli_zero_dim1().
Referenced by bli_ctrmvsx(), FLA_Eig_gest_nl_opc_var1(), FLA_Eig_gest_nl_opc_var5(), FLA_Eig_gest_nu_opc_var1(), FLA_Eig_gest_nu_opc_var5(), FLA_Hess_UT_step_opc_var5(), FLA_Trinv_ln_opc_var1(), FLA_Trinv_ln_opc_var4(), FLA_Trinv_lu_opc_var1(), FLA_Trinv_lu_opc_var4(), FLA_Trinv_un_opc_var1(), FLA_Trinv_un_opc_var4(), FLA_Trinv_uu_opc_var1(), FLA_Trinv_uu_opc_var4(), FLA_Trmv_external(), FLA_Ttmm_l_opc_var3(), and FLA_Ttmm_u_opc_var3().
{ scomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; scomplex* x_conj; int incx_conj; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_ccreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); bli_toggle_trans( trans ); } // Initialize with values assuming that trans is not conjnotrans. x_conj = x; incx_conj = incx; // We want to handle the conjnotrans case, but without explicitly // conjugating A. To do so, we leverage the fact that computing the // product conj(A) * x is equivalent to computing conj( A * conj(x) ). // Note: strictly speaking, we don't need to create a copy of x since // the operation is simpler than, say, gemv. However, we create a copy // anyway since in practice it performs better due to increased spatial // locality. if ( bli_is_conjnotrans( trans ) ) { x_conj = bli_callocv( m ); incx_conj = 1; bli_ccopyv( BLIS_CONJUGATE, m, x, incx, x_conj, incx_conj ); } bli_ctrmv_blas( uplo, trans, diag, m, a, lda, x_conj, incx_conj ); // Save the contents of and then free the temporary conjugated x vector. if ( bli_is_conjnotrans( trans ) ) { bli_ccopyv( BLIS_CONJUGATE, m, x_conj, incx_conj, x, incx ); bli_cfree( x_conj ); } // Free the temporary contiguous matrix. bli_cfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_ctrmv_blas | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
scomplex * | a, | ||
int | lda, | ||
scomplex * | x, | ||
int | incx | ||
) |
References bli_param_map_to_netlib_diag(), bli_param_map_to_netlib_trans(), bli_param_map_to_netlib_uplo(), cblas_ctrmv(), CblasColMajor, and F77_ctrmv().
Referenced by bli_ctrmv().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; enum CBLAS_TRANSPOSE cblas_trans; enum CBLAS_DIAG cblas_diag; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); bli_param_map_to_netlib_trans( trans, &cblas_trans ); bli_param_map_to_netlib_diag( diag, &cblas_diag ); cblas_ctrmv( cblas_order, cblas_uplo, cblas_trans, cblas_diag, m, a, lda, x, incx ); #else char blas_uplo; char blas_trans; char blas_diag; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); bli_param_map_to_netlib_trans( trans, &blas_trans ); bli_param_map_to_netlib_diag( diag, &blas_diag ); F77_ctrmv( &blas_uplo, &blas_trans, &blas_diag, &m, a, &lda, x, &incx ); #endif }
void bli_ctrmvsx | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
scomplex * | alpha, | ||
scomplex * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | beta, | ||
scomplex * | y, | ||
int | incy | ||
) |
References bli_callocv(), bli_caxpyv(), bli_ccopyv(), bli_ccreate_contigmr(), bli_cfree(), bli_cfree_contigm(), bli_cscalv(), bli_ctrmv(), and bli_zero_dim1().
Referenced by FLA_Hess_UT_step_opc_var5().
{ scomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; scomplex* x_temp; int incx_temp; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_ccreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Allocate a temporary vector conformal to x. x_temp = bli_callocv( m ); incx_temp = 1; // Copy x to a temporary vector. bli_ccopyv( BLIS_NO_CONJUGATE, m, x, incx, x_temp, incx_temp ); // Perform the operation, storing the result to x_temp. bli_ctrmv( uplo, trans, diag, m, a, a_rs, a_cs, x_temp, incx_temp ); // Scale y by beta. bli_cscalv( BLIS_NO_CONJUGATE, m, beta, y, incy ); // Axpy the partial result in x_temp into y. bli_caxpyv( BLIS_NO_CONJUGATE, m, alpha, x_temp, incx_temp, y, incy ); // Free the temporary vector. bli_cfree( x_temp ); // Free the temporary contiguous matrix. bli_cfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_ctrsv | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
scomplex * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
scomplex * | x, | ||
int | incx | ||
) |
References bli_callocv(), bli_ccopyv(), bli_ccreate_contigmr(), bli_cfree(), bli_cfree_contigm(), bli_ctrsv_blas(), bli_is_conjnotrans(), bli_is_row_storage(), and bli_zero_dim1().
Referenced by bli_ctrsvsx(), FLA_Chol_l_opc_var1(), FLA_Chol_u_opc_var1(), FLA_Eig_gest_il_opc_var1(), FLA_Eig_gest_il_opc_var5(), FLA_Eig_gest_iu_opc_var1(), FLA_Eig_gest_iu_opc_var5(), FLA_Hess_UT_step_opc_var5(), FLA_LU_nopiv_opc_var1(), FLA_LU_nopiv_opc_var2(), FLA_LU_nopiv_opc_var3(), FLA_LU_piv_opc_var3(), FLA_Lyap_h_opc_var1(), FLA_Lyap_h_opc_var2(), FLA_Lyap_h_opc_var3(), FLA_Lyap_h_opc_var4(), FLA_Lyap_n_opc_var1(), FLA_Lyap_n_opc_var2(), FLA_Lyap_n_opc_var3(), FLA_Lyap_n_opc_var4(), FLA_Trinv_ln_opc_var2(), FLA_Trinv_ln_opc_var4(), FLA_Trinv_lu_opc_var2(), FLA_Trinv_lu_opc_var4(), FLA_Trinv_un_opc_var2(), FLA_Trinv_un_opc_var4(), FLA_Trinv_uu_opc_var2(), FLA_Trinv_uu_opc_var4(), and FLA_Trsv_external().
{ scomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; scomplex* x_conj; int incx_conj; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_ccreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); bli_toggle_trans( trans ); } // Initialize with values assuming that trans is not conjnotrans. x_conj = x; incx_conj = incx; // We want to handle the conjnotrans case, but without explicitly // conjugating A. To do so, we leverage the fact that computing the // product conj(A) * x is equivalent to computing conj( A * conj(x) ). // Note: strictly speaking, we don't need to create a copy of x since // the operation is simpler than, say, gemv. However, we create a copy // anyway since in practice it performs better due to increased spatial // locality. if ( bli_is_conjnotrans( trans ) ) { x_conj = bli_callocv( m ); incx_conj = 1; bli_ccopyv( BLIS_CONJUGATE, m, x, incx, x_conj, incx_conj ); } bli_ctrsv_blas( uplo, trans, diag, m, a, lda, x_conj, incx_conj ); // Save the contents of and then free the temporary conjugated x vector. if ( bli_is_conjnotrans( trans ) ) { bli_ccopyv( BLIS_CONJUGATE, m, x_conj, incx_conj, x, incx ); bli_cfree( x_conj ); } // Free the temporary contiguous matrix. bli_cfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_ctrsv_blas | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
scomplex * | a, | ||
int | lda, | ||
scomplex * | x, | ||
int | incx | ||
) |
References bli_param_map_to_netlib_diag(), bli_param_map_to_netlib_trans(), bli_param_map_to_netlib_uplo(), cblas_ctrsv(), CblasColMajor, and F77_ctrsv().
Referenced by bli_ctrsv().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; enum CBLAS_TRANSPOSE cblas_trans; enum CBLAS_DIAG cblas_diag; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); bli_param_map_to_netlib_trans( trans, &cblas_trans ); bli_param_map_to_netlib_diag( diag, &cblas_diag ); cblas_ctrsv( cblas_order, cblas_uplo, cblas_trans, cblas_diag, m, a, lda, x, incx ); #else char blas_uplo; char blas_trans; char blas_diag; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); bli_param_map_to_netlib_trans( trans, &blas_trans ); bli_param_map_to_netlib_diag( diag, &blas_diag ); F77_ctrsv( &blas_uplo, &blas_trans, &blas_diag, &m, a, &lda, x, &incx ); #endif }
void bli_ctrsvsx | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
scomplex * | alpha, | ||
scomplex * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
scomplex * | x, | ||
int | incx, | ||
scomplex * | beta, | ||
scomplex * | y, | ||
int | incy | ||
) |
References bli_callocv(), bli_caxpyv(), bli_ccopyv(), bli_ccreate_contigmr(), bli_cfree(), bli_cfree_contigm(), bli_cscalv(), bli_ctrsv(), and bli_zero_dim1().
{ scomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; scomplex* x_temp; int incx_temp; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_ccreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Allocate a temporary vector conformal to x. x_temp = bli_callocv( m ); incx_temp = 1; // Copy x to a temporary vector. bli_ccopyv( BLIS_NO_CONJUGATE, m, x, incx, x_temp, incx_temp ); // Perform the operation, storing the result to x_temp. bli_ctrsv( uplo, trans, diag, m, a, a_rs, a_cs, x_temp, incx_temp ); // Scale y by beta. bli_cscalv( BLIS_NO_CONJUGATE, m, beta, y, incy ); // Axpy the partial result in x_temp into y. bli_caxpyv( BLIS_NO_CONJUGATE, m, alpha, x_temp, incx_temp, y, incy ); // Free the temporary vector. bli_cfree( x_temp ); // Free the temporary contiguous matrix. bli_cfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_dgemv | ( | char | transa, |
char | conjx, | ||
int | m, | ||
int | n, | ||
double * | alpha, | ||
double * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
double * | x, | ||
int | incx, | ||
double * | beta, | ||
double * | y, | ||
int | incy | ||
) |
References bli_dcreate_contigm(), bli_dfree_contigm(), bli_dgemv_blas(), bli_does_trans(), bli_dscalv(), bli_is_row_storage(), and bli_zero_dim2().
Referenced by FLA_Accum_T_UT_fc_opd_var1(), FLA_Accum_T_UT_fr_opd_var1(), FLA_Apply_H2_UT_l_opd_var1(), FLA_Apply_H2_UT_r_opd_var1(), FLA_Apply_HUD_UT_l_opd_var1(), FLA_Bidiag_UT_u_step_ofd_var2(), FLA_Bidiag_UT_u_step_ofd_var3(), FLA_Bidiag_UT_u_step_ofd_var4(), FLA_Bidiag_UT_u_step_opd_var1(), FLA_Bidiag_UT_u_step_opd_var2(), FLA_Bidiag_UT_u_step_opd_var3(), FLA_Bidiag_UT_u_step_opd_var4(), FLA_Bidiag_UT_u_step_opd_var5(), FLA_Chol_l_opd_var2(), FLA_Chol_u_opd_var2(), FLA_Eig_gest_il_opd_var2(), FLA_Eig_gest_il_opd_var3(), FLA_Eig_gest_iu_opd_var2(), FLA_Eig_gest_iu_opd_var3(), FLA_Eig_gest_nl_opd_var2(), FLA_Eig_gest_nu_opd_var2(), FLA_Gemv_external(), FLA_Gemvc_external(), FLA_Hess_UT_step_ofd_var2(), FLA_Hess_UT_step_ofd_var3(), FLA_Hess_UT_step_ofd_var4(), FLA_Hess_UT_step_opd_var1(), FLA_Hess_UT_step_opd_var2(), FLA_Hess_UT_step_opd_var3(), FLA_Hess_UT_step_opd_var4(), FLA_Hess_UT_step_opd_var5(), FLA_LQ_UT_opd_var2(), FLA_LU_nopiv_opd_var2(), FLA_LU_nopiv_opd_var3(), FLA_LU_nopiv_opd_var4(), FLA_LU_piv_opd_var3(), FLA_LU_piv_opd_var4(), FLA_Lyap_h_opd_var2(), FLA_Lyap_h_opd_var3(), FLA_Lyap_n_opd_var2(), FLA_Lyap_n_opd_var3(), FLA_QR2_UT_opd_var1(), FLA_QR_UT_opd_var2(), FLA_Tridiag_UT_l_step_ofd_var2(), FLA_Tridiag_UT_l_step_ofd_var3(), FLA_Tridiag_UT_l_step_opd_var1(), FLA_Tridiag_UT_l_step_opd_var2(), FLA_Tridiag_UT_l_step_opd_var3(), FLA_Ttmm_l_opd_var2(), and FLA_Ttmm_u_opd_var2().
{ double* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim2( m, n ) ) { int n_elem; if ( bli_does_trans( transa ) ) n_elem = n; else n_elem = m; bli_dscalv( BLIS_NO_CONJUGATE, n_elem, beta, y, incy ); return; } // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_dcreate_contigm( m, n, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( m, n ); bli_swap_ints( lda, inca ); bli_toggle_trans( transa ); } bli_dgemv_blas( transa, m, n, alpha, a, lda, x, incx, beta, y, incy ); // Free the temporary contiguous matrix. bli_dfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_dgemv_blas | ( | char | transa, |
int | m, | ||
int | n, | ||
double * | alpha, | ||
double * | a, | ||
int | lda, | ||
double * | x, | ||
int | incx, | ||
double * | beta, | ||
double * | y, | ||
int | incy | ||
) |
References bli_param_map_to_netlib_trans(), cblas_dgemv(), CblasColMajor, and F77_dgemv().
Referenced by bli_dgemv().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_TRANSPOSE cblas_transa; bli_param_map_to_netlib_trans( transa, &cblas_transa ); cblas_dgemv( cblas_order, cblas_transa, m, n, *alpha, a, lda, x, incx, *beta, y, incy ); #else char blas_transa; bli_param_map_to_netlib_trans( transa, &blas_transa ); F77_dgemv( &blas_transa, &m, &n, alpha, a, &lda, x, &incx, beta, y, &incy ); #endif }
void bli_dger | ( | char | conjx, |
char | conjy, | ||
int | m, | ||
int | n, | ||
double * | alpha, | ||
double * | x, | ||
int | incx, | ||
double * | y, | ||
int | incy, | ||
double * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_dcreate_contigm(), bli_dfree_saved_contigm(), bli_dger_blas(), bli_is_row_storage(), and bli_zero_dim2().
Referenced by FLA_Apply_H2_UT_l_opd_var1(), FLA_Apply_H2_UT_r_opd_var1(), FLA_Apply_HUD_UT_l_opd_var1(), FLA_Bidiag_UT_u_step_ofd_var3(), FLA_Bidiag_UT_u_step_opd_var2(), FLA_Bidiag_UT_u_step_opd_var3(), FLA_Eig_gest_il_opd_var3(), FLA_Eig_gest_il_opd_var4(), FLA_Eig_gest_iu_opd_var3(), FLA_Eig_gest_iu_opd_var4(), FLA_Eig_gest_nl_opd_var4(), FLA_Eig_gest_nu_opd_var4(), FLA_Ger_external(), FLA_Gerc_external(), FLA_Hess_UT_step_ofd_var2(), FLA_Hess_UT_step_ofd_var3(), FLA_Hess_UT_step_ofd_var4(), FLA_Hess_UT_step_opd_var2(), FLA_Hess_UT_step_opd_var3(), FLA_Hess_UT_step_opd_var4(), FLA_LU_nopiv_opd_var5(), FLA_LU_piv_opd_var5(), FLA_Lyap_h_opd_var2(), FLA_Lyap_n_opd_var2(), FLA_SA_LU_unb(), FLA_Trinv_ln_opd_var3(), FLA_Trinv_ln_opd_var4(), FLA_Trinv_lu_opd_var3(), FLA_Trinv_lu_opd_var4(), FLA_Trinv_un_opd_var3(), FLA_Trinv_un_opd_var4(), FLA_Trinv_uu_opd_var3(), and FLA_Trinv_uu_opd_var4().
{ int m_save = m; int n_save = n; double* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim2( m, n ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_dcreate_contigm( m, n, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( m, n ); bli_swap_ints( lda, inca ); bli_swap_ints( incx, incy ); bli_swap_chars( conjx, conjy ); bli_dswap_pointers( x, y ); } // Initialize with values assuming no conjugation of x. bli_dger_blas( m, n, alpha, x, incx, y, incy, a, lda ); // Free the temporary contiguous matrix. bli_dfree_saved_contigm( m_save, n_save, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_dger_blas | ( | int | m, |
int | n, | ||
double * | alpha, | ||
double * | x, | ||
int | incx, | ||
double * | y, | ||
int | incy, | ||
double * | a, | ||
int | lda | ||
) |
References cblas_dger(), CblasColMajor, and F77_dger().
Referenced by bli_dger().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; cblas_dger( cblas_order, m, n, *alpha, x, incx, y, incy, a, lda ); #else F77_dger( &m, &n, alpha, x, &incx, y, &incy, a, &lda ); #endif }
void bli_dhemv | ( | char | uplo, |
char | conj, | ||
int | m, | ||
double * | alpha, | ||
double * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
double * | x, | ||
int | incx, | ||
double * | beta, | ||
double * | y, | ||
int | incy | ||
) |
References bli_dsymv().
Referenced by FLA_Eig_gest_il_opd_var1(), FLA_Eig_gest_il_opd_var2(), FLA_Eig_gest_iu_opd_var1(), FLA_Eig_gest_iu_opd_var2(), FLA_Eig_gest_nl_opd_var1(), FLA_Eig_gest_nl_opd_var2(), FLA_Eig_gest_nu_opd_var1(), FLA_Eig_gest_nu_opd_var2(), FLA_Lyap_h_opd_var1(), and FLA_Lyap_n_opd_var1().
{ bli_dsymv( uplo, m, alpha, a, a_rs, a_cs, x, incx, beta, y, incy ); }
void bli_dher | ( | char | uplo, |
char | conj, | ||
int | m, | ||
double * | alpha, | ||
double * | x, | ||
int | incx, | ||
double * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_dsyr().
{ bli_dsyr( uplo, m, alpha, x, incx, a, a_rs, a_cs ); }
void bli_dher2 | ( | char | uplo, |
char | conj, | ||
int | m, | ||
double * | alpha, | ||
double * | x, | ||
int | incx, | ||
double * | y, | ||
int | incy, | ||
double * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_dsyr2().
Referenced by FLA_Eig_gest_il_opd_var4(), FLA_Eig_gest_il_opd_var5(), FLA_Eig_gest_iu_opd_var4(), FLA_Eig_gest_iu_opd_var5(), FLA_Eig_gest_nl_opd_var4(), FLA_Eig_gest_nl_opd_var5(), FLA_Eig_gest_nu_opd_var4(), FLA_Eig_gest_nu_opd_var5(), FLA_Lyap_h_opd_var4(), and FLA_Lyap_n_opd_var4().
{ bli_dsyr2( uplo, m, alpha, x, incx, y, incy, a, a_rs, a_cs ); }
void bli_dsymv | ( | char | uplo, |
int | m, | ||
double * | alpha, | ||
double * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
double * | x, | ||
int | incx, | ||
double * | beta, | ||
double * | y, | ||
int | incy | ||
) |
References bli_dcreate_contigmr(), bli_dfree_contigm(), bli_dsymv_blas(), bli_is_row_storage(), and bli_zero_dim1().
Referenced by bli_dhemv(), FLA_Hemv_external(), FLA_Hemvc_external(), FLA_Symv_external(), FLA_Tridiag_UT_l_step_ofd_var2(), FLA_Tridiag_UT_l_step_ofd_var3(), FLA_Tridiag_UT_l_step_opd_var1(), FLA_Tridiag_UT_l_step_opd_var2(), and FLA_Tridiag_UT_l_step_opd_var3().
{ double* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_dcreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); } bli_dsymv_blas( uplo, m, alpha, a, lda, x, incx, beta, y, incy ); // Free the temporary contiguous matrix. bli_dfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_dsymv_blas | ( | char | uplo, |
int | m, | ||
double * | alpha, | ||
double * | a, | ||
int | lda, | ||
double * | x, | ||
int | incx, | ||
double * | beta, | ||
double * | y, | ||
int | incy | ||
) |
References bli_param_map_to_netlib_uplo(), cblas_dsymv(), CblasColMajor, and F77_dsymv().
Referenced by bli_dsymv().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); cblas_dsymv( cblas_order, cblas_uplo, m, *alpha, a, lda, x, incx, *beta, y, incy ); #else char blas_uplo; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); F77_dsymv( &blas_uplo, &m, alpha, a, &lda, x, &incx, beta, y, &incy ); #endif }
void bli_dsyr | ( | char | uplo, |
int | m, | ||
double * | alpha, | ||
double * | x, | ||
int | incx, | ||
double * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_dcreate_contigmr(), bli_dfree_saved_contigm(), bli_dsyr_blas(), bli_is_row_storage(), and bli_zero_dim1().
Referenced by bli_dher(), FLA_Chol_l_opd_var3(), FLA_Chol_u_opd_var3(), FLA_Her_external(), FLA_Herc_external(), FLA_Syr_external(), FLA_Ttmm_l_opd_var1(), and FLA_Ttmm_u_opd_var1().
{ int m_save = m; double* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_dcreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); } bli_dsyr_blas( uplo, m, alpha, x, incx, a, lda ); // Free the temporary contiguous matrix. bli_dfree_saved_contigm( m_save, m_save, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_dsyr2 | ( | char | uplo, |
int | m, | ||
double * | alpha, | ||
double * | x, | ||
int | incx, | ||
double * | y, | ||
int | incy, | ||
double * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_dcreate_contigmr(), bli_dfree_saved_contigm(), bli_dsyr2_blas(), bli_is_row_storage(), and bli_zero_dim1().
Referenced by bli_dher2(), FLA_Her2_external(), FLA_Her2c_external(), FLA_Syr2_external(), FLA_Tridiag_UT_l_step_ofd_var2(), FLA_Tridiag_UT_l_step_opd_var1(), and FLA_Tridiag_UT_l_step_opd_var2().
{ int m_save = m; double* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_dcreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); } bli_dsyr2_blas( uplo, m, alpha, x, incx, y, incy, a, lda ); // Free the temporary contiguous matrix. bli_dfree_saved_contigm( m_save, m_save, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_dsyr2_blas | ( | char | uplo, |
int | m, | ||
double * | alpha, | ||
double * | x, | ||
int | incx, | ||
double * | y, | ||
int | incy, | ||
double * | a, | ||
int | lda | ||
) |
References bli_param_map_to_netlib_uplo(), cblas_dsyr2(), CblasColMajor, and F77_dsyr2().
Referenced by bli_dsyr2().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); cblas_dsyr2( cblas_order, cblas_uplo, m, *alpha, x, incx, y, incy, a, lda ); #else char blas_uplo; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); F77_dsyr2( &uplo, &m, alpha, x, &incx, y, &incy, a, &lda ); #endif }
void bli_dsyr_blas | ( | char | uplo, |
int | m, | ||
double * | alpha, | ||
double * | x, | ||
int | incx, | ||
double * | a, | ||
int | lda | ||
) |
References bli_param_map_to_netlib_uplo(), cblas_dsyr(), CblasColMajor, and F77_dsyr().
Referenced by bli_dsyr().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); cblas_dsyr( cblas_order, cblas_uplo, m, *alpha, x, incx, a, lda ); #else char blas_uplo; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); F77_dsyr( &uplo, &m, alpha, x, &incx, a, &lda ); #endif }
void bli_dtrmv | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
double * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
double * | x, | ||
int | incx | ||
) |
References bli_dcreate_contigmr(), bli_dfree_contigm(), bli_dtrmv_blas(), bli_is_row_storage(), and bli_zero_dim1().
Referenced by bli_dtrmvsx(), FLA_Eig_gest_nl_opd_var1(), FLA_Eig_gest_nl_opd_var5(), FLA_Eig_gest_nu_opd_var1(), FLA_Eig_gest_nu_opd_var5(), FLA_Hess_UT_step_opd_var5(), FLA_Trinv_ln_opd_var1(), FLA_Trinv_ln_opd_var4(), FLA_Trinv_lu_opd_var1(), FLA_Trinv_lu_opd_var4(), FLA_Trinv_un_opd_var1(), FLA_Trinv_un_opd_var4(), FLA_Trinv_uu_opd_var1(), FLA_Trinv_uu_opd_var4(), FLA_Trmv_external(), FLA_Ttmm_l_opd_var3(), and FLA_Ttmm_u_opd_var3().
{ double* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_dcreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); bli_toggle_trans( trans ); } bli_dtrmv_blas( uplo, trans, diag, m, a, lda, x, incx ); // Free the temporary contiguous matrix. bli_dfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_dtrmv_blas | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
double * | a, | ||
int | lda, | ||
double * | x, | ||
int | incx | ||
) |
References bli_param_map_to_netlib_diag(), bli_param_map_to_netlib_trans(), bli_param_map_to_netlib_uplo(), cblas_dtrmv(), CblasColMajor, and F77_dtrmv().
Referenced by bli_dtrmv().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; enum CBLAS_TRANSPOSE cblas_trans; enum CBLAS_DIAG cblas_diag; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); bli_param_map_to_netlib_trans( trans, &cblas_trans ); bli_param_map_to_netlib_diag( diag, &cblas_diag ); cblas_dtrmv( cblas_order, cblas_uplo, cblas_trans, cblas_diag, m, a, lda, x, incx ); #else char blas_uplo; char blas_trans; char blas_diag; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); bli_param_map_to_netlib_trans( trans, &blas_trans ); bli_param_map_to_netlib_diag( diag, &blas_diag ); F77_dtrmv( &blas_uplo, &blas_trans, &blas_diag, &m, a, &lda, x, &incx ); #endif }
void bli_dtrmvsx | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
double * | alpha, | ||
double * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
double * | x, | ||
int | incx, | ||
double * | beta, | ||
double * | y, | ||
int | incy | ||
) |
References bli_dallocv(), bli_daxpyv(), bli_dcopyv(), bli_dcreate_contigmr(), bli_dfree(), bli_dfree_contigm(), bli_dscalv(), bli_dtrmv(), and bli_zero_dim1().
Referenced by FLA_Hess_UT_step_opd_var5().
{ double* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; double* x_temp; int incx_temp; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_dcreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Allocate a temporary vector conformal to x. x_temp = bli_dallocv( m ); incx_temp = 1; // Copy x to a temporary vector. bli_dcopyv( BLIS_NO_CONJUGATE, m, x, incx, x_temp, incx_temp ); // Perform the operation, storing the result to x_temp. bli_dtrmv( uplo, trans, diag, m, a, a_rs, a_cs, x_temp, incx_temp ); // Scale y by beta. bli_dscalv( BLIS_NO_CONJUGATE, m, beta, y, incy ); // Axpy the partial result in x_temp into y. bli_daxpyv( BLIS_NO_CONJUGATE, m, alpha, x_temp, incx_temp, y, incy ); // Free the temporary vector. bli_dfree( x_temp ); // Free the temporary contiguous matrix. bli_dfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_dtrsv | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
double * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
double * | x, | ||
int | incx | ||
) |
References bli_dcreate_contigmr(), bli_dfree_contigm(), bli_dtrsv_blas(), bli_is_row_storage(), and bli_zero_dim1().
Referenced by bli_dtrsvsx(), FLA_Chol_l_opd_var1(), FLA_Chol_u_opd_var1(), FLA_Eig_gest_il_opd_var1(), FLA_Eig_gest_il_opd_var5(), FLA_Eig_gest_iu_opd_var1(), FLA_Eig_gest_iu_opd_var5(), FLA_Hess_UT_step_opd_var5(), FLA_LU_nopiv_opd_var1(), FLA_LU_nopiv_opd_var2(), FLA_LU_nopiv_opd_var3(), FLA_LU_piv_opd_var3(), FLA_Lyap_h_opd_var1(), FLA_Lyap_h_opd_var2(), FLA_Lyap_h_opd_var3(), FLA_Lyap_h_opd_var4(), FLA_Lyap_n_opd_var1(), FLA_Lyap_n_opd_var2(), FLA_Lyap_n_opd_var3(), FLA_Lyap_n_opd_var4(), FLA_Trinv_ln_opd_var2(), FLA_Trinv_ln_opd_var4(), FLA_Trinv_lu_opd_var2(), FLA_Trinv_lu_opd_var4(), FLA_Trinv_un_opd_var2(), FLA_Trinv_un_opd_var4(), FLA_Trinv_uu_opd_var2(), FLA_Trinv_uu_opd_var4(), and FLA_Trsv_external().
{ double* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_dcreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); bli_toggle_trans( trans ); } bli_dtrsv_blas( uplo, trans, diag, m, a, lda, x, incx ); // Free the temporary contiguous matrix. bli_dfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_dtrsv_blas | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
double * | a, | ||
int | lda, | ||
double * | x, | ||
int | incx | ||
) |
References bli_param_map_to_netlib_diag(), bli_param_map_to_netlib_trans(), bli_param_map_to_netlib_uplo(), cblas_dtrsv(), CblasColMajor, and F77_dtrsv().
Referenced by bli_dtrsv().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; enum CBLAS_TRANSPOSE cblas_trans; enum CBLAS_DIAG cblas_diag; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); bli_param_map_to_netlib_trans( trans, &cblas_trans ); bli_param_map_to_netlib_diag( diag, &cblas_diag ); cblas_dtrsv( cblas_order, cblas_uplo, cblas_trans, cblas_diag, m, a, lda, x, incx ); #else char blas_uplo; char blas_trans; char blas_diag; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); bli_param_map_to_netlib_trans( trans, &blas_trans ); bli_param_map_to_netlib_diag( diag, &blas_diag ); F77_dtrsv( &blas_uplo, &blas_trans, &blas_diag, &m, a, &lda, x, &incx ); #endif }
void bli_dtrsvsx | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
double * | alpha, | ||
double * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
double * | x, | ||
int | incx, | ||
double * | beta, | ||
double * | y, | ||
int | incy | ||
) |
References bli_dallocv(), bli_daxpyv(), bli_dcopyv(), bli_dcreate_contigmr(), bli_dfree(), bli_dfree_contigm(), bli_dscalv(), bli_dtrsv(), and bli_zero_dim1().
{ double* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; double* x_temp; int incx_temp; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_dcreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Allocate a temporary vector conformal to x. x_temp = bli_dallocv( m ); incx_temp = 1; // Copy x to a temporary vector. bli_dcopyv( BLIS_NO_CONJUGATE, m, x, incx, x_temp, incx_temp ); // Perform the operation, storing the result to x_temp. bli_dtrsv( uplo, trans, diag, m, a, a_rs, a_cs, x_temp, incx_temp ); // Scale y by beta. bli_dscalv( BLIS_NO_CONJUGATE, m, beta, y, incy ); // Axpy the partial result in x_temp into y. bli_daxpyv( BLIS_NO_CONJUGATE, m, alpha, x_temp, incx_temp, y, incy ); // Free the temporary vector. bli_dfree( x_temp ); // Free the temporary contiguous matrix. bli_dfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_sgemv | ( | char | transa, |
char | conjx, | ||
int | m, | ||
int | n, | ||
float * | alpha, | ||
float * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
float * | x, | ||
int | incx, | ||
float * | beta, | ||
float * | y, | ||
int | incy | ||
) |
References bli_does_trans(), bli_is_row_storage(), bli_screate_contigm(), bli_sfree_contigm(), bli_sgemv_blas(), bli_sscalv(), and bli_zero_dim2().
Referenced by FLA_Accum_T_UT_fc_ops_var1(), FLA_Accum_T_UT_fr_ops_var1(), FLA_Apply_H2_UT_l_ops_var1(), FLA_Apply_H2_UT_r_ops_var1(), FLA_Apply_HUD_UT_l_ops_var1(), FLA_Bidiag_UT_u_step_ofs_var2(), FLA_Bidiag_UT_u_step_ofs_var3(), FLA_Bidiag_UT_u_step_ofs_var4(), FLA_Bidiag_UT_u_step_ops_var1(), FLA_Bidiag_UT_u_step_ops_var2(), FLA_Bidiag_UT_u_step_ops_var3(), FLA_Bidiag_UT_u_step_ops_var4(), FLA_Bidiag_UT_u_step_ops_var5(), FLA_Chol_l_ops_var2(), FLA_Chol_u_ops_var2(), FLA_Eig_gest_il_ops_var2(), FLA_Eig_gest_il_ops_var3(), FLA_Eig_gest_iu_ops_var2(), FLA_Eig_gest_iu_ops_var3(), FLA_Eig_gest_nl_ops_var2(), FLA_Eig_gest_nu_ops_var2(), FLA_Gemv_external(), FLA_Gemvc_external(), FLA_Hess_UT_step_ofs_var2(), FLA_Hess_UT_step_ofs_var3(), FLA_Hess_UT_step_ofs_var4(), FLA_Hess_UT_step_ops_var1(), FLA_Hess_UT_step_ops_var2(), FLA_Hess_UT_step_ops_var3(), FLA_Hess_UT_step_ops_var4(), FLA_Hess_UT_step_ops_var5(), FLA_LQ_UT_ops_var2(), FLA_LU_nopiv_ops_var2(), FLA_LU_nopiv_ops_var3(), FLA_LU_nopiv_ops_var4(), FLA_LU_piv_ops_var3(), FLA_LU_piv_ops_var4(), FLA_Lyap_h_ops_var2(), FLA_Lyap_h_ops_var3(), FLA_Lyap_n_ops_var2(), FLA_Lyap_n_ops_var3(), FLA_QR2_UT_ops_var1(), FLA_QR_UT_ops_var2(), FLA_Tridiag_UT_l_step_ofs_var2(), FLA_Tridiag_UT_l_step_ofs_var3(), FLA_Tridiag_UT_l_step_ops_var1(), FLA_Tridiag_UT_l_step_ops_var2(), FLA_Tridiag_UT_l_step_ops_var3(), FLA_Ttmm_l_ops_var2(), and FLA_Ttmm_u_ops_var2().
{ float* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim2( m, n ) ) { int n_elem; if ( bli_does_trans( transa ) ) n_elem = n; else n_elem = m; bli_sscalv( BLIS_NO_CONJUGATE, n_elem, beta, y, incy ); return; } // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_screate_contigm( m, n, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( m, n ); bli_swap_ints( lda, inca ); bli_toggle_trans( transa ); } bli_sgemv_blas( transa, m, n, alpha, a, lda, x, incx, beta, y, incy ); // Free the temporary contiguous matrix. bli_sfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_sgemv_blas | ( | char | transa, |
int | m, | ||
int | n, | ||
float * | alpha, | ||
float * | a, | ||
int | lda, | ||
float * | x, | ||
int | incx, | ||
float * | beta, | ||
float * | y, | ||
int | incy | ||
) |
References bli_param_map_to_netlib_trans(), cblas_sgemv(), CblasColMajor, and F77_sgemv().
Referenced by bli_sgemv().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_TRANSPOSE cblas_transa; bli_param_map_to_netlib_trans( transa, &cblas_transa ); cblas_sgemv( cblas_order, cblas_transa, m, n, *alpha, a, lda, x, incx, *beta, y, incy ); #else char blas_transa; bli_param_map_to_netlib_trans( transa, &blas_transa ); F77_sgemv( &blas_transa, &m, &n, alpha, a, &lda, x, &incx, beta, y, &incy ); #endif }
void bli_sger | ( | char | conjx, |
char | conjy, | ||
int | m, | ||
int | n, | ||
float * | alpha, | ||
float * | x, | ||
int | incx, | ||
float * | y, | ||
int | incy, | ||
float * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_is_row_storage(), bli_screate_contigm(), bli_sfree_saved_contigm(), bli_sger_blas(), and bli_zero_dim2().
Referenced by FLA_Apply_H2_UT_l_ops_var1(), FLA_Apply_H2_UT_r_ops_var1(), FLA_Apply_HUD_UT_l_ops_var1(), FLA_Bidiag_UT_u_step_ofs_var3(), FLA_Bidiag_UT_u_step_ops_var2(), FLA_Bidiag_UT_u_step_ops_var3(), FLA_Eig_gest_il_ops_var3(), FLA_Eig_gest_il_ops_var4(), FLA_Eig_gest_iu_ops_var3(), FLA_Eig_gest_iu_ops_var4(), FLA_Eig_gest_nl_ops_var4(), FLA_Eig_gest_nu_ops_var4(), FLA_Ger_external(), FLA_Gerc_external(), FLA_Hess_UT_step_ofs_var2(), FLA_Hess_UT_step_ofs_var3(), FLA_Hess_UT_step_ofs_var4(), FLA_Hess_UT_step_ops_var2(), FLA_Hess_UT_step_ops_var3(), FLA_Hess_UT_step_ops_var4(), FLA_LU_nopiv_ops_var5(), FLA_LU_piv_ops_var5(), FLA_Lyap_h_ops_var2(), FLA_Lyap_n_ops_var2(), FLA_SA_LU_unb(), FLA_Trinv_ln_ops_var3(), FLA_Trinv_ln_ops_var4(), FLA_Trinv_lu_ops_var3(), FLA_Trinv_lu_ops_var4(), FLA_Trinv_un_ops_var3(), FLA_Trinv_un_ops_var4(), FLA_Trinv_uu_ops_var3(), and FLA_Trinv_uu_ops_var4().
{ int m_save = m; int n_save = n; float* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim2( m, n ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_screate_contigm( m, n, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( m, n ); bli_swap_ints( lda, inca ); bli_swap_ints( incx, incy ); bli_swap_chars( conjx, conjy ); bli_sswap_pointers( x, y ); } // Initialize with values assuming no conjugation of x. bli_sger_blas( m, n, alpha, x, incx, y, incy, a, lda ); // Free the temporary contiguous matrix. bli_sfree_saved_contigm( m_save, n_save, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_sger_blas | ( | int | m, |
int | n, | ||
float * | alpha, | ||
float * | x, | ||
int | incx, | ||
float * | y, | ||
int | incy, | ||
float * | a, | ||
int | lda | ||
) |
References cblas_sger(), CblasColMajor, and F77_sger().
Referenced by bli_sger().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; cblas_sger( cblas_order, m, n, *alpha, x, incx, y, incy, a, lda ); #else F77_sger( &m, &n, alpha, x, &incx, y, &incy, a, &lda ); #endif }
void bli_shemv | ( | char | uplo, |
char | conj, | ||
int | m, | ||
float * | alpha, | ||
float * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
float * | x, | ||
int | incx, | ||
float * | beta, | ||
float * | y, | ||
int | incy | ||
) |
References bli_ssymv().
Referenced by FLA_Eig_gest_il_ops_var1(), FLA_Eig_gest_il_ops_var2(), FLA_Eig_gest_iu_ops_var1(), FLA_Eig_gest_iu_ops_var2(), FLA_Eig_gest_nl_ops_var1(), FLA_Eig_gest_nl_ops_var2(), FLA_Eig_gest_nu_ops_var1(), FLA_Eig_gest_nu_ops_var2(), FLA_Lyap_h_ops_var1(), and FLA_Lyap_n_ops_var1().
{ bli_ssymv( uplo, m, alpha, a, a_rs, a_cs, x, incx, beta, y, incy ); }
void bli_sher | ( | char | uplo, |
char | conj, | ||
int | m, | ||
float * | alpha, | ||
float * | x, | ||
int | incx, | ||
float * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_ssyr().
{ bli_ssyr( uplo, m, alpha, x, incx, a, a_rs, a_cs ); }
void bli_sher2 | ( | char | uplo, |
char | conj, | ||
int | m, | ||
float * | alpha, | ||
float * | x, | ||
int | incx, | ||
float * | y, | ||
int | incy, | ||
float * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_ssyr2().
Referenced by FLA_Eig_gest_il_ops_var4(), FLA_Eig_gest_il_ops_var5(), FLA_Eig_gest_iu_ops_var4(), FLA_Eig_gest_iu_ops_var5(), FLA_Eig_gest_nl_ops_var4(), FLA_Eig_gest_nl_ops_var5(), FLA_Eig_gest_nu_ops_var4(), FLA_Eig_gest_nu_ops_var5(), FLA_Lyap_h_ops_var4(), and FLA_Lyap_n_ops_var4().
{ bli_ssyr2( uplo, m, alpha, x, incx, y, incy, a, a_rs, a_cs ); }
void bli_ssymv | ( | char | uplo, |
int | m, | ||
float * | alpha, | ||
float * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
float * | x, | ||
int | incx, | ||
float * | beta, | ||
float * | y, | ||
int | incy | ||
) |
References bli_is_row_storage(), bli_screate_contigmr(), bli_sfree_contigm(), bli_ssymv_blas(), and bli_zero_dim1().
Referenced by bli_shemv(), FLA_Hemv_external(), FLA_Hemvc_external(), FLA_Symv_external(), FLA_Tridiag_UT_l_step_ofs_var2(), FLA_Tridiag_UT_l_step_ofs_var3(), FLA_Tridiag_UT_l_step_ops_var1(), FLA_Tridiag_UT_l_step_ops_var2(), and FLA_Tridiag_UT_l_step_ops_var3().
{ float* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_screate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); } bli_ssymv_blas( uplo, m, alpha, a, lda, x, incx, beta, y, incy ); // Free the temporary contiguous matrix. bli_sfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_ssymv_blas | ( | char | uplo, |
int | m, | ||
float * | alpha, | ||
float * | a, | ||
int | lda, | ||
float * | x, | ||
int | incx, | ||
float * | beta, | ||
float * | y, | ||
int | incy | ||
) |
References bli_param_map_to_netlib_uplo(), cblas_ssymv(), CblasColMajor, and F77_ssymv().
Referenced by bli_ssymv().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); cblas_ssymv( cblas_order, cblas_uplo, m, *alpha, a, lda, x, incx, *beta, y, incy ); #else char blas_uplo; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); F77_ssymv( &blas_uplo, &m, alpha, a, &lda, x, &incx, beta, y, &incy ); #endif }
void bli_ssyr | ( | char | uplo, |
int | m, | ||
float * | alpha, | ||
float * | x, | ||
int | incx, | ||
float * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_is_row_storage(), bli_screate_contigmr(), bli_sfree_saved_contigm(), bli_ssyr_blas(), and bli_zero_dim1().
Referenced by bli_sher(), FLA_Chol_l_ops_var3(), FLA_Chol_u_ops_var3(), FLA_Her_external(), FLA_Herc_external(), FLA_Syr_external(), FLA_Ttmm_l_ops_var1(), and FLA_Ttmm_u_ops_var1().
{ int m_save = m; float* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_screate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); } bli_ssyr_blas( uplo, m, alpha, x, incx, a, lda ); // Free the temporary contiguous matrix. bli_sfree_saved_contigm( m_save, m_save, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_ssyr2 | ( | char | uplo, |
int | m, | ||
float * | alpha, | ||
float * | x, | ||
int | incx, | ||
float * | y, | ||
int | incy, | ||
float * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_is_row_storage(), bli_screate_contigmr(), bli_sfree_saved_contigm(), bli_ssyr2_blas(), and bli_zero_dim1().
Referenced by bli_sher2(), FLA_Her2_external(), FLA_Her2c_external(), FLA_Syr2_external(), FLA_Tridiag_UT_l_step_ofs_var2(), FLA_Tridiag_UT_l_step_ops_var1(), and FLA_Tridiag_UT_l_step_ops_var2().
{ int m_save = m; float* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_screate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); } bli_ssyr2_blas( uplo, m, alpha, x, incx, y, incy, a, lda ); // Free the temporary contiguous matrix. bli_sfree_saved_contigm( m_save, m_save, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_ssyr2_blas | ( | char | uplo, |
int | m, | ||
float * | alpha, | ||
float * | x, | ||
int | incx, | ||
float * | y, | ||
int | incy, | ||
float * | a, | ||
int | lda | ||
) |
References bli_param_map_to_netlib_uplo(), cblas_ssyr2(), CblasColMajor, and F77_ssyr2().
Referenced by bli_ssyr2().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); cblas_ssyr2( cblas_order, cblas_uplo, m, *alpha, x, incx, y, incy, a, lda ); #else char blas_uplo; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); F77_ssyr2( &uplo, &m, alpha, x, &incx, y, &incy, a, &lda ); #endif }
void bli_ssyr_blas | ( | char | uplo, |
int | m, | ||
float * | alpha, | ||
float * | x, | ||
int | incx, | ||
float * | a, | ||
int | lda | ||
) |
References bli_param_map_to_netlib_uplo(), cblas_ssyr(), CblasColMajor, and F77_ssyr().
Referenced by bli_ssyr().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); cblas_ssyr( cblas_order, cblas_uplo, m, *alpha, x, incx, a, lda ); #else char blas_uplo; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); F77_ssyr( &uplo, &m, alpha, x, &incx, a, &lda ); #endif }
void bli_strmv | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
float * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
float * | x, | ||
int | incx | ||
) |
References bli_is_row_storage(), bli_screate_contigmr(), bli_sfree_contigm(), bli_strmv_blas(), and bli_zero_dim1().
Referenced by bli_strmvsx(), FLA_Eig_gest_nl_ops_var1(), FLA_Eig_gest_nl_ops_var5(), FLA_Eig_gest_nu_ops_var1(), FLA_Eig_gest_nu_ops_var5(), FLA_Hess_UT_step_ops_var5(), FLA_Trinv_ln_ops_var1(), FLA_Trinv_ln_ops_var4(), FLA_Trinv_lu_ops_var1(), FLA_Trinv_lu_ops_var4(), FLA_Trinv_un_ops_var1(), FLA_Trinv_un_ops_var4(), FLA_Trinv_uu_ops_var1(), FLA_Trinv_uu_ops_var4(), FLA_Trmv_external(), FLA_Ttmm_l_ops_var3(), and FLA_Ttmm_u_ops_var3().
{ float* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_screate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); bli_toggle_trans( trans ); } bli_strmv_blas( uplo, trans, diag, m, a, lda, x, incx ); // Free the temporary contiguous matrix. bli_sfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_strmv_blas | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
float * | a, | ||
int | lda, | ||
float * | x, | ||
int | incx | ||
) |
References bli_param_map_to_netlib_diag(), bli_param_map_to_netlib_trans(), bli_param_map_to_netlib_uplo(), cblas_strmv(), CblasColMajor, and F77_strmv().
Referenced by bli_strmv().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; enum CBLAS_TRANSPOSE cblas_trans; enum CBLAS_DIAG cblas_diag; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); bli_param_map_to_netlib_trans( trans, &cblas_trans ); bli_param_map_to_netlib_diag( diag, &cblas_diag ); cblas_strmv( cblas_order, cblas_uplo, cblas_trans, cblas_diag, m, a, lda, x, incx ); #else char blas_uplo; char blas_trans; char blas_diag; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); bli_param_map_to_netlib_trans( trans, &blas_trans ); bli_param_map_to_netlib_diag( diag, &blas_diag ); F77_strmv( &blas_uplo, &blas_trans, &blas_diag, &m, a, &lda, x, &incx ); #endif }
void bli_strmvsx | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
float * | alpha, | ||
float * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
float * | x, | ||
int | incx, | ||
float * | beta, | ||
float * | y, | ||
int | incy | ||
) |
References bli_sallocv(), bli_saxpyv(), bli_scopyv(), bli_screate_contigmr(), bli_sfree(), bli_sfree_contigm(), bli_sscalv(), bli_strmv(), and bli_zero_dim1().
Referenced by FLA_Hess_UT_step_ops_var5().
{ float* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; float* x_temp; int incx_temp; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_screate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Allocate a temporary vector conformal to x. x_temp = bli_sallocv( m ); incx_temp = 1; // Copy x to a temporary vector. bli_scopyv( BLIS_NO_CONJUGATE, m, x, incx, x_temp, incx_temp ); // Perform the operation, storing the result to x_temp. bli_strmv( uplo, trans, diag, m, a, a_rs, a_cs, x_temp, incx_temp ); // Scale y by beta. bli_sscalv( BLIS_NO_CONJUGATE, m, beta, y, incy ); // Axpy the partial result in x_temp into y. bli_saxpyv( BLIS_NO_CONJUGATE, m, alpha, x_temp, incx_temp, y, incy ); // Free the temporary vector. bli_sfree( x_temp ); // Free the temporary contiguous matrix. bli_sfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_strsv | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
float * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
float * | x, | ||
int | incx | ||
) |
References bli_is_row_storage(), bli_screate_contigmr(), bli_sfree_contigm(), bli_strsv_blas(), and bli_zero_dim1().
Referenced by bli_strsvsx(), FLA_Chol_l_ops_var1(), FLA_Chol_u_ops_var1(), FLA_Eig_gest_il_ops_var1(), FLA_Eig_gest_il_ops_var5(), FLA_Eig_gest_iu_ops_var1(), FLA_Eig_gest_iu_ops_var5(), FLA_Hess_UT_step_ops_var5(), FLA_LU_nopiv_ops_var1(), FLA_LU_nopiv_ops_var2(), FLA_LU_nopiv_ops_var3(), FLA_LU_piv_ops_var3(), FLA_Lyap_h_ops_var1(), FLA_Lyap_h_ops_var2(), FLA_Lyap_h_ops_var3(), FLA_Lyap_h_ops_var4(), FLA_Lyap_n_ops_var1(), FLA_Lyap_n_ops_var2(), FLA_Lyap_n_ops_var3(), FLA_Lyap_n_ops_var4(), FLA_Trinv_ln_ops_var2(), FLA_Trinv_ln_ops_var4(), FLA_Trinv_lu_ops_var2(), FLA_Trinv_lu_ops_var4(), FLA_Trinv_un_ops_var2(), FLA_Trinv_un_ops_var4(), FLA_Trinv_uu_ops_var2(), FLA_Trinv_uu_ops_var4(), and FLA_Trsv_external().
{ float* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_screate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); bli_toggle_trans( trans ); } bli_strsv_blas( uplo, trans, diag, m, a, lda, x, incx ); // Free the temporary contiguous matrix. bli_sfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_strsv_blas | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
float * | a, | ||
int | lda, | ||
float * | x, | ||
int | incx | ||
) |
References bli_param_map_to_netlib_diag(), bli_param_map_to_netlib_trans(), bli_param_map_to_netlib_uplo(), cblas_strsv(), CblasColMajor, and F77_strsv().
Referenced by bli_strsv().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; enum CBLAS_TRANSPOSE cblas_trans; enum CBLAS_DIAG cblas_diag; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); bli_param_map_to_netlib_trans( trans, &cblas_trans ); bli_param_map_to_netlib_diag( diag, &cblas_diag ); cblas_strsv( cblas_order, cblas_uplo, cblas_trans, cblas_diag, m, a, lda, x, incx ); #else char blas_uplo; char blas_trans; char blas_diag; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); bli_param_map_to_netlib_trans( trans, &blas_trans ); bli_param_map_to_netlib_diag( diag, &blas_diag ); F77_strsv( &blas_uplo, &blas_trans, &blas_diag, &m, a, &lda, x, &incx ); #endif }
void bli_strsvsx | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
float * | alpha, | ||
float * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
float * | x, | ||
int | incx, | ||
float * | beta, | ||
float * | y, | ||
int | incy | ||
) |
References bli_sallocv(), bli_saxpyv(), bli_scopyv(), bli_screate_contigmr(), bli_sfree(), bli_sfree_contigm(), bli_sscalv(), bli_strsv(), and bli_zero_dim1().
{ float* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; float* x_temp; int incx_temp; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_screate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Allocate a temporary vector conformal to x. x_temp = bli_sallocv( m ); incx_temp = 1; // Copy x to a temporary vector. bli_scopyv( BLIS_NO_CONJUGATE, m, x, incx, x_temp, incx_temp ); // Perform the operation, storing the result to x_temp. bli_strsv( uplo, trans, diag, m, a, a_rs, a_cs, x_temp, incx_temp ); // Scale y by beta. bli_sscalv( BLIS_NO_CONJUGATE, m, beta, y, incy ); // Axpy the partial result in x_temp into y. bli_saxpyv( BLIS_NO_CONJUGATE, m, alpha, x_temp, incx_temp, y, incy ); // Free the temporary vector. bli_sfree( x_temp ); // Free the temporary contiguous matrix. bli_sfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_zgemv | ( | char | transa, |
char | conjx, | ||
int | m, | ||
int | n, | ||
dcomplex * | alpha, | ||
dcomplex * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | beta, | ||
dcomplex * | y, | ||
int | incy | ||
) |
References bli_does_trans(), bli_is_conj(), bli_is_conjnotrans(), bli_is_row_storage(), bli_z0(), bli_z1(), bli_zallocv(), bli_zaxpyv(), bli_zconjv(), bli_zcopyv(), bli_zcreate_contigm(), bli_zero_dim2(), bli_zfree(), bli_zfree_contigm(), bli_zgemv_blas(), and bli_zscalv().
Referenced by FLA_Accum_T_UT_fc_opz_var1(), FLA_Accum_T_UT_fr_opz_var1(), FLA_Apply_H2_UT_l_opz_var1(), FLA_Apply_H2_UT_r_opz_var1(), FLA_Apply_HUD_UT_l_opz_var1(), FLA_Bidiag_UT_u_step_ofz_var2(), FLA_Bidiag_UT_u_step_ofz_var3(), FLA_Bidiag_UT_u_step_ofz_var4(), FLA_Bidiag_UT_u_step_opz_var1(), FLA_Bidiag_UT_u_step_opz_var2(), FLA_Bidiag_UT_u_step_opz_var3(), FLA_Bidiag_UT_u_step_opz_var4(), FLA_Bidiag_UT_u_step_opz_var5(), FLA_Chol_l_opz_var2(), FLA_Chol_u_opz_var2(), FLA_Eig_gest_il_opz_var2(), FLA_Eig_gest_il_opz_var3(), FLA_Eig_gest_iu_opz_var2(), FLA_Eig_gest_iu_opz_var3(), FLA_Eig_gest_nl_opz_var2(), FLA_Eig_gest_nu_opz_var2(), FLA_Gemv_external(), FLA_Gemvc_external(), FLA_Hess_UT_step_ofz_var2(), FLA_Hess_UT_step_ofz_var3(), FLA_Hess_UT_step_ofz_var4(), FLA_Hess_UT_step_opz_var1(), FLA_Hess_UT_step_opz_var2(), FLA_Hess_UT_step_opz_var3(), FLA_Hess_UT_step_opz_var4(), FLA_Hess_UT_step_opz_var5(), FLA_LQ_UT_opz_var2(), FLA_LU_nopiv_opz_var2(), FLA_LU_nopiv_opz_var3(), FLA_LU_nopiv_opz_var4(), FLA_LU_piv_opz_var3(), FLA_LU_piv_opz_var4(), FLA_Lyap_h_opz_var2(), FLA_Lyap_h_opz_var3(), FLA_Lyap_n_opz_var2(), FLA_Lyap_n_opz_var3(), FLA_QR2_UT_opz_var1(), FLA_QR_UT_opz_var2(), FLA_Tridiag_UT_l_step_ofz_var2(), FLA_Tridiag_UT_l_step_ofz_var3(), FLA_Tridiag_UT_l_step_opz_var1(), FLA_Tridiag_UT_l_step_opz_var2(), FLA_Tridiag_UT_l_step_opz_var3(), FLA_Ttmm_l_opz_var2(), and FLA_Ttmm_u_opz_var2().
{ dcomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; dcomplex zero = bli_z0(); dcomplex one = bli_z1(); dcomplex* x_conj; dcomplex* ax; int lda, inca; int n_x; int incx_conj; int incax; // Return early if possible. if ( bli_zero_dim2( m, n ) ) { int n_elem; if ( bli_does_trans( transa ) ) n_elem = n; else n_elem = m; bli_zscalv( BLIS_NO_CONJUGATE, n_elem, beta, y, incy ); return; } // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_zcreate_contigm( m, n, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( m, n ); bli_swap_ints( lda, inca ); bli_toggle_trans( transa ); } // Initialize with values assuming no conjugation of x. x_conj = x; incx_conj = incx; // We need a temporary vector for the cases when x is conjugated, and // also for the cases where A is conjugated. if ( bli_is_conj( conjx ) || bli_is_conjnotrans( transa ) ) { if ( bli_does_trans( transa ) ) n_x = m; else n_x = n; x_conj = bli_zallocv( n_x ); incx_conj = 1; bli_zcopyv( conjx, n_x, x, incx, x_conj, incx_conj ); } // We want to handle the conjnotrans case, but without explicitly // conjugating A. To do so, we leverage the fact that computing the // product conj(A) * x is equivalent to computing conj( A * conj(x) ). if ( bli_is_conjnotrans( transa ) ) { // We need a temporary vector for the product A * conj(x), which is // conformal to y. We know we are not transposing, so y is length m. ax = bli_zallocv( m ); incax = 1; // Start by conjugating the contents of the temporary copy of x. bli_zconjv( n, x_conj, incx_conj ); // Compute A * conj(x) where x is the temporary copy of x created above. bli_zgemv_blas( BLIS_NO_TRANSPOSE, m, n, &one, a, lda, x_conj, incx_conj, &zero, ax, incax ); // Scale y by beta. bli_zscalv( BLIS_NO_CONJUGATE, m, beta, y, incy ); // And finally, accumulate alpha * conj( A * conj(x) ) into y. bli_zaxpyv( BLIS_CONJUGATE, m, alpha, ax, incax, y, incy); // Free the temporary vector for Ax. bli_zfree( ax ); } else // notrans, trans, or conjtrans { bli_zgemv_blas( transa, m, n, alpha, a, lda, x_conj, incx_conj, beta, y, incy ); } // Free the temporary conjugated x vector. if ( bli_is_conj( conjx ) || bli_is_conjnotrans( transa ) ) bli_zfree( x_conj ); // Free the temporary contiguous matrix. bli_zfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_zgemv_blas | ( | char | transa, |
int | m, | ||
int | n, | ||
dcomplex * | alpha, | ||
dcomplex * | a, | ||
int | lda, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | beta, | ||
dcomplex * | y, | ||
int | incy | ||
) |
References bli_param_map_to_netlib_trans(), cblas_zgemv(), CblasColMajor, and F77_zgemv().
Referenced by bli_zgemv().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_TRANSPOSE cblas_transa; bli_param_map_to_netlib_trans( transa, &cblas_transa ); cblas_zgemv( cblas_order, cblas_transa, m, n, alpha, a, lda, x, incx, beta, y, incy ); #else char blas_transa; bli_param_map_to_netlib_trans( transa, &blas_transa ); F77_zgemv( &blas_transa, &m, &n, alpha, a, &lda, x, &incx, beta, y, &incy ); #endif }
void bli_zger | ( | char | conjx, |
char | conjy, | ||
int | m, | ||
int | n, | ||
dcomplex * | alpha, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | y, | ||
int | incy, | ||
dcomplex * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_is_conj(), bli_is_row_storage(), bli_zallocv(), bli_zcopyv(), bli_zcreate_contigm(), bli_zero_dim2(), bli_zfree(), bli_zfree_saved_contigm(), bli_zgerc_blas(), and bli_zgeru_blas().
Referenced by FLA_Apply_H2_UT_l_opz_var1(), FLA_Apply_H2_UT_r_opz_var1(), FLA_Apply_HUD_UT_l_opz_var1(), FLA_Bidiag_UT_u_step_ofz_var3(), FLA_Bidiag_UT_u_step_opz_var2(), FLA_Bidiag_UT_u_step_opz_var3(), FLA_Eig_gest_il_opz_var3(), FLA_Eig_gest_il_opz_var4(), FLA_Eig_gest_iu_opz_var3(), FLA_Eig_gest_iu_opz_var4(), FLA_Eig_gest_nl_opz_var4(), FLA_Eig_gest_nu_opz_var4(), FLA_Ger_external(), FLA_Gerc_external(), FLA_Hess_UT_step_ofz_var2(), FLA_Hess_UT_step_ofz_var3(), FLA_Hess_UT_step_ofz_var4(), FLA_Hess_UT_step_opz_var2(), FLA_Hess_UT_step_opz_var3(), FLA_Hess_UT_step_opz_var4(), FLA_LU_nopiv_opz_var5(), FLA_LU_piv_opz_var5(), FLA_Lyap_h_opz_var2(), FLA_Lyap_n_opz_var2(), FLA_SA_LU_unb(), FLA_Trinv_ln_opz_var3(), FLA_Trinv_ln_opz_var4(), FLA_Trinv_lu_opz_var3(), FLA_Trinv_lu_opz_var4(), FLA_Trinv_un_opz_var3(), FLA_Trinv_un_opz_var4(), FLA_Trinv_uu_opz_var3(), and FLA_Trinv_uu_opz_var4().
{ int m_save = m; int n_save = n; dcomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; dcomplex* x_conj; int incx_conj; int lda, inca; // Return early if possible. if ( bli_zero_dim2( m, n ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_zcreate_contigm( m, n, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( m, n ); bli_swap_ints( lda, inca ); bli_swap_ints( incx, incy ); bli_swap_chars( conjx, conjy ); bli_zswap_pointers( x, y ); } // Initialize with values assuming no conjugation of x. x_conj = x; incx_conj = incx; // We need a temporary vector for the cases when x is conjugated. if ( bli_is_conj( conjx ) ) { x_conj = bli_zallocv( m ); incx_conj = 1; bli_zcopyv( BLIS_CONJUGATE, m, x, incx, x_conj, incx_conj ); } // Conjugation of y is supported in the BLAS. if ( bli_is_conj( conjy ) ) { bli_zgerc_blas( m, n, alpha, x_conj, incx_conj, y, incy, a, lda ); } else { bli_zgeru_blas( m, n, alpha, x_conj, incx_conj, y, incy, a, lda ); } // Free the temporary conjugated x vector. if ( bli_is_conj( conjx ) ) bli_zfree( x_conj ); // Free the temporary contiguous matrix. bli_zfree_saved_contigm( m_save, n_save, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_zgerc_blas | ( | int | m, |
int | n, | ||
dcomplex * | alpha, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | y, | ||
int | incy, | ||
dcomplex * | a, | ||
int | lda | ||
) |
References cblas_zgerc(), CblasColMajor, and F77_zgerc().
Referenced by bli_zger().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; cblas_zgerc( cblas_order, m, n, alpha, x, incx, y, incy, a, lda ); #else F77_zgerc ( &m, &n, alpha, x, &incx, y, &incy, a, &lda ); #endif }
void bli_zgeru_blas | ( | int | m, |
int | n, | ||
dcomplex * | alpha, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | y, | ||
int | incy, | ||
dcomplex * | a, | ||
int | lda | ||
) |
References cblas_zgeru(), CblasColMajor, and F77_zgeru().
Referenced by bli_zger().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; cblas_zgeru( cblas_order, m, n, alpha, x, incx, y, incy, a, lda ); #else F77_zgeru ( &m, &n, alpha, x, &incx, y, &incy, a, &lda ); #endif }
void bli_zhemv | ( | char | uplo, |
char | conj, | ||
int | m, | ||
dcomplex * | alpha, | ||
dcomplex * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | beta, | ||
dcomplex * | y, | ||
int | incy | ||
) |
References bli_is_conj(), bli_is_row_storage(), bli_z0(), bli_z1(), bli_zallocv(), bli_zaxpyv(), bli_zcopyv(), bli_zcreate_contigmr(), bli_zero_dim1(), bli_zfree(), bli_zfree_contigm(), bli_zhemv_blas(), and bli_zscalv().
Referenced by FLA_Eig_gest_il_opz_var1(), FLA_Eig_gest_il_opz_var2(), FLA_Eig_gest_iu_opz_var1(), FLA_Eig_gest_iu_opz_var2(), FLA_Eig_gest_nl_opz_var1(), FLA_Eig_gest_nl_opz_var2(), FLA_Eig_gest_nu_opz_var1(), FLA_Eig_gest_nu_opz_var2(), FLA_Hemv_external(), FLA_Hemvc_external(), FLA_Lyap_h_opz_var1(), FLA_Lyap_n_opz_var1(), FLA_Tridiag_UT_l_step_ofz_var2(), FLA_Tridiag_UT_l_step_ofz_var3(), FLA_Tridiag_UT_l_step_opz_var1(), FLA_Tridiag_UT_l_step_opz_var2(), and FLA_Tridiag_UT_l_step_opz_var3().
{ dcomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; dcomplex zero = bli_z0(); dcomplex one = bli_z1(); dcomplex* x_conj; dcomplex* ax; int lda, inca; int incx_conj; int incax; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_zcreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); bli_toggle_conj( conj ); } // We want to handle the case where A is conjugated, but without // explicitly or conjugating A. To do so, we leverage the fact that // computing the product conj(A) * x is equivalent to computing // conj( A * conj(x) ). if ( bli_is_conj( conj ) ) { // We need a temporary vector so we can create a conjugated copy of x. x_conj = bli_zallocv( m ); incx_conj = 1; bli_zcopyv( BLIS_CONJUGATE, m, x, incx, x_conj, incx_conj ); // We need a temporary vector for the product A * conj(x), which is // conformal to y (and x). ax = bli_zallocv( m ); incax = 1; // Compute A * conj(x) where x is the temporary copy of x created above. bli_zhemv_blas( uplo, m, &one, a, lda, x_conj, incx_conj, &zero, ax, incax ); // Scale y by beta. bli_zscalv( BLIS_NO_CONJUGATE, m, beta, y, incy ); // And finally, accumulate alpha * conj( A * conj(x) ) into y. bli_zaxpyv( BLIS_CONJUGATE, m, alpha, ax, incax, y, incy); // Free the temporary vectors for x and Ax. bli_zfree( x_conj ); bli_zfree( ax ); } else // noconj { bli_zhemv_blas( uplo, m, alpha, a, lda, x, incx, beta, y, incy ); } // Free the temporary contiguous matrix. bli_zfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_zhemv_blas | ( | char | uplo, |
int | m, | ||
dcomplex * | alpha, | ||
dcomplex * | a, | ||
int | lda, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | beta, | ||
dcomplex * | y, | ||
int | incy | ||
) |
References bli_param_map_to_netlib_uplo(), cblas_zhemv(), CblasColMajor, and F77_zhemv().
Referenced by bli_zhemv().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); cblas_zhemv( cblas_order, cblas_uplo, m, alpha, a, lda, x, incx, beta, y, incy ); #else char blas_uplo; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); F77_zhemv( &blas_uplo, &m, alpha, a, &lda, x, &incx, beta, y, &incy ); #endif }
void bli_zher | ( | char | uplo, |
char | conj, | ||
int | m, | ||
double * | alpha, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_is_conj(), bli_is_row_storage(), bli_zallocv(), bli_zcopyv(), bli_zcreate_contigmr(), bli_zero_dim1(), bli_zfree(), bli_zfree_saved_contigm(), and bli_zher_blas().
Referenced by FLA_Chol_l_opz_var3(), FLA_Chol_u_opz_var3(), FLA_Her_external(), FLA_Herc_external(), FLA_Ttmm_l_opz_var1(), and FLA_Ttmm_u_opz_var1().
{ int m_save = m; dcomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; dcomplex* x_conj; int incx_conj; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_zcreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); bli_toggle_conj( conj ); } // Initialize with values assuming no conjugation of ( x * x' ). x_conj = x; incx_conj = incx; // We want to handle the case where ( x * x' ) is conjugated, but // without explicitly conjugating the matrix. To do so, we leverage // the fact that computing the product conj( x * x' ) is equivalent // to computing ( conj(x) * conj(x)' ), since ( x * x' ) is Hermitian. if ( bli_is_conj( conj ) ) { x_conj = bli_zallocv( m ); incx_conj = 1; bli_zcopyv( BLIS_CONJUGATE, m, x, incx, x_conj, incx_conj ); } bli_zher_blas( uplo, m, alpha, x_conj, incx_conj, a, lda ); // Free the temporary conjugated x vector. if ( bli_is_conj( conj ) ) bli_zfree( x_conj ); // Free the temporary contiguous matrix. bli_zfree_saved_contigm( m_save, m_save, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_zher2 | ( | char | uplo, |
char | conj, | ||
int | m, | ||
dcomplex * | alpha, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | y, | ||
int | incy, | ||
dcomplex * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_is_conj(), bli_is_row_storage(), bli_zallocv(), bli_zcopyv(), bli_zcreate_contigmr(), bli_zero_dim1(), bli_zfree(), bli_zfree_saved_contigm(), and bli_zher2_blas().
Referenced by FLA_Eig_gest_il_opz_var4(), FLA_Eig_gest_il_opz_var5(), FLA_Eig_gest_iu_opz_var4(), FLA_Eig_gest_iu_opz_var5(), FLA_Eig_gest_nl_opz_var4(), FLA_Eig_gest_nl_opz_var5(), FLA_Eig_gest_nu_opz_var4(), FLA_Eig_gest_nu_opz_var5(), FLA_Her2_external(), FLA_Her2c_external(), FLA_Lyap_h_opz_var4(), FLA_Lyap_n_opz_var4(), FLA_Tridiag_UT_l_step_ofz_var2(), FLA_Tridiag_UT_l_step_opz_var1(), and FLA_Tridiag_UT_l_step_opz_var2().
{ int m_save = m; dcomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; dcomplex* x_conj; dcomplex* y_conj; int incx_conj; int incy_conj; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_zcreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); bli_toggle_conj( conj ); } // Initialize with values assuming no conjugation of ( x * y' ) or // ( y * x' ). x_conj = x; incx_conj = incx; y_conj = y; incy_conj = incy; // We want to handle the case where ( x * y' ) and ( y * x' ) are // conjugated, but without explicitly conjugating the matrices. To do // so, we leverage the fact that computing the products conj( x * y' ) // and conj( y * x' ) is equivalent to computing ( conj(x) * conj(y)' ) // and ( conj(y) * conj(x)' ), respectively. if ( bli_is_conj( conj ) ) { x_conj = bli_zallocv( m ); incx_conj = 1; y_conj = bli_zallocv( m ); incy_conj = 1; bli_zcopyv( BLIS_CONJUGATE, m, x, incx, x_conj, incx_conj ); bli_zcopyv( BLIS_CONJUGATE, m, y, incy, y_conj, incy_conj ); } bli_zher2_blas( uplo, m, alpha, x_conj, incx_conj, y_conj, incy_conj, a, lda ); // Free the temporary conjugated x and y vectors. if ( bli_is_conj( conj ) ) { bli_zfree( x_conj ); bli_zfree( y_conj ); } // Free the temporary contiguous matrix. bli_zfree_saved_contigm( m_save, m_save, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_zher2_blas | ( | char | uplo, |
int | m, | ||
dcomplex * | alpha, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | y, | ||
int | incy, | ||
dcomplex * | a, | ||
int | lda | ||
) |
References bli_param_map_to_netlib_uplo(), cblas_zher2(), CblasColMajor, and F77_zher2().
Referenced by bli_zher2().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); cblas_zher2( cblas_order, cblas_uplo, m, alpha, x, incx, y, incy, a, lda ); #else char blas_uplo; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); F77_zher2( &uplo, &m, alpha, x, &incx, y, &incy, a, &lda ); #endif }
void bli_zher_blas | ( | char | uplo, |
int | m, | ||
double * | alpha, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | a, | ||
int | lda | ||
) |
References bli_param_map_to_netlib_uplo(), cblas_zher(), CblasColMajor, and F77_zher().
Referenced by bli_zher().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); cblas_zher( cblas_order, cblas_uplo, m, *alpha, x, incx, a, lda ); #else char blas_uplo; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); F77_zher( &uplo, &m, alpha, x, &incx, a, &lda ); #endif }
void bli_zsymv | ( | char | uplo, |
int | m, | ||
dcomplex * | alpha, | ||
dcomplex * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | beta, | ||
dcomplex * | y, | ||
int | incy | ||
) |
References bli_is_row_storage(), bli_zcreate_contigmr(), bli_zero_dim1(), bli_zfree_contigm(), and bli_zsymv_blas().
Referenced by FLA_Symv_external().
{ dcomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_zcreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); } bli_zsymv_blas( uplo, m, alpha, a, lda, x, incx, beta, y, incy ); // Free the temporary contiguous matrix. bli_zfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_zsymv_blas | ( | char | uplo, |
int | m, | ||
dcomplex * | alpha, | ||
dcomplex * | a, | ||
int | lda, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | beta, | ||
dcomplex * | y, | ||
int | incy | ||
) |
References bli_param_map_to_netlib_side(), bli_param_map_to_netlib_uplo(), bli_zallocv(), bli_zcopyv(), bli_zfree(), cblas_zsymm(), CblasColMajor, and F77_zsymm().
Referenced by bli_zsymv().
{ dcomplex* x_copy; dcomplex* y_copy; int n = 1; int ldx = m; int ldy = m; #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_SIDE cblas_side; enum CBLAS_UPLO cblas_uplo; bli_param_map_to_netlib_side( BLIS_LEFT, &cblas_side ); bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); x_copy = bli_zallocv( m ); y_copy = bli_zallocv( m ); bli_zcopyv( BLIS_NO_CONJUGATE, m, x, incx, x_copy, 1 ); bli_zcopyv( BLIS_NO_CONJUGATE, m, y, incy, y_copy, 1 ); cblas_zsymm( cblas_order, cblas_side, cblas_uplo, m, n, alpha, a, lda, x_copy, ldx, beta, y_copy, ldy ); bli_zcopyv( BLIS_NO_CONJUGATE, m, y_copy, 1, y, incy ); bli_zfree( x_copy ); bli_zfree( y_copy ); #else char blas_side; char blas_uplo; bli_param_map_to_netlib_side( BLIS_LEFT, &blas_side ); bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); x_copy = bli_zallocv( m ); y_copy = bli_zallocv( m ); bli_zcopyv( BLIS_NO_CONJUGATE, m, x, incx, x_copy, 1 ); bli_zcopyv( BLIS_NO_CONJUGATE, m, y, incy, y_copy, 1 ); F77_zsymm ( &blas_side, &blas_uplo, &m, &n, alpha, a, &lda, x_copy, &ldx, beta, y_copy, &ldy ); bli_zcopyv( BLIS_NO_CONJUGATE, m, y_copy, 1, y, incy ); bli_zfree( x_copy ); bli_zfree( y_copy ); #endif }
void bli_zsyr | ( | char | uplo, |
int | m, | ||
dcomplex * | alpha, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_is_row_storage(), bli_zcreate_contigmr(), bli_zero_dim1(), bli_zfree_saved_contigm(), and bli_zsyr_blas().
Referenced by FLA_Syr_external().
{ int m_save = m; dcomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_zcreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); } bli_zsyr_blas( uplo, m, alpha, x, incx, a, lda ); // Free the temporary contiguous matrix. bli_zfree_saved_contigm( m_save, m_save, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_zsyr2 | ( | char | uplo, |
int | m, | ||
dcomplex * | alpha, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | y, | ||
int | incy, | ||
dcomplex * | a, | ||
int | a_rs, | ||
int | a_cs | ||
) |
References bli_is_row_storage(), bli_zcreate_contigmr(), bli_zero_dim1(), bli_zfree_saved_contigm(), and bli_zsyr2_blas().
Referenced by FLA_Syr2_external().
{ int m_save = m; dcomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_zcreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); } bli_zsyr2_blas( uplo, m, alpha, x, incx, y, incy, a, lda ); // Free the temporary contiguous matrix. bli_zfree_saved_contigm( m_save, m_save, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_zsyr2_blas | ( | char | uplo, |
int | m, | ||
dcomplex * | alpha, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | y, | ||
int | incy, | ||
dcomplex * | a, | ||
int | lda | ||
) |
References bli_param_map_to_netlib_trans(), bli_param_map_to_netlib_uplo(), bli_zallocv(), bli_zcopyv(), bli_zfree(), cblas_zsyr2k(), CblasColMajor, F77_zsyr2k(), dcomplex::imag, and dcomplex::real.
Referenced by bli_zsyr2().
{ dcomplex* x_copy; dcomplex* y_copy; dcomplex beta; int k = 1; int ldx = m; int ldy = m; #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; enum CBLAS_TRANSPOSE cblas_trans; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); bli_param_map_to_netlib_trans( BLIS_NO_TRANSPOSE, &cblas_trans ); x_copy = bli_zallocv( m ); y_copy = bli_zallocv( m ); bli_zcopyv( BLIS_NO_CONJUGATE, m, x, incx, x_copy, 1 ); bli_zcopyv( BLIS_NO_CONJUGATE, m, y, incy, y_copy, 1 ); beta.real = 1.0; beta.imag = 0.0; cblas_zsyr2k( cblas_order, cblas_uplo, cblas_trans, m, k, alpha, x_copy, ldx, y_copy, ldy, &beta, a, lda ); bli_zfree( x_copy ); bli_zfree( y_copy ); #else char blas_uplo; char blas_trans; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); bli_param_map_to_netlib_trans( BLIS_NO_TRANSPOSE, &blas_trans ); x_copy = bli_zallocv( m ); y_copy = bli_zallocv( m ); bli_zcopyv( BLIS_NO_CONJUGATE, m, x, incx, x_copy, 1 ); bli_zcopyv( BLIS_NO_CONJUGATE, m, y, incy, y_copy, 1 ); beta.real = 1.0; beta.imag = 0.0; F77_zsyr2k ( &blas_uplo, &blas_trans, &m, &k, alpha, x_copy, &ldx, y_copy, &ldy, &beta, a, &lda ); bli_zfree( x_copy ); bli_zfree( y_copy ); #endif }
void bli_zsyr_blas | ( | char | uplo, |
int | m, | ||
dcomplex * | alpha, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | a, | ||
int | lda | ||
) |
References bli_param_map_to_netlib_trans(), bli_param_map_to_netlib_uplo(), bli_zallocv(), bli_zcopyv(), bli_zfree(), cblas_zsyrk(), CblasColMajor, F77_zsyrk(), dcomplex::imag, and dcomplex::real.
Referenced by bli_zsyr().
{ dcomplex* x_copy; dcomplex beta; int k = 1; int ldx = m; #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; enum CBLAS_TRANSPOSE cblas_trans; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); bli_param_map_to_netlib_trans( BLIS_NO_TRANSPOSE, &cblas_trans ); x_copy = bli_zallocv( m ); bli_zcopyv( BLIS_NO_CONJUGATE, m, x, incx, x_copy, 1 ); beta.real = 1.0; beta.imag = 0.0; cblas_zsyrk( cblas_order, cblas_uplo, cblas_trans, m, k, alpha, x_copy, ldx, &beta, a, lda ); bli_zfree( x_copy ); #else char blas_uplo; char blas_trans; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); bli_param_map_to_netlib_trans( BLIS_NO_TRANSPOSE, &blas_trans ); x_copy = bli_zallocv( m ); bli_zcopyv( BLIS_NO_CONJUGATE, m, x, incx, x_copy, 1 ); beta.real = 1.0; beta.imag = 0.0; F77_zsyrk ( &blas_uplo, &blas_trans, &m, &k, alpha, x_copy, &ldx, &beta, a, &lda ); bli_zfree( x_copy ); #endif }
void bli_ztrmv | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
dcomplex * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
dcomplex * | x, | ||
int | incx | ||
) |
References bli_is_conjnotrans(), bli_is_row_storage(), bli_zallocv(), bli_zcopyv(), bli_zcreate_contigmr(), bli_zero_dim1(), bli_zfree(), bli_zfree_contigm(), and bli_ztrmv_blas().
Referenced by bli_ztrmvsx(), FLA_Eig_gest_nl_opz_var1(), FLA_Eig_gest_nl_opz_var5(), FLA_Eig_gest_nu_opz_var1(), FLA_Eig_gest_nu_opz_var5(), FLA_Hess_UT_step_opz_var5(), FLA_Trinv_ln_opz_var1(), FLA_Trinv_ln_opz_var4(), FLA_Trinv_lu_opz_var1(), FLA_Trinv_lu_opz_var4(), FLA_Trinv_un_opz_var1(), FLA_Trinv_un_opz_var4(), FLA_Trinv_uu_opz_var1(), FLA_Trinv_uu_opz_var4(), FLA_Trmv_external(), FLA_Ttmm_l_opz_var3(), and FLA_Ttmm_u_opz_var3().
{ dcomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; dcomplex* x_conj; int incx_conj; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_zcreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); bli_toggle_trans( trans ); } // Initialize with values assuming that trans is not conjnotrans. x_conj = x; incx_conj = incx; // We want to handle the conjnotrans case, but without explicitly // conjugating A. To do so, we leverage the fact that computing the // product conj(A) * x is equivalent to computing conj( A * conj(x) ). // Note: strictly speaking, we don't need to create a copy of x since // the operation is simpler than, say, gemv. However, we create a copy // anyway since in practice it performs better due to increased spatial // locality. if ( bli_is_conjnotrans( trans ) ) { x_conj = bli_zallocv( m ); incx_conj = 1; bli_zcopyv( BLIS_CONJUGATE, m, x, incx, x_conj, incx_conj ); } bli_ztrmv_blas( uplo, trans, diag, m, a, lda, x_conj, incx_conj ); // Save the contents of and then free the temporary conjugated x vector. if ( bli_is_conjnotrans( trans ) ) { bli_zcopyv( BLIS_CONJUGATE, m, x_conj, incx_conj, x, incx ); bli_zfree( x_conj ); } // Free the temporary contiguous matrix. bli_zfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_ztrmv_blas | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
dcomplex * | a, | ||
int | lda, | ||
dcomplex * | x, | ||
int | incx | ||
) |
References bli_param_map_to_netlib_diag(), bli_param_map_to_netlib_trans(), bli_param_map_to_netlib_uplo(), cblas_ztrmv(), CblasColMajor, and F77_ztrmv().
Referenced by bli_ztrmv().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; enum CBLAS_TRANSPOSE cblas_trans; enum CBLAS_DIAG cblas_diag; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); bli_param_map_to_netlib_trans( trans, &cblas_trans ); bli_param_map_to_netlib_diag( diag, &cblas_diag ); cblas_ztrmv( cblas_order, cblas_uplo, cblas_trans, cblas_diag, m, a, lda, x, incx ); #else char blas_uplo; char blas_trans; char blas_diag; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); bli_param_map_to_netlib_trans( trans, &blas_trans ); bli_param_map_to_netlib_diag( diag, &blas_diag ); F77_ztrmv( &blas_uplo, &blas_trans, &blas_diag, &m, a, &lda, x, &incx ); #endif }
void bli_ztrmvsx | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
dcomplex * | alpha, | ||
dcomplex * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | beta, | ||
dcomplex * | y, | ||
int | incy | ||
) |
References bli_zallocv(), bli_zaxpyv(), bli_zcopyv(), bli_zcreate_contigmr(), bli_zero_dim1(), bli_zfree(), bli_zfree_contigm(), bli_zscalv(), and bli_ztrmv().
Referenced by FLA_Hess_UT_step_opz_var5().
{ dcomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; dcomplex* x_temp; int incx_temp; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_zcreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Allocate a temporary vector conformal to x. x_temp = bli_zallocv( m ); incx_temp = 1; // Copy x to a temporary vector. bli_zcopyv( BLIS_NO_CONJUGATE, m, x, incx, x_temp, incx_temp ); // Perform the operation, storing the result to x_temp. bli_ztrmv( uplo, trans, diag, m, a, a_rs, a_cs, x_temp, incx_temp ); // Scale y by beta. bli_zscalv( BLIS_NO_CONJUGATE, m, beta, y, incy ); // Axpy the partial result in x_temp into y. bli_zaxpyv( BLIS_NO_CONJUGATE, m, alpha, x_temp, incx_temp, y, incy ); // Free the temporary vector. bli_zfree( x_temp ); // Free the temporary contiguous matrix. bli_zfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_ztrsv | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
dcomplex * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
dcomplex * | x, | ||
int | incx | ||
) |
References bli_is_conjnotrans(), bli_is_row_storage(), bli_zallocv(), bli_zcopyv(), bli_zcreate_contigmr(), bli_zero_dim1(), bli_zfree(), bli_zfree_contigm(), and bli_ztrsv_blas().
Referenced by bli_ztrsvsx(), FLA_Chol_l_opz_var1(), FLA_Chol_u_opz_var1(), FLA_Eig_gest_il_opz_var1(), FLA_Eig_gest_il_opz_var5(), FLA_Eig_gest_iu_opz_var1(), FLA_Eig_gest_iu_opz_var5(), FLA_Hess_UT_step_opz_var5(), FLA_LU_nopiv_opz_var1(), FLA_LU_nopiv_opz_var2(), FLA_LU_nopiv_opz_var3(), FLA_LU_piv_opz_var3(), FLA_Lyap_h_opz_var1(), FLA_Lyap_h_opz_var2(), FLA_Lyap_h_opz_var3(), FLA_Lyap_h_opz_var4(), FLA_Lyap_n_opz_var1(), FLA_Lyap_n_opz_var2(), FLA_Lyap_n_opz_var3(), FLA_Lyap_n_opz_var4(), FLA_Trinv_ln_opz_var2(), FLA_Trinv_ln_opz_var4(), FLA_Trinv_lu_opz_var2(), FLA_Trinv_lu_opz_var4(), FLA_Trinv_un_opz_var2(), FLA_Trinv_un_opz_var4(), FLA_Trinv_uu_opz_var2(), FLA_Trinv_uu_opz_var4(), and FLA_Trsv_external().
{ dcomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; dcomplex* x_conj; int incx_conj; int lda, inca; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_zcreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Initialize with values assuming column-major storage. lda = a_cs; inca = a_rs; // If A is a row-major matrix, then we can use the underlying column-major // BLAS implementation by fiddling with the parameters. if ( bli_is_row_storage( a_rs, a_cs ) ) { bli_swap_ints( lda, inca ); bli_toggle_uplo( uplo ); bli_toggle_trans( trans ); } // Initialize with values assuming that trans is not conjnotrans. x_conj = x; incx_conj = incx; // We want to handle the conjnotrans case, but without explicitly // conjugating A. To do so, we leverage the fact that computing the // product conj(A) * x is equivalent to computing conj( A * conj(x) ). // Note: strictly speaking, we don't need to create a copy of x since // the operation is simpler than, say, gemv. However, we create a copy // anyway since in practice it performs better due to increased spatial // locality. if ( bli_is_conjnotrans( trans ) ) { x_conj = bli_zallocv( m ); incx_conj = 1; bli_zcopyv( BLIS_CONJUGATE, m, x, incx, x_conj, incx_conj ); } bli_ztrsv_blas( uplo, trans, diag, m, a, lda, x_conj, incx_conj ); // Save the contents of and then free the temporary conjugated x vector. if ( bli_is_conjnotrans( trans ) ) { bli_zcopyv( BLIS_CONJUGATE, m, x_conj, incx_conj, x, incx ); bli_zfree( x_conj ); } // Free the temporary contiguous matrix. bli_zfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }
void bli_ztrsv_blas | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
dcomplex * | a, | ||
int | lda, | ||
dcomplex * | x, | ||
int | incx | ||
) |
References bli_param_map_to_netlib_diag(), bli_param_map_to_netlib_trans(), bli_param_map_to_netlib_uplo(), cblas_ztrsv(), CblasColMajor, and F77_ztrsv().
Referenced by bli_ztrsv().
{ #ifdef BLIS_ENABLE_CBLAS_INTERFACES enum CBLAS_ORDER cblas_order = CblasColMajor; enum CBLAS_UPLO cblas_uplo; enum CBLAS_TRANSPOSE cblas_trans; enum CBLAS_DIAG cblas_diag; bli_param_map_to_netlib_uplo( uplo, &cblas_uplo ); bli_param_map_to_netlib_trans( trans, &cblas_trans ); bli_param_map_to_netlib_diag( diag, &cblas_diag ); cblas_ztrsv( cblas_order, cblas_uplo, cblas_trans, cblas_diag, m, a, lda, x, incx ); #else char blas_uplo; char blas_trans; char blas_diag; bli_param_map_to_netlib_uplo( uplo, &blas_uplo ); bli_param_map_to_netlib_trans( trans, &blas_trans ); bli_param_map_to_netlib_diag( diag, &blas_diag ); F77_ztrsv( &blas_uplo, &blas_trans, &blas_diag, &m, a, &lda, x, &incx ); #endif }
void bli_ztrsvsx | ( | char | uplo, |
char | trans, | ||
char | diag, | ||
int | m, | ||
dcomplex * | alpha, | ||
dcomplex * | a, | ||
int | a_rs, | ||
int | a_cs, | ||
dcomplex * | x, | ||
int | incx, | ||
dcomplex * | beta, | ||
dcomplex * | y, | ||
int | incy | ||
) |
References bli_zallocv(), bli_zaxpyv(), bli_zcopyv(), bli_zcreate_contigmr(), bli_zero_dim1(), bli_zfree(), bli_zfree_contigm(), bli_zscalv(), and bli_ztrsv().
{ dcomplex* a_save = a; int a_rs_save = a_rs; int a_cs_save = a_cs; dcomplex* x_temp; int incx_temp; // Return early if possible. if ( bli_zero_dim1( m ) ) return; // If necessary, allocate, initialize, and use a temporary contiguous // copy of the matrix rather than the original matrix. bli_zcreate_contigmr( uplo, m, m, a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); // Allocate a temporary vector conformal to x. x_temp = bli_zallocv( m ); incx_temp = 1; // Copy x to a temporary vector. bli_zcopyv( BLIS_NO_CONJUGATE, m, x, incx, x_temp, incx_temp ); // Perform the operation, storing the result to x_temp. bli_ztrsv( uplo, trans, diag, m, a, a_rs, a_cs, x_temp, incx_temp ); // Scale y by beta. bli_zscalv( BLIS_NO_CONJUGATE, m, beta, y, incy ); // Axpy the partial result in x_temp into y. bli_zaxpyv( BLIS_NO_CONJUGATE, m, alpha, x_temp, incx_temp, y, incy ); // Free the temporary vector. bli_zfree( x_temp ); // Free the temporary contiguous matrix. bli_zfree_contigm( a_save, a_rs_save, a_cs_save, &a, &a_rs, &a_cs ); }