diff --git a/Grid/algorithms/iterative/ConjugateGradient.h b/Grid/algorithms/iterative/ConjugateGradient.h index 379a3706..a67c8981 100644 --- a/Grid/algorithms/iterative/ConjugateGradient.h +++ b/Grid/algorithms/iterative/ConjugateGradient.h @@ -132,9 +132,9 @@ public: auto psi_v = psi.View(); auto p_v = p.View(); auto r_v = r.View(); - accelerator_loop(ss,p_v,{ - vstream(psi_v[ss], a * p_v[ss] + psi_v[ss]); - vstream(p_v [ss], b * p_v[ss] + r_v[ss]); + accelerator_for(ss,p_v.size(), Field::vector_object::Nsimd(),{ + coalescedWrite(psi_v[ss], a * p_v(ss) + psi_v(ss)); + coalescedWrite(p_v[ss] , b * p_v(ss) + r_v (ss)); }); LinearCombTimer.Stop(); LinalgTimer.Stop();