Expand description
Typed scope guard around ncclGroupStart / ncclGroupEnd.
Usage at the world level:
ⓘ
NcclWorld::group(|w| {
w.send(buf, peer)?;
w.recv(buf2, peer)?;
Ok(())
})?;At the actor level (one rank), GroupGuard issues group_start
on construction and group_end on Drop (or on commit()),
while emitting BeginGroup / EndGroup markers via a tracker so
tests can assert the begin/end pair fires exactly once.
Structs§
- Group
Guard - RAII scope guard for a group call on a single rank. Issues
ncclGroupStarton construction;ncclGroupEndonDropifcommit()was not called (errors logged but swallowed in Drop). - Group
Tracker - Counter of begin/end events. Tests construct one, hand it to a
GroupGuard, and assert the begin/end pair is balanced.