Classes | Typedefs | Functions
rapidsmpf::coll::detail Namespace Reference

Classes

struct  HostOp
 Host-side range-based reduction operator. More...
 
struct  DeviceOp
 Device-side range-based reduction operator. More...
 
class  Chunk
 Represents a data chunk in the allgather operation. More...
 
class  PostBox
 A thread-safe container for managing chunks in collectives. More...
 

Typedefs

using ChunkID = std::uint64_t
 Type alias for chunk identifiers.
 

Functions

template<typename T , typename Op >
requires std::invocable< Op, T const &, T const & > ReduceOperator make_host_reduce_operator (Op op)
 Create a host-based reduction operator from a typed binary operation. More...
 
template<typename T , typename Op >
requires std::invocable< Op, T const &, T const & > ReduceOperator make_device_reduce_operator (Op op)
 Create a device-based reduction operator from a typed binary operation. More...
 
std::vector< std::unique_ptr< Chunk > > test_some (std::vector< std::unique_ptr< Chunk >> &chunks, std::vector< std::unique_ptr< Communicator::Future >> &futures, Communicator *comm)
 Complete posted chunk receives. More...
 

Detailed Description

SPDX-FileCopyrightText: Copyright (c) 2025-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. SPDX-License-Identifier: Apache-2.0

Function Documentation

◆ make_device_reduce_operator()

template<typename T , typename Op >
requires std::invocable<Op, T const&, T const&> ReduceOperator rapidsmpf::coll::detail::make_device_reduce_operator ( Op  op)

Create a device-based reduction operator from a typed binary operation.

Template Parameters
TThe element type.
OpThe binary operation type.
Parameters
opThe binary operation (e.g., cuda::std::plus<T>{}).
Returns
A ReduceOperator wrapping the DeviceOp.
Note
This function requires CUDA compilation (CUDACC defined) to be used. Attempting to use it without CUDA will result in a compilation error.

Definition at line 355 of file allreduce.hpp.

◆ make_host_reduce_operator()

template<typename T , typename Op >
requires std::invocable<Op, T const&, T const&> ReduceOperator rapidsmpf::coll::detail::make_host_reduce_operator ( Op  op)

Create a host-based reduction operator from a typed binary operation.

Template Parameters
TThe element type.
OpThe binary operation type.
Parameters
opThe binary operation (e.g., std::plus<T>{}).
Returns
A ReduceOperator wrapping the HostOp.

Definition at line 338 of file allreduce.hpp.

◆ test_some()

std::vector<std::unique_ptr<Chunk> > rapidsmpf::coll::detail::test_some ( std::vector< std::unique_ptr< Chunk >> &  chunks,
std::vector< std::unique_ptr< Communicator::Future >> &  futures,
Communicator comm 
)

Complete posted chunk receives.

Tests a set of outstanding communicator futures, and for every completed receive, reattaches the received data buffer to the corresponding chunk before returning it.

Parameters
chunksChunks with receives currently in flight.
futuresReceive futures corresponding 1:1 with chunks.
commCommunicator used to test and release completed receives.
Returns
The subset of chunks whose receives completed during this call.