1#ifndef QDP_SCALARSITE_GENERIC_BLAS_WRAPPER_H
2#define QDP_SCALARSITE_GENERIC_BLAS_WRAPPER_H
34 InScale = &InScale[index];
38 vaxpy3(Out, scalep, InScale, Add, n_4vec);
49 const OLattice< TVec >&
x;
60 const OLattice< TVec >& x = a->
x;
61 OLattice< TVec >& d = a->
d;
63 const int* tab = a->
tab;
67 for(
int j=lo; j < hi; j++) {
69 REAL* xptr = (
REAL *)&(x.elem(i).elem(0).elem(0).real());
70 REAL* yptr = &(d.elem(i).elem(0).elem(0).
real());
71 vaxpy3(yptr, scalep, xptr, yptr, 1);
75 for(
int j=lo; j < hi; j++) {
77 REAL* xptr = (
REAL *)&(x.elem(i).elem(0).elem(0).real());
78 REAL* yptr = &(d.elem(i).elem(0).elem(0).
real());
79 vaxpy3(yptr, scalep, yptr, xptr, 1);
89 const OLattice< TVec >& y_,
92 const int* tab_) :
x(x_),
y(y_),
d(d_),
scalep(scalep_),
tab(tab_) {}
94 const OLattice< TVec >&
x;
95 const OLattice< TVec >&
y;
105 const OLattice< TVec >& x = a->
x;
106 const OLattice< TVec >& y = a->
y;
107 OLattice< TVec >& d = a->
d;
109 const int* tab = a->
tab;
111 for(
int j=lo; j < hi; j++) {
113 REAL* xptr = (
REAL *)&(x.elem(i).elem(0).elem(0).real());
114 REAL* yptr = (
REAL *)&(y.elem(i).elem(0).elem(0).real());
115 REAL* zptr = &(d.elem(i).elem(0).elem(0).
real());
116 vaxpy3(zptr, scalep, xptr, yptr, 1);
143 int n_3vec = hi - lo;
145 InScale = &InScale[index];
149 vaxmy3(Out, scalep, InScale, Sub, n_3vec);
156 OLattice< TVec >& d_,
158 const int* tab_) :
x(x_),
d(d_),
scalep(scalep_),
tab(tab_) {}
160 const OLattice< TVec >&
x;
170 const OLattice< TVec >& x = a->
x;
171 OLattice< TVec >& d = a->
d;
173 const int* tab = a->
tab;
175 for(
int j=lo; j < hi; j++) {
177 REAL* xptr = (
REAL *)&(x.elem(i).elem(0).elem(0).real());
178 REAL* yptr = &(d.elem(i).elem(0).elem(0).
real());
179 vaxmy3(yptr, scalep, yptr, xptr, 1);
186 const OLattice< TVec >& x_,
187 const OLattice< TVec >& y_,
188 OLattice< TVec >& d_,
190 const int* tab_) :
x(x_),
y(y_),
d(d_),
scalep(scalep_),
tab(tab_) {}
192 const OLattice< TVec >&
x;
193 const OLattice< TVec >&
y;
203 const OLattice< TVec >& x = a->
x;
204 const OLattice< TVec >& y = a->
y;
205 OLattice< TVec >& d = a->
d;
207 const int* tab = a->
tab;
209 for(
int j=lo; j < hi; j++) {
211 REAL* xptr = (
REAL *)&(x.elem(i).elem(0).elem(0).real());
212 REAL* yptr = (
REAL *)&(y.elem(i).elem(0).elem(0).real());
213 REAL* zptr = &(d.elem(i).elem(0).elem(0).
real());
214 vaxmy3(zptr, scalep, xptr, yptr, 1);
239 int n_3vec = hi - lo;
243 vscal(Out, scalep, In, n_3vec);
250 const OLattice< TVec >& x_,
251 OLattice< TVec >& d_,
255 const OLattice< TVec >&
x;
265 const OLattice< TVec >& x = a->
x;
266 OLattice< TVec >& d = a->
d;
268 const int* tab = a->
tab;
270 for(
int j=lo; j < hi; j++) {
272 REAL *xptr = (
REAL *) &(x.elem(i).elem(0).elem(0).real());
273 REAL *zptr = &(d.elem(i).elem(0).elem(0).
real());
274 vscal(zptr, scalep, xptr, 1);
304 int n_3vec = hi - lo;
309 vaxpby3(Out, ap, xp, bp, yp, n_3vec);
315 const OLattice< TVec >& y_,
316 OLattice< TVec >& d_,
319 const int* tab_):
x(x_),
y(y_),
d(d_),
aptr(aptr_),
bptr(bptr_),
tab(tab_) {}
320 const OLattice< TVec >&
x;
321 const OLattice< TVec >&
y;
332 const OLattice< TVec >& x = a->
x;
333 const OLattice< TVec >& y = a->
y;
334 OLattice< TVec >& d = a->
d;
337 const int* tab = a->
tab;
339 for(
int j=lo; j < hi; j++) {
341 REAL *xptr = (
REAL *) &(x.elem(i).elem(0).elem(0).real());
342 REAL *yptr = (
REAL *) &(y.elem(i).elem(0).elem(0).real());
343 REAL* zptr = &(d.elem(i).elem(0).elem(0).
real());
346 vaxpby3(zptr, aptr, xptr, bptr, yptr, 1);
377 int n_3vec = hi - lo;
382 vaxmby3(Out, ap, xp, bp, yp, n_3vec);
388 const OLattice< TVec >& y_,
389 OLattice< TVec >& d_,
392 const int* tab_):
x(x_),
y(y_),
d(d_),
aptr(aptr_),
bptr(bptr_),
tab(tab_) {}
394 const OLattice< TVec >&
x;
395 const OLattice< TVec >&
y;
406 const OLattice< TVec >& x = a->
x;
407 const OLattice< TVec >& y = a->
y;
408 OLattice< TVec >& d = a->
d;
411 const int* tab = a->
tab;
413 for(
int j=lo; j < hi; j++) {
415 REAL *xptr = (
REAL *) &(x.elem(i).elem(0).elem(0).real());
416 REAL *yptr = (
REAL *) &(y.elem(i).elem(0).elem(0).real());
417 REAL* zptr = &(d.elem(i).elem(0).elem(0).
real());
420 vaxmby3(zptr, aptr, xptr, bptr, yptr,1);
MakeReturn< UnaryNode< FnReal, typenameCreateLeaf< QDPExpr< T1, C1 > >::Leaf_t >, typenameUnaryReturn< C1, FnReal >::Type_t >::Expression_t real(const QDPExpr< T1, C1 > &l)
void ordered_vaxmy3_evaluate_function(int lo, int hi, int myId, ordered_vaxmy3_user_arg *a)
void ordered_vaxmby3_evaluate_function(int lo, int hi, int myId, ordered_vaxmby3_user_arg *a)
void unordered_vaxmy3_y_evaluate_function(int lo, int hi, int myId, unordered_vaxmy3_y_user_arg *a)
void unordered_vscal_evaluate_function(int lo, int hi, int myId, unordered_vscal_user_arg *a)
void unordered_vaxpy3_z_evaluate_function(int lo, int hi, int myId, unordered_vaxpy3_z_user_arg *a)
void unordered_vaxpby3_evaluate_function(int lo, int hi, int myId, unordered_vaxpby3_user_arg *a)
void ordered_vaxpy3_evaluate_function(int lo, int hi, int myId, ordered_vaxpy3_user_arg *a)
void ordered_vaxpby3_evaluate_function(int lo, int hi, int myId, ordered_vaxpby3_user_arg *a)
void unordered_vaxmy3_z_evaluate_function(int lo, int hi, int myId, unordered_vaxmy3_z_user_arg *a)
void unordered_vaxmby3_evaluate_function(int lo, int hi, int myId, unordered_vaxmby3_user_arg *a)
void ordered_vscal_evaluate_function(int lo, int hi, int myId, ordered_vscal_user_arg *a)
void unordered_vaxpy3_y_evaluate_function(int lo, int hi, int myId, unordered_vaxpy3_y_user_arg *a)
const OLattice< TVec > & y
unordered_vaxmby3_user_arg(const OLattice< TVec > &x_, const OLattice< TVec > &y_, OLattice< TVec > &d_, REAL *aptr_, REAL *bptr_, const int *tab_)
const OLattice< TVec > & x
unordered_vaxmy3_y_user_arg(const OLattice< TVec > &x_, OLattice< TVec > &d_, REAL *scalep_, const int *tab_)
const OLattice< TVec > & x
const OLattice< TVec > & y
const OLattice< TVec > & x
unordered_vaxmy3_z_user_arg(const OLattice< TVec > &x_, const OLattice< TVec > &y_, OLattice< TVec > &d_, REAL *scalep_, const int *tab_)
const OLattice< TVec > & x
const OLattice< TVec > & y
unordered_vaxpby3_user_arg(const OLattice< TVec > &x_, const OLattice< TVec > &y_, OLattice< TVec > &d_, REAL *aptr_, REAL *bptr_, const int *tab_)
const OLattice< TVec > & x
unordered_vaxpy3_y_user_arg(const OLattice< TVec > &x_, OLattice< TVec > &d_, REAL *scalep_, const int *tab_, int xy_order_)
const OLattice< TVec > & x
unordered_vaxpy3_z_user_arg(const OLattice< TVec > &x_, const OLattice< TVec > &y_, OLattice< TVec > &d_, REAL *scalep_, const int *tab_)
const OLattice< TVec > & y
const OLattice< TVec > & x
unordered_vscal_user_arg(const OLattice< TVec > &x_, OLattice< TVec > &d_, REAL *scalep_, const int *tab_)