Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions config/algorithms/MPI/Cray-MPICH/alltoallv.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"default_mpich": {
"desc": "MPICH default algorithm selection",
"version": "8.0.0",
"constraints": [
{
"key": "count",
"conditions": [
{
"operator": ">=",
"value": "comm_sz"
}
]
}
],
"selection": "auto",
"tags": [
"default"
]
}
}
32 changes: 31 additions & 1 deletion config/algorithms/MPI/LibPico/alltoall.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,36 @@
"external"
]
},
"bine_dh_over": {
"desc": "LibPico external Alltoall algorithm . This algorithm follows the distance-halving Bine butterfly communication pattern described in the Bine paper.",
"version": "1.0.0",
"constraints": [
{
"key": "count",
"conditions": [
{
"operator": ">=",
"value": "comm_sz"
}
]
},
{
"key": "comm_sz",
"conditions": [
{
"operator": "is_power_of_two",
"value": true
}
]
}
],
"selection": "pico",
"tags": [
"bine",
"external",
"distance-halving"
]
},
"pairwise_ompi_over": {
"desc": "libpico pairwise algorithm, copied from Open MPI.",
"version": "1.0.0",
Expand Down Expand Up @@ -57,4 +87,4 @@
"external"
]
}
}
}
32 changes: 32 additions & 0 deletions config/algorithms/MPI/LibPico/alltoallv.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"bine_dh_over": {
"desc": "LibPico external Alltoall algorithm . This algorithm follows the distance-halving Bine butterfly communication pattern described in the Bine paper.",
"version": "1.0.0",
"constraints": [
{
"key": "count",
"conditions": [
{
"operator": ">=",
"value": "comm_sz"
}
]
},
{
"key": "comm_sz",
"conditions": [
{
"operator": "is_power_of_two",
"value": true
}
]
}
],
"selection": "pico",
"tags": [
"bine",
"external",
"distance-halving"
]
}
}
21 changes: 21 additions & 0 deletions config/algorithms/MPI/MPICH/alltoallv.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"default_mpich": {
"desc": "MPICH default Alltoallv algorithm selection",
"version": "4.3.0",
"constraints": [
{
"key": "count",
"conditions": [
{
"operator": ">=",
"value": "comm_sz"
}
]
}
],
"selection": "auto",
"tags": [
"default"
]
}
}
66 changes: 66 additions & 0 deletions config/algorithms/MPI/Open-MPI/alltoallv.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
{
"default_ompi": {
"desc": "Open MPI default Alltoallv algorithm selection.",
"version": "4.1.5",
"constraints": [
{
"key": "count",
"conditions": [
{
"operator": ">=",
"value": "comm_sz"
}
]
}
],
"selection": 0,
"cuda_support": "yes",
"rocm_support": "ucx",
"tags": [
"ignore"
]
},
"basic_linear_ompi": {
"desc": "Open MPI basic linear Alltoallv algorithm.",
"version": "4.1.5",
"constraints": [
{
"key": "count",
"conditions": [
{
"operator": ">=",
"value": "comm_sz"
}
]
}
],
"selection": 1,
"cuda_support": "yes",
"rocm_support": "ucx",
"tags": [
"basic_linear",
"linear"
]
},
"pairwise_ompi": {
"desc": "Open MPI pairwise Alltoallv algorithm.",
"version": "4.1.5",
"constraints": [
{
"key": "count",
"conditions": [
{
"operator": ">=",
"value": "comm_sz"
}
]
}
],
"selection": 2,
"cuda_support": "yes",
"rocm_support": "ucx",
"tags": [
"pairwise"
]
}
}
35 changes: 35 additions & 0 deletions config/algorithms/NCCL/LibPico/alltoallv.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{
"bine_dh_over": {
"desc": "LibPico external GPU-aware Alltoallv algorithm. This algorithm follows the distance-halving Bine butterfly communication pattern.",
"version": "1.0.0",
"constraints": [
{
"key": "count",
"conditions": [
{
"operator": ">=",
"value": "comm_sz"
}
]
},
{
"key": "comm_sz",
"conditions": [
{
"operator": "is_power_of_two",
"value": true
}
]
}
],
"selection": "pico",
"tags": [
"alltoallv",
"bine",
"cuda",
"gpu-aware",
"distance-halving",
"external"
]
}
}
65 changes: 65 additions & 0 deletions config/algorithms/NCCL/NCCL/alltoallv.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
{
"default_nccl_alltoallv": {
"desc": "Default NCCL-based Alltoallv implementation in PICO. Uses NCCL point-to-point communication with the default scheduling strategy selected by the benchmark code.",
"version": "2.7",
"selection": "default",
"tags": [
"alltoallv",
"nccl",
"gpu",
"p2p",
"default"
]
},
"grouped_p2p_nccl_alltoallv": {
"desc": "NCCL Alltoallv implemented with grouped ncclSend/ncclRecv calls. All peer sends and receives are issued inside ncclGroupStart/ncclGroupEnd to allow concurrent progress and avoid deadlocks.",
"version": "2.7",
"selection": "grouped_p2p",
"tags": [
"alltoallv",
"nccl",
"gpu",
"p2p",
"sendrecv",
"grouped"
]
},
"pairwise_nccl_alltoallv": {
"desc": "NCCL Alltoallv implemented as a pairwise schedule. Each round exchanges variable-size data with one peer using ncclSend/ncclRecv grouped together.",
"version": "2.7",
"selection": "pairwise",
"tags": [
"alltoallv",
"nccl",
"gpu",
"p2p",
"pairwise"
]
},
"linear_nccl_alltoallv": {
"desc": "NCCL Alltoallv implemented with a linear/fan-out schedule. Each rank communicates variable-size blocks with all peers through NCCL point-to-point operations.",
"version": "2.7",
"selection": "linear",
"tags": [
"alltoallv",
"nccl",
"gpu",
"p2p",
"linear",
"fanout"
]
},
"spreadout_nccl_alltoallv": {
"desc": "NCCL Alltoallv implemented with a spread-out schedule. Communication is organized in rounds so that each rank communicates with a different peer per round, reducing the number of concurrent peer exchanges.",
"version": "2.7",
"selection": "spreadout",
"tags": [
"alltoallv",
"nccl",
"gpu",
"p2p",
"spreadout",
"round-based"
]
}
}
2 changes: 1 addition & 1 deletion config/parse_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"type": "object",
"properties": {
"libpico_version": {"type": "string", "pattern": "^\\d+\\.\\d+\\.\\d+$"},
"collective": {"type": "string", "enum": ["ALLREDUCE", "ALLTOALL", "ALLGATHER", "BCAST", "GATHER", "REDUCE", "REDUCE_SCATTER", "SCATTER"]},
"collective": {"type": "string", "enum": ["ALLREDUCE", "ALLTOALL","ALLTOALLV", "ALLGATHER", "BCAST", "GATHER", "REDUCE", "REDUCE_SCATTER", "SCATTER"]},
"MPI_Op": {"type": "string"},
"tags": {
"type": "object",
Expand Down
16 changes: 16 additions & 0 deletions config/test/alltoallv.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"libpico_version": "1.0.0",
"collective": "ALLTOALLV",
"MPI_Op": "MPI_SUM",
"tags": {
"include": [
"internal",
"external"
],
"exclude": []
},
"specific": {
"include": [],
"exclude": []
}
}
5 changes: 5 additions & 0 deletions include/libpico.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@
void* rbuf, size_t rcount, MPI_Datatype rdtype, MPI_Comm comm
#define ALLTOALL_MPI_ARGS const void *sbuf, size_t scount, MPI_Datatype sdtype, \
void *rbuf, size_t rcount, MPI_Datatype rdtype, MPI_Comm comm
#define ALLTOALLV_MPI_ARGS const void *sbuf, const int scounts[], const int sdispls[], MPI_Datatype sdtype, \
void *rbuf, const int rcounts[], const int rdispls[], MPI_Datatype rdtype, MPI_Comm comm
#define BCAST_MPI_ARGS void *buf, size_t count, MPI_Datatype dtype, int root, MPI_Comm comm
#define GATHER_MPI_ARGS const void *sbuf, size_t scount, MPI_Datatype sdtype, \
void *rbuf, size_t rcount, MPI_Datatype rdtype, int root, MPI_Comm comm
Expand Down Expand Up @@ -92,6 +94,9 @@ int alltoall_bine(ALLTOALL_MPI_ARGS);
// int alltoall_nccl_custom(ALLTOALL_NCCL_ARGS)
#endif

int alltoallv_bine_DH(ALLTOALLV_MPI_ARGS);


int bcast_linear(BCAST_MPI_ARGS);
int bcast_binomial_halving(BCAST_MPI_ARGS);
int bcast_binomial_doubling(BCAST_MPI_ARGS);
Expand Down
Loading