ug4
ug::HorizontalAlgebraLayouts Class Reference

Holds Interfaces and communicators for horizontal communication. More...

#include <algebra_layouts.h>

+ Inheritance diagram for ug::HorizontalAlgebraLayouts:

Public Member Functions

void clear ()
 clears the struct More...
 
pcl::InterfaceCommunicator< IndexLayout > & comm () const
 returns (non-const !!!) communicator More...
 
void enable_overlap (bool enable)
 
 HorizontalAlgebraLayouts ()
 
bool overlap_enabled () const
 Tells whether overlap interfaces should be considered. More...
 
const pcl::ProcessCommunicatorproc_comm () const
 returns process communicator More...
 
const IndexLayoutmaster () const
 
const IndexLayoutmaster_overlap () const
 
const IndexLayoutslave () const
 
const IndexLayoutslave_overlap () const
 
IndexLayoutmaster ()
 
IndexLayoutmaster_overlap ()
 
IndexLayoutslave ()
 
IndexLayoutslave_overlap ()
 
pcl::InterfaceCommunicator< IndexLayout > & comm ()
 
pcl::ProcessCommunicatorproc_comm ()
 

Protected Attributes

pcl::InterfaceCommunicator< IndexLayoutcommunicator
 communicator More...
 
bool m_overlapEnabled
 
IndexLayout masterLayout
 (horizontal) master index layout More...
 
IndexLayout masterOverlapLayout
 
pcl::ProcessCommunicator processCommunicator
 process communicator More...
 
IndexLayout slaveLayout
 (horizontal) slave index layout More...
 
IndexLayout slaveOverlapLayout
 

Detailed Description

Holds Interfaces and communicators for horizontal communication.

The internal ProcessCommunicator is initialized as PCD_WORLD.

Constructor & Destructor Documentation

◆ HorizontalAlgebraLayouts()

ug::HorizontalAlgebraLayouts::HorizontalAlgebraLayouts ( )
inline

Member Function Documentation

◆ clear()

void ug::HorizontalAlgebraLayouts::clear ( )
inline

◆ comm() [1/2]

pcl::InterfaceCommunicator<IndexLayout>& ug::HorizontalAlgebraLayouts::comm ( )
inline

returns communicator

References communicator.

◆ comm() [2/2]

pcl::InterfaceCommunicator<IndexLayout>& ug::HorizontalAlgebraLayouts::comm ( ) const
inline

returns (non-const !!!) communicator

We return a non-const communicator, since it can only be used non-const. This is requirement of the InterfaceCommunicator design, since internally buffers are used during communication. Theoretically, a communicator could be created each time for communication, but for performance reasons we provide this one that can be shared and reused.

References communicator.

Referenced by ug::BroadcastVectorFromOne(), ug::ConsistencyCheck(), ug::GatherVectorOnOne(), ug::GenerateGlobalConsecutiveIndices(), ug::OverlapWriter< TAlgebra >::init(), ug::AgglomeratingBase< TBase, TAlgebra >::init_mat(), ug::PrintLayouts(), and ug::TestHorizontalAlgebraLayouts().

◆ enable_overlap()

void ug::HorizontalAlgebraLayouts::enable_overlap ( bool  enable)
inline

It is important to enable or disable overlap on all involved processes at the same time. Otherwise communication issues may arise.

References m_overlapEnabled.

◆ master() [1/2]

IndexLayout& ug::HorizontalAlgebraLayouts::master ( )
inline

returns the horizontal slave/master index layout

References masterLayout.

◆ master() [2/2]

◆ master_overlap() [1/2]

IndexLayout& ug::HorizontalAlgebraLayouts::master_overlap ( )
inline

returns the horizontal slave/master index layout

References masterOverlapLayout.

◆ master_overlap() [2/2]

const IndexLayout& ug::HorizontalAlgebraLayouts::master_overlap ( ) const
inline

returns the horizontal slave/master index layout

References masterOverlapLayout.

Referenced by ug::OverlapWriter< TAlgebra >::init(), and ug::TestHorizontalAlgebraLayouts().

◆ overlap_enabled()

bool ug::HorizontalAlgebraLayouts::overlap_enabled ( ) const
inline

Tells whether overlap interfaces should be considered.

References m_overlapEnabled.

◆ proc_comm() [1/2]

pcl::ProcessCommunicator& ug::HorizontalAlgebraLayouts::proc_comm ( )
inline

returns communicator

References processCommunicator.

◆ proc_comm() [2/2]

◆ slave() [1/2]

IndexLayout& ug::HorizontalAlgebraLayouts::slave ( )
inline

returns the horizontal slave/master index layout

References slaveLayout.

◆ slave() [2/2]

◆ slave_overlap() [1/2]

IndexLayout& ug::HorizontalAlgebraLayouts::slave_overlap ( )
inline

returns the horizontal slave/master index layout

References slaveOverlapLayout.

◆ slave_overlap() [2/2]

const IndexLayout& ug::HorizontalAlgebraLayouts::slave_overlap ( ) const
inline

returns the horizontal slave/master index layout

References slaveOverlapLayout.

Referenced by ug::OverlapWriter< TAlgebra >::init(), and ug::TestHorizontalAlgebraLayouts().

Member Data Documentation

◆ communicator

pcl::InterfaceCommunicator<IndexLayout> ug::HorizontalAlgebraLayouts::communicator
protected

communicator

Referenced by comm().

◆ m_overlapEnabled

bool ug::HorizontalAlgebraLayouts::m_overlapEnabled
protected

Referenced by enable_overlap(), and overlap_enabled().

◆ masterLayout

IndexLayout ug::HorizontalAlgebraLayouts::masterLayout
protected

(horizontal) master index layout

Referenced by clear(), and master().

◆ masterOverlapLayout

IndexLayout ug::HorizontalAlgebraLayouts::masterOverlapLayout
protected

Referenced by master_overlap().

◆ processCommunicator

pcl::ProcessCommunicator ug::HorizontalAlgebraLayouts::processCommunicator
protected

process communicator

Referenced by proc_comm().

◆ slaveLayout

IndexLayout ug::HorizontalAlgebraLayouts::slaveLayout
protected

(horizontal) slave index layout

Referenced by clear(), and slave().

◆ slaveOverlapLayout

IndexLayout ug::HorizontalAlgebraLayouts::slaveOverlapLayout
protected

Referenced by slave_overlap().


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