HiRep 0.1
Loading...
Searching...
No Matches
spinor_field.h File Reference

The elementary site structures defined in suN.h are used in this file to define field structures that contain arrays to save field data and information on the geometry. More...

#include "Geometry/geometry_descriptor.h"
#include "suN_types.h"
#include "hr_mpi.h"
#include "TMPL/spinor_field.h.tmpl"
Include dependency graph for spinor_field.h:

Go to the source code of this file.

Data Structures

struct  suNg_field
 Gauge field of SU(N_g) matrices. More...
 
struct  suNg_scalar_field
 SU(N_g) scalar field of SU(N_g) vectors. More...
 
struct  suNg_field_flt
 Gauge field of single precision SU(N_g) matrices. More...
 
struct  suNf_field
 Gauge field in chosen fermion representation. More...
 
struct  suNf_field_flt
 Single precision gauge field in the chosen fermion representation. More...
 
struct  spinor_field
 Spinor field array containing SU(N_f) spinors in chosen fermion representation. More...
 
struct  spinor_field_flt
 Spinor field array containing single precision SU(N_f) spinors in chosen fermion representation. More...
 
struct  suNg_av_field
 Field of SU(N_g) algebra vectors. More...
 
struct  scalar_field
 Scalar field of double precision real values. More...
 
struct  ldl_field
 LDL decomposition field needed for clover improvement. More...
 
struct  suNfc_field
 Complexified su(N_f) field field. More...
 
struct  clover_term
 Clover term. More...
 
struct  clover_force
 Clover Force. More...
 
struct  staple_field
 Staple field for Luescher-Weisz
More...
 
struct  gtransf
 Gauge transformation. More...
 

Macros

#define ALL_COMMS   (CPU_COMM | GPU_COMM)
 
#define _GPU_FIELD_DATA(_type)
 This macro corresponds to a field declaration line to be used inside a struct declaration. It only adds a GPU field data array, if the code is compiled with the flag WITH_GPU.
 
#define _GPU_FIELD_DATA(_type)
 This macro corresponds to a field declaration line to be used inside a struct declaration. It only adds a GPU field data array, if the code is compiled with the flag WITH_GPU.
 
#define _MPI_FIELD_DATA(_type)
 This macro corresponds to a field declaration line to be used inside a struct declaration. It only add MPI communication handles if the code is compiled with the flag WITH_MPI.
 
#define _MPI_FIELD_DATA(_type)
 This macro corresponds to a field declaration line to be used inside a struct declaration. It only add MPI communication handles if the code is compiled with the flag WITH_MPI.
 
#define _DECLARE_FIELD_STRUCT(_name, _type)
 This macro declares a field struct that contains all necessary field data arrays, geometry information and communication handles.
 
#define _FIELD_TYPE   spinor_field
 
#define _FIELD_DIM   1
 
#define _FIELD_TYPE   spinor_field_flt
 
#define _FIELD_DIM   1
 
#define _FIELD_TYPE   scalar_field
 
#define _FIELD_DIM   1
 
#define _FIELD_TYPE   suNg_field
 
#define _FIELD_DIM   4
 
#define _FIELD_TYPE   suNg_field_flt
 
#define _FIELD_DIM   4
 
#define _FIELD_TYPE   suNf_field
 
#define _FIELD_DIM   4
 
#define _FIELD_TYPE   suNf_field_flt
 
#define _FIELD_DIM   4
 
#define _FIELD_TYPE   suNg_scalar_field
 
#define _FIELD_DIM   1
 
#define _FIELD_TYPE   suNg_av_field
 
#define _FIELD_DIM   4
 
#define _FIELD_TYPE   gtransf
 
#define _FIELD_DIM   1
 
#define _FIELD_TYPE   ldl_field
 
#define _FIELD_DIM   1
 
#define _FIELD_TYPE   clover_term
 
#define _FIELD_DIM   4
 
#define _FIELD_TYPE   clover_force
 
#define _FIELD_DIM   6
 
#define _FIELD_TYPE   staple_field
 
#define _FIELD_DIM   3
 

Typedefs

typedef enum comm_t comm_t
 
typedef enum mem_t mem_t
 
typedef struct suNg_field suNg_field
 
typedef struct suNg_scalar_field suNg_scalar_field
 
typedef struct suNg_field_flt suNg_field_flt
 
typedef struct suNf_field suNf_field
 
typedef struct suNf_field_flt suNf_field_flt
 
typedef struct spinor_field spinor_field
 
typedef struct spinor_field_flt spinor_field_flt
 
typedef struct suNg_av_field suNg_av_field
 
typedef struct scalar_field scalar_field
 
typedef struct ldl_field ldl_field
 
typedef struct suNfc_field suNfc_field
 
typedef struct clover_term clover_term
 
typedef struct clover_force clover_force
 
typedef struct staple_field staple_field
 
typedef struct gtransf gtransf
 

Enumerations

enum  comm_t { CPU_COMM = 1 << 0 , GPU_COMM = 1 << 1 }
 
enum  mem_t { CPU_MEM = 1 << 0 , GPU_MEM = 1 << 1 }
 

Detailed Description

The elementary site structures defined in suN.h are used in this file to define field structures that contain arrays to save field data and information on the geometry.

Macro Definition Documentation

◆ _DECLARE_FIELD_STRUCT

#define _DECLARE_FIELD_STRUCT ( _name,
_type )
Value:
typedef struct _name { \
_type *ptr; \
int field_dim; \
_MPI_FIELD_DATA(_type) \
_GPU_FIELD_DATA(_type) \
comm_t comm_type; \
mem_t alloc_t; \
} _name
This struct should contain all information necessary to perform operations on the local lattice inclu...
Definition geometry_descriptor.h:106

This macro declares a field struct that contains all necessary field data arrays, geometry information and communication handles.

Parameters
_nameThe name of the field type
_typeThe elementary type struct of data stored at each site/link.

◆ _GPU_FIELD_DATA [1/2]

#define _GPU_FIELD_DATA ( _type)

This macro corresponds to a field declaration line to be used inside a struct declaration. It only adds a GPU field data array, if the code is compiled with the flag WITH_GPU.

Parameters
_typeElementary site/link type of the field data

◆ _GPU_FIELD_DATA [2/2]

#define _GPU_FIELD_DATA ( _type)
Value:
_type *gpu_ptr;

This macro corresponds to a field declaration line to be used inside a struct declaration. It only adds a GPU field data array, if the code is compiled with the flag WITH_GPU.

Parameters
_typeElementary site/link type of the field data

◆ _MPI_FIELD_DATA

#define _MPI_FIELD_DATA ( _type)
Value:
MPI_Request *comm_req; \
_type *sendbuf_ptr; \
_type *sendbuf_gpu_ptr; \
_type *recvbuf_gpu_ptr;

This macro corresponds to a field declaration line to be used inside a struct declaration. It only add MPI communication handles if the code is compiled with the flag WITH_MPI.