SpECTRE  v2024.09.29
Parallel::ArrayIndex< Index > Struct Template Reference

The array index used for indexing Chare Arrays, mostly an implementation detail. More...

#include <ArrayIndex.hpp>

Public Member Functions

 ArrayIndex (const Index &array_index)
 
 ArrayIndex (const CkArrayIndex &array_index)
 
 ArrayIndex (const ArrayIndex &rhs)=delete
 
ArrayIndexoperator= (const ArrayIndex &rhs)=delete
 
 ArrayIndex (ArrayIndex &&)=delete
 
ArrayIndexoperator= (ArrayIndex &&)=delete
 
const Indexget_index () const
 

Detailed Description

template<class Index>
struct Parallel::ArrayIndex< Index >

The array index used for indexing Chare Arrays, mostly an implementation detail.

The implementation is generic and can handle custom array indices. This replaces the generated, hard-coded Charm++ array indices with a template, allowing a single implementation to be used for different array indices.

Details

Charm++ allocates memory for CkArrayIndex. The size can be configured (in the Charm++ configuration) and defaults to the size of three integers. We place the Index into this buffer using placement new. Then, CkArrayIndex::data() can be safely reinterpreted as an Index*.


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