DASH
0.3.0
|
Concept of distributed dynamic global memory space shared by units in a specified team. More...
Classes | |
class | dash::GlobHeapMem< ElementType, LocalMemorySpace, AllocationPolicy, LocalAlloc > |
Global memory region with dynamic size. More... | |
Functions | |
dash::GlobHeapMem< ElementType, LocalMemorySpace, AllocationPolicy, LocalAlloc >::GlobHeapMem (size_type n_local_elem=0) | |
Constructor, collectively allocates the given number of elements in local memory of every unit in dash::Team::All(). More... | |
dash::GlobHeapMem< ElementType, LocalMemorySpace, AllocationPolicy, LocalAlloc >::GlobHeapMem (size_type n_local_elem, dash::Team &team) | |
Constructor, collectively allocates the given number of elements in local memory of every unit in a team. More... | |
dash::GlobHeapMem< ElementType, LocalMemorySpace, AllocationPolicy, LocalAlloc >::GlobHeapMem (size_type n_local_elem, LocalMemorySpace *r) | |
Constructor, collectively allocates the given number of elements in local memory of every unit in dash::Team::All(). More... | |
Concept of distributed dynamic global memory space shared by units in a specified team.
Extends the Global Memory concept by dynamic address spaces.
Units can change the capacity of the global memory space by resizing their own local segment of the global memory space. Resizing local memory segments (methods resize
, grow
and shrink
) is non-collective, however the resulting changes to local and global memory space are only immediately visible to the unit that executed the resize operation.
The collective operation commit
synchronizes changes on local memory spaces between all units such that new allocated memory segments are attached in global memory and deallocated segments detached, respectively.
Newly allocated memory segments are unattached and immediately accessible by the local unit only. Deallocated memory is immediately removed from the local unit's memory space but remains accessible for remote units.
Different from typical dynamic container semantics, neither resizing the memory space nor commit operations invalidate iterators to elements in allocated global memory. An iterators referencing a remote element in global dynamic memory is only invalidated in the commit
operation following the deallocation of the element's memory segment.
Type Name | Description |
---|---|
GlobalRAI | Random access iterator on global address space |
LocalRAI | Random access iterator on a single local address space |
Return Type | Method | Parameters | Description |
---|---|---|---|
void | resize | size lsize_new | Resize the local segment of the global memory space to the specified number of values. |
void | grow | size lsize_diff | Extend the size of the local segment of the global memory space by the specified number of values. |
void | shrink | size lsize_diff | Reduce the size of the local segment of the global memory space by the specified number of values. |
void | commit | nbsp; | Publish changes to local memory across all units. |
Return Type | Method | Parameters | Description |
---|---|---|---|
GlobalRAI | begin | Global pointer to the initial address of the global memory space | |
GlobalRAI | end | Global pointer past the final element in the global memory space | |
LocalRAI | lbegin | Local pointer to the initial address in the local segment of the global memory space | |
LocalRAI | lbegin | unit u | Local pointer to the initial address in the local segment at unit u of the global memory space |
LocalRAI | lend | Local pointer past the final element in the local segment of the global memory space | |
LocalRAI | lend | unit u | Local pointer past the final element in the local segment at unit u of the global memory space |
GlobalRAI | at | index gidx | Global pointer to the element at canonical global offset gidx in the global memory space |
void | put_value | value & v_in, index gidx | Stores value specified in parameter v_in to address in global memory at canonical global offset gidx |
void | get_value | value * v_out, index gidx | Loads value from address in global memory at canonical global offset gidx into local address v_out |
void | barrier | Blocking synchronization of all units associated with the global memory instance |
|
inline |
#include </tmp/tmporruphar/dash/include/dash/memory/GlobHeapMem.h>
Constructor, collectively allocates the given number of elements in local memory of every unit in dash::Team::All().
n_local_elem | Initial number of local elements to allocate in global memory space |
Definition at line 308 of file GlobHeapMem.h.
|
inline |
#include </tmp/tmporruphar/dash/include/dash/memory/GlobHeapMem.h>
Constructor, collectively allocates the given number of elements in local memory of every unit in a team.
n_local_elem | Initial number of local elements to allocate in global memory space |
team | The specified team |
Definition at line 322 of file GlobHeapMem.h.
|
inline |
#include </tmp/tmporruphar/dash/include/dash/memory/GlobHeapMem.h>
Constructor, collectively allocates the given number of elements in local memory of every unit in dash::Team::All().
The underlying memory space is specified by the resource which is passed in
n_local_elem | Initial number of local elements to allocate in global memory space |
r | The underlying local memory space |
Definition at line 339 of file GlobHeapMem.h.
References dash::GlobHeapMem< ElementType, LocalMemorySpace, AllocationPolicy, LocalAlloc >::commit(), dash::Team::dart_id(), dash::GlobHeapMem< ElementType, LocalMemorySpace, AllocationPolicy, LocalAlloc >::grow(), dash::Array< ElementType, IndexType, PatternType, LocalMemSpaceT >::local, dash::Team::size(), and dash::GlobHeapMem< ElementType, LocalMemorySpace, AllocationPolicy, LocalAlloc >::team().