OOFEM 3.0
Loading...
Searching...
No Matches
oofem::CommunicatorBuff Class Reference

#include <communicator.h>

Public Member Functions

 CommunicatorBuff (int s, CommBuffType t=CBT_static)
ProcessCommunicatorBuffgiveProcessCommunicatorBuff (int i)

Protected Attributes

std::vector< ProcessCommunicatorBuffprocessCommBuffs
 Array of process communicators.

Detailed Description

The Communicator and corresponding buffers (represented by this class) are separated in order to allow share the same buffer by several communicators. Here sharing means reusing for different but non-overlapping communications. if communications overlap, the different instances of CommunicatorBuff should be used! The CommunicatorBuff objects are registered in corresponding communicator, then if maps are available, comBuff should be resized and used in subsequent ops.

The registration is necessary, otherwise before each send op the buffers (given probably as parameter) will be resized again (size have to be computed again) and this is probably quite cost operation. When comBuff will be registered, resize is needed only when maps change, and this will not occur frequently (its even quite rare).

Definition at line 61 of file communicator.h.

Constructor & Destructor Documentation

◆ CommunicatorBuff()

oofem::CommunicatorBuff::CommunicatorBuff ( int s,
CommBuffType t = CBT_static )

Definition at line 46 of file communicator.C.

References processCommBuffs.

Member Function Documentation

◆ giveProcessCommunicatorBuff()

ProcessCommunicatorBuff * oofem::CommunicatorBuff::giveProcessCommunicatorBuff ( int i)
inline

Returns i-th process communicator buff. The process comm buffs are numbered from rank 0.

Parameters
iProcess communicator buff index [0..size-1].
Returns
Pointer to corresponding process communicator buff, NULL otherwise.

Definition at line 76 of file communicator.h.

Referenced by oofem::Communicator::Communicator().

Member Data Documentation

◆ processCommBuffs

std::vector<ProcessCommunicatorBuff> oofem::CommunicatorBuff::processCommBuffs
protected

Array of process communicators.

Definition at line 65 of file communicator.h.

Referenced by CommunicatorBuff().


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

This page is part of the OOFEM-3.0 documentation. Copyright Copyright (C) 1994-2025 Borek Patzak Bořek Patzák
Project e-mail: oofem@fsv.cvut.cz
Generated at for OOFEM by doxygen 1.15.0 written by Dimitri van Heesch, © 1997-2011