From 6c6e35bb40ca600695077f3a3618e9195d2411c9 Mon Sep 17 00:00:00 2001 From: Gilles Gouaillardet Date: Thu, 6 Oct 2016 15:03:06 +0900 Subject: [PATCH] ompi/communicator: silence warnings --- ompi/communicator/comm_cid.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/ompi/communicator/comm_cid.c b/ompi/communicator/comm_cid.c index 65493d7343..1abcef4f07 100644 --- a/ompi/communicator/comm_cid.c +++ b/ompi/communicator/comm_cid.c @@ -607,7 +607,7 @@ static int ompi_comm_allreduce_inter_nb (int *inbuf, int *outbuf, ompi_comm_allreduce_context_t *context; ompi_comm_request_t *request; ompi_request_t *subreq; - int local_rank, rsize, rc; + int local_rank, rc; if (!OMPI_COMM_IS_INTER (cid_context->comm)) { return MPI_ERR_COMM; @@ -627,7 +627,6 @@ static int ompi_comm_allreduce_inter_nb (int *inbuf, int *outbuf, request->context = &context->super; /* Allocate temporary arrays */ - rsize = ompi_comm_remote_size (intercomm); local_rank = ompi_comm_rank (intercomm); if (0 == local_rank) { @@ -700,12 +699,12 @@ static int ompi_comm_allreduce_inter_bcast (ompi_comm_request_t *request) ompi_comm_allreduce_context_t *context = (ompi_comm_allreduce_context_t *) request->context; ompi_communicator_t *comm = context->cid_context->comm->c_local_comm; ompi_request_t *subreq; - int scount = 0, rc; + int rc; /* both roots have the same result. broadcast to the local group */ rc = comm->c_coll.coll_ibcast (context->outbuf, context->count, MPI_INT, 0, comm, &subreq, comm->c_coll.coll_ibcast_module); - if (OMPI_SUCCESS != rc) { + if (OPAL_UNLIKELY(OMPI_SUCCESS != rc)) { return rc; }