Nektar++
|
#include <AssemblyCommDG.h>
Public Member Functions | |
Pairwise (const LibUtilities::CommSharedPtr &comm, const std::map< int, std::vector< int >> &rankSharedEdges, const std::map< int, std::vector< int >> &edgeToTrace) | |
void | PerformExchange (const Array< OneD, NekDouble > &testFwd, Array< OneD, NekDouble > &testBwd) final |
![]() | |
ExchangeMethod ()=default | |
Default constructor. More... | |
virtual | ~ExchangeMethod ()=default |
Default destructor. More... | |
Private Attributes | |
LibUtilities::CommSharedPtr | m_comm |
Communicator. More... | |
std::vector< std::pair< int, std::vector< int > > > | m_vecPairPartitionTrace |
List of partition to trace map indices of the quad points to exchange. More... | |
Array< OneD, int > | m_sendDisp |
List of displacements. More... | |
Array< OneD, NekDouble > | m_recvBuff |
Receive buffer for exchange. More... | |
Array< OneD, NekDouble > | m_sendBuff |
Send buffer for exchange. More... | |
LibUtilities::CommRequestSharedPtr | m_recvRequest |
List of receive requests. More... | |
LibUtilities::CommRequestSharedPtr | m_sendRequest |
List of send requests. More... | |
Uses persistent MPI_Irecv and MPI_Isend operations to perform the exchange of quadrature values. This allows for varying exchange array sizes to minimise communication data size. Ranks only communicate with ranks with which they need to exchange data, i.e. are adjacent in the mesh or share a periodic boundary condition. On each rank there are 'n' receives and 'n' sends posted where 'n' is the number of other ranks with which communication is needed. We use persistent communication methods to reduce overhead.
Definition at line 202 of file AssemblyCommDG.h.
Nektar::MultiRegions::Pairwise::Pairwise | ( | const LibUtilities::CommSharedPtr & | comm, |
const std::map< int, std::vector< int >> & | rankSharedEdges, | ||
const std::map< int, std::vector< int >> & | edgeToTrace | ||
) |
Definition at line 177 of file AssemblyCommDG.cpp.
References m_comm, m_recvBuff, m_recvRequest, m_sendBuff, m_sendDisp, m_sendRequest, and m_vecPairPartitionTrace.
|
finalvirtual |
Perform MPI comm exchange taking the Fwd trace and sending partition edge trace values to the matching locations in the Bwd trace of corresponding adjacent partitions.
[in] | testFwd | The values to send to adjacent partitions |
[out] | testBwd | The values received from adjacent partitions |
Implements Nektar::MultiRegions::ExchangeMethod.
Definition at line 301 of file AssemblyCommDG.cpp.
References m_comm, m_recvBuff, m_recvRequest, m_sendBuff, m_sendDisp, m_sendRequest, and m_vecPairPartitionTrace.
|
private |
Communicator.
Definition at line 216 of file AssemblyCommDG.h.
Referenced by Pairwise(), and PerformExchange().
Receive buffer for exchange.
Definition at line 222 of file AssemblyCommDG.h.
Referenced by Pairwise(), and PerformExchange().
|
private |
List of receive requests.
Definition at line 226 of file AssemblyCommDG.h.
Referenced by Pairwise(), and PerformExchange().
Send buffer for exchange.
Definition at line 224 of file AssemblyCommDG.h.
Referenced by Pairwise(), and PerformExchange().
List of displacements.
Definition at line 220 of file AssemblyCommDG.h.
Referenced by Pairwise(), and PerformExchange().
|
private |
List of send requests.
Definition at line 228 of file AssemblyCommDG.h.
Referenced by Pairwise(), and PerformExchange().
|
private |
List of partition to trace map indices of the quad points to exchange.
Definition at line 218 of file AssemblyCommDG.h.
Referenced by Pairwise(), and PerformExchange().