3 #define FINE_GRAINED_ACCESS 9 template <
typename FloatOut,
typename FloatIn,
int length,
typename InOrder>
13 errorQuda(
"Reconstruct type %d not supported",
out.Reconstruct());
19 #ifdef FINE_GRAINED_ACCESS 22 copyGauge<FloatOut,FloatIn,length>(G(
out,(
void*)Out,(
void**)outGhost), inOrder,
out.
Volume(), faceVolumeCB,
26 copyGauge<FloatOut,FloatIn,length>(G(
out,(
void*)Out,(
void**)outGhost), inOrder,
out.
Volume(), faceVolumeCB,
31 copyGauge<FloatOut,FloatIn,length>
32 (G(
out,Out,outGhost), inOrder,
out.
Volume(), faceVolumeCB,
38 #ifdef FINE_GRAINED_ACCESS 40 copyGauge<FloatOut,FloatIn,length>(G(
out,(
void*)Out,(
void**)outGhost), inOrder,
out.
Volume(),
44 copyGauge<FloatOut,FloatIn,length>(G(
out, Out, outGhost), inOrder,
out.
Volume(),
50 #ifdef FINE_GRAINED_ACCESS 52 copyGauge<FloatOut,FloatIn,length>(G(
out,(
void*)Out,(
void**)outGhost), inOrder,
out.
Volume(),
56 copyGauge<FloatOut,FloatIn,length>(G(
out, Out, outGhost), inOrder,
out.
Volume(),
61 errorQuda(
"Gauge field %d order not supported",
out.Order());
66 template <
typename FloatOut,
typename FloatIn,
int length>
68 FloatOut *Out, FloatIn *In, FloatOut **outGhost, FloatIn **inGhost,
int type) {
71 errorQuda(
"Reconstruct type %d not supported",
in.Reconstruct());
75 #ifdef FINE_GRAINED_ACCESS 78 copyGaugeMG<FloatOut,FloatIn,length> (G(const_cast<GaugeField&>(
in),(
void*)In,(
void**)inGhost),
out,
in, location, Out, outGhost, type);
81 copyGaugeMG<FloatOut,FloatIn,length> (G(const_cast<GaugeField&>(
in),(
void*)In,(
void**)inGhost),
out,
in, location, Out, outGhost, type);
85 copyGaugeMG<FloatOut,FloatIn,length> (G(
in, In,inGhost),
out,
in, location, Out, outGhost, type);
89 #ifdef FINE_GRAINED_ACCESS 91 copyGaugeMG<FloatOut,FloatIn,length>(G(const_cast<GaugeField&>(
in),(
void*)In,(
void**)inGhost),
out,
in, location, Out, outGhost, type);
94 copyGaugeMG<FloatOut,FloatIn,length>(G(
in, In, inGhost),
out,
in, location, Out, outGhost, type);
99 #ifdef FINE_GRAINED_ACCESS 101 copyGaugeMG<FloatOut,FloatIn,length>(G(const_cast<GaugeField&>(
in),(
void*)In,(
void**)inGhost),
out,
in, location, Out, outGhost, type);
104 copyGaugeMG<FloatOut,FloatIn,length>(G(
in, In, inGhost),
out,
in, location, Out, outGhost, type);
108 errorQuda(
"Gauge field %d order not supported",
in.Order());
113 template <
typename FloatOut,
typename FloatIn>
115 FloatIn *In, FloatOut **outGhost, FloatIn **inGhost,
int type) {
120 copyGaugeMG<FloatOut,FloatIn,2*Nc*Nc>(
out,
in, location, Out, In, outGhost, inGhost, type);
123 copyGaugeMG<FloatOut,FloatIn,2*Nc*Nc>(
out,
in, location, Out, In, outGhost, inGhost, type);
126 copyGaugeMG<FloatOut,FloatIn,2*Nc*Nc>(
out,
in, location, Out, In, outGhost, inGhost, type);
129 copyGaugeMG<FloatOut,FloatIn,2*Nc*Nc>(
out,
in, location, Out, In, outGhost, inGhost, type);
132 copyGaugeMG<FloatOut,FloatIn,2*Nc*Nc>(
out,
in, location, Out, In, outGhost, inGhost, type);
135 copyGaugeMG<FloatOut,FloatIn,2*Nc*Nc>(
out,
in, location, Out, In, outGhost, inGhost, type);
138 copyGaugeMG<FloatOut,FloatIn,2*Nc*Nc>(
out,
in, location, Out, In, outGhost, inGhost, type);
141 copyGaugeMG<FloatOut,FloatIn,2*Nc*Nc>(
out,
in, location, Out, In, outGhost, inGhost, type);
144 copyGaugeMG<FloatOut,FloatIn,2*Nc*Nc>(
out,
in, location, Out, In, outGhost, inGhost, type);
146 #endif // GPU_MULTIGRID 154 void *Out,
void *In,
void **ghostOut,
void **ghostIn,
int type) {
157 #ifdef GPU_MULTIGRID_DOUBLE 159 copyGaugeMG(
out,
in, location, (
double*)Out, (
double*)In, (
double**)ghostOut, (
double**)ghostIn, type);
161 copyGaugeMG(
out,
in, location, (
double*)Out, (
float*)In, (
double**)ghostOut, (
float**)ghostIn, type);
166 errorQuda(
"Double precision multigrid has not been enabled");
170 #ifdef GPU_MULTIGRID_DOUBLE 171 copyGaugeMG(
out,
in, location, (
float*)Out, (
double*)In, (
float**)ghostOut, (
double**)ghostIn, type);
173 errorQuda(
"Double precision multigrid has not been enabled");
176 copyGaugeMG(
out,
in, location, (
float*)Out, (
float*)In, (
float**)ghostOut, (
float**)ghostIn, type);
const int * SurfaceCB() const
void copyGaugeMG(const InOrder &inOrder, GaugeField &out, const GaugeField &in, QudaFieldLocation location, FloatOut *Out, FloatOut **outGhost, int type)
Main header file for host and device accessors to GaugeFields.
enum QudaFieldLocation_s QudaFieldLocation
cpuColorSpinorField * out
void copyGenericGaugeMG(GaugeField &out, const GaugeField &in, QudaFieldLocation location, void *Out, void *In, void **ghostOut, void **ghostIn, int type)
#define QUDA_MAX_DIM
Maximum number of dimensions supported by QUDA. In practice, no routines make use of more than 5...
QudaPrecision Precision() const