28 #ifndef _chemistry_qc_mbptr12_distarray4_mpiiofile_h
29 #define _chemistry_qc_mbptr12_distarray4_mpiiofile_h
31 #define OMPI_SKIP_MPICXX
32 #define MPICH_SKIP_MPICXX
34 #include <util/ref/ref.h>
35 #include <util/group/memory.h>
36 #include <util/misc/registry.h>
37 #include <math/distarray4/distarray4.h>
41 #define AVOID_XLC_BUG 1
59 size_t nints_per_block_;
69 mutable double* ints_[max_num_te_types];
70 mutable bool manage_[max_num_te_types];
71 mutable int refcount_[max_num_te_types];
78 void init(
bool restart);
80 int ij_proc(
int i,
int j)
const {
return 0;};
85 DistArray4Dimensions::default_dim());
91 DistArray4Storage
storage = DistArray4Storage_XY);
114 void clone_filename(std::string& result,
const char* original,
int id);
117 #ifndef AVOID_XLC_BUG
118 template <
typename Derived>
122 std::string clonename;
123 using detail::clone_filename;
124 clone_filename(clonename, this->filename_,
id);
128 clone_filename(clonename, this->filename_,
id);
131 clonelist_ = ListOfClones::instance();
133 clonelist_->
add(clonename,
id);
136 if (dim == DistArray4Dimensions::default_dim())
142 result =
new Derived(clonename.c_str(), dim.num_te_types(),
147 result->set_clonelist(clonelist_);
166 DistArray4Storage
storage = DistArray4Storage_XY);
175 int xstart,
int xfence,
int ystart,
int yfence,
178 double* buf = 0)
const;
180 int xstart,
int xfence,
int ystart,
int yfence,
bool is_local(int i, int j) const
Is this block stored locally?
Definition: distarray4_mpiiofile.h:106
virtual Ref< DistArray4 > clone(const DistArray4Dimensions &dim=DistArray4Dimensions::default_dim())=0
how to clone.
int nj() const
Rank of index space j.
Definition: distarray4.h:116
bool is_avail(int i, int j) const
In this implementation blocks are available everywhere.
Definition: distarray4_mpiiofile.h:108
bool has_access(int proc) const
Does this task have access to all the integrals?
Definition: distarray4_mpiiofile.h:110
DistArray4 contains a set of one or more distributed dense 4-index arrays.
Definition: distarray4.h:94
int num_te_types() const
The number of types of integrals that are being handled together.
Definition: distarray4.h:112
void add(const Key &key, const Value &obj)
registers this object
Definition: registry.timpl.h:206
const double * retrieve_pair_block(int i, int j, tbint_type oper_type, double *buf=0) const
Retrieves an ij block of integrals.
A template class that maintains references counts.
Definition: ref.h:361
void save_data_state(StateOut &)
Save the base classes (with save_data_state) and the members in the same order that the StateIn CTOR ...
int ny() const
Rank of index space y.
Definition: distarray4.h:120
void deactivate()
implementation of DistArray4::deactivate()
Definition: distarray4_mpiiofile.h:68
void activate()
implementation of DistArray4::activate()
void release_pair_block(int i, int j, tbint_type oper_type) const
Releases an ij pair block of integrals.
void store_pair_subblock(int i, int j, tbint_type oper_type, int xstart, int xfence, int ystart, int yfence, const double *ints)
Stores an rectangular subblock of ij block of integrals.
void retrieve_pair_subblock(int i, int j, tbint_type oper_type, int xstart, int xfence, int ystart, int yfence, double *buf) const
Retrieves a rectangular subblock of ij block of integrals.
bool data_persistent() const
implementation of DistArray4::data_persistent()
Definition: distarray4_mpiiofile.h:101
const DistArray4Storage & storage() const
physical storage of the integrals. The default storage is XY. Storage is not mutable.
Definition: distarray4.h:122
Definition: stateout.h:71
void store_pair_block(int i, int j, tbint_type oper_type, const double *ints)
Stores an ij pair block of integrals.
void init(bool restart)
Initialization tasks common to all constructors.
void check_error_code_(int errcod) const
Utility function to check MPI I/O error codes.
int ni() const
Rank of index space i.
Definition: distarray4.h:114
Ref< DistArray4 > clone(const DistArray4Dimensions &dim=DistArray4Dimensions::default_dim())
how to clone.
unsigned int tbint_type
Types of two-body operators that DistArray4 understands.
Definition: distarray4.h:108
DistArray4_MPIIOFile handles transformed integrals stored in a binary file accessed through MPI-IO.
Definition: distarray4_mpiiofile.h:55
Definition: distarray4.h:43
DistArray4_MPIIOFile_Ind handles transformed integrals stored in a binary file accessed through MPI-I...
Definition: distarray4_mpiiofile.h:161
int nx() const
Rank of index space x.
Definition: distarray4.h:118
bool key_exists(const Key &key) const
key exists?
Definition: registry.timpl.h:140
Contains all MPQC code up to version 3.
Definition: mpqcin.h:14
Registry wraps std::map and can be policy-configured to act as a Singleton or a regular object.
Definition: registry.h:112
void save_data_state(StateOut &)
Save the base classes (with save_data_state) and the members in the same order that the StateIn CTOR ...
Generated at Sun Jan 26 2020 23:24:00 for MPQC
3.0.0-alpha using the documentation package Doxygen
1.8.16.