OPAL (Object Oriented Parallel Accelerator Library) 2024.2
OPAL
CompressedBrickIterator< T, Dim > Class Template Reference

#include <CompressedBrickIterator.h>

Inheritance diagram for CompressedBrickIterator< T, Dim >:
Collaboration diagram for CompressedBrickIterator< T, Dim >:

Public Types

typedef T PETE_Return_t
typedef BrickIterator< T, DimPETE_Expr_t

Public Member Functions

 CompressedBrickIterator (T *t, const NDIndex< Dim > &c, const NDIndex< Dim > &a, T &compressed)
 CompressedBrickIterator (T *t, const vec< int, Dim > &v, T &compressed)
 CompressedBrickIterator (T &t)
 CompressedBrickIterator ()
 CompressedBrickIterator (const NDIndex< Dim > &a, T &compressed)
 CompressedBrickIterator (const BrickIterator< T, Dim > &x, T &compressed)
bool IsCompressed () const
bool CanCompress (const T &) const
void Compress (T &val)
bool TryCompress ()
bool TryCompress (T val)
const CompressedBrickIterator< T, Dim > & operator= (const CompressedBrickIterator< T, Dim > &rhs)
 CompressedBrickIterator (const CompressedBrickIterator< T, Dim > &X)
MessageputMessage (Message &m, bool makecopy=true)
MessagegetMessage (Message &m)
CompressedBrickIterator< T, 1 > permute (NDIndex< Dim > &current, NDIndex< 1 > &permuted) const
CompressedBrickIterator< T, 2 > permute (NDIndex< Dim > &current, NDIndex< 2 > &permuted) const
CompressedBrickIterator< T, 3 > permute (NDIndex< Dim > &current, NDIndex< 3 > &permuted) const
CompressedBrickIterator< T, 4 > permute (NDIndex< Dim > &current, NDIndex< 4 > &permuted) const
CompressedBrickIterator< T, 5 > permute (NDIndex< Dim > &current, NDIndex< 5 > &permuted) const
CompressedBrickIterator< T, 6 > permute (NDIndex< Dim > &current, NDIndex< 6 > &permuted) const
void SetCurrent (T *p)
void SetCount (int d, int count)
void ResetCounter (int d)
void SetStride (int d, int stride)
int GetStride (int d) const
T & GetCompressedData () const
void SetCompressedData (T *newData)
BrickIteratoroperator++ ()
bool whole () const
bool operator== (const BrickIterator< T, Dim > &a) const
bool operator!= (const BrickIterator< T, Dim > &a) const
T & operator* () const
void step (unsigned d)
void rewind (unsigned d)
T & offset (int i) const
T & offset (int i, int j) const
T & offset (int i, int j, int k) const
T & offset (int *i) const
T & unit_offset (int i) const
T & unit_offset (int i, int j) const
T & unit_offset (int i, int j, int k) const
void moveBy (int i)
void moveBy (int i, int j)
void moveBy (int i, int j, int k)
void moveBy (const int *i)
int Stride (int i) const
PETE_Expr_t MakeExpression () const
bool done (unsigned d) const
int size (unsigned d) const
int GetOffset (unsigned d) const

Protected Member Functions

void op_pp ()

Protected Attributes

T *__restrict__ Current
vec< int, DimStrides
bool Whole
vec< int, DimCounters
vec< int, DimCounts

Private Attributes

T * CompressedData

Detailed Description

template<class T, unsigned Dim>
class CompressedBrickIterator< T, Dim >

Definition at line 48 of file CompressedBrickIterator.h.

Member Typedef Documentation

◆ PETE_Expr_t

template<class T, unsigned Dim>
typedef BrickIterator<T,Dim> BrickIterator< T, Dim >::PETE_Expr_t
inherited

Definition at line 175 of file BrickIterator.h.

◆ PETE_Return_t

template<class T, unsigned Dim>
typedef T BrickIterator< T, Dim >::PETE_Return_t
inherited

Definition at line 174 of file BrickIterator.h.

Constructor & Destructor Documentation

◆ CompressedBrickIterator() [1/7]

◆ CompressedBrickIterator() [2/7]

template<class T, unsigned Dim>
CompressedBrickIterator< T, Dim >::CompressedBrickIterator ( T * t,
const vec< int, Dim > & v,
T & compressed )
inline

Definition at line 73 of file CompressedBrickIterator.h.

References BrickIterator< T, Dim >::BrickIterator(), CompressedData, BrickIterator< T, Dim >::Current, Dim, and BrickIterator< T, Dim >::Strides.

