Responsible for determining the home location for elements of the map container, specifically for discrete GID types.
More...
|
| map_manager (size_t block_size) |
| Create a manager with a given block size, which will be used to map GIDs to location in a blocked manner. More...
|
|
| map_manager (Partition const &ps, Mapper const &m) |
| Create a manager with a given partition and mapper. The block size will be determined by the size of the first partition. More...
|
|
template<typename PartitionContainer > |
| map_manager (PartitionContainer const *const part_cont, Partition const &partition, Mapper const &mapper) |
| Create a manager for an arbitrary distribution specified by the elements of part_cont and represented by the partition and mapper parameters. The block size will be determined by the size of the first partition. More...
|
|
std::pair< location_type, loc_qual > | operator() (gid_type const &index) const |
| Compute the home / manager location of a given GID. More...
|
|
map_result_type | operator() (std::pair< gid_type, gid_type > const &interval) const |
| Compute the home / manager location of a range of GIDs. More...
|
|
std::tuple< boost::icl::interval_set< index_type >, cid_type > | range_of (gid_type const &index) |
| For a given key, returns in which interval it is in.
|
|
Partition const & | partition (void) const |
|
Partition & | partition (void) |
|
void | partition (Partition const &p) |
|
Mapper const & | mapper (void) const |
|
Mapper & | mapper (void) |
|
void | mapper (Mapper const &m) |
|
template<typename Partition, typename Mapper>
class stapl::map_manager< Partition, Mapper, true, true >
Responsible for determining the home location for elements of the map container, specifically for discrete GID types.
This specialization operates on discrete key types, and supports the view-based partition class. The non-discrete implementation requires a partition class to provide the inverse mapping operation from a GID to the partition that contains it.
- Template Parameters
-
Partitioner | Used to specify how to partition the elements. |
Mapper | Maps the different partitions to the available locations. |
template<typename Partition , typename Mapper >
template<typename PartitionContainer >
stapl::map_manager< Partition, Mapper, true, true >::map_manager |
( |
PartitionContainer const *const |
part_cont, |
|
|
Partition const & |
partition, |
|
|
Mapper const & |
mapper |
|
) |
| |
Create a manager for an arbitrary distribution specified by the elements of part_cont
and represented by the partition
and mapper
parameters. The block size will be determined by the size of the first partition.
This constructor allows more efficient extraction of the partition information from the container specifying an arbitrary distribution than the element-wise extraction of the information that is performed by the detail::compute_local_domains() function when a view-based distribution that utilizes closed-form mapping functions is provided.
- Parameters
-
p | The partition of the container |
m | The mapper of the container |
template<typename Partition , typename Mapper >
Compute the home / manager location of a range of GIDs.
- Parameters
-
interval | A collection of GIDS to map, represented as a pair of GIDs defining the lower and upper boundary of a contiguous range. |
The range of GID provided in interval may not all be in the same bContainers, and as such may map into different cids. The cid information is used only to compute the home location, and shouldn't be mistaken as the attribute that determines when a new interval is needed. Only a change in the home location signifies the need of a new interval in the output map.
- Returns
- Return the computed home location as a map from intervals to locations