This class abstracts the semantics of a butterfly-based allreduce skeleton by exposing only the necessary information in its representation. More...
Public Member Functions | |
allreduce (Op const &op) | |
Op | get_op () const |
Public Types | |
using | skeleton_tag_type = tags::allreduce< tags::butterfly< false > > |
using | base_type = decltype(skeletons::compose(skeletons::reduce_to_pow_two< Span >(std::declval< Op >()), skeletons::butterfly< false, stapl::use_default, spans::nearest_pow_two< Span > >(std::declval< Op >()), skeletons::expand_from_pow_two< Span >(stapl::identity_op()))) |
This class abstracts the semantics of a butterfly-based allreduce skeleton by exposing only the necessary information in its representation.
A butterfly-based allreduce skeleton can handle only inputs of power-of-two sizes.
This abstraction not only makes the reconstruction of an butterfly-based allreduce skeleton easier, but also provides access to the underlying operations of the enclosed reduction operation. Furthermore, it reduces the symbol size for an allreduce skeleton, hence, reducing the total compilation time.
Op | the operation to be used while reducing the input. |
Span | the iteration space for elements on each level of both the reduction and the broadcast tree. |