Here is the call graph for this function:

◆ CompressedBrickIterator() [3/7]

template<class T, unsigned Dim>
CompressedBrickIterator< T, Dim >::CompressedBrickIterator ( T & t)
inline

Definition at line 84 of file CompressedBrickIterator.h.

References CompressedData.

◆ CompressedBrickIterator() [4/7]

template<class T, unsigned Dim>
CompressedBrickIterator< T, Dim >::CompressedBrickIterator ( )
inline

Definition at line 88 of file CompressedBrickIterator.h.

References CompressedData.

◆ CompressedBrickIterator() [5/7]

template<class T, unsigned Dim>
CompressedBrickIterator< T, Dim >::CompressedBrickIterator ( const NDIndex< Dim > & a,
T & compressed )

◆ CompressedBrickIterator() [6/7]

template<class T, unsigned Dim>
CompressedBrickIterator< T, Dim >::CompressedBrickIterator ( const BrickIterator< T, Dim > & x,
T & compressed )
inline

Definition at line 96 of file CompressedBrickIterator.h.

References BrickIterator< T, Dim >::BrickIterator(), CompressedData, and Dim.

Here is the call graph for this function:

◆ CompressedBrickIterator() [7/7]

template<class T, unsigned Dim>
CompressedBrickIterator< T, Dim >::CompressedBrickIterator ( const CompressedBrickIterator< T, Dim > & X)

Definition at line 340 of file CompressedBrickIterator.hpp.

References BrickIterator< T, Dim >::BrickIterator(), CompressedBrickIterator(), CompressedData, Dim, and X.

Here is the call graph for this function:

Member Function Documentation

◆ CanCompress()

template<class T, unsigned Dim>
bool CompressedBrickIterator< T, Dim >::CanCompress ( const T & val) const

Definition at line 198 of file CompressedBrickIterator.hpp.

References all_values_equal(), CompressedData, Dim, and IsCompressed().

Referenced by BareField< T, Dim >::accumGuardCells(), and TryCompress().

Here is the call graph for this function:

◆ Compress()

template<class T, unsigned Dim>
void CompressedBrickIterator< T, Dim >::Compress ( T & val)

◆ done()

template<unsigned Dim>
bool BrickCounter< Dim >::done ( unsigned d) const
inlineinherited

Definition at line 36 of file BrickIterator.h.

References Counters, and Counts.

Referenced by BareFieldIterator< T, Dim >::done(), and SIndexExpLoop< OP, Dim >::evaluate().

◆ GetCompressedData()

template<class T, unsigned Dim>
T & CompressedBrickIterator< T, Dim >::GetCompressedData ( ) const
inline

Definition at line 169 of file CompressedBrickIterator.h.

References CompressedData.

Referenced by permute().

◆ getMessage()

template<class T, unsigned Dim>
Message & CompressedBrickIterator< T, Dim >::getMessage ( Message & m)

Definition at line 245 of file CompressedBrickIterator.hpp.

References CompressedData, BrickCounter< Dim >::Counters, BrickCounter< Dim >::Counts, BrickIterator< T, Dim >::Current, Dim, Message::get(), BrickIterator< T, Dim >::getMessage(), getMessage_iter(), PAssert, and BrickIterator< T, Dim >::Strides.

Referenced by BareField< T, Dim >::accumGuardCells(), and FieldDataSource< T, Dim, M, C >::gather_data().

Here is the call graph for this function:

◆ GetOffset()

template<unsigned Dim>
int BrickCounter< Dim >::GetOffset ( unsigned d) const
inlineinherited

◆ GetStride()

template<class T, unsigned Dim>
int CompressedBrickIterator< T, Dim >::GetStride ( int d) const
inline

Definition at line 168 of file CompressedBrickIterator.h.

References BrickIterator< T, Dim >::Strides.

Referenced by permute().

◆ IsCompressed()

template<class T, unsigned Dim>
bool CompressedBrickIterator< T, Dim >::IsCompressed ( ) const
inline

◆ MakeExpression()

template<class T, unsigned Dim>
PETE_Expr_t BrickIterator< T, Dim >::MakeExpression ( ) const
inlineinherited

Definition at line 176 of file BrickIterator.h.

◆ moveBy() [1/4]

template<class T, unsigned Dim>
void BrickIterator< T, Dim >::moveBy ( const int * i)
inlineinherited

Definition at line 153 of file BrickIterator.h.

References BrickCounter< Dim >::Counters, Current, Dim, and Strides.

