QUDA v0.4.0
A library for QCD on GPUs
Namespaces | Defines | Functions | Variables
quda/lib/unitarize_links_quda.cu File Reference
#include <cstdlib>
#include <cstdio>
#include <iostream>
#include <iomanip>
#include <cuda.h>
#include <gauge_field.h>
#include "quda_matrix.h"
#include "svd_quda.h"
#include <hisq_links_quda.h>

Go to the source code of this file.

Namespaces

namespace  hisq

Defines

#define FL_UNITARIZE_PI   3.14159265358979323846
#define FL_UNITARIZE_PI23   FL_UNITARIZE_PI*2.0/3.0
#define FL_UNITARIZE_EPS   HOST_FL_UNITARIZE_EPS
#define FL_REUNIT_SVD_REL_ERROR   HOST_FL_REUNIT_SVD_REL_ERROR
#define FL_REUNIT_SVD_ABS_ERROR   HOST_FL_REUNIT_SVD_ABS_ERROR
#define FL_REUNIT_SVD_ONLY   HOST_FL_REUNIT_SVD_ONLY
#define FL_REUNIT_ALLOW_SVD   HOST_FL_REUNIT_ALLOW_SVD
#define FL_MAX_ERROR   HOST_FL_MAX_ERROR
#define MAX_ITER   HOST_MAX_ITER
#define FL_MAX_ERROR   HOST_FL_MAX_ERROR
#define FL_CHECK_UNITARIZATION   HOST_FL_CHECK_UNITARIZATION

Functions

void hisq::setUnitarizeLinksPadding (int input_padding, int output_padding)
template<class Cmplx >
__device__ __host__ bool hisq::isUnitary (const Matrix< Cmplx, 3 > &matrix, double max_error)
template<class Cmplx >
__device__ __host__ bool hisq::isUnitarizedLinkConsistent (const Matrix< Cmplx, 3 > &initial_matrix, const Matrix< Cmplx, 3 > &unitary_matrix, double max_error)
void hisq::setUnitarizeLinksConstants (double unitarize_eps, double max_error, bool allow_svd, bool svd_only, double svd_rel_error, double svd_abs_error, bool check_unitarization=true)
template<class T >
__device__ __host__ T hisq::getAbsMin (const T *const array, int size)
template<class Real >
__device__ __host__ bool hisq::checkAbsoluteError (Real a, Real b, Real epsilon)
template<class Real >
__device__ __host__ bool hisq::checkRelativeError (Real a, Real b, Real epsilon)
template<class Cmplx >
__device__ __host__ bool hisq::reciprocalRoot (const Matrix< Cmplx, 3 > &q, Matrix< Cmplx, 3 > *res)
template<class Cmplx >
__host__ __device__ bool hisq::unitarizeLinkMILC (const Matrix< Cmplx, 3 > &in, Matrix< Cmplx, 3 > *const result)
template<class Cmplx >
__host__ __device__ bool hisq::unitarizeLinkSVD (const Matrix< Cmplx, 3 > &in, Matrix< Cmplx, 3 > *const result)
template<class Cmplx >
__host__ __device__ bool hisq::unitarizeLinkNewton (const Matrix< Cmplx, 3 > &in, Matrix< Cmplx, 3 > *const result)
template<class Cmplx >
__global__ void hisq::getUnitarizedField (const Cmplx *inlink_even, const Cmplx *inlink_odd, Cmplx *outlink_even, Cmplx *outlink_odd, int *num_failures)
void hisq::unitarizeLinksCuda (const QudaGaugeParam &param, cudaGaugeField &infield, cudaGaugeField *outfield, int *num_failures)
void hisq::unitarizeLinksCPU (const QudaGaugeParam &param, cpuGaugeField &infield, cpuGaugeField *outfield)
bool hisq::isUnitary (const QudaGaugeParam &param, cpuGaugeField &field, double max_error)

Variables

__constant__ int INPUT_PADDING = 0
__constant__ int OUTPUT_PADDING = 0
__constant__ int DEV_MAX_ITER = 20
__constant__ double DEV_FL_MAX_ERROR
__constant__ double DEV_FL_UNITARIZE_EPS
__constant__ bool DEV_FL_REUNIT_ALLOW_SVD
__constant__ bool DEV_FL_REUNIT_SVD_ONLY
__constant__ double DEV_FL_REUNIT_SVD_REL_ERROR
__constant__ double DEV_FL_REUNIT_SVD_ABS_ERROR
__constant__ bool DEV_FL_CHECK_UNITARIZATION

Define Documentation

#define FL_CHECK_UNITARIZATION   HOST_FL_CHECK_UNITARIZATION
#define FL_MAX_ERROR   HOST_FL_MAX_ERROR
#define FL_MAX_ERROR   HOST_FL_MAX_ERROR
#define FL_REUNIT_ALLOW_SVD   HOST_FL_REUNIT_ALLOW_SVD
#define FL_REUNIT_SVD_ABS_ERROR   HOST_FL_REUNIT_SVD_ABS_ERROR
#define FL_REUNIT_SVD_ONLY   HOST_FL_REUNIT_SVD_ONLY
#define FL_REUNIT_SVD_REL_ERROR   HOST_FL_REUNIT_SVD_REL_ERROR
#define FL_UNITARIZE_EPS   HOST_FL_UNITARIZE_EPS
#define FL_UNITARIZE_PI   3.14159265358979323846

Definition at line 13 of file unitarize_links_quda.cu.

#define FL_UNITARIZE_PI23   FL_UNITARIZE_PI*2.0/3.0

Definition at line 16 of file unitarize_links_quda.cu.

#define MAX_ITER   HOST_MAX_ITER

Variable Documentation

__constant__ bool DEV_FL_CHECK_UNITARIZATION

Definition at line 31 of file unitarize_links_quda.cu.

__constant__ double DEV_FL_MAX_ERROR

Definition at line 25 of file unitarize_links_quda.cu.

__constant__ bool DEV_FL_REUNIT_ALLOW_SVD

Definition at line 27 of file unitarize_links_quda.cu.

__constant__ double DEV_FL_REUNIT_SVD_ABS_ERROR

Definition at line 30 of file unitarize_links_quda.cu.

__constant__ bool DEV_FL_REUNIT_SVD_ONLY

Definition at line 28 of file unitarize_links_quda.cu.

__constant__ double DEV_FL_REUNIT_SVD_REL_ERROR

Definition at line 29 of file unitarize_links_quda.cu.

__constant__ double DEV_FL_UNITARIZE_EPS

Definition at line 26 of file unitarize_links_quda.cu.

__constant__ int DEV_MAX_ITER = 20

Definition at line 21 of file unitarize_links_quda.cu.

__constant__ int INPUT_PADDING = 0

Definition at line 19 of file unitarize_links_quda.cu.

__constant__ int OUTPUT_PADDING = 0

Definition at line 20 of file unitarize_links_quda.cu.

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines