65 for (
int dir = 0; dir < 4; dir++) {
73 for (
int d=0; d<4; d++) csParam.
x[d] = param.
X[d];
94 csParam.
pad = param.
X[0] * param.
X[1] * param.
X[2];
112 printf(
"Sending fields to GPU...\n"); fflush(stdout);
114 #ifdef BUILD_CPS_INTERFACE 132 printf(
"CPS Gauge send time = %e seconds\n", cpsGtime);
137 printf(
"CPS Gauge restore time = %e seconds\n", cpsGRtime);
141 #ifdef BUILD_QDP_INTERFACE 159 printf(
"QDP Gauge send time = %e seconds\n", qdpGtime);
164 printf(
"QDP Gauge restore time = %e seconds\n", qdpGRtime);
172 printf(
"Spinor send time = %e seconds\n", sSendTime); fflush(stdout);
177 printf(
"Spinor receive time = %e seconds\n", sRecTime); fflush(stdout);
180 double cuda_spinor_norm =
blas::norm2(*cudaSpinor);
183 printf(
"Norm check: CPU = %e, CUDA = %e, CPU = %e\n",
184 spinor_norm, cuda_spinor_norm, spinor2_norm);
190 extern void usage(
char**);
192 int main(
int argc,
char **argv) {
193 for (
int i=1; i<argc; i++){
198 fprintf(stderr,
"ERROR: Invalid option:%s\n", argv[i]);
cpuColorSpinorField * spinor
QudaReconstructType reconstruct_sloppy
void setPrecision(QudaPrecision precision, QudaPrecision ghost_precision=QUDA_INVALID_PRECISION, bool force_native=false)
void setVerbosityQuda(QudaVerbosity verbosity, const char prefix[], FILE *outfile)
enum QudaPrecision_s QudaPrecision
void saveCPUField(cpuGaugeField &cpu) const
Upload from this field into a CPU field.
cpuColorSpinorField * spinor2
double norm2(const ColorSpinorField &a)
int process_command_line_option(int argc, char **argv, int *idx)
void Source(const QudaSourceType sourceType, const int st=0, const int s=0, const int c=0)
QudaGaugeFieldOrder gauge_order
QudaSiteSubset siteSubset
double stopwatchReadSeconds()
void loadCPUField(const cpuGaugeField &cpu)
Download into this field from a CPU field.
void initQuda(int device)
QudaFieldOrder fieldOrder
cudaColorSpinorField * cudaSpinor
QudaGammaBasis gammaBasis
QudaGaugeFieldOrder order
QudaPrecision cuda_prec_sloppy
QudaReconstructType link_recon
QudaReconstructType reconstruct
static int Compare(const cpuColorSpinorField &a, const cpuColorSpinorField &b, const int resolution=1)
Perform a component by component comparison of two color-spinor fields. In doing we normalize with re...
void setPrecision(QudaPrecision precision, bool force_native=false)
Helper function for setting the precision and corresponding field order for QUDA internal fields...
enum QudaReconstructType_s QudaReconstructType
QudaPrecision Precision() const
int main(int argc, char **argv)
QudaReconstructType reconstruct
int gridsize_from_cmdline[]
void initComms(int argc, char **argv, int *const commDims)