cuda::experimental::stf::place_partition#
-
class place_partition#
Get subsets of an execution place.
This computes a vector of execution places which are the partition of the input execution place divided with a specific partitioning granularity. One may partition a place into devices, or green contexts, for example.
An iterator is provided to dispatch computation over the subplaces.
Public Types
-
using iterator = ::std::vector<exec_place>::iterator#
Public Functions
- inline place_partition(
- async_resources_handle &handle,
- exec_place place,
- place_partition_scope scope,
Partition an execution place into a vector of subplaces.
- async_resources_handle &handle,
- ::std::vector<::std::shared_ptr<exec_place>> places,
- place_partition_scope scope,
Partition a vector of execution places into a vector of subplaces.
-
~place_partition() = default#
-
inline size_t size() const#
Number of subplaces in the partition.
-
inline exec_place &get(size_t i)#
Get the i-th place.
-
inline const exec_place &get(size_t i) const#
Get the i-th place (const reference)
-
using iterator = ::std::vector<exec_place>::iterator#