AMPI's non-blocking collectives are not sequenced
AMPI's non-blocking collectives should be sequenced/ordered just like non-blocking pt2pt messages are.
#1 Updated by Sam White over 2 years ago
Should be able to break this down into multiple parts:
1. Make the sequence number into the refnum instead of a member of AmpiMsg. This enables us to pass the seq num on CkReductionMsg's as well as AmpiMsg's.
2. Get message sequencing working for Broadcasts and Scatters since they use AmpiMsg's.
3. Refactor AmpiSeqQ to handle both AmpiMsg's and CkReductionMsg's in a common data structure.
4. Refactor AmpiSeqQ for collectives: AmpiOtherElement has incoming and outgoing counts, for collectives we only need 1 count (There may be some complications with intercomm's (some ranks send and don't receive).
C++17's std::variant should make implementing support for sequencing/matching of non-blocking collective messages easier, since both AmpIMsg's and CkReductionMsg's can use the RefNum for the sequence number alike, so we can store a std::variant<AmpiMsg, CkReductionMsg> msg type.