Teuchos::MpiComm< Ordinal > Class Template Reference

Concrete communicator subclass based on MPI. More...

#include <Teuchos_DefaultMpiComm.hpp>

Inheritance diagram for Teuchos::MpiComm< Ordinal >:
Teuchos::Comm< Ordinal > Teuchos::Describable Teuchos::LabeledObject

List of all members.

Public Member Functions

Constructors

 MpiComm (const RCP< const OpaqueWrapper< MPI_Comm > > &rawMpiComm)
 Construct given a wrapped MPI_Comm oqaque object.
RCP< const OpaqueWrapper
< MPI_Comm > > 
getRawMpiComm () const
 Return the embedded wrapped opaque MPI_Comm object.
Overridden from Comm

virtual int getRank () const
 
virtual int getSize () const
 
virtual void barrier () const
 
virtual void broadcast (const int rootRank, const Ordinal bytes, char buffer[]) const
 
virtual void gatherAll (const Ordinal sendBytes, const char sendBuffer[], const Ordinal recvBytes, char recvBuffer[]) const
 
virtual void reduceAll (const ValueTypeReductionOp< Ordinal, char > &reductOp, const Ordinal bytes, const char sendBuffer[], char globalReducts[]) const
 
virtual void reduceAllAndScatter (const ValueTypeReductionOp< Ordinal, char > &reductOp, const Ordinal sendBytes, const char sendBuffer[], const Ordinal recvCounts[], char myGlobalReducts[]) const
 
virtual void scan (const ValueTypeReductionOp< Ordinal, char > &reductOp, const Ordinal bytes, const char sendBuffer[], char scanReducts[]) const
 
virtual void send (const Ordinal bytes, const char sendBuffer[], const int destRank) const
 
virtual int receive (const int sourceRank, const Ordinal bytes, char recvBuffer[]) const
 
virtual void readySend (const ArrayView< const char > &sendBuffer, const int destRank) const
 
virtual RCP< CommRequestisend (const ArrayView< const char > &sendBuffer, const int destRank) const
 
virtual RCP< CommRequestireceive (const ArrayView< char > &Buffer, const int sourceRank) const
 
virtual void waitAll (const ArrayView< RCP< CommRequest > > &requests) const
 
virtual void wait (const Ptr< RCP< CommRequest > > &request) const
 
Overridden from Describable

std::string description () const
 

Related Functions

(Note that these are not member functions.)



template<typename Ordinal >
RCP< MpiComm< Ordinal > > createMpiComm (const RCP< const OpaqueWrapper< MPI_Comm > > &rawMpiComm)
 Helper function that creates a dynamically allocated MpiComm object or returns Teuchos::null to correctly represent a null communicator.

Detailed Description

template<typename Ordinal>
class Teuchos::MpiComm< Ordinal >

Concrete communicator subclass based on MPI.

Assertions:

ToDo: Finish documentation!

Definition at line 105 of file Teuchos_DefaultMpiComm.hpp.


Constructor & Destructor Documentation

template<typename Ordinal >
Teuchos::MpiComm< Ordinal >::MpiComm ( const RCP< const OpaqueWrapper< MPI_Comm > > &  rawMpiComm  )  [inline]

Construct given a wrapped MPI_Comm oqaque object.

Preconditions:

  • rawMpiComm.get()!=NULL && *rawMpiComm != MPI_COMM_NULL

Definition at line 265 of file Teuchos_DefaultMpiComm.hpp.


Member Function Documentation

template<typename Ordinal >
RCP<const OpaqueWrapper<MPI_Comm> > Teuchos::MpiComm< Ordinal >::getRawMpiComm (  )  const [inline]

Return the embedded wrapped opaque MPI_Comm object.

Definition at line 122 of file Teuchos_DefaultMpiComm.hpp.

template<typename Ordinal >
int Teuchos::MpiComm< Ordinal >::getRank (  )  const [inline, virtual]

Implements Teuchos::Comm< Ordinal >.

Definition at line 284 of file Teuchos_DefaultMpiComm.hpp.

template<typename Ordinal >
int Teuchos::MpiComm< Ordinal >::getSize (  )  const [inline, virtual]

Implements Teuchos::Comm< Ordinal >.

Definition at line 291 of file Teuchos_DefaultMpiComm.hpp.

template<typename Ordinal >
void Teuchos::MpiComm< Ordinal >::barrier (  )  const [inline, virtual]

Implements Teuchos::Comm< Ordinal >.

Definition at line 298 of file Teuchos_DefaultMpiComm.hpp.

template<typename Ordinal >
void Teuchos::MpiComm< Ordinal >::broadcast ( const int  rootRank,
const Ordinal  bytes,
char  buffer[] 
) const [inline, virtual]

Implements Teuchos::Comm< Ordinal >.

Definition at line 308 of file Teuchos_DefaultMpiComm.hpp.

