Asynchronous (coroutine) interface to coll::AllGather.
More...
#include <allgather.hpp>
Public Types | |
| using | Ordered = rapidsmpf::coll::AllGather::Ordered |
| Tag requesting ordering for extraction. More... | |
Public Member Functions | |
| AllGather (std::shared_ptr< Context > ctx, std::shared_ptr< Communicator > comm, OpID op_id) | |
| Construct an asynchronous allgather. More... | |
| AllGather (AllGather const &)=delete | |
| AllGather & | operator= (AllGather const &)=delete |
| AllGather (AllGather &&)=delete | |
| AllGather & | operator= (AllGather &&)=delete |
| std::shared_ptr< Context > const & | ctx () const noexcept |
| Gets the streaming context associated with this AllGather object. More... | |
| std::shared_ptr< Communicator > const & | comm () const noexcept |
| Gets the communicator associated with this AllGather. More... | |
| void | insert (std::uint64_t sequence_number, PackedData &&chunk) |
| Insert a chunk into the allgather. More... | |
| void | insert_finished () |
| Mark that this rank has finished contributing data. More... | |
| coro::task< std::vector< PackedData > > | extract_all (Ordered ordered=Ordered::YES) |
| Extract all gathered data. More... | |
Asynchronous (coroutine) interface to coll::AllGather.
Once the AllGather is created, many tasks may insert data into it. If multiple tasks insert data, the user is responsible for arranging that insert_finished is only called after all insertions have completed. A single consumer task should extract data.
Definition at line 31 of file allgather.hpp.
Tag requesting ordering for extraction.
Definition at line 34 of file allgather.hpp.
| rapidsmpf::streaming::AllGather::AllGather | ( | std::shared_ptr< Context > | ctx, |
| std::shared_ptr< Communicator > | comm, | ||
| OpID | op_id | ||
| ) |
Construct an asynchronous allgather.
| ctx | Streaming context |
| comm | Communicator for the collective operation. |
| op_id | Unique identifier for the allgather. |
|
noexcept |
Gets the communicator associated with this AllGather.
|
noexcept |
Gets the streaming context associated with this AllGather object.
| coro::task<std::vector<PackedData> > rapidsmpf::streaming::AllGather::extract_all | ( | Ordered | ordered = Ordered::YES | ) |
Extract all gathered data.
| ordered | If the extracted data should be ordered. If ordered, return data will be ordered first by rank and then by sequence number of the inserted chunks on that rank. |
| void rapidsmpf::streaming::AllGather::insert | ( | std::uint64_t | sequence_number, |
| PackedData && | chunk | ||
| ) |
Insert a chunk into the allgather.
| sequence_number | The sequence number for this chunk. |
| chunk | The chunk to insert. |
| void rapidsmpf::streaming::AllGather::insert_finished | ( | ) |
Mark that this rank has finished contributing data.