pub struct GroupGuard { /* private fields */ }Expand description
RAII scope guard for a group call on a single rank. Issues
ncclGroupStart on construction; ncclGroupEnd on Drop if
commit() was not called (errors logged but swallowed in Drop).
Implementations§
Source§impl GroupGuard
impl GroupGuard
Sourcepub fn begin(tracker: Option<Arc<GroupTracker>>) -> Result<Self, GpuError>
pub fn begin(tracker: Option<Arc<GroupTracker>>) -> Result<Self, GpuError>
Begin a group. If tracker is Some, increments
tracker.begins on construction and tracker.ends on the
matching end.
Sourcepub fn begin_inert(tracker: Option<Arc<GroupTracker>>) -> Self
pub fn begin_inert(tracker: Option<Arc<GroupTracker>>) -> Self
Begin a group without invoking NCCL — for tests on hosts without a working NCCL install. Bumps the tracker but issues no FFI call.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for GroupGuard
impl RefUnwindSafe for GroupGuard
impl Send for GroupGuard
impl Sync for GroupGuard
impl Unpin for GroupGuard
impl UnsafeUnpin for GroupGuard
impl UnwindSafe for GroupGuard
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more