MSCCL Algorithm

MSCCL Algorithm#

Rocprofiler SDK Developer API: MSCCL Algorithm
Rocprofiler SDK Developer API 0.6.0
ROCm Profiling API and tools
MSCCL Algorithm

API calls relating to the optional MSCCL algorithm datapath. More...

Typedefs

typedef int mscclAlgoHandle_t
 Opaque handle to MSCCL algorithm.
 

Functions

ncclResult_t mscclLoadAlgo (const char *mscclAlgoFilePath, mscclAlgoHandle_t *mscclAlgoHandle, int rank)
 MSCCL Load Algorithm.
 
ncclResult_t mscclRunAlgo (const void *sendBuff, const unsigned long sendCounts[], const unsigned long sDisPls[], void *recvBuff, const unsigned long recvCounts[], const unsigned long rDisPls[], unsigned long count, ncclDataType_t dataType, int root, int peer, ncclRedOp_t op, mscclAlgoHandle_t mscclAlgoHandle, ncclComm_t comm, hipStream_t stream)
 MSCCL Run Algorithm.
 
ncclResult_t mscclUnloadAlgo (mscclAlgoHandle_t mscclAlgoHandle)
 MSCCL Unload Algorithm.
 

Detailed Description

API calls relating to the optional MSCCL algorithm datapath.

Typedef Documentation

◆ mscclAlgoHandle_t

typedef int mscclAlgoHandle_t

Opaque handle to MSCCL algorithm.

Definition at line 944 of file rccl.h.

Function Documentation

◆ mscclLoadAlgo()

ncclResult_t mscclLoadAlgo ( const char *  mscclAlgoFilePath,
mscclAlgoHandle_t mscclAlgoHandle,
int  rank 
)

MSCCL Load Algorithm.

Load MSCCL algorithm file specified in mscclAlgoFilePath and return its handle via mscclAlgoHandle. This API is expected to be called by MSCCL scheduler instead of end users.

Returns
Result code. See Result Codes for more details.
Parameters
[in]mscclAlgoFilePathPath to MSCCL algorithm file
[out]mscclAlgoHandleReturned handle to MSCCL algorithm
[in]rankCurrent rank

◆ mscclRunAlgo()

ncclResult_t mscclRunAlgo ( const void *  sendBuff,
const unsigned long  sendCounts[],
const unsigned long  sDisPls[],
void *  recvBuff,
const unsigned long  recvCounts[],
const unsigned long  rDisPls[],
unsigned long  count,
ncclDataType_t  dataType,
int  root,
int  peer,
ncclRedOp_t  op,
mscclAlgoHandle_t  mscclAlgoHandle,
ncclComm_t  comm,
hipStream_t  stream 
)

MSCCL Run Algorithm.

Run MSCCL algorithm specified by mscclAlgoHandle. The parameter list merges all possible parameters required by different operations as this is a general-purposed API. This API is expected to be called by MSCCL scheduler instead of end users.

Returns
Result code. See Result Codes for more details.
Parameters
[in]sendBuffData array to send
[in]sendCountsArray containing number of elements to send to each participating rank
[in]sDisPlsArray of offsets into sendbuff for each participating rank
[out]recvBuffData array to receive
[in]recvCountsArray containing number of elements to receive from each participating rank
[in]rDisPlsArray of offsets into recvbuff for each participating rank
[in]countNumber of elements
[in]dataTypeData buffer element datatype
[in]rootRoot rank index
[in]peerPeer rank index
[in]opReduction operator
[in]mscclAlgoHandleHandle to MSCCL algorithm
[in]commCommunicator group object to execute on
[in]streamHIP stream to execute collective on

◆ mscclUnloadAlgo()

ncclResult_t mscclUnloadAlgo ( mscclAlgoHandle_t  mscclAlgoHandle)

MSCCL Unload Algorithm.

Unload MSCCL algorithm previous loaded using its handle. This API is expected to be called by MSCCL scheduler instead of end users.

Returns
Result code. See Result Codes for more details.
Parameters
[in]mscclAlgoHandleHandle to MSCCL algorithm to unload