CHROMA
multi_syssolver_mdagm_cg_clover_quda_w.h
Go to the documentation of this file.
1 // -*- C++ -*-
2 /*! \file
3  * \brief Solve a MdagM*psi=chi linear system by CG2 using CG
4  */
5 
6 #ifndef __multi_syssolver_mdagm_cg_clover_quda_w_h__
7 #define __multi_syssolver_mdagm_cg_clover_quda_w_h__
8 
9 #include <cfloat>
10 #include <cstdio>
11 #include "chroma_config.h"
12 
13 #ifdef BUILD_QUDA
14 
15 #include "handle.h"
16 #include "syssolver.h"
17 #include "linearop.h"
18 #include "lmdagm.h"
22 
25 #include "io/aniso_io.h"
26 #include <string>
27 
28 #include "util/gauge/reunit.h"
29 
30 #include <quda.h>
31 
32 
33 
34 #ifdef QDP_IS_QDPJIT
36 #endif
37 
38 namespace Chroma
39 {
40 
41  //! CG system solver namespace
42  namespace MdagMMultiSysSolverCGQudaCloverEnv
43  {
44  //! Register the syssolver
45  bool registerAll();
46  }
47 
48  //! Solve a CG2 system. Here, the operator is NOT assumed to be hermitian
49  /*! \ingroup invert
50  */
51  class MdagMMultiSysSolverCGQudaClover : public MdagMMultiSystemSolver<LatticeFermion>
52  {
53  public:
54  typedef LatticeFermion T;
55  typedef LatticeColorMatrix U;
56  typedef multi1d<LatticeColorMatrix> Q;
57  typedef multi1d<LatticeColorMatrix> P;
58 
59  typedef LatticeFermionF TF;
60  typedef LatticeColorMatrixF UF;
61  typedef multi1d<LatticeColorMatrixF> QF;
62  typedef multi1d<LatticeColorMatrixF> PF;
63 
64  typedef LatticeFermionD TD;
65  typedef LatticeColorMatrixD UD;
66  typedef multi1d<LatticeColorMatrixD> QD;
67  typedef multi1d<LatticeColorMatrixD> PD;
68 
69  typedef WordType<T>::Type_t REALT;
70  //! Constructor
71  /*!
72  * \param M_ Linear operator ( Read )
73  * \param invParam inverter parameters ( Read )
74  */
75  MdagMMultiSysSolverCGQudaClover(Handle< LinearOperator<T> > M_,
76  Handle< FermState<T,P,Q> > state_,
77  const MultiSysSolverQUDACloverParams& invParam_) :
78  A(M_), invParam(invParam_), clov(new CloverTermT<T,U>()), invclov(new CloverTermT<T,U>())
79 
80  {
81  QDPIO::cout << "MdagMMultiSysSolverCGQUDAClover: " << std::endl;
82  // FOLLOWING INITIALIZATION in test QUDA program
83 
84  // 1) work out cpu_prec, cuda_prec, cuda_prec_sloppy
85  int s = sizeof( WordType<T>::Type_t );
86  if (s == 4) {
87  cpu_prec = QUDA_SINGLE_PRECISION;
88  }
89  else {
90  cpu_prec = QUDA_DOUBLE_PRECISION;
91  }
92 
93 
94  // Work out GPU precision
95  switch( invParam.cudaPrecision ) {
96  case HALF:
97  gpu_prec = QUDA_HALF_PRECISION;
98  break;
99  case SINGLE:
100  gpu_prec = QUDA_SINGLE_PRECISION;
101  break;
102  case DOUBLE:
103  gpu_prec = QUDA_DOUBLE_PRECISION;
104  break;
105  default:
106  gpu_prec = cpu_prec;
107  break;
108  }
109 
110  // Work out GPU Sloppy precision
111  // Default: No Sloppy
112  switch( invParam.cudaSloppyPrecision ) {
113  case HALF:
114  gpu_half_prec = QUDA_HALF_PRECISION;
115  break;
116  case SINGLE:
117  gpu_half_prec = QUDA_SINGLE_PRECISION;
118  break;
119  case DOUBLE:
120  gpu_half_prec = QUDA_DOUBLE_PRECISION;
121  break;
122  default:
123  gpu_half_prec = gpu_prec;
124  break;
125  }
126 
127  // Work out GPU Sloppy precision
128  // Default: No Sloppy
129  switch( invParam.cudaRefinementPrecision ) {
130  case HALF:
131  gpu_ref_prec = QUDA_HALF_PRECISION;
132  break;
133  case SINGLE:
134  gpu_ref_prec = QUDA_SINGLE_PRECISION;
135  break;
136  case DOUBLE:
137  gpu_ref_prec = QUDA_DOUBLE_PRECISION;
138  break;
139  default:
140  gpu_ref_prec = gpu_prec;
141  break;
142  }
143 
144  // 2) pull 'new; GAUGE and Invert params
145  //
146  QDPIO::cout << " Calling new QUDA Invert Param" << std::endl;
147  q_gauge_param = newQudaGaugeParam();
148  quda_inv_param = newQudaInvertParam();
149 
150  // 3) set lattice size
151  const multi1d<int>& latdims = Layout::subgridLattSize();
152 
153  q_gauge_param.X[0] = latdims[0];
154  q_gauge_param.X[1] = latdims[1];
155  q_gauge_param.X[2] = latdims[2];
156  q_gauge_param.X[3] = latdims[3];
157 
158  // 4) - deferred (anisotropy)
159 
160  // 5) - set QUDA_WILSON_LINKS, QUDA_GAUGE_ORDER
161  q_gauge_param.type = QUDA_WILSON_LINKS;
162 
163 #ifndef BUILD_QUDA_DEVIFACE_GAUGE
164  q_gauge_param.gauge_order = QUDA_QDP_GAUGE_ORDER; // gauge[mu], p
165 #else
166  //QDPIO::cout << "MULTI MDAGM Using QDP-JIT gauge order" << std::endl;
167  q_gauge_param.location = QUDA_CUDA_FIELD_LOCATION;
168  q_gauge_param.gauge_order = QUDA_QDPJIT_GAUGE_ORDER;
169 #endif
170 
171  // 6) - set t_boundary
172  // Convention: BC has to be applied already
173  // This flag just tells QUDA that this is so,
174  // so that QUDA can take care in the reconstruct
175  if( invParam.AntiPeriodicT ) {
176  q_gauge_param.t_boundary = QUDA_ANTI_PERIODIC_T;
177  }
178  else {
179  q_gauge_param.t_boundary = QUDA_PERIODIC_T;
180  }
181 
182  // Set cpu_prec, cuda_prec, reconstruct and sloppy versions
183  q_gauge_param.cpu_prec = cpu_prec;
184  q_gauge_param.cuda_prec = gpu_prec;
185 
186 
187  switch( invParam.cudaReconstruct ) {
188  case RECONS_NONE:
189  q_gauge_param.reconstruct = QUDA_RECONSTRUCT_NO;
190  break;
191  case RECONS_8:
192  q_gauge_param.reconstruct = QUDA_RECONSTRUCT_8;
193  break;
194  case RECONS_12:
195  q_gauge_param.reconstruct = QUDA_RECONSTRUCT_12;
196  break;
197  default:
198  q_gauge_param.reconstruct = QUDA_RECONSTRUCT_12;
199  break;
200  };
201 
202  q_gauge_param.cuda_prec_sloppy = gpu_half_prec;
203  q_gauge_param.cuda_prec_precondition = gpu_half_prec;
204  q_gauge_param.cuda_prec_refinement_sloppy = gpu_ref_prec;
205 
206  switch( invParam.cudaSloppyReconstruct ) {
207  case RECONS_NONE:
208  q_gauge_param.reconstruct_sloppy = QUDA_RECONSTRUCT_NO;
209  break;
210  case RECONS_8:
211  q_gauge_param.reconstruct_sloppy = QUDA_RECONSTRUCT_8;
212  break;
213  case RECONS_12:
214  q_gauge_param.reconstruct_sloppy = QUDA_RECONSTRUCT_12;
215  break;
216  default:
217  q_gauge_param.reconstruct_sloppy = QUDA_RECONSTRUCT_12;
218  break;
219  };
220 
221  // Default
222  q_gauge_param.reconstruct_precondition = q_gauge_param.reconstruct_sloppy;
223 
224  // Mathias's Hardwired version:
225  // q_gauge_param.reconstruct_refinement_sloppy = q_gauge_param.reconstruct_sloppy;
226 
227  // Parameter file based version
228  switch( invParam.cudaRefinementReconstruct ) {
229  case RECONS_NONE:
230  q_gauge_param.reconstruct_refinement_sloppy = QUDA_RECONSTRUCT_NO;
231  break;
232  case RECONS_8:
233  q_gauge_param.reconstruct_refinement_sloppy = QUDA_RECONSTRUCT_8;
234  break;
235  case RECONS_12:
236  q_gauge_param.reconstruct_refinement_sloppy = QUDA_RECONSTRUCT_12;
237  break;
238  default:
239  q_gauge_param.reconstruct_refinement_sloppy = QUDA_RECONSTRUCT_12;
240  break;
241  };
242 
243 
244  // Gauge fixing:
245 
246  // These are the links
247  // They may be smeared and the BC's may be applied
248  Q links_single(Nd);
249 
250  // Now downcast to single prec fields.
251  for(int mu=0; mu < Nd; mu++) {
252  links_single[mu] = (state_->getLinks())[mu];
253  }
254 
255  // GaugeFix
256  if( invParam.axialGaugeP ) {
257  QDPIO::cout << "Fixing Temporal Gauge" << std::endl;
258  temporalGauge(links_single, GFixMat, Nd-1);
259  for(int mu=0; mu < Nd; mu++){
260  links_single[mu] = GFixMat*(state_->getLinks())[mu]*adj(shift(GFixMat, FORWARD, mu));
261  }
262  q_gauge_param.gauge_fix = QUDA_GAUGE_FIXED_YES;
263  }
264  else {
265  // No GaugeFix
266  q_gauge_param.gauge_fix = QUDA_GAUGE_FIXED_NO; // No Gfix yet
267  }
268 
269  // deferred 4) Gauge Anisotropy
270  const AnisoParam_t& aniso = invParam.CloverParams.anisoParam;
271  if( aniso.anisoP ) { // Anisotropic case
272  Real gamma_f = aniso.xi_0 / aniso.nu;
273  q_gauge_param.anisotropy = toDouble(gamma_f);
274  }
275  else {
276  q_gauge_param.anisotropy = 1.0;
277  }
278 
279  // MAKE FSTATE BEFORE RESCALING links_single
280  // Because the clover term expects the unrescaled links...
281  Handle<FermState<T,Q,Q> > fstate( new PeriodicFermState<T,Q,Q>(links_single));
282 
283  if( aniso.anisoP ) { // Anisotropic case
284  multi1d<Real> cf=makeFermCoeffs(aniso);
285  for(int mu=0; mu < Nd; mu++) {
286  links_single[mu] *= cf[mu];
287  }
288  }
289 
290  // Now onto the inv param:
291  // Dslash type
292  quda_inv_param.dslash_type = QUDA_CLOVER_WILSON_DSLASH;
293  solver_string = "MULTI_CG";
294  quda_inv_param.inv_type = QUDA_CG_INVERTER;
295  quda_inv_param.use_alternative_reliable = 1;
296  // Mass
297 
298  // Fiendish idea from Ron. Set the kappa=1/2 and use
299  // unmodified clover term, and ask for Kappa normalization
300  // This should give us A - (1/2)D as the unpreconditioned operator
301  // and probabl 1 - {1/4} A^{-1} D A^{-1} D as the preconditioned
302  // op. Apart from the A_oo stuff on the antisymmetric we have
303  // nothing to do...
304  if( invParam.asymmetricP ) {
305  quda_inv_param.mass_normalization = QUDA_KAPPA_NORMALIZATION;
306  quda_inv_param.kappa = 0.5;
307  }
308  else {
309  quda_inv_param.mass_normalization = QUDA_KAPPA_NORMALIZATION;
310  quda_inv_param.kappa = 0.5;
311  }
312 
313  // FIXME: If we ever use QUDA to compute our clover term we need to fix this
314  // and QUDA will have to deal with anisotropy. Right now this is a hack to make
315  // the check_param pass. We pass in our clover term so this outghtnt matter
316  quda_inv_param.clover_coeff = 1.0; // dummy vaue
317 
318  quda_inv_param.tol = toDouble(invParam.RsdTarget[0]);
319  quda_inv_param.maxiter = invParam.MaxIter;
320  quda_inv_param.reliable_delta = toDouble(invParam.Delta);
321  quda_inv_param.pipeline = invParam.Pipeline;
322 
323  // Solution type
324  quda_inv_param.solution_type = QUDA_MATPCDAG_MATPC_SOLUTION;
325 
326  // Solve type
327  switch( invParam.solverType ) {
328  case CG:
329  quda_inv_param.solve_type = QUDA_NORMOP_PC_SOLVE;
330  break;
331  default:
332  QDPIO::cerr << "Only CG Is currently implemented for multi-shift" << std::endl;
333  QDP_abort(1);
334 
335  break;
336  }
337 
338  // Only suppfkort Asymmetric linop
339  if ( invParam.asymmetricP ) {
340  QDPIO::cout << "Working with asymmetric solution" << std::endl;
341  quda_inv_param.matpc_type = QUDA_MATPC_ODD_ODD_ASYMMETRIC;
342  }
343  else {
344  QDPIO::cout << "Working with symmetric solution" << std::endl;
345  quda_inv_param.matpc_type = QUDA_MATPC_ODD_ODD;
346  }
347 
348  quda_inv_param.dagger = QUDA_DAG_NO;
349 
350  quda_inv_param.cpu_prec = cpu_prec;
351  quda_inv_param.cuda_prec = gpu_prec;
352  quda_inv_param.cuda_prec_sloppy = gpu_half_prec;
353  quda_inv_param.cuda_prec_precondition = gpu_half_prec;
354  quda_inv_param.cuda_prec_refinement_sloppy = gpu_ref_prec;
355  quda_inv_param.preserve_source = QUDA_PRESERVE_SOURCE_NO;
356  quda_inv_param.gamma_basis = QUDA_DEGRAND_ROSSI_GAMMA_BASIS;
357 
358 #ifndef BUILD_QUDA_DEVIFACE_SPINOR
359  quda_inv_param.dirac_order = QUDA_DIRAC_ORDER;
360 #else
361  //QDPIO::cout << "MULTI MDAGM Using QDP-JIT spinor order" << std::endl;
362  quda_inv_param.dirac_order = QUDA_QDPJIT_DIRAC_ORDER;
363  quda_inv_param.input_location = QUDA_CUDA_FIELD_LOCATION;
364  quda_inv_param.output_location = QUDA_CUDA_FIELD_LOCATION;
365 #endif
366 
367 
368  // Autotuning
369  if( invParam.tuneDslashP ) {
370  QDPIO::cout << "Enabling Dslash Autotuning" << std::endl;
371 
372  quda_inv_param.tune = QUDA_TUNE_YES;
373  }
374  else {
375  QDPIO::cout << "Disabling Dslash Autotuning" << std::endl;
376 
377  quda_inv_param.tune = QUDA_TUNE_NO;
378  }
379 
380 
381  // PADDING
382 
383  // Setup padding
384  multi1d<int> face_size(4);
385  face_size[0] = latdims[1]*latdims[2]*latdims[3]/2;
386  face_size[1] = latdims[0]*latdims[2]*latdims[3]/2;
387  face_size[2] = latdims[0]*latdims[1]*latdims[3]/2;
388  face_size[3] = latdims[0]*latdims[1]*latdims[2]/2;
389 
390  int max_face = face_size[0];
391  for(int i=1; i <=3; i++) {
392  if ( face_size[i] > max_face ) {
393  max_face = face_size[i];
394  }
395  }
396 
397 
398  q_gauge_param.ga_pad = max_face;
399  quda_inv_param.sp_pad = 0;
400  quda_inv_param.cl_pad = 0;
401 
402 
403  // Setting GCR Preconditioner to defaults, as we don't use it..
404  // This is kinda yucky.
405 
406  QDPIO::cout << "Setting Precondition stuff to defaults for not using" << std::endl;
407  quda_inv_param.inv_type_precondition= QUDA_INVALID_INVERTER;
408  quda_inv_param.tol_precondition = 1.0e-1;
409  quda_inv_param.maxiter_precondition = 1000;
410  quda_inv_param.verbosity_precondition = QUDA_SILENT;
411  quda_inv_param.gcrNkrylov = 1;
412 
413  // Clover precision and order
414  quda_inv_param.clover_cpu_prec = cpu_prec;
415  quda_inv_param.clover_cuda_prec = gpu_prec;
416  quda_inv_param.clover_cuda_prec_sloppy = gpu_half_prec;
417  quda_inv_param.clover_cuda_prec_precondition = gpu_half_prec;
418  quda_inv_param.clover_cuda_prec_refinement_sloppy = gpu_ref_prec;
419 
420 #ifndef BUILD_QUDA_DEVIFACE_CLOVER
421  quda_inv_param.clover_order = QUDA_PACKED_CLOVER_ORDER;
422 #else
423  QDPIO::cout << "MULTI MDAGM clover CUDA location\n";
424  quda_inv_param.clover_location = QUDA_CUDA_FIELD_LOCATION;
425  quda_inv_param.clover_order = QUDA_QDPJIT_CLOVER_ORDER;
426 #endif
427 
428 
429  if( invParam.verboseP ) {
430  quda_inv_param.verbosity = QUDA_VERBOSE;
431  }
432  else {
433  quda_inv_param.verbosity = QUDA_SUMMARIZE;
434  }
435 
436  // Set up the links
437  void* gauge[4];
438 
439 #ifndef BUILD_QUDA_DEVIFACE_GAUGE
440  for(int mu=0; mu < Nd; mu++) {
441  gauge[mu] = (void *)&(links_single[mu].elem(all.start()).elem().elem(0,0).real());
442  }
443 #else
444  GetMemoryPtrGauge(gauge,links_single);
445  //gauge[mu] = GetMemoryPtr( links_single[mu].getId() );
446 #endif
447 
448 
449  loadGaugeQuda((void *)gauge, &q_gauge_param);
450 
451  // Setup the clover term...
452  QDPIO::cout << "Creating CloverTerm" << std::endl;
453  clov->create(fstate, invParam_.CloverParams);
454  invclov->create(fstate, invParam_.CloverParams);
455 
456  QDPIO::cout << "Inverting CloverTerm" << std::endl;
457  invclov->choles(0);
458  invclov->choles(1);
459 
460 
461 #ifndef BUILD_QUDA_DEVIFACE_CLOVER
462  multi1d<QUDAPackedClovSite<REALT> > packed_clov;
463 
464  packed_clov.resize(all.siteTable().size());
465 
466  clov->packForQUDA(packed_clov, 0);
467  clov->packForQUDA(packed_clov, 1);
468 
469  // Always need inverse
470  multi1d<QUDAPackedClovSite<REALT> > packed_invclov(all.siteTable().size());
471  invclov->packForQUDA(packed_invclov, 0);
472  invclov->packForQUDA(packed_invclov, 1);
473 
474  loadCloverQuda(&(packed_clov[0]), &(packed_invclov[0]),&quda_inv_param);
475 #else
476 
477  quda_inv_param.clover_location = QUDA_CUDA_FIELD_LOCATION;
478  quda_inv_param.clover_order = QUDA_QDPJIT_CLOVER_ORDER;
479 
480  void *clover[2];
481  void *cloverInv[2];
482 
483  GetMemoryPtrClover(clov->getOffId(),clov->getDiaId(),invclov->getOffId(),invclov->getDiaId());
484 
485 
486  loadCloverQuda( (void*)(clover) , (void*)(cloverInv) ,&quda_inv_param);
487 #endif
488 
489  }
490 
491  //! Destructor is automatic
492  ~MdagMMultiSysSolverCGQudaClover() {
493  QDPIO::cout << "Destructing" << std::endl;
494  freeGaugeQuda();
495  freeCloverQuda();
496  }
497 
498  //! Return the subset on which the operator acts
499  const Subset& subset() const {return A->subset();}
500 
501  //! Solver the linear system
502  /*!
503  * \param psi solution ( Modify )
504  * \param chi source ( Read )
505  * \return syssolver results
506  */
507  SystemSolverResults_t operator() (multi1d<T>& psi, const multi1d<Real>& shifts, const T& chi) const
508  {
509  START_CODE();
510  StopWatch swatch;
511  swatch.reset();
512  swatch.start();
513  SystemSolverResults_t res;
514  res.n_count = 0;
515 
516  if( invParam.RsdTarget.size() > 1 ) {
517  if( invParam.RsdTarget.size() != shifts.size()) {
518  QDPIO::cerr << "There are: " << invParam.RsdTarget.size() << " values for RsdTarget but " << shifts.size() << " shifts" << std::endl;
519  QDPIO::cerr << "This doesnt match. Aborting" << std::endl;
520  }
521  }
522 
523  if ( invParam.axialGaugeP ) {
524  T g_chi;
525  multi1d<T> g_psi(psi.size());
526 
527  // Gauge Fix source and initial guess
528  QDPIO::cout << "Gauge Fixing source and initial guess" << std::endl;
529  g_chi[ rb[1] ] = GFixMat * chi;
530  for(int s=0; s < psi.size(); s++) {
531  g_psi[s][ rb[1] ] = zero; // All initial guesses are zero
532  }
533 
534  QDPIO::cout << "Solving" << std::endl;
535  res = qudaInvertMulti(
536  g_chi,
537  g_psi,
538  shifts);
539  QDPIO::cout << "Untransforming solution." << std::endl;
540  for(int s=0; s< psi.size(); s++) {
541  psi[s][ rb[1]] = adj(GFixMat)*g_psi[s];
542  }
543 
544  }
545  else {
546  res = qudaInvertMulti(chi,
547  psi,
548  shifts);
549  }
550 
551  swatch.stop();
552  double time = swatch.getTimeInSeconds();
553 
554  bool abortFound = false;
555  if (invParam.checkShiftsP ) {
556  Double chinorm=norm2(chi, A->subset());
557  multi1d<Double> r_rel(shifts.size());
558 
559 #ifdef QUDA_DEBUG
560  for(int i=0; i < shifts.size(); i++) {
561  char normpsi_subset[256];
562  char normpsi_full[256];
563  std::sprintf( normpsi_subset, "%.*e", DECIMAL_DIG, toDouble(norm2(psi[i],A->subset())) );
564  std::sprintf( normpsi_full, "%.*e", DECIMAL_DIG, toDouble(norm2(psi[i])) );
565  QDPIO::cout << "psi[ " << i << " ] : norm( A->subset() ) = " << normpsi_subset << " norm(total) = " << normpsi_full << std::endl;
566  }
567 #endif
568  for(int i=0; i < shifts.size(); i++) {
569  T tmp1,tmp2;
570  (*A)(tmp1, psi[i], PLUS);
571  (*A)(tmp2, tmp1, MINUS); // tmp2 = A^\dagger A psi
572  tmp2[ A->subset() ] += shifts[i]* psi[i]; // tmp2 = ( A^\dagger A + shift_i ) psi
573  T r;
574  r[ A->subset() ] = chi - tmp2;
575  r_rel[i] = sqrt(norm2(r, A->subset())/chinorm );
576 #if 1
577  QDPIO::cout << "r[" <<i <<"] = " << r_rel[i] << std::endl;
578 #endif
579  if ( toBool( r_rel[i] > invParam.RsdTarget[i]*invParam.RsdToleranceFactor ) ) {
580  QDPIO::cout << "Shift " << i << " has rel. residuum " << r_rel[i] << " exceeding target "
581  << invParam.RsdTarget[i] << " . Aborting! " << std::endl;
582  abortFound = true;
583  }
584  }
585  }
586  QDPIO::cout << "MULTI_CG_QUDA_CLOVER_SOLVER: " << res.n_count << " iterations. Rsd = " << res.resid << std::endl;
587  QDPIO::cout << "MULTI_CG_QUDA_CLOVER_SOLVER: "<<time<< " sec" << std::endl;
588  if( abortFound ) QDP_abort(1);
589 
590 
591  END_CODE();
592 
593  return res;
594  }
595 
596 
597  private:
598  // Hide default constructor
599  MdagMMultiSysSolverCGQudaClover() {}
600  U GFixMat;
601  QudaPrecision_s cpu_prec;
602  QudaPrecision_s gpu_prec;
603  QudaPrecision_s gpu_half_prec;
604  QudaPrecision_s gpu_ref_prec;
605 
606  Handle< LinearOperator<T> > A;
607  const MultiSysSolverQUDACloverParams invParam;
608  QudaGaugeParam q_gauge_param;
609  mutable QudaInvertParam quda_inv_param;
610 
611  Handle< CloverTermT<T, U> > clov;
612  Handle< CloverTermT<T, U> > invclov;
613 
614  SystemSolverResults_t qudaInvertMulti(const T& chi_s,
615  multi1d<T>& psi_s,
616  multi1d<Real> shifts
617  )const ;
618 
619  std::string solver_string;
620 
621  };
622 
623 
624 } // End namespace
625 
626 #endif
627 #endif
628 
Anisotropy parameters.
Include possibly optimized Clover terms.
int mu
Definition: cool.cc:24
void temporalGauge(multi1d< LatticeColorMatrix > &ug, LatticeColorMatrix &g, int decay_dir)
Temporal gauge fixing.
Class for counted reference semantics.
Linear Operators.
M^dag*M composition of a linear operator.
Nd
Definition: meslate.cc:74
Double tmp2
Definition: mesq.cc:30
multi1d< LatticeColorMatrix > P
multi1d< Hadron2PtContraction_t > operator()(const multi1d< LatticeColorMatrix > &u)
Asqtad Staggered-Dirac operator.
Definition: klein_gord.cc:10
LinOpSysSolverMGProtoClover::Q Q
LinOpSysSolverMGProtoClover::T T
int i
Definition: pbg5p_w.cc:55
@ MINUS
Definition: chromabase.h:45
@ PLUS
Definition: chromabase.h:45
multi1d< LatticeFermion > chi(Ncb)
LatticeFermion psi
Definition: mespbg5p_w.cc:35
QDPCloverTermT< T, U > CloverTermT
Definition: clover_term_w.h:97
START_CODE()
A(A, psi, r, Ncb, PLUS)
Double zero
Definition: invbicg.cc:106
multi1d< Real > makeFermCoeffs(const AnisoParam_t &aniso)
Make fermion coefficients.
Definition: aniso_io.cc:63
multi1d< LatticeFermion > s(Ncb)
@ RECONS_12
Definition: enum_quda_io.h:80
@ RECONS_NONE
Definition: enum_quda_io.h:78
@ RECONS_8
Definition: enum_quda_io.h:79
FloatingPoint< double > Double
Definition: gtest.h:7351
::std::string string
Definition: gtest.h:1979
Periodic ferm state and a creator.
#define FORWARD
Definition: primitives.h:82
Reunitarize in place a color matrix to SU(N)
Simple fermionic BC.
Linear system solvers.
multi1d< LatticeColorMatrix > U
LatticeFermion T
Definition: t_clover.cc:11
multi1d< LatticeColorMatrix > Q
Definition: t_clover.cc:12
multi1d< LatticeColorMatrixF > QF
Definition: t_quda_tprec.cc:19
LatticeColorMatrixF UF
Definition: t_quda_tprec.cc:18
multi1d< LatticeColorMatrixF > PF
Definition: t_quda_tprec.cc:20
LatticeFermionD TD
Definition: t_quda_tprec.cc:22
LatticeColorMatrixD UD
Definition: t_quda_tprec.cc:23
LatticeFermionF TF
Definition: t_quda_tprec.cc:17
multi1d< LatticeColorMatrixD > PD
Definition: t_quda_tprec.cc:25
multi1d< LatticeColorMatrixD > QD
Definition: t_quda_tprec.cc:24
Axial gauge fixing.