◆ moveBy() [2/4]

◆ moveBy() [3/4]

template<class T, unsigned Dim>
void BrickIterator< T, Dim >::moveBy ( int i,
int j )
inlineinherited

Definition at line 140 of file BrickIterator.h.

References BrickCounter< Dim >::Counters, Current, and Strides.

◆ moveBy() [4/4]

template<class T, unsigned Dim>
void BrickIterator< T, Dim >::moveBy ( int i,
int j,
int k )
inlineinherited

Definition at line 146 of file BrickIterator.h.

References BrickCounter< Dim >::Counters, Current, and Strides.

◆ offset() [1/4]

template<class T, unsigned Dim>
T & BrickIterator< T, Dim >::offset ( int * i) const
inlineinherited

Definition at line 119 of file BrickIterator.h.

References Current, vec< T, Length >::dot(), and Strides.

Here is the call graph for this function:

◆ offset() [2/4]

template<class T, unsigned Dim>
T & BrickIterator< T, Dim >::offset ( int i) const
inlineinherited

Definition at line 107 of file BrickIterator.h.

References Current, and Strides.

Referenced by all_values_equal(), all_values_equal(), all_values_equal(), FieldDebugWriteb(), for_each(), for_each(), for_each(), for_each(), IntCICImpl< 1U >::gather(), IntCICImpl< 1U >::gather(), IntCICImpl< 1U >::gather(), IntCICImpl< 2U >::gather(), IntCICImpl< 2U >::gather(), IntCICImpl< 2U >::gather(), IntCICImpl< 2U >::gather(), IntCICImpl< 3U >::gather(), IntCICImpl< 3U >::gather(), IntCICImpl< 3U >::gather(), IntCICImpl< 3U >::gather(), IntSUDSImpl< 1U >::gather(), IntSUDSImpl< 1U >::gather(), IntSUDSImpl< 1U >::gather(), IntSUDSImpl< 2U >::gather(), IntSUDSImpl< 2U >::gather(), IntSUDSImpl< 2U >::gather(), IntSUDSImpl< 3U >::gather(), IntSUDSImpl< 3U >::gather(), IntSUDSImpl< 3U >::gather(), IntTSCImpl< 1U >::gather(), IntTSCImpl< 1U >::gather(), IntTSCImpl< 1U >::gather(), IntTSCImpl< 2U >::gather(), IntTSCImpl< 2U >::gather(), IntTSCImpl< 2U >::gather(), IntTSCImpl< 3U >::gather(), IntTSCImpl< 3U >::gather(), IntTSCImpl< 3U >::gather(), IntCICImpl< 1U >::scatter(), IntCICImpl< 1U >::scatter(), IntCICImpl< 1U >::scatter(), IntCICImpl< 2U >::scatter(), IntCICImpl< 2U >::scatter(), IntCICImpl< 2U >::scatter(), IntCICImpl< 2U >::scatter(), IntCICImpl< 3U >::scatter(), IntCICImpl< 3U >::scatter(), IntCICImpl< 3U >::scatter(), IntCICImpl< 3U >::scatter(), IntSUDSImpl< 1U >::scatter(), IntSUDSImpl< 1U >::scatter(), IntSUDSImpl< 1U >::scatter(), IntSUDSImpl< 2U >::scatter(), IntSUDSImpl< 2U >::scatter(), IntSUDSImpl< 2U >::scatter(), IntSUDSImpl< 3U >::scatter(), IntSUDSImpl< 3U >::scatter(), IntSUDSImpl< 3U >::scatter(), IntTSCImpl< 1U >::scatter(), IntTSCImpl< 1U >::scatter(), IntTSCImpl< 1U >::scatter(), IntTSCImpl< 2U >::scatter(), IntTSCImpl< 2U >::scatter(), IntTSCImpl< 2U >::scatter(), IntTSCImpl< 3U >::scatter(), IntTSCImpl< 3U >::scatter(), and IntTSCImpl< 3U >::scatter().

◆ offset() [3/4]

template<class T, unsigned Dim>
T & BrickIterator< T, Dim >::offset ( int i,
int j ) const
inlineinherited

Definition at line 111 of file BrickIterator.h.

References Current, and Strides.

◆ offset() [4/4]

template<class T, unsigned Dim>
T & BrickIterator< T, Dim >::offset ( int i,
int j,
int k ) const
inlineinherited

Definition at line 115 of file BrickIterator.h.

References Current, and Strides.

◆ op_pp()

