ViennaCL - The Vienna Computing Library  1.7.0
Free open-source GPU-accelerated linear algebra and solver library.
matrix_operations.hpp File Reference

Implementations of dense matrix related operations, including matrix-vector products, using OpenCL. More...

Go to the source code of this file.

Namespaces

 viennacl
 Main namespace in ViennaCL. Holds all the basic types such as vector, matrix, etc. and defines operations upon them.
 
 viennacl::linalg
 Provides all linear algebra operations which are not covered by operator overloads.
 
 viennacl::linalg::opencl
 Holds all routines providing OpenCL linear algebra operations.
 
 viennacl::linalg::opencl::detail
 Helper functions for OpenCL-accelerated linear algebra operations.
 

Functions

template<typename NumericT >
viennacl::ocl::kernelviennacl::linalg::opencl::detail::legacy_kernel_for_matrix (matrix_base< NumericT > const &M, std::string const &kernel_name)
 
template<typename DestNumericT , typename SrcNumericT >
void viennacl::linalg::opencl::convert (matrix_base< DestNumericT > &dest, matrix_base< SrcNumericT > const &src)
 
template<typename NumericT , typename ScalarT1 >
void viennacl::linalg::opencl::am (matrix_base< NumericT > &A, matrix_base< NumericT > const &B, ScalarT1 const &alpha, vcl_size_t, bool reciprocal_alpha, bool flip_sign_alpha)
 
template<typename NumericT , typename ScalarT1 , typename ScalarT2 >
void viennacl::linalg::opencl::ambm (matrix_base< NumericT > &A, matrix_base< NumericT > const &B, ScalarT1 const &alpha, vcl_size_t, bool reciprocal_alpha, bool flip_sign_alpha, matrix_base< NumericT > const &C, ScalarT2 const &beta, vcl_size_t, bool reciprocal_beta, bool flip_sign_beta)
 
template<typename NumericT , typename ScalarT1 , typename ScalarT2 >
void viennacl::linalg::opencl::ambm_m (matrix_base< NumericT > &A, matrix_base< NumericT > const &B, ScalarT1 const &alpha, vcl_size_t, bool reciprocal_alpha, bool flip_sign_alpha, matrix_base< NumericT > const &C, ScalarT2 const &beta, vcl_size_t, bool reciprocal_beta, bool flip_sign_beta)
 
template<typename NumericT , typename SizeT , typename DistanceT >
void viennacl::linalg::opencl::trans (const matrix_expression< const matrix_base< NumericT, SizeT, DistanceT >, const matrix_base< NumericT, SizeT, DistanceT >, op_trans > &proxy, matrix_base< NumericT > &temp_trans)
 
template<typename NumericT >
void viennacl::linalg::opencl::matrix_assign (matrix_base< NumericT > &A, NumericT s, bool up_to_internal_size=false)
 
template<typename NumericT >
void viennacl::linalg::opencl::matrix_diagonal_assign (matrix_base< NumericT > &A, NumericT s)
 
template<typename NumericT >
void viennacl::linalg::opencl::matrix_diag_from_vector (const vector_base< NumericT > &vec, int k, matrix_base< NumericT > &A)
 
template<typename NumericT >
void viennacl::linalg::opencl::matrix_diag_to_vector (const matrix_base< NumericT > &A, int k, vector_base< NumericT > &vec)
 
template<typename NumericT >
void viennacl::linalg::opencl::matrix_row (const matrix_base< NumericT > &A, unsigned int i, vector_base< NumericT > &vec)
 
template<typename NumericT >
void viennacl::linalg::opencl::matrix_column (const matrix_base< NumericT > &A, unsigned int j, vector_base< NumericT > &vec)
 
template<typename NumericT , typename OpT >
void viennacl::linalg::opencl::element_op (matrix_base< NumericT > &A, matrix_expression< const matrix_base< NumericT >, const matrix_base< NumericT >, op_element_binary< OpT > > const &proxy)
 Implementation of binary element-wise operations A = OP(B,C) More...
 
