QUDA  v1.1.0
A library for QCD on GPUs
gauge_field.cpp
Go to the documentation of this file.
1 #include <gauge_field.h>
2 #include <typeinfo>
3 #include <blas_quda.h>
4 
5 namespace quda {
6 
9  location(u.Location()),
10  nColor(u.Ncolor()),
11  nFace(u.Nface()),
12  reconstruct(u.Reconstruct()),
13  order(u.Order()),
14  fixed(u.GaugeFixed()),
15  link_type(u.LinkType()),
16  t_boundary(u.TBoundary()),
17  anisotropy(u.Anisotropy()),
18  tadpole(u.Tadpole()),
19  gauge(NULL),
20  create(QUDA_NULL_FIELD_CREATE),
21  geometry(u.Geometry()),
22  compute_fat_link_max(false),
23  staggeredPhaseType(u.StaggeredPhase()),
24  staggeredPhaseApplied(u.StaggeredPhaseApplied()),
25  i_mu(u.iMu()),
26  site_offset(u.SiteOffset()),
27  site_size(u.SiteSize())
28  { }
29 
32  bytes(0),
33  phase_offset(0),
34  phase_bytes(0),
36  nFace(param.nFace),
37  geometry(param.geometry),
38  reconstruct(param.reconstruct),
39  nInternal(reconstruct != QUDA_RECONSTRUCT_NO ? reconstruct : nColor * nColor * 2),
40  order(param.order),
41  fixed(param.fixed),
42  link_type(param.link_type),
43  t_boundary(param.t_boundary),
45  tadpole(param.tadpole),
46  fat_link_max(link_type == QUDA_ASQTAD_FAT_LINKS ? 0.0 : 1.0),
47  create(param.create),
48  staggeredPhaseType(param.staggeredPhaseType),
49  staggeredPhaseApplied(param.staggeredPhaseApplied),
50  i_mu(param.i_mu),
51  site_offset(param.site_offset),
52  site_size(param.site_size)
53  {
54  if (order == QUDA_NATIVE_GAUGE_ORDER) errorQuda("Invalid gauge order %d", order);
55  if (ghost_precision != precision) ghost_precision = precision; // gauge fields require matching precision
56 
57  if (link_type != QUDA_COARSE_LINKS && nColor != 3)
58  errorQuda("nColor must be 3, not %d for this link type", nColor);
59  if (nDim != 4)
60  errorQuda("Number of dimensions must be 4 not %d", nDim);
61  if (link_type != QUDA_WILSON_LINKS && anisotropy != 1.0)
62  errorQuda("Anisotropy only supported for Wilson links");
64  errorQuda("Temporal gauge fixing only supported for Wilson links");
67  length = 2*stride*nInternal; // two comes from being full lattice
68  } else if (geometry == QUDA_VECTOR_GEOMETRY) {
70  length = 2*nDim*stride*nInternal; // two comes from being full lattice
71  } else if (geometry == QUDA_TENSOR_GEOMETRY) {
73  length = 2*(nDim*(nDim-1)/2)*stride*nInternal; // two comes from being full lattice
74  } else if (geometry == QUDA_COARSE_GEOMETRY) {
76  length = 2*2*nDim*stride*nInternal; //two comes from being full lattice
77  }
78 
80  errorQuda("Cannot request a 12/8 reconstruct type without SU(3) link type");
81  }
82 
84  // Need to adjust the phase alignment as well.
85  int half_phase_bytes
86  = (length / (2 * reconstruct)) * precision; // number of bytes needed to store phases for a single parity
87  int half_gauge_bytes = (length / 2) * precision
88  - half_phase_bytes; // number of bytes needed to store the gauge field for a single parity excluding the phases
89  // Adjust the alignments for the gauge and phase separately
90  half_phase_bytes = ((half_phase_bytes + (512-1))/512)*512;
91  half_gauge_bytes = ((half_gauge_bytes + (512-1))/512)*512;
92 
93  phase_offset = half_gauge_bytes;
94  phase_bytes = half_phase_bytes*2;
95  bytes = (half_gauge_bytes + half_phase_bytes)*2;
96  } else {
98  if (isNative()) bytes = 2*ALIGNMENT_ADJUST(bytes/2);
99  }
100  total_bytes = bytes;
101 
102  setTuningString();
103  }
104 
106 
107  }
108 
111  int aux_string_n = TuneKey::aux_n / 2;
113  snprintf(aux_string, aux_string_n, "vol=%lu,stride=%lu,precision=%d,geometry=%d,Nc=%d,r=%d%d%d%d",
114  volume, stride, precision, geometry, nColor, r[0], r[1], r[2], r[3]) :
115  snprintf(aux_string, aux_string_n, "vol=%lu,stride=%lu,precision=%d,geometry=%d,Nc=%d",
117  if (check < 0 || check >= aux_string_n) errorQuda("Error writing aux string");
118  }
119 
120  void GaugeField::createGhostZone(const int *R, bool no_comms_fill, bool bidir) const
121  {
122  if (typeid(*this) == typeid(cpuGaugeField)) return;
123 
124  // if this is not a bidirectional exchange then we are doing a
125  // scalar exchange, e.g., only the link matrix in the direcion we
126  // are exchanging is exchanged, and none of the orthogonal links
128 
129  // calculate size of ghost zone required
130  ghost_bytes_old = ghost_bytes; // save for subsequent resize checking
131  ghost_bytes = 0;
132  for (int i=0; i<nDim; i++) {
133  ghost_face_bytes[i] = 0;
134  if ( !(comm_dim_partitioned(i) || (no_comms_fill && R[i])) ) ghostFace[i] = 0;
135  else ghostFace[i] = surface[i] * R[i]; // includes the radius (unlike ColorSpinorField)
136 
137  ghost_face_bytes[i] = ghostFace[i] * geometry_comms * nInternal * ghost_precision;
139 
140  ghost_offset[i][0] = (i == 0) ? 0 : ghost_offset[i - 1][1] + ghost_face_bytes_aligned[i - 1];
141  ghost_offset[i][1] = (bidir ? ghost_offset[i][0] + ghost_face_bytes_aligned[i] : ghost_offset[i][0]);
142 
143  ghost_bytes += (bidir ? 2 : 1) * ghost_face_bytes_aligned[i]; // factor of two from direction
144  }
145 
147  } // createGhostZone
148 
150  if (staggeredPhaseApplied) errorQuda("Staggered phases already applied");
151 
152  if (phase != QUDA_STAGGERED_PHASE_INVALID) staggeredPhaseType = phase;
153  applyGaugePhase(*this);
155  if (typeid(*this)==typeid(cudaGaugeField)) {
156  static_cast<cudaGaugeField&>(*this).exchangeGhost();
157  } else {
158  static_cast<cpuGaugeField&>(*this).exchangeGhost();
159  }
160  }
161  staggeredPhaseApplied = true;
162  }
163 
165  if (!staggeredPhaseApplied) errorQuda("No staggered phases to remove");
166  applyGaugePhase(*this);
168  if (typeid(*this)==typeid(cudaGaugeField)) {
169  static_cast<cudaGaugeField&>(*this).exchangeGhost();
170  } else {
171  static_cast<cpuGaugeField&>(*this).exchangeGhost();
172  }
173  }
174  staggeredPhaseApplied = false;
175  }
176 
177  void GaugeField::exchange(void **ghost_link, void **link_sendbuf, QudaDirection dir) const {
178  MsgHandle *mh_send[4];
179  MsgHandle *mh_recv[4];
180  size_t bytes[4];
181 
182  for (int i=0; i<nDimComms; i++) bytes[i] = 2*nFace*surfaceCB[i]*nInternal*precision;
183 
184  // in general (standard ghost exchange) we always do the exchange
185  // even if a dimension isn't partitioned. However, this breaks
186  // GaugeField::injectGhost(), so when transferring backwards we
187  // only exchange if a dimension is partitioned. FIXME: this
188  // should probably be cleaned up.
189  bool no_comms_fill = (dir == QUDA_BACKWARDS) ? false : true;
190 
191  void *send[4];
192  void *receive[4];
194  for (int i=0; i<nDimComms; i++) {
195  if (comm_dim_partitioned(i)) {
196  send[i] = link_sendbuf[i];
197  receive[i] = ghost_link[i];
198  } else {
199  if (no_comms_fill) memcpy(ghost_link[i], link_sendbuf[i], bytes[i]);
200  }
201  }
202  } else { // FIXME for CUDA field copy back to the CPU
203  for (int i=0; i<nDimComms; i++) {
204  if (comm_dim_partitioned(i)) {
205  send[i] = pool_pinned_malloc(bytes[i]);
206  receive[i] = pool_pinned_malloc(bytes[i]);
207  qudaMemcpy(send[i], link_sendbuf[i], bytes[i], cudaMemcpyDeviceToHost);
208  } else {
209  if (no_comms_fill) qudaMemcpy(ghost_link[i], link_sendbuf[i], bytes[i], cudaMemcpyDeviceToDevice);
210  }
211  }
212  }
213 
214  for (int i=0; i<nDimComms; i++) {
215  if (!comm_dim_partitioned(i)) continue;
216  if (dir == QUDA_FORWARDS) {
217  mh_send[i] = comm_declare_send_relative(send[i], i, +1, bytes[i]);
218  mh_recv[i] = comm_declare_receive_relative(receive[i], i, -1, bytes[i]);
219  } else if (dir == QUDA_BACKWARDS) {
220  mh_send[i] = comm_declare_send_relative(send[i], i, -1, bytes[i]);
221  mh_recv[i] = comm_declare_receive_relative(receive[i], i, +1, bytes[i]);
222  } else {
223  errorQuda("Unsuported dir=%d", dir);
224  }
225 
226  }
227 
228  for (int i=0; i<nDimComms; i++) {
229  if (!comm_dim_partitioned(i)) continue;
230  comm_start(mh_send[i]);
231  comm_start(mh_recv[i]);
232  }
233 
234  for (int i=0; i<nDimComms; i++) {
235  if (!comm_dim_partitioned(i)) continue;
236  comm_wait(mh_send[i]);
237  comm_wait(mh_recv[i]);
238  }
239 
241  for (int i=0; i<nDimComms; i++) {
242  if (!comm_dim_partitioned(i)) continue;
243  qudaMemcpy(ghost_link[i], receive[i], bytes[i], cudaMemcpyHostToDevice);
244  pool_pinned_free(send[i]);
245  pool_pinned_free(receive[i]);
246  }
247  }
248 
249  for (int i=0; i<nDimComms; i++) {
250  if (!comm_dim_partitioned(i)) continue;
251  comm_free(mh_send[i]);
252  comm_free(mh_recv[i]);
253  }
254 
255  }
256 
257  void GaugeField::checkField(const LatticeField &l) const {
259  try {
260  const GaugeField &g = dynamic_cast<const GaugeField&>(l);
261  if (g.link_type != link_type) errorQuda("link_type does not match %d %d", link_type, g.link_type);
262  if (g.nColor != nColor) errorQuda("nColor does not match %d %d", nColor, g.nColor);
263  if (g.nFace != nFace) errorQuda("nFace does not match %d %d", nFace, g.nFace);
264  if (g.fixed != fixed) errorQuda("fixed does not match %d %d", fixed, g.fixed);
265  if (g.t_boundary != t_boundary) errorQuda("t_boundary does not match %d %d", t_boundary, g.t_boundary);
266  if (g.anisotropy != anisotropy) errorQuda("anisotropy does not match %e %e", anisotropy, g.anisotropy);
267  if (g.tadpole != tadpole) errorQuda("tadpole does not match %e %e", tadpole, g.tadpole);
268  }
269  catch(std::bad_cast &e) {
270  errorQuda("Failed to cast reference to GaugeField");
271  }
272  }
273 
274  std::ostream& operator<<(std::ostream& output, const GaugeFieldParam& param) {
275  output << static_cast<const LatticeFieldParam &>(param);
276  output << "nColor = " << param.nColor << std::endl;
277  output << "nFace = " << param.nFace << std::endl;
278  output << "reconstruct = " << param.reconstruct << std::endl;
279  int nInternal = (param.reconstruct != QUDA_RECONSTRUCT_NO ?
280  param.reconstruct : param.nColor * param.nColor * 2);
281  output << "nInternal = " << nInternal << std::endl;
282  output << "order = " << param.order << std::endl;
283  output << "fixed = " << param.fixed << std::endl;
284  output << "link_type = " << param.link_type << std::endl;
285  output << "t_boundary = " << param.t_boundary << std::endl;
286  output << "anisotropy = " << param.anisotropy << std::endl;
287  output << "tadpole = " << param.tadpole << std::endl;
288  output << "create = " << param.create << std::endl;
289  output << "geometry = " << param.geometry << std::endl;
290  output << "staggeredPhaseType = " << param.staggeredPhaseType << std::endl;
291  output << "staggeredPhaseApplied = " << param.staggeredPhaseApplied << std::endl;
292 
293  return output; // for multiple << operators.
294  }
295 
298  errorQuda("Not implemented for this order %d", a.FieldOrder());
299 
300  if (a.LinkType() == QUDA_COARSE_LINKS) errorQuda("Not implemented for coarse-link type");
301  if (a.Ncolor() != 3) errorQuda("Not implemented for Ncolor = %d", a.Ncolor());
302 
304  errorQuda("Casting a GaugeField into ColorSpinorField not possible in half or quarter precision");
305 
306  ColorSpinorParam spinor_param;
307  spinor_param.nColor = (a.Geometry()*a.Reconstruct())/2;
308  spinor_param.nSpin = 1;
309  spinor_param.nDim = a.Ndim();
310  for (int d=0; d<a.Ndim(); d++) spinor_param.x[d] = a.X()[d];
311  spinor_param.pad = a.Pad();
312  spinor_param.siteSubset = QUDA_FULL_SITE_SUBSET;
313  spinor_param.siteOrder = QUDA_EVEN_ODD_SITE_ORDER;
314  spinor_param.setPrecision(a.Precision(), a.Precision(), true);
315  spinor_param.gammaBasis = QUDA_UKQCD_GAMMA_BASIS;
316  spinor_param.create = QUDA_REFERENCE_FIELD_CREATE;
317  spinor_param.v = (void*)a.Gauge_p();
318  spinor_param.location = a.Location();
319  return spinor_param;
320  }
321 
322  // Return the L2 norm squared of the gauge field
323  double norm2(const GaugeField &a) {
325  double nrm2 = blas::norm2(*b);
326  delete b;
327  return nrm2;
328  }
329 
330  // Return the L1 norm of the gauge field
331  double norm1(const GaugeField &a) {
333  double nrm1 = blas::norm1(*b);
334  delete b;
335  return nrm1;
336  }
337 
338  // Scale the gauge field by the constant a
339  void ax(const double &a, GaugeField &u) {
341  blas::ax(a, *b);
342  delete b;
343  }
344 
345  uint64_t GaugeField::checksum(bool mini) const {
346  return Checksum(*this, mini);
347  }
348 
350 
351  GaugeField *field = nullptr;
353  field = new cpuGaugeField(param);
354  } else if (param.location== QUDA_CUDA_FIELD_LOCATION) {
355  field = new cudaGaugeField(param);
356  } else {
357  errorQuda("Invalid field location %d", param.location);
358  }
359 
360  return field;
361  }
362 
363  // helper for creating extended gauge fields
364  cudaGaugeField *createExtendedGauge(cudaGaugeField &in, const int *R, TimeProfile &profile, bool redundant_comms,
365  QudaReconstructType recon)
366  {
367  profile.TPSTART(QUDA_PROFILE_INIT);
368  GaugeFieldParam gParamEx(in);
370  gParamEx.pad = 0;
371  gParamEx.nFace = 1;
372  gParamEx.tadpole = in.Tadpole();
373  gParamEx.anisotropy = in.Anisotropy();
374  for (int d = 0; d < 4; d++) {
375  gParamEx.x[d] += 2 * R[d];
376  gParamEx.r[d] = R[d];
377  }
378 
379  auto *out = new cudaGaugeField(gParamEx);
380 
381  // copy input field into the extended device gauge field
383 
384  profile.TPSTOP(QUDA_PROFILE_INIT);
385 
386  // now fill up the halos
387  out->exchangeExtendedGhost(R, profile, redundant_comms);
388 
389  return out;
390  }
391 
392  // helper for creating extended (cpu) gauge fields
394  {
395  GaugeFieldParam gauge_field_param(gauge, gauge_param);
396  cpuGaugeField cpu(gauge_field_param);
397 
398  gauge_field_param.ghostExchange = QUDA_GHOST_EXCHANGE_EXTENDED;
399  gauge_field_param.create = QUDA_ZERO_FIELD_CREATE;
400  for (int d = 0; d < 4; d++) {
401  gauge_field_param.x[d] += 2 * R[d];
402  gauge_field_param.r[d] = R[d];
403  }
404  cpuGaugeField *padded_cpu = new cpuGaugeField(gauge_field_param);
405 
406  copyExtendedGauge(*padded_cpu, cpu, QUDA_CPU_FIELD_LOCATION);
407  padded_cpu->exchangeExtendedGhost(R, true); // Do comm to fill halo = true
408 
409  return padded_cpu;
410  }
411 
412 } // namespace quda
int Ncolor
Definition: blas_test.cpp:51
static ColorSpinorField * Create(const ColorSpinorParam &param)
QudaFieldLocation location
void setPrecision(QudaPrecision precision, QudaPrecision ghost_precision=QUDA_INVALID_PRECISION, bool force_native=false)
QudaFieldGeometry Geometry() const
Definition: gauge_field.h:294
QudaLinkType link_type
Definition: gauge_field.h:216
QudaTboundary t_boundary
Definition: gauge_field.h:217
QudaGaugeFixed fixed
Definition: gauge_field.h:215
void removeStaggeredPhase()
void setTuningString()
Set the vol_string and aux_string for use in tuning.
QudaGaugeFieldOrder order
Definition: gauge_field.h:214
QudaLinkType LinkType() const
Definition: gauge_field.h:291
bool staggeredPhaseApplied
Definition: gauge_field.h:237
virtual ~GaugeField()
QudaStaggeredPhase staggeredPhaseType
Definition: gauge_field.h:232
GaugeField(const GaugeFieldParam &param)
Definition: gauge_field.cpp:30
QudaGaugeFieldOrder FieldOrder() const
Definition: gauge_field.h:293
static GaugeField * Create(const GaugeFieldParam &param)
Create the gauge field, with meta data specified in the parameter struct.
double Tadpole() const
Definition: gauge_field.h:289
void exchange(void **recv, void **send, QudaDirection dir) const
Exchange the buffers across all dimensions in a given direction.
void applyStaggeredPhase(QudaStaggeredPhase phase=QUDA_STAGGERED_PHASE_INVALID)
int Ncolor() const
Definition: gauge_field.h:285
virtual void * Gauge_p()
Definition: gauge_field.h:358
uint64_t checksum(bool mini=false) const
int ghostFace[QUDA_MAX_DIM]
Definition: gauge_field.h:227
bool isNative() const
Definition: gauge_field.h:350
void checkField(const LatticeField &) const
QudaFieldGeometry geometry
Definition: gauge_field.h:210
QudaReconstructType reconstruct
Definition: gauge_field.h:212
double Anisotropy() const
Definition: gauge_field.h:288
void createGhostZone(const int *R, bool no_comms_fill, bool bidir=true) const
QudaReconstructType Reconstruct() const
Definition: gauge_field.h:286
QudaGhostExchange ghostExchange
size_t ghost_offset[QUDA_MAX_DIM][2]
QudaPrecision ghost_precision
QudaPrecision Precision() const
QudaFieldLocation Location() const
QudaPrecision precision
size_t ghost_face_bytes[QUDA_MAX_DIM]
char aux_string[TuneKey::aux_n]
virtual void setTuningString()
const int * R() const
const int * X() const
int surfaceCB[QUDA_MAX_DIM]
int surface[QUDA_MAX_DIM]
void checkField(const LatticeField &a) const
int r[QUDA_MAX_DIM]
size_t ghost_face_bytes_aligned[QUDA_MAX_DIM]
void exchangeExtendedGhost(const int *R, bool no_comms_fill=false)
This does routine will populate the border / halo region of a gauge field that has been created using...
void exchangeGhost(QudaLinkDirection link_direction=QUDA_LINK_BACKWARDS)
Exchange the ghost and store store in the padded region.
void exchangeGhost(QudaLinkDirection link_direction=QUDA_LINK_BACKWARDS)
Exchange the ghost and store store in the padded region.
void comm_start(MsgHandle *mh)
int comm_dim_partitioned(int dim)
#define comm_declare_receive_relative(buffer, dim, dir, nbytes)
Definition: comm_quda.h:82
void comm_wait(MsgHandle *mh)
void comm_free(MsgHandle *&mh)
#define comm_declare_send_relative(buffer, dim, dir, nbytes)
Definition: comm_quda.h:67
double anisotropy
const int nColor
Definition: covdev_test.cpp:44
QudaGaugeParam gauge_param
Definition: covdev_test.cpp:26
enum QudaStaggeredPhase_s QudaStaggeredPhase
@ QUDA_STAGGERED_PHASE_INVALID
Definition: enum_quda.h:519
@ QUDA_CUDA_FIELD_LOCATION
Definition: enum_quda.h:326
@ QUDA_CPU_FIELD_LOCATION
Definition: enum_quda.h:325
enum QudaDirection_s QudaDirection
@ QUDA_FULL_SITE_SUBSET
Definition: enum_quda.h:333
@ QUDA_UKQCD_GAMMA_BASIS
Definition: enum_quda.h:369
@ QUDA_RECONSTRUCT_NO
Definition: enum_quda.h:70
@ QUDA_RECONSTRUCT_12
Definition: enum_quda.h:71
@ QUDA_RECONSTRUCT_13
Definition: enum_quda.h:74
@ QUDA_RECONSTRUCT_8
Definition: enum_quda.h:72
@ QUDA_RECONSTRUCT_9
Definition: enum_quda.h:73
@ QUDA_SCALAR_GEOMETRY
Definition: enum_quda.h:500
@ QUDA_VECTOR_GEOMETRY
Definition: enum_quda.h:501
@ QUDA_TENSOR_GEOMETRY
Definition: enum_quda.h:502
@ QUDA_COARSE_GEOMETRY
Definition: enum_quda.h:503
enum QudaFieldGeometry_s QudaFieldGeometry
@ QUDA_FORWARDS
Definition: enum_quda.h:493
@ QUDA_BACKWARDS
Definition: enum_quda.h:491
@ QUDA_GHOST_EXCHANGE_EXTENDED
Definition: enum_quda.h:510
@ QUDA_GHOST_EXCHANGE_PAD
Definition: enum_quda.h:509
@ QUDA_GAUGE_FIXED_YES
Definition: enum_quda.h:81
@ QUDA_EVEN_ODD_SITE_ORDER
Definition: enum_quda.h:340
enum QudaReconstructType_s QudaReconstructType
@ QUDA_QUARTER_PRECISION
Definition: enum_quda.h:62
@ QUDA_HALF_PRECISION
Definition: enum_quda.h:63
@ QUDA_QDP_GAUGE_ORDER
Definition: enum_quda.h:44
@ QUDA_NATIVE_GAUGE_ORDER
Definition: enum_quda.h:43
@ QUDA_QDPJIT_GAUGE_ORDER
Definition: enum_quda.h:45
@ QUDA_ZERO_FIELD_CREATE
Definition: enum_quda.h:361
@ QUDA_REFERENCE_FIELD_CREATE
Definition: enum_quda.h:363
@ QUDA_NULL_FIELD_CREATE
Definition: enum_quda.h:360
@ QUDA_SU3_LINKS
Definition: enum_quda.h:24
@ QUDA_COARSE_LINKS
Definition: enum_quda.h:28
@ QUDA_WILSON_LINKS
Definition: enum_quda.h:30
@ QUDA_ASQTAD_FAT_LINKS
Definition: enum_quda.h:31
float fat_link_max
#define pool_pinned_malloc(size)
Definition: malloc_quda.h:172
#define pool_pinned_free(ptr)
Definition: malloc_quda.h:173
double norm1(const ColorSpinorField &b)
unsigned long long bytes
void ax(double a, ColorSpinorField &x)
double norm2(const ColorSpinorField &a)
ColorSpinorParam colorSpinorParam(const CloverField &a, bool inverse)
double norm2(const CloverField &a, bool inverse=false)
void ax(const double &a, GaugeField &u)
Scale the gauge field by the scalar a.
uint64_t Checksum(const GaugeField &u, bool mini=false)
@ QUDA_PROFILE_INIT
Definition: timer.h:106
double norm1(const CloverField &u, bool inverse=false)
cudaGaugeField * createExtendedGauge(cudaGaugeField &in, const int *R, TimeProfile &profile, bool redundant_comms=false, QudaReconstructType recon=QUDA_RECONSTRUCT_INVALID)
void copyExtendedGauge(GaugeField &out, const GaugeField &in, QudaFieldLocation location, void *Out=0, void *In=0)
void applyGaugePhase(GaugeField &u)
std::ostream & operator<<(std::ostream &output, const CloverFieldParam &param)
QudaGaugeParam param
Definition: pack_test.cpp:18
#define qudaMemcpy(dst, src, count, kind)
Definition: quda_api.h:204
#define ALIGNMENT_ADJUST(n)
Definition: quda_internal.h:42
double anisotropy
Definition: quda.h:37
QudaReconstructType reconstruct
Definition: quda.h:49
QudaFieldLocation location
Definition: quda.h:33
QudaTboundary t_boundary
Definition: quda.h:44
GaugeFieldParam(void *const h_gauge=NULL)
Definition: gauge_field.h:85
QudaFieldCreate create
Definition: gauge_field.h:60
int r[QUDA_MAX_DIM]
Definition: lattice_field.h:80
QudaGhostExchange ghostExchange
Definition: lattice_field.h:77
int x[QUDA_MAX_DIM]
Definition: lattice_field.h:68
QudaSiteSubset siteSubset
Definition: lattice_field.h:72
static const int aux_n
Definition: tune_key.h:12
#define errorQuda(...)
Definition: util_quda.h:120