Skip to content

Commit

Permalink
fix(tuner): fix implicit conversions
Browse files Browse the repository at this point in the history
cpp requires explicit cast to double here.

stack-info: PR: #573, branch: aws-nslick/stack/20
  • Loading branch information
aws-nslick committed Sep 4, 2024
1 parent 21ab1dd commit 5eb7499
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/tuner/nccl_ofi_tuner.c
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,7 @@ ncclResult_t nccl_ofi_tuner_get_coll_info(void *context,
int in_out = -1;
int algorithm = NCCL_ALGO_UNDEF;
int protocol = NCCL_PROTO_UNDEF;
nccl_ofi_tuner_point_t p = {.x = nBytes, .y = nccl_ofi_tuner_ctx->dims.num_ranks};
nccl_ofi_tuner_point_t p = {.x = (double)nBytes, .y = (double)nccl_ofi_tuner_ctx->dims.num_ranks};

/* Check all regions */
for (size_t i = 0; i < nccl_ofi_tuner_ctx->num_regions && in_out < 0; i++) {
Expand Down Expand Up @@ -409,7 +409,7 @@ ncclResult_t nccl_ofi_tuner_get_coll_info_v2(
}

int in_out = -1;
nccl_ofi_tuner_point_t p = {.x = nBytes, .y = nccl_ofi_tuner_ctx->dims.num_ranks};
nccl_ofi_tuner_point_t p = {.x = (double)nBytes, .y = (double)nccl_ofi_tuner_ctx->dims.num_ranks};

/* Check all regions */
for (size_t i = 0; i < nccl_ofi_tuner_ctx->num_regions && in_out < 0; i++) {
Expand Down

0 comments on commit 5eb7499

Please sign in to comment.