#include <msa-distArray.h>
Public Types | |
typedef MSA_CacheGroup< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE > | CacheGroup_t |
typedef CProxy_MSA_CacheGroup < ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE > | CProxy_CacheGroup_t |
typedef CProxy_MSA_PageArray < ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE > | CProxy_PageArray_t |
typedef ENTRY | T |
typedef ENTRY_OPS_CLASS | OPS |
typedef MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE > | thisMSA |
typedef MSAHandle< thisMSA > | Handle |
typedef MSARead< thisMSA > | Read |
typedef MSAAccum< thisMSA > | Accum |
typedef MSAWrite< thisMSA > | Write |
Public Member Functions | |
MSA3D () | |
virtual void | pup (PUP::er &p) |
MSA3D (unsigned x, unsigned y, unsigned z, unsigned int num_wrkrs, unsigned int maxBytes=MSA_DEFAULT_MAX_BYTES) | |
Create a completely new MSA array. | |
MSA3D (int xa_, int xb_, int ya_, int yb_, int za_, int zb_, unsigned int num_wrkrs, unsigned int maxBytes=MSA_DEFAULT_MAX_BYTES) | |
Create a completely new MSA array. | |
~MSA3D () | |
void | changePE () |
this function is supposed to be called when the thread/object using this array migrates to another PE. | |
const CProxy_CacheGroup_t & | getCacheGroup () const |
unsigned int | getNumEntriesPerPage () const |
unsigned int | index (unsigned x, unsigned y, unsigned z) |
unsigned int | getPageIndex (unsigned int idx) |
Return the page this entry is stored at. | |
unsigned int | getOffsetWithinPage (unsigned int idx) |
Return the offset, in entries, that this entry is stored at within a page. | |
void | enroll (int num_workers) |
void | enroll () |
ENTRY & | getPageBottom (unsigned int idx, MSA_Page_Fault_t accessMode) |
void | FreeMem () |
void | Prefetch (unsigned int start, unsigned int end) |
Non-blocking prefetch of entries from start to end, inclusive. | |
int | WaitAll () |
Block until all prefetched pages arrive. | |
void | Unlock () |
Unlock all locked pages. | |
void | Unlock (unsigned int start, unsigned int end) |
start and end are element indexes. | |
Write | getInitialWrite () |
Accum | getInitialAccum () |
Protected Member Functions | |
const ENTRY * | readablePage (unsigned int page) |
const ENTRY * | readablePage2 (unsigned int page) |
ENTRY * | writeablePage (unsigned int page, unsigned int offset) |
const ENTRY & | get (unsigned x, unsigned y, unsigned z) |
Return a read-only copy of the element at idx. | |
const ENTRY & | get2 (unsigned x, unsigned y, unsigned z) |
Return a read-only copy of the element at idx; ONLY WORKS WHEN ELEMENT IS ALREADY IN THE CACHE-- WILL SEGFAULT IF ELEMENT NOT ALREADY PRESENT. | |
ENTRY & | set (unsigned x, unsigned y, unsigned z) |
Return a writeable copy of the element at idx. | |
ENTRY & | accumulate (unsigned x, unsigned y, unsigned z) |
Fetch the ENTRY at idx to be accumulated. | |
void | accumulate (unsigned x, unsigned y, unsigned z, const ENTRY &ent) |
Add ent to the element at idx. | |
void | sync (int single=0, bool clear=false) |
Synchronize reads and writes across the entire array. | |
Protected Attributes | |
unsigned int | nEntries |
Total number of ENTRY's in the whole array. | |
bool | initHandleGiven |
CacheGroup_t * | cache |
Handle to owner of cache. | |
CProxy_CacheGroup_t | cg |
Private Attributes | |
int | xa |
Inclusive lower and upper bounds on entry indices. | |
int | xb |
int | ya |
int | yb |
int | za |
int | zb |
unsigned | dim_x |
Size of the array in each dimension. | |
unsigned | dim_y |
unsigned | dim_z |
Friends | |
class | MSAHandle< thisMSA > |
class | MSARead< thisMSA > |
class | MSAWrite< thisMSA > |
class | MSAAccum< thisMSA > |
There are nEntries total numer of ENTRY's, with ENTRIES_PER_PAGE data items per "page". It is implemented as a Chare Array of pages, and a Group representing the local cache.
The requirements for the templates are: ENTRY: User data class stored in the array, with at least:
Definition at line 834 of file msa-distArray.h.
typedef MSA_CacheGroup<ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE> MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::CacheGroup_t |
Definition at line 842 of file msa-distArray.h.
typedef CProxy_MSA_CacheGroup<ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE> MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::CProxy_CacheGroup_t |
Definition at line 843 of file msa-distArray.h.
typedef CProxy_MSA_PageArray<ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE> MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::CProxy_PageArray_t |
Definition at line 844 of file msa-distArray.h.
typedef ENTRY MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::T |
Definition at line 846 of file msa-distArray.h.
typedef ENTRY_OPS_CLASS MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::OPS |
Definition at line 847 of file msa-distArray.h.
typedef MSA3D<ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE> MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::thisMSA |
Definition at line 848 of file msa-distArray.h.
typedef MSAHandle<thisMSA> MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::Handle |
Definition at line 849 of file msa-distArray.h.
typedef MSARead<thisMSA> MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::Read |
Definition at line 850 of file msa-distArray.h.
typedef MSAAccum<thisMSA> MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::Accum |
Definition at line 851 of file msa-distArray.h.
typedef MSAWrite<thisMSA> MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::Write |
Definition at line 852 of file msa-distArray.h.
MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::MSA3D | ( | ) | [inline] |
Definition at line 887 of file msa-distArray.h.
MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::MSA3D | ( | unsigned | x, | |
unsigned | y, | |||
unsigned | z, | |||
unsigned int | num_wrkrs, | |||
unsigned int | maxBytes = MSA_DEFAULT_MAX_BYTES | |||
) | [inline] |
Create a completely new MSA array.
This call creates the corresponding groups, so only call it once per array.
Valid indices lie in [0,x-1]*[0,y-1]*[0,z-1]
Definition at line 909 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cache, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cg, and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::nEntries.
MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::MSA3D | ( | int | xa_, | |
int | xb_, | |||
int | ya_, | |||
int | yb_, | |||
int | za_, | |||
int | zb_, | |||
unsigned int | num_wrkrs, | |||
unsigned int | maxBytes = MSA_DEFAULT_MAX_BYTES | |||
) | [inline] |
Create a completely new MSA array.
This call creates the corresponding groups, so only call it once per array.
Valid indices lie in [xa,xb]*[ya,yb]*[za,zb]
Definition at line 929 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cache, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cg, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::dim_x, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::dim_y, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::dim_z, and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::nEntries.
MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::~MSA3D | ( | ) | [inline] |
Definition at line 944 of file msa-distArray.h.
const ENTRY* MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::readablePage | ( | unsigned int | page | ) | [inline, protected] |
Definition at line 867 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cache, and MSA_CacheGroup< ENTRY_TYPE, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::readablePage().
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::get(), and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::getPageBottom().
const ENTRY* MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::readablePage2 | ( | unsigned int | page | ) | [inline, protected] |
Definition at line 873 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cache, and MSA_CacheGroup< ENTRY_TYPE, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::readablePage2().
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::get2().
ENTRY* MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::writeablePage | ( | unsigned int | page, | |
unsigned int | offset | |||
) | [inline, protected] |
Definition at line 880 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cache, and MSA_CacheGroup< ENTRY_TYPE, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::writeablePage().
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::getPageBottom(), and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::set().
virtual void MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::pup | ( | PUP::er & | p | ) | [inline, virtual] |
Definition at line 891 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cache, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cg, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::dim_x, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::dim_y, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::dim_z, PUP::er::isUnpacking(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::nEntries, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::xa, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::xb, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::ya, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::yb, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::za, and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::zb.
void MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::changePE | ( | ) | [inline] |
this function is supposed to be called when the thread/object using this array migrates to another PE.
Definition at line 958 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cache, and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cg.
const CProxy_CacheGroup_t& MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::getCacheGroup | ( | ) | const [inline] |
Definition at line 967 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cg.
unsigned int MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::getNumEntriesPerPage | ( | ) | const [inline] |
Definition at line 971 of file msa-distArray.h.
unsigned int MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::index | ( | unsigned | x, | |
unsigned | y, | |||
unsigned | z | |||
) | [inline] |
Definition at line 973 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::dim_x, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::dim_y, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::dim_z, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::xa, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::ya, and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::za.
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::accumulate(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::get(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::get2(), and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::set().
unsigned int MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::getPageIndex | ( | unsigned int | idx | ) | [inline] |
unsigned int MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::getOffsetWithinPage | ( | unsigned int | idx | ) | [inline] |
Return the offset, in entries, that this entry is stored at within a page.
Definition at line 991 of file msa-distArray.h.
void MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::enroll | ( | int | num_workers | ) | [inline] |
Definition at line 1004 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cache, and MSA_CacheGroup< ENTRY_TYPE, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::enroll().
void MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::enroll | ( | ) | [inline] |
Definition at line 1013 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cache, and MSA_CacheGroup< ENTRY_TYPE, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::enroll().
ENTRY& MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::getPageBottom | ( | unsigned int | idx, | |
MSA_Page_Fault_t | accessMode | |||
) | [inline] |
Definition at line 1022 of file msa-distArray.h.
References Accumulate_Fault, offset, Read_Fault, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::readablePage(), Write_Fault, and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::writeablePage().
void MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::FreeMem | ( | ) | [inline] |
Definition at line 1036 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cache, and MSA_CacheGroup< ENTRY_TYPE, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::FreeMem().
void MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::Prefetch | ( | unsigned int | start, | |
unsigned int | end | |||
) | [inline] |
Non-blocking prefetch of entries from start to end, inclusive.
Prefetch'd pages are locked into the cache, so you must call unlock afterwards.
Definition at line 1044 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cache, and MSA_CacheGroup< ENTRY_TYPE, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::Prefetch().
int MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::WaitAll | ( | ) | [inline] |
Block until all prefetched pages arrive.
Definition at line 1052 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cache, and MSA_CacheGroup< ENTRY_TYPE, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::WaitAll().
void MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::Unlock | ( | ) | [inline] |
Unlock all locked pages.
Definition at line 1055 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cache, and MSA_CacheGroup< ENTRY_TYPE, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::UnlockPages().
void MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::Unlock | ( | unsigned int | start, | |
unsigned int | end | |||
) | [inline] |
start and end are element indexes.
Unlocks completely spanned pages given a range of elements index'd from "start" to "end", inclusive. If start/end does not span a page completely, i.e. start/end is in the middle of a page, the entire page is still unlocked--in particular, this means you should not have several adjacent ranges locked.
Definition at line 1063 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cache, and MSA_CacheGroup< ENTRY_TYPE, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::UnlockPages().
Write MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::getInitialWrite | ( | ) | [inline] |
Definition at line 1070 of file msa-distArray.h.
References CmiAbort(), and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::initHandleGiven.
Accum MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::getInitialAccum | ( | ) | [inline] |
Definition at line 1079 of file msa-distArray.h.
References CmiAbort(), and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::initHandleGiven.
const ENTRY& MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::get | ( | unsigned | x, | |
unsigned | y, | |||
unsigned | z | |||
) | [inline, protected] |
Return a read-only copy of the element at idx.
May block if the element is not already in the cache.
Definition at line 1093 of file msa-distArray.h.
References idx, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::index(), offset, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::readablePage(), and x.
const ENTRY& MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::get2 | ( | unsigned | x, | |
unsigned | y, | |||
unsigned | z | |||
) | [inline, protected] |
Return a read-only copy of the element at idx; ONLY WORKS WHEN ELEMENT IS ALREADY IN THE CACHE-- WILL SEGFAULT IF ELEMENT NOT ALREADY PRESENT.
Never blocks; may crash if element not already present.
Definition at line 1105 of file msa-distArray.h.
References idx, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::index(), offset, and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::readablePage2().
ENTRY& MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::set | ( | unsigned | x, | |
unsigned | y, | |||
unsigned | z | |||
) | [inline, protected] |
Return a writeable copy of the element at idx.
Never blocks; will create a new blank element if none exists locally. UNDEFINED if two threads set the same element.
Definition at line 1116 of file msa-distArray.h.
References idx, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::index(), offset, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::writeablePage(), and x.
ENTRY& MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::accumulate | ( | unsigned | x, | |
unsigned | y, | |||
unsigned | z | |||
) | [inline, protected] |
Fetch the ENTRY at idx to be accumulated.
You must perform the accumulation on the return value before calling "sync". Never blocks.
Definition at line 1129 of file msa-distArray.h.
References MSA_CacheGroup< ENTRY_TYPE, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::accumulate(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cache, idx, MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::index(), and offset.
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::accumulate().
void MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::accumulate | ( | unsigned | x, | |
unsigned | y, | |||
unsigned | z, | |||
const ENTRY & | ent | |||
) | [inline, protected] |
Add ent to the element at idx.
Never blocks. Merges together accumulates from different threads.
Definition at line 1140 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::accumulate().
void MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::sync | ( | int | single = 0 , |
|
bool | clear = false | |||
) | [inline, protected] |
Synchronize reads and writes across the entire array.
Definition at line 1146 of file msa-distArray.h.
References MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cache, and MSA_CacheGroup< ENTRY_TYPE, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::SyncReq().
friend class MSAHandle< thisMSA > [friend] |
Definition at line 853 of file msa-distArray.h.
friend class MSARead< thisMSA > [friend] |
Definition at line 854 of file msa-distArray.h.
friend class MSAWrite< thisMSA > [friend] |
Definition at line 855 of file msa-distArray.h.
friend class MSAAccum< thisMSA > [friend] |
Definition at line 856 of file msa-distArray.h.
int MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::xa [private] |
Inclusive lower and upper bounds on entry indices.
Definition at line 837 of file msa-distArray.h.
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::index(), and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::pup().
int MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::xb [private] |
Definition at line 837 of file msa-distArray.h.
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::pup().
int MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::ya [private] |
Definition at line 837 of file msa-distArray.h.
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::index(), and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::pup().
int MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::yb [private] |
Definition at line 837 of file msa-distArray.h.
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::pup().
int MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::za [private] |
Definition at line 837 of file msa-distArray.h.
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::index(), and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::pup().
int MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::zb [private] |
Definition at line 837 of file msa-distArray.h.
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::pup().
unsigned MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::dim_x [private] |
Size of the array in each dimension.
Definition at line 839 of file msa-distArray.h.
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::index(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::MSA3D(), and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::pup().
unsigned MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::dim_y [private] |
Definition at line 839 of file msa-distArray.h.
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::index(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::MSA3D(), and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::pup().
unsigned MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::dim_z [private] |
Definition at line 839 of file msa-distArray.h.
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::index(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::MSA3D(), and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::pup().
unsigned int MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::nEntries [protected] |
Total number of ENTRY's in the whole array.
Definition at line 860 of file msa-distArray.h.
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::MSA3D(), and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::pup().
bool MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::initHandleGiven [protected] |
Definition at line 861 of file msa-distArray.h.
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::getInitialAccum(), and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::getInitialWrite().
CacheGroup_t* MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cache [protected] |
Handle to owner of cache.
Definition at line 864 of file msa-distArray.h.
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::accumulate(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::changePE(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::enroll(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::FreeMem(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::MSA3D(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::Prefetch(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::pup(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::readablePage(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::readablePage2(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::sync(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::Unlock(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::WaitAll(), and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::writeablePage().
CProxy_CacheGroup_t MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::cg [protected] |
Definition at line 865 of file msa-distArray.h.
Referenced by MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::changePE(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::getCacheGroup(), MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::MSA3D(), and MSA::MSA3D< ENTRY, ENTRY_OPS_CLASS, ENTRIES_PER_PAGE >::pup().