33 #ifndef _util_group_memmtmpi_h
34 #define _util_group_memmtmpi_h
37 #define MPICH_SKIP_MPICXX
40 #include <util/group/message.h>
41 #include <util/group/memamsg.h>
42 #include <util/group/thread.h>
66 unsigned int *nreq_sent_;
67 unsigned int *nreq_sent_buf_;
69 MTMPIThread **thread_;
74 void init_mtmpimg(MPI_Comm comm,
int nthreads);
77 void retrieve_data(
void *,
int node,
int offset,
int size,
int lock);
78 void replace_data(
void *,
int node,
int offset,
int size,
int unlock);
79 void sum_data(
double *data,
int node,
int doffset,
int dsize);
81 friend class MTMPIThread;
88 MPI_Comm comm = MPI_COMM_WORLD);
distsize_t offset(int node)
Returns the global offset to node's memory.
Definition: memory.h:168
void sync()
Synchronizes all the nodes.
A template class that maintains references counts.
Definition: ref.h:332
void deactivate()
Deactivate is called after the memory has been used.
int size(int node)
Returns the amount of memory residing on node.
Definition: memory.h:165
void activate()
Activate is called before the memory is to be used.
This MemoryGrp class requires a MT-safe MPI implementation.
Definition: memmtmpi.h:52
MTMPIMemoryGrp(const Ref< MessageGrp > &msg, const Ref< ThreadGrp > &th, MPI_Comm comm=MPI_COMM_WORLD)
Construct a MTMPIMemoryGrp given a MessageGrp, ThreadGrp, and an MPI communicator.
The ActiveMsgMemoryGrp abstract class specializes the MsgMemoryGrp class.
Definition: memamsg.h:93
Generated at Sun Jan 26 2020 23:33:04 for MPQC
2.3.1 using the documentation package Doxygen
1.8.16.