Information for a mesh exchange between sub-domains. More...
#include <arcane/mesh/MeshExchanger.h>
Public Member Functions | |
| MeshExchanger (IMesh *mesh, ITimeStats *stats) | |
| bool | computeExchangeInfos () override |
| Calculates the information to send/receive from other subdomains. | |
| void | processExchange () override |
| Performs the exchange of information between subdomains. | |
| void | removeNeededItems () override |
| Deletes from this subdomain the entities that should no longer be there following the exchange. | |
| void | allocateReceivedItems () override |
| Allocates the entities received from other subdomains. | |
| void | updateItemGroups () override |
| Update of entity groups. | |
| void | updateVariables () override |
| Update of variables. | |
| void | finalizeExchange () override |
| Finalizes the exchanges. | |
| IPrimaryMesh * | mesh () const override |
| Mesh associated with this exchanger. | |
| void | build () |
| IItemFamilyExchanger * | findExchanger (IItemFamily *family) override |
| Exchanger associated with the family. Throws an exception if not found. | |
| ePhase | phase () const override |
| Phase of the exchange we are currently in. | |
| Public Member Functions inherited from Arcane::TraceAccessor | |
| TraceAccessor (ITraceMng *m) | |
| Constructs an accessor via the trace manager m. | |
| TraceAccessor (const TraceAccessor &rhs) | |
| Copy constructor. | |
| TraceAccessor & | operator= (const TraceAccessor &rhs) |
| Copy assignment operator. | |
| virtual | ~TraceAccessor () |
| Frees resources. | |
| ITraceMng * | traceMng () const |
| Trace manager. | |
| TraceMessage | info () const |
| Flow for an information message. | |
| TraceMessage | pinfo () const |
| Flow for a parallel information message. | |
| TraceMessage | info (char category) const |
| Flow for an information message of a given category. | |
| TraceMessage | pinfo (char category) const |
| Flow for a parallel information message of a given category. | |
| TraceMessage | info (bool v) const |
| Flow for an information message. | |
| TraceMessage | warning () const |
| Flow for a warning message. | |
| TraceMessage | pwarning () const |
| TraceMessage | error () const |
| Flow for an error message. | |
| TraceMessage | perror () const |
| TraceMessage | log () const |
| Flow for a log message. | |
| TraceMessage | plog () const |
| Flow for a log message. | |
| TraceMessage | logdate () const |
| Flow for a log message preceded by the date. | |
| TraceMessage | fatal () const |
| Flow for a fatal error message. | |
| TraceMessage | pfatal () const |
| Flow for a parallel fatal error message. | |
| TraceMessageDbg | debug (Trace::eDebugLevel=Trace::Medium) const |
| Flow for a debug message. | |
| Trace::eDebugLevel | configDbgLevel () const |
| Debug level of the configuration file. | |
| TraceMessage | info (Int32 verbose_level) const |
| Flow for an information message of a given level. | |
| TraceMessage | linfo () const |
| Flow for an information message with the local information level of this instance. | |
| TraceMessage | linfo (Int32 relative_level) const |
| Flow for an information message with the local information level of this instance. | |
| void | fatalMessage (const StandaloneTraceMessage &o) const |
Protected Member Functions | |
| void | _setNextPhase (ePhase next_phase) |
| Protected Member Functions inherited from Arcane::TraceAccessor | |
| void | _setLocalVerboseLevel (Int32 v) |
| Int32 | _localVerboseLevel () const |
Private Types | |
| typedef std::map< IItemFamily *, IItemFamilyExchanger * > | ItemFamilyExchangerMap |
Private Member Functions | |
| void | _checkPhase (ePhase wanted_phase) |
| void | _buildWithItemFamilyNetwork () |
| void | _addItemFamilyExchanger (IItemFamily *family) |
Private Attributes | |
| IMesh * | m_mesh |
| List< IItemFamilyExchanger * > | m_family_exchangers |
| ItemFamilyExchangerMap | m_family_exchanger_map |
| ITimeStats * | m_time_stats |
| ePhase | m_phase |
| ParallelExchangerOptions | m_exchanger_option |
Additional Inherited Members | |
| Public Types inherited from Arcane::IMeshExchanger | |
| enum class | ePhase { Init = 0 , ComputeInfos , ProcessExchange , RemoveItems , AllocateItems , UpdateItemGroups , UpdateVariables , Finalize , Ended } |
| Indicates the different phases of the exchange. More... | |
Information for a mesh exchange between sub-domains.
Definition at line 41 of file MeshExchanger.h.
|
private |
Definition at line 47 of file MeshExchanger.h.
| Arcane::mesh::MeshExchanger::MeshExchanger | ( | IMesh * | mesh, |
| ITimeStats * | stats ) |
Definition at line 41 of file MeshExchanger.cc.
| Arcane::mesh::MeshExchanger::~MeshExchanger | ( | ) |
Definition at line 67 of file MeshExchanger.cc.
|
private |
Definition at line 178 of file MeshExchanger.cc.
|
private |
Definition at line 160 of file MeshExchanger.cc.
|
private |
Definition at line 190 of file MeshExchanger.cc.
|
protected |
Definition at line 457 of file MeshExchanger.cc.
|
overridevirtual |
Allocates the entities received from other subdomains.
This operation is collective.
Implements Arcane::IMeshExchanger.
Definition at line 335 of file MeshExchanger.cc.
References Arcane::platform::getCurrentDateTime(), and Arcane::TraceAccessor::info().
| void Arcane::mesh::MeshExchanger::build | ( | ) |
Definition at line 80 of file MeshExchanger.cc.
|
overridevirtual |
Calculates the information to send/receive from other subdomains.
This operation is collective.
The calculation of information to send is done by knowing the new owner of each entity. This information is stored in the IItemFamily::itemsNewOwner() variable. For example, a cell will be migrated if the new owner is different from the current owner (which is given by Item::owner()).
After calling this method, each mesh entity is modified as follows:
Returns true if there is no exchange to perform.
Implements Arcane::IMeshExchanger.
Definition at line 201 of file MeshExchanger.cc.
References Arcane::IItemFamily::allItems(), Arcane::IItemFamilyExchanger::computeExchangeInfos(), Arcane::mesh::MeshExchange::computeInfos(), ENUMERATE_ITEM, findExchanger(), Arcane::platform::getCurrentDateTime(), Arcane::IParticleFamily::getEnableGhostItems(), Arcane::mesh::MeshExchange::getItemsToSend(), Arcane::TraceAccessor::info(), Arcane::IItemFamily::itemsNewOwner(), Arcane::Item::mutableItemBase(), Arcane::IItemFamily::name(), Arcane::IItemFamily::notifyItemsOwnerChanged(), Arcane::TraceAccessor::pwarning(), Arcane::IItemFamilyExchanger::setExchangeItems(), Arcane::MutableItemBase::setOwner(), and Arcane::IItemFamily::toParticleFamily().
|
overridevirtual |
Finalizes the exchanges.
This operation is collective.
This method performs the last necessary operations during the exchange.
Implements Arcane::IMeshExchanger.
Definition at line 415 of file MeshExchanger.cc.
|
overridevirtual |
Exchanger associated with the family. Throws an exception if not found.
Implements Arcane::IMeshExchanger.
Definition at line 436 of file MeshExchanger.cc.
References ARCANE_FATAL, and Arcane::IItemFamily::name().
Referenced by computeExchangeInfos().
|
overridevirtual |
Mesh associated with this exchanger.
Implements Arcane::IMeshExchanger.
Definition at line 448 of file MeshExchanger.cc.
References Arcane::IMesh::toPrimaryMesh().
|
inlineoverridevirtual |
Phase of the exchange we are currently in.
Implements Arcane::IMeshExchanger.
Definition at line 66 of file MeshExchanger.h.
|
overridevirtual |
Performs the exchange of information between subdomains.
This operation is collective.
This operation makes no modification to the mesh. It simply sends and receives the necessary information for mesh update.
Implements Arcane::IMeshExchanger.
Definition at line 280 of file MeshExchanger.cc.
References Arcane::platform::getCurrentDateTime(), Arcane::platform::getMemoryUsed(), and Arcane::TraceAccessor::info().
|
overridevirtual |
Deletes from this subdomain the entities that should no longer be there following the exchange.
All entities marked with the ItemFlags::II_NeedRemove flag are deleted.
Implements Arcane::IMeshExchanger.
Definition at line 302 of file MeshExchanger.cc.
References Arcane::platform::getCurrentDateTime(), Arcane::IParticleFamily::getEnableGhostItems(), Arcane::TraceAccessor::info(), Arcane::IParticleFamily::itemFamily(), and Arcane::IItemFamily::toParticleFamily().
|
overridevirtual |
Update of entity groups.
This operation is collective.
Implements Arcane::IMeshExchanger.
Definition at line 381 of file MeshExchanger.cc.
References Arcane::platform::getCurrentDateTime(), and Arcane::TraceAccessor::info().
|
overridevirtual |
Update of variables.
This operation is collective.
Implements Arcane::IMeshExchanger.
Definition at line 397 of file MeshExchanger.cc.
References Arcane::platform::getCurrentDateTime(), and Arcane::TraceAccessor::info().
|
private |
Definition at line 79 of file MeshExchanger.h.
|
private |
Definition at line 76 of file MeshExchanger.h.
|
private |
Definition at line 75 of file MeshExchanger.h.
|
private |
Definition at line 74 of file MeshExchanger.h.
|
private |
Definition at line 78 of file MeshExchanger.h.
|
private |
Definition at line 77 of file MeshExchanger.h.