Classdesc  3.D29
MPIbuf Class Reference

buffer object providing MPI functionality More...

#include <classdescMP.h>

Inheritance diagram for MPIbuf:
Inheritance graph
Collaboration diagram for MPIbuf:
Collaboration graph

Public Member Functions

unsigned myid ()
 
unsigned nprocs ()
 current processes taskID
 
 MPIbuf (const MPIbuf &x)
 
const MPIbufoperator= (const MPIbuf &x)
 
bool sent ()
 returns true if previous asyncronous call has been set
 
void wait ()
 wait for previous asyncronous call to complete
 
void send (unsigned dest, int tag)
 send data to dest with tag tag
 
void isend (unsigned dest, int tag)
 asyncronously send data to dest with tag tag
 
MPIbufget (int p=MPI_ANY_SOURCE, int t=MPI_ANY_TAG)
 receive a message from p (MPI_ANY_SOURCE) with tag t (MPI_ANY_TAG)
 
void send_recv (unsigned dest, int sendtag, int source, int recvtag)
 perform a simultaneous send and receive between a pair of processes
 
MPIbufbcast (unsigned root)
 broadcast data from root
 
MPIbufgather (unsigned root)
 gather data (concatenated) into root's buffer
 
MPIbufscatter (unsigned root)
 scatter root's data (that has been marked with mark)
 
MPIbufreset ()
 reset the buffer to send or receive a new message
 
bool msg_waiting (int source=MPI_ANY_SOURCE, int tag=MPI_ANY_TAG)
 is there a message waiting to be received into the buffe
 
template<class T >
MPIbufoperator<< (const T &x)
 
MPIbufoperator<< (classdesc::send s)
 
MPIbufoperator<< (classdesc::isend s)
 
MPIbufoperator<< (classdesc::bcast s)
 
MPIbufoperator<< (mark s)
 
- Public Member Functions inherited from pack_t
const char * data () const
 actual buffer
 
char * data ()
 actual buffer
 
size_t size () const
 size of buffer
 
size_t pos () const
 position of read pointer
 
char * realloc (char *d, size_t s)
 
void realloc (size_t s)
 
virtual void append (const basic_type &x)
 
virtual void popoff (basic_type &x)
 
 pack_t (size_t sz=0)
 
 pack_t (const char *fname, const char *rw)
 
virtual operator bool ()
 
virtual pack_treseti ()
 
virtual pack_treseto ()
 
virtual pack_tseeki (long offs)
 
virtual pack_tseeko (long offs)
 
void clear ()
 
virtual void packraw (const char *x, size_t s)
 
virtual void unpackraw (char *x, size_t s)
 
virtual void swap (pack_t &other)
 
virtual int cmp (const pack_t &x) const
 
bool operator< (const pack_t &x) const
 
bool operator> (const pack_t &x) const
 
bool operator== (const pack_t &x) const
 
bool operator!= (const pack_t &x) const
 
const char * data () const
 actual buffer
 
char * data ()
 actual buffer
 
size_t size () const
 size of buffer
 
size_t pos () const
 position of read pointer
 
char * realloc (char *d, size_t s)
 
void realloc (size_t s)
 
virtual void append (const basic_type &x)
 
virtual void popoff (basic_type &x)
 
 pack_t (size_t sz=0)
 
 pack_t (const char *fname, const char *rw)
 
virtual operator bool ()
 
virtual pack_treseti ()
 
virtual pack_treseto ()
 
virtual pack_tseeki (long offs)
 
virtual pack_tseeko (long offs)
 
void clear ()
 
virtual void packraw (const char *x, size_t s)
 
virtual void unpackraw (char *x, size_t s)
 
virtual void swap (pack_t &other)
 
virtual int cmp (const pack_t &x) const
 
bool operator< (const pack_t &x) const
 
bool operator> (const pack_t &x) const
 
bool operator== (const pack_t &x) const
 
bool operator!= (const pack_t &x) const
 

Public Attributes

MPI_Comm Communicator
 The MPI communicator to be used for subsequent communications.
 
bool const_buffer
 buffer size is same on all processes in a collective communication More...
 
int proc
 
int tag
 
- Public Attributes inherited from pack_t
Ptr_flag ptr_flag
 
unsigned recur_max
 recursion limit for pack_graph
 
std::vector< PtrStoreRefalloced
 

Friends

class MPIbuf_array
 

Additional Inherited Members

- Protected Types inherited from pack_t
enum  mode_t {
  buf, readf, writef, buf,
  readf, writef
}
 
enum  mode_t {
  buf, readf, writef, buf,
  readf, writef
}
 
- Protected Member Functions inherited from pack_t
void swap_base (pack_t &other)
 
void swap_base (pack_t &other)
 
- Protected Attributes inherited from pack_t
FILE * f
 
mode_t mode
 
char * m_data
 actual buffer
 
size_t m_size
 size of buffer
 
size_t m_pos
 position of read pointer
 

Detailed Description

buffer object providing MPI functionality

This class inherits from pack_t, so full classdesc serialisation is available

Member Data Documentation

bool const_buffer

buffer size is same on all processes in a collective communication

number of processesset this to true for improved collective communication. Safe to leave as false

Referenced by MPIbuf::bcast(), and MPIbuf::gather().


The documentation for this class was generated from the following file: