22 #include "utilities.h" 31 template<
class Interface>
44 init_vector<pseudo_random>(X_stl,_size);
45 init_vector<pseudo_random>(Y_stl,_size);
46 init_vector<null_function>(resu_stl,_size);
50 Interface::vector_from_stl(X_ref,X_stl);
51 Interface::vector_from_stl(Y_ref,Y_stl);
53 Interface::vector_from_stl(
X,X_stl);
54 Interface::vector_from_stl(
Y,Y_stl);
63 INFOS(
"illegal call to Action_axpy Copy Ctor");
75 Interface::free_vector(X_ref);
76 Interface::free_vector(Y_ref);
78 Interface::free_vector(
X);
79 Interface::free_vector(
Y);
84 static inline std::string
name(
void )
94 Interface::copy_vector(X_ref,
X,_size);
95 Interface::copy_vector(Y_ref,
Y,_size);
105 if (_size>128)
return;
108 Interface::vector_to_stl(
Y,resu_stl);
112 typename Interface::real_type
error=
116 INFOS(
"WRONG CALCULATION...residual=" << error);
124 typename Interface::stl_vector
X_stl;
125 typename Interface::stl_vector
Y_stl;
128 typename Interface::gene_vector
X_ref;
129 typename Interface::gene_vector
Y_ref;
131 typename Interface::gene_vector
X;
132 typename Interface::gene_vector
Y;
134 typename Interface::real_type
_coef;
Interface::gene_vector Y_ref
static void axpy(real coef, const gene_vector &X, gene_vector &Y, int N)
Interface::gene_vector X_ref
static std::string name(void)
Interface::real_type _coef
#define BTL_ASM_COMMENT(X)
Array< double, 1, 3 > e(1./3., 0.5, 2.)
Interface::stl_vector resu_stl
Interface::stl_vector X_stl
Action_axpy(const Action_axpy &)
static real norm_diff(const stl_vector &A, const stl_vector &B)
int EIGEN_BLAS_FUNC() axpy(const int *n, const RealScalar *palpha, const RealScalar *px, const int *incx, RealScalar *py, const int *incy)
Interface::stl_vector Y_stl