template<class T, unsigned Dim>
void BrickIterator< T, Dim >::op_pp ( )
protectedinherited

Definition at line 111 of file BrickIterator.hpp.

References BrickCounter< Dim >::Counters, BrickCounter< Dim >::Counts, Current, Dim, rewind(), and step().

Referenced by operator++().

Here is the call graph for this function:

◆ operator!=()

template<class T, unsigned Dim>
bool BrickIterator< T, Dim >::operator!= ( const BrickIterator< T, Dim > & a) const
inlineinherited

Definition at line 83 of file BrickIterator.h.

References a, BrickIterator(), and Current.

Here is the call graph for this function:

◆ operator*()

template<class T, unsigned Dim>
T & BrickIterator< T, Dim >::operator* ( ) const
inlineinherited

Definition at line 89 of file BrickIterator.h.

References Current.

Referenced by BareFieldIterator< T, Dim >::operator*().

◆ operator++()

template<class T, unsigned Dim>
BrickIterator & BrickIterator< T, Dim >::operator++ ( )
inlineinherited

Definition at line 73 of file BrickIterator.h.

References BrickIterator(), and op_pp().

Here is the call graph for this function:

◆ operator=()

template<class T, unsigned Dim>
const CompressedBrickIterator< T, Dim > & CompressedBrickIterator< T, Dim >::operator= ( const CompressedBrickIterator< T, Dim > & rhs)

Definition at line 325 of file CompressedBrickIterator.hpp.

References BrickIterator< T, Dim >::BrickIterator(), CompressedBrickIterator(), and CompressedData.

Here is the call graph for this function:

◆ operator==()

template<class T, unsigned Dim>
bool BrickIterator< T, Dim >::operator== ( const BrickIterator< T, Dim > & a) const
inlineinherited

Definition at line 79 of file BrickIterator.h.

References a, BrickIterator(), and Current.

Here is the call graph for this function:

◆ permute() [1/6]

template<class T, unsigned Dim>
CompressedBrickIterator< T, 1 > CompressedBrickIterator< T, Dim >::permute ( NDIndex< Dim > & current,
NDIndex< 1 > & permuted ) const
inline

Definition at line 146 of file CompressedBrickIterator.h.

Referenced by IndexedLocalAssign(), and IndexedSend().

◆ permute() [2/6]

template<class T, unsigned Dim>
CompressedBrickIterator< T, 2 > CompressedBrickIterator< T, Dim >::permute ( NDIndex< Dim > & current,
NDIndex< 2 > & permuted ) const
inline

Definition at line 149 of file CompressedBrickIterator.h.

◆ permute() [3/6]

template<class T, unsigned Dim>
CompressedBrickIterator< T, 3 > CompressedBrickIterator< T, Dim >::permute ( NDIndex< Dim > & current,
NDIndex< 3 > & permuted ) const
inline

Definition at line 152 of file CompressedBrickIterator.h.

◆ permute() [4/6]

template<class T, unsigned Dim>
CompressedBrickIterator< T, 4 > CompressedBrickIterator< T, Dim >::permute ( NDIndex< Dim > & current,
NDIndex< 4 > & permuted ) const
inline

Definition at line 155 of file CompressedBrickIterator.h.

◆ permute() [5/6]

template<class T, unsigned Dim>
CompressedBrickIterator< T, 5 > CompressedBrickIterator< T, Dim >::permute ( NDIndex< Dim > & current,
NDIndex< 5 > & permuted ) const
inline

Definition at line 158 of file CompressedBrickIterator.h.

◆ permute() [6/6]

template<class T, unsigned Dim>
CompressedBrickIterator< T, 6 > CompressedBrickIterator< T, Dim >::permute ( NDIndex< Dim > & current,
NDIndex< 6 > & permuted ) const
inline

Definition at line 161 of file CompressedBrickIterator.h.

◆ putMessage()

template<class T, unsigned Dim>
Message & CompressedBrickIterator< T, Dim >::putMessage ( Message & m,
bool makecopy = true )

Definition at line 220 of file CompressedBrickIterator.hpp.

References BrickIterator< T, Dim >::Current, Dim, IsCompressed(), Message::put(), BrickIterator< T, Dim >::putMessage(), putMessage(), and BrickCounter< Dim >::size().

Referenced by FieldDataSource< T, Dim, M, C >::gather_data(), and IndexedSend().

Here is the call graph for this function:

◆ ResetCounter()

template<class T, unsigned Dim>
void CompressedBrickIterator< T, Dim >::ResetCounter ( int d)
inline

