diff --git a/src/coll_patterns/recursive_knomial.h b/src/coll_patterns/recursive_knomial.h index 298a7a78ad..4f5d2ac672 100644 --- a/src/coll_patterns/recursive_knomial.h +++ b/src/coll_patterns/recursive_knomial.h @@ -1,5 +1,5 @@ /** - * Copyright (c) 2021-2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved. + * Copyright (c) 2021-2024, NVIDIA CORPORATION & AFFILIATES. All rights reserved. * * See file LICENSE for terms. */ diff --git a/src/components/ec/cpu/ec_cpu.c b/src/components/ec/cpu/ec_cpu.c index df0dc3779f..2ce75baf07 100644 --- a/src/components/ec/cpu/ec_cpu.c +++ b/src/components/ec/cpu/ec_cpu.c @@ -1,5 +1,5 @@ /** - * Copyright (c) 2022, NVIDIA CORPORATION & AFFILIATES. All rights reserved. + * Copyright (c) 2022-2024, NVIDIA CORPORATION & AFFILIATES. All rights reserved. * * See file LICENSE for terms. */ diff --git a/src/components/tl/ucp/tl_ucp_team.c b/src/components/tl/ucp/tl_ucp_team.c index 8600eda5d9..4bde47430c 100644 --- a/src/components/tl/ucp/tl_ucp_team.c +++ b/src/components/tl/ucp/tl_ucp_team.c @@ -1,5 +1,5 @@ /** - * Copyright (c) 2020-2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved. + * Copyright (c) 2020-2024, NVIDIA CORPORATION & AFFILIATES. All rights reserved. * * See file LICENSE for terms. */ @@ -47,6 +47,7 @@ UCC_CLASS_INIT_FUNC(ucc_tl_ucp_team_t, ucc_base_context_t *tl_context, ucc_tl_ucp_context_t *ctx = ucc_derived_of(tl_context, ucc_tl_ucp_context_t); ucc_kn_radix_t max_radix, min_radix; + ucc_rank_t tsize; ucc_status_t status; UCC_CLASS_CALL_SUPER_INIT(ucc_tl_team_t, &ctx->super, params); @@ -91,14 +92,11 @@ UCC_CLASS_INIT_FUNC(ucc_tl_ucp_team_t, ucc_base_context_t *tl_context, } if (self->topo && !IS_SERVICE_TEAM(self) && self->topo->topo->sock_bound) { - max_radix = ucc_min(UCC_TL_TEAM_SIZE(self), - ucc_topo_max_ppn(self->topo) == 1 ? - UCC_TL_TEAM_SIZE(self): - ucc_topo_min_socket_size(self->topo)); - min_radix = ucc_min(UCC_TL_TEAM_SIZE(self), - ucc_topo_max_ppn(self->topo) == 1 ? 3: 2); - self->opt_radix = ucc_kn_get_opt_radix(UCC_TL_TEAM_SIZE(self), - min_radix, max_radix); + tsize = UCC_TL_TEAM_SIZE(self); + max_radix = (ucc_topo_max_ppn(self->topo) == 1) ? tsize : + ucc_min(tsize, ucc_topo_min_socket_size(self->topo)); + min_radix = ucc_min(tsize, ucc_topo_max_ppn(self->topo) == 1 ? 3: 2); + self->opt_radix = ucc_kn_get_opt_radix(tsize, min_radix, max_radix); tl_debug(tl_context->lib, "opt knomial radix: %d", self->opt_radix); }