template<typename Ordinal >
void Teuchos::MpiComm< Ordinal >::gatherAll ( const Ordinal  sendBytes,
const char  sendBuffer[],
const Ordinal  recvBytes,
char  recvBuffer[] 
) const [inline, virtual]

Implements Teuchos::Comm< Ordinal >.

Definition at line 320 of file Teuchos_DefaultMpiComm.hpp.

template<typename Ordinal >
void Teuchos::MpiComm< Ordinal >::reduceAll ( const ValueTypeReductionOp< Ordinal, char > &  reductOp,
const Ordinal  bytes,
const char  sendBuffer[],
char  globalReducts[] 
) const [inline, virtual]

Implements Teuchos::Comm< Ordinal >.

Definition at line 338 of file Teuchos_DefaultMpiComm.hpp.

template<typename Ordinal >
void Teuchos::MpiComm< Ordinal >::reduceAllAndScatter ( const ValueTypeReductionOp< Ordinal, char > &  reductOp,
const Ordinal  sendBytes,
const char  sendBuffer[],
const Ordinal  recvCounts[],
char  myGlobalReducts[] 
) const [inline, virtual]

Implements Teuchos::Comm< Ordinal >.

Definition at line 355 of file Teuchos_DefaultMpiComm.hpp.

template<typename Ordinal >
void Teuchos::MpiComm< Ordinal >::scan ( const ValueTypeReductionOp< Ordinal, char > &  reductOp,
const Ordinal  bytes,
const char  sendBuffer[],
char  scanReducts[] 
) const [inline, virtual]

Implements Teuchos::Comm< Ordinal >.

Definition at line 421 of file Teuchos_DefaultMpiComm.hpp.

template<typename Ordinal >
void Teuchos::MpiComm< Ordinal >::send ( const Ordinal  bytes,
const char  sendBuffer[],
const int  destRank 
) const [inline, virtual]

Implements Teuchos::Comm< Ordinal >.

Definition at line 438 of file Teuchos_DefaultMpiComm.hpp.

template<typename Ordinal >
int Teuchos::MpiComm< Ordinal >::receive ( const int  sourceRank,
const Ordinal  bytes,
char  recvBuffer[] 
) const [inline, virtual]

Implements Teuchos::Comm< Ordinal >.

Definition at line 499 of file Teuchos_DefaultMpiComm.hpp.

template<typename Ordinal >
void Teuchos::MpiComm< Ordinal >::readySend ( const ArrayView< const char > &  sendBuffer,
const int  destRank 
) const [inline, virtual]

Implements Teuchos::Comm< Ordinal >.

Definition at line 468 of file Teuchos_DefaultMpiComm.hpp.

template<typename Ordinal >
RCP< CommRequest > Teuchos::MpiComm< Ordinal >::isend ( const ArrayView< const char > &  sendBuffer,
const int  destRank 
) const [inline, virtual]

Implements Teuchos::Comm< Ordinal >.

Definition at line 534 of file Teuchos_DefaultMpiComm.hpp.

template<typename Ordinal >
RCP< CommRequest > Teuchos::MpiComm< Ordinal >::ireceive ( const ArrayView< char > &  Buffer,
const int  sourceRank 
) const [inline, virtual]

Implements Teuchos::Comm< Ordinal >.

Definition at line 555 of file Teuchos_DefaultMpiComm.hpp.

template<typename Ordinal >
void Teuchos::MpiComm< Ordinal >::waitAll ( const ArrayView< RCP< CommRequest > > &  requests  )  const [inline, virtual]

Implements Teuchos::Comm< Ordinal >.

Definition at line 576 of file Teuchos_DefaultMpiComm.hpp.

template<typename Ordinal >
void Teuchos::MpiComm< Ordinal >::wait ( const Ptr< RCP< CommRequest > > &  request  )  const [inline, virtual]

Implements Teuchos::Comm< Ordinal >.

Definition at line 608 of file Teuchos_DefaultMpiComm.hpp.

template<typename Ordinal >
std::string Teuchos::MpiComm< Ordinal >::description (  )  const [inline, virtual]

Reimplemented from Teuchos::Describable.

Definition at line 632 of file Teuchos_DefaultMpiComm.hpp.


Friends And Related Function Documentation

template<typename Ordinal >
RCP< MpiComm< Ordinal > > createMpiComm ( const RCP< const OpaqueWrapper< MPI_Comm > > &  rawMpiComm  )  [related]

Helper function that creates a dynamically allocated MpiComm object or returns Teuchos::null to correctly represent a null communicator.

Postconditions: [rawMpiComm.get()!=NULL && *rawMpiComm!=MPI_COMM_NULL] return.get()!=NULL [rawMpiComm.get()==NULL || *rawMpiComm==MPI_COMM_NULL] return.get()==NULL


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Generated on Wed Apr 13 09:57:46 2011 for Teuchos - Trilinos Tools Package by  doxygen 1.6.3