ViennaCL - The Vienna Computing Library  1.7.1
Free open-source GPU-accelerated linear algebra and solver library.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
self_assign.cpp File Reference

Go to the source code of this file.

Classes

struct  op_assign
 
struct  op_plus_assign
 
struct  op_minus_assign
 

Functions

template<typename NumericT >
NumericT diff (NumericT const &s1, viennacl::scalar< NumericT > const &s2)
 
template<typename NumericT >
NumericT diff (std::vector< NumericT > const &v1, viennacl::vector< NumericT > const &v2)
 
template<typename NumericT >
NumericT diff (std::vector< std::vector< NumericT > > const &A1, viennacl::matrix< NumericT > const &A2)
 
template<typename HostContainerT , typename DeviceContainerT , typename NumericT >
void check (HostContainerT const &host_container, DeviceContainerT const &device_container, std::string current_stage, NumericT epsilon)
 
template<typename OpT , typename NumericT , typename HostMatrixT , typename DeviceMatrixT >
void test_gemm (NumericT epsilon, HostMatrixT &host_A, HostMatrixT &host_B, HostMatrixT &host_C, DeviceMatrixT &device_A, std::string name_A, DeviceMatrixT &device_B, std::string name_B, DeviceMatrixT &device_C, bool copy_from_A, bool trans_first, bool trans_second)
 
template<typename OpT , typename NumericT , typename HostMatrixT , typename DeviceMatrixT >
void test_gemm (NumericT epsilon, HostMatrixT &host_A, HostMatrixT &host_B, HostMatrixT &host_C, DeviceMatrixT &device_A, std::string name_A, DeviceMatrixT &device_B, std::string name_B, DeviceMatrixT &device_C, bool copy_from_A)
 
template<typename NumericT >
int test (NumericT epsilon)
 
int main ()
 

Detailed Description

Tests the correct handling of self-assignments.

Test:
Tests the correct handling of self-assignments.

Definition in file self_assign.cpp.

Function Documentation

template<typename HostContainerT , typename DeviceContainerT , typename NumericT >
void check ( HostContainerT const &  host_container,
DeviceContainerT const &  device_container,
std::string  current_stage,
NumericT  epsilon 
)

Definition at line 114 of file self_assign.cpp.

template<typename NumericT >
NumericT diff ( NumericT const &  s1,
viennacl::scalar< NumericT > const &  s2 
)

Definition at line 59 of file self_assign.cpp.

template<typename NumericT >
NumericT diff ( std::vector< NumericT > const &  v1,
viennacl::vector< NumericT > const &  v2 
)

Definition at line 67 of file self_assign.cpp.

template<typename NumericT >
NumericT diff ( std::vector< std::vector< NumericT > > const &  A1,
viennacl::matrix< NumericT > const &  A2 
)

Definition at line 97 of file self_assign.cpp.

int main ( )

Definition at line 456 of file self_assign.cpp.

template<typename NumericT >
int test ( NumericT  epsilon)

Definition at line 235 of file self_assign.cpp.

template<typename OpT , typename NumericT , typename HostMatrixT , typename DeviceMatrixT >
void test_gemm ( NumericT  epsilon,
HostMatrixT &  host_A,
HostMatrixT &  host_B,
HostMatrixT &  host_C,
DeviceMatrixT &  device_A,
std::string  name_A,
DeviceMatrixT &  device_B,
std::string  name_B,
DeviceMatrixT &  device_C,
bool  copy_from_A,
bool  trans_first,
bool  trans_second 
)

Definition at line 161 of file self_assign.cpp.

template<typename OpT , typename NumericT , typename HostMatrixT , typename DeviceMatrixT >
void test_gemm ( NumericT  epsilon,
HostMatrixT &  host_A,
HostMatrixT &  host_B,
HostMatrixT &  host_C,
DeviceMatrixT &  device_A,
std::string  name_A,
DeviceMatrixT &  device_B,
std::string  name_B,
DeviceMatrixT &  device_C,
bool  copy_from_A 
)

Definition at line 219 of file self_assign.cpp.