template<typename NumericT , typename OpT >
void viennacl::linalg::opencl::element_op (matrix_base< NumericT > &A, matrix_expression< const matrix_base< NumericT >, const matrix_base< NumericT >, op_element_unary< OpT > > const &proxy)
 Implementation of unary element-wise operations A = OP(B) More...
 
template<typename NumericT >
void viennacl::linalg::opencl::prod_impl (const matrix_base< NumericT > &A, bool trans_A, const vector_base< NumericT > &vec, vector_base< NumericT > &result)
 Carries out matrix-vector multiplication. More...
 
template<typename NumericT , typename ScalarType >
void viennacl::linalg::opencl::prod_impl (matrix_base< NumericT > const &A, bool A_trans, matrix_base< NumericT > const &B, bool B_trans, matrix_base< NumericT > &C, ScalarType alpha, ScalarType beta)
 Carries out matrix-matrix multiplication. More...
 
template<typename NumericT , typename ScalarT1 >
void viennacl::linalg::opencl::scaled_rank_1_update (matrix_base< NumericT > &A, ScalarT1 const &alpha, vcl_size_t len_alpha, bool reciprocal_alpha, bool flip_sign_alpha, const vector_base< NumericT > &vec1, const vector_base< NumericT > &vec2)
 The implementation of the operation mat += alpha * vec1 * vec2^T, i.e. a scaled rank 1 update. More...
 
template<typename SCALARTYPE , typename VectorType >
void viennacl::linalg::opencl::bidiag_pack_svd (viennacl::matrix< SCALARTYPE > &A, VectorType &dh, VectorType &sh)
 
template<typename NumericT >
void viennacl::linalg::opencl::bidiag_pack (matrix_base< NumericT > &A, viennacl::vector< NumericT > &dh, viennacl::vector< NumericT > &sh)
 
template<typename NumericT >
void viennacl::linalg::opencl::house_update_A_left (matrix_base< NumericT > &A, vector_base< NumericT > &D, vcl_size_t start)
 
template<typename NumericT >
void viennacl::linalg::opencl::house_update_A_right (matrix_base< NumericT > &A, vector_base< NumericT > &D)
 
template<typename NumericT >
void viennacl::linalg::opencl::house_update_QL (matrix_base< NumericT > &Q, vector_base< NumericT > &D, vcl_size_t A_size1)
 
template<typename NumericT >
void viennacl::linalg::opencl::givens_next (matrix_base< NumericT > &matrix, vector_base< NumericT > &tmp1, vector_base< NumericT > &tmp2, int l, int m)
 
template<typename NumericT >
void viennacl::linalg::opencl::copy_vec (matrix_base< NumericT > &A, vector_base< NumericT > &V, vcl_size_t row_start, vcl_size_t col_start, bool copy_col)
 

Variables

const std::string viennacl::linalg::opencl::SVD_BIDIAG_PACK_KERNEL = "bidiag_pack"
 
const std::string viennacl::linalg::opencl::SVD_HOUSEHOLDER_UPDATE_A_LEFT_KERNEL = "house_update_A_left"
 
const std::string viennacl::linalg::opencl::SVD_HOUSEHOLDER_UPDATE_A_RIGHT_KERNEL = "house_update_A_right"
 
const std::string viennacl::linalg::opencl::SVD_HOUSEHOLDER_UPDATE_QL_KERNEL = "house_update_QL"
 
const std::string viennacl::linalg::opencl::SVD_GIVENS_NEXT_KERNEL = "givens_next"
 
const std::string viennacl::linalg::opencl::SVD_COPY_COL_KERNEL = "copy_col"
 
const std::string viennacl::linalg::opencl::SVD_COPY_ROW_KERNEL = "copy_row"
 

Detailed Description

Implementations of dense matrix related operations, including matrix-vector products, using OpenCL.

Definition in file matrix_operations.hpp.