Definition at line 166 of file CompressedBrickIterator.h.

References BrickCounter< Dim >::Counters.

◆ rewind()

template<class T, unsigned Dim>
void BrickIterator< T, Dim >::rewind ( unsigned d)
inlineinherited

Definition at line 100 of file BrickIterator.h.

References BrickCounter< Dim >::Counts, Current, BrickCounter< Dim >::rewind(), and Strides.

Referenced by for_each(), for_each(), for_each(), and op_pp().

Here is the call graph for this function:

◆ SetCompressedData()

template<class T, unsigned Dim>
void CompressedBrickIterator< T, Dim >::SetCompressedData ( T * newData)
inline

Definition at line 170 of file CompressedBrickIterator.h.

References CompressedData.

◆ SetCount()

template<class T, unsigned Dim>
void CompressedBrickIterator< T, Dim >::SetCount ( int d,
int count )
inline

Definition at line 165 of file CompressedBrickIterator.h.

References BrickCounter< Dim >::Counts.

◆ SetCurrent()

template<class T, unsigned Dim>
void CompressedBrickIterator< T, Dim >::SetCurrent ( T * p)
inline

Definition at line 164 of file CompressedBrickIterator.h.

References BrickIterator< T, Dim >::Current.

◆ SetStride()

template<class T, unsigned Dim>
void CompressedBrickIterator< T, Dim >::SetStride ( int d,
int stride )
inline

Definition at line 167 of file CompressedBrickIterator.h.

References BrickIterator< T, Dim >::Strides.

◆ size()

template<unsigned Dim>
int BrickCounter< Dim >::size ( unsigned d) const
inlineinherited

◆ step()

template<class T, unsigned Dim>
void BrickIterator< T, Dim >::step ( unsigned d)
inlineinherited

Definition at line 95 of file BrickIterator.h.

References Current, BrickCounter< Dim >::step(), and Strides.

Referenced by all_values_equal(), for_each(), for_each(), for_each(), and op_pp().

Here is the call graph for this function:

◆ Stride()

template<class T, unsigned Dim>
int BrickIterator< T, Dim >::Stride ( int i) const
inlineinherited

Definition at line 160 of file BrickIterator.h.

References Strides.

Referenced by for_each(), for_each(), and for_each().

◆ TryCompress() [1/2]

template<class T, unsigned Dim>
bool CompressedBrickIterator< T, Dim >::TryCompress ( )
inline

Definition at line 114 of file CompressedBrickIterator.h.

References TryCompress().

Referenced by BareField< T, Dim >::accumGuardCells(), assign(), IndexedSend(), FieldDebugPrint< T, Dim >::print(), FieldPrint< T, Dim >::print(), and TryCompress().

Here is the call graph for this function:

◆ TryCompress() [2/2]

template<class T, unsigned Dim>
bool CompressedBrickIterator< T, Dim >::TryCompress ( T val)

Definition at line 385 of file CompressedBrickIterator.hpp.

References CanCompress(), Compress(), and IsCompressed().

Here is the call graph for this function:

◆ unit_offset() [1/3]

template<class T, unsigned Dim>
T & BrickIterator< T, Dim >::unit_offset ( int i) const
inlineinherited

Definition at line 123 of file BrickIterator.h.

References Current.

Referenced by for_each(), and for_each().

◆ unit_offset() [2/3]

template<class T, unsigned Dim>
T & BrickIterator< T, Dim >::unit_offset ( int i,
int j ) const
inlineinherited

Definition at line 127 of file BrickIterator.h.

References Current, and Strides.

◆ unit_offset() [3/3]

template<class T, unsigned Dim>
T & BrickIterator< T, Dim >::unit_offset ( int i,
int j,
int k ) const
inlineinherited

Definition at line 131 of file BrickIterator.h.

References Current, and Strides.

◆ whole()

template<class T, unsigned Dim>
bool BrickIterator< T, Dim >::whole ( ) const
inlineinherited

Definition at line 76 of file BrickIterator.h.

References Whole.

Referenced by putMessage(), and DiscField< Dim >::write_offset_and_data().

Member Data Documentation

◆ CompressedData

◆ Counters

◆ Counts

◆ Current

◆ Strides

◆ Whole

template<class T, unsigned Dim>
bool BrickIterator< T, Dim >::Whole
protectedinherited

Definition at line 182 of file BrickIterator.h.

Referenced by BrickIterator(), BrickIterator(), BrickIterator(), and whole().


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