Arcane  4.2.3.0
Developer documentation
Loading...
Searching...
No Matches
Arcane::MessagePassing::IMessagePassingMng Class Referenceabstract

Interface of the message passing manager. More...

#include </__w/arcaneframework.github.io/arcaneframework.github.io/framework/arccore/src/message_passing/arccore/message_passing/IMessagePassingMng.h>

Inheritance diagram for Arcane::MessagePassing::IMessagePassingMng:
Collaboration diagram for Arcane::MessagePassing::IMessagePassingMng:

Public Member Functions

virtual Int32 commRank () const =0
 Rank of this instance in the communicator.
virtual Int32 commSize () const =0
 Number of instances in the communicator.
virtual ITimeMetricCollector * timeMetricCollector () const =0
 Interface for collecting execution times (can be null).
virtual Communicator communicator () const
 MPI communicator associated with this instance.
virtual IDispatchers * dispatchers ()=0

Private Member Functions

 ARCCORE_DECLARE_REFERENCE_COUNTED_INCLASS_METHODS ()

Friends

void mpDelete (IMessagePassingMng *p)
 Destroys the message passing instance p.

Detailed Description

Interface of the message passing manager.

This class uses a semantic by reference and instances are automatically destroyed when needed.

Most of the operations on this class use free functions (like mpSend() or mpReceive()) which are defined in file 'Messages.h'.

Arcane provides several implementation for message passing, using MPI, shared memory message passing or hybrid (MPI + shared memory) message passing. When using MPI, it is possible to create an instance of this class using the class StandaloneMpiMessagePassingMng.

Definition at line 53 of file IMessagePassingMng.h.

Member Function Documentation

◆ commRank()

virtual Int32 Arcane::MessagePassing::IMessagePassingMng::commRank ( ) const
pure virtual

Rank of this instance in the communicator.

Implemented in Arcane::MessagePassing::HybridParallelMng, Arcane::MessagePassing::MessagePassingMng, Arcane::MessagePassing::SharedMemoryParallelMng, Arcane::MpiParallelMng, Arcane::ParallelMngDispatcher, Arcane::SequentialParallelMng, and Arccore::MessagePassing::MessagePassingMng.

Referenced by Arcane::MessagePassing::mpCreateSerializeMessage(), and Arcane::MessagePassing::mpCreateSerializeMessage().

Here is the caller graph for this function:

◆ commSize()

◆ communicator()

Communicator Arcane::MessagePassing::IMessagePassingMng::communicator ( ) const
virtual

MPI communicator associated with this instance.

The communicator is only valid if the instance is associated with an MPI implementation. You can convert a communicator to a MPI communicator using helper methods toMpiCommunicator() and fillMpiCommunicatorIfValid() or like that:

IMessagePassingMng* mpm = ...;
Communicator comm = mpm->communicator();
if (comm.isValid())
MPI_Comm mpi_comm = static_cast<MPI_Comm>(comm).
Communicator for message exchange.
bool isValid() const
Indicates if the communicator is valid.
Interface of the message passing manager.
virtual Communicator communicator() const
MPI communicator associated with this instance.

Reimplemented in Arcane::MessagePassing::HybridParallelMng, Arcane::MessagePassing::MessagePassingMng, Arcane::MessagePassing::SharedMemoryParallelMng, Arcane::MpiParallelMng, Arcane::ParallelMngDispatcher, Arcane::SequentialParallelMng, and Arccore::MessagePassing::MessagePassingMng.

Definition at line 89 of file MessagePassingMng.cc.

Referenced by Arcane::MessagePassing::fillMpiCommunicatorIfValid(), timeMetricCollector(), and Arcane::MessagePassing::toMpiCommunicator().

Here is the caller graph for this function:

◆ timeMetricCollector()

virtual ITimeMetricCollector * Arcane::MessagePassing::IMessagePassingMng::timeMetricCollector ( ) const
pure virtual

Interface for collecting execution times (can be null).

Implemented in Arcane::MessagePassing::MessagePassingMng, Arcane::ParallelMngDispatcher, and Arccore::MessagePassing::MessagePassingMng.

References communicator().

Here is the call graph for this function:

◆ mpDelete

void mpDelete ( IMessagePassingMng * p)
friend

Destroys the message passing instance p.

Warning
This should only be used when using deprecated functions which do not return instances of Ref<IMessagePassingMng> and instead only return a IMessagePassingMng*.

Definition at line 81 of file MessagePassingMng.cc.

References mpDelete.

Referenced by mpDelete.


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