Skip to content

Commit 4c442f2

Browse files
authored
Merge pull request #5934 from hoopoepg/topic/suppressed-cov-warn-added-log-msg
COMMON/UCX: suppressed coverity warnings
2 parents 6900249 + 1099d5f commit 4c442f2

File tree

4 files changed

+18
-4
lines changed

4 files changed

+18
-4
lines changed

ompi/mca/osc/ucx/osc_ucx_active_target.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,10 @@ int ompi_osc_ucx_complete(struct ompi_win_t *win) {
193193
OSC_UCX_VERBOSE(1, "ucp_atomic_post failed: %d", status);
194194
}
195195

196-
opal_common_ucx_ep_flush(ep, mca_osc_ucx_component.ucp_worker);
196+
ret = opal_common_ucx_ep_flush(ep, mca_osc_ucx_component.ucp_worker);
197+
if (OMPI_SUCCESS != ret) {
198+
OSC_UCX_VERBOSE(1, "opal_common_ucx_ep_flush failed: %d", ret);
199+
}
197200
}
198201

199202
OBJ_RELEASE(module->start_group);

ompi/mca/osc/ucx/osc_ucx_component.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -825,7 +825,10 @@ int ompi_osc_ucx_free(struct ompi_win_t *win) {
825825
ucp_worker_progress(mca_osc_ucx_component.ucp_worker);
826826
}
827827

828-
opal_common_ucx_worker_flush(mca_osc_ucx_component.ucp_worker);
828+
ret = opal_common_ucx_worker_flush(mca_osc_ucx_component.ucp_worker);
829+
if (OMPI_SUCCESS != ret) {
830+
OSC_UCX_VERBOSE(1, "opal_common_ucx_worker_flush failed: %d", ret);
831+
}
829832

830833
ret = module->comm->c_coll->coll_barrier(module->comm,
831834
module->comm->c_coll->coll_barrier_module);

ompi/mca/pml/ucx/pml_ucx_datatype.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ int mca_pml_ucx_datatype_attr_del_fn(ompi_datatype_t* datatype, int keyval,
133133
{
134134
ucp_datatype_t ucp_datatype = (ucp_datatype_t)attr_val;
135135

136-
PML_UCX_ASSERT((void*)ucp_datatype == datatype->pml_data);
136+
PML_UCX_ASSERT((uint64_t)ucp_datatype == datatype->pml_data);
137137

138138
ucp_dt_destroy(ucp_datatype);
139139
datatype->pml_data = PML_UCX_DATATYPE_INVALID;

opal/mca/common/ucx/common_ucx.c

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,8 @@ OPAL_DECLSPEC void opal_common_ucx_mca_var_register(const mca_base_component_t *
8080

8181
OPAL_DECLSPEC void opal_common_ucx_mca_register(void)
8282
{
83+
int ret;
84+
8385
opal_common_ucx.registered++;
8486
if (opal_common_ucx.registered > 1) {
8587
/* process once */
@@ -89,7 +91,13 @@ OPAL_DECLSPEC void opal_common_ucx_mca_register(void)
8991
opal_common_ucx.output = opal_output_open(NULL);
9092
opal_output_set_verbosity(opal_common_ucx.output, opal_common_ucx.verbose);
9193

92-
mca_base_framework_open(&opal_memory_base_framework, 0);
94+
ret = mca_base_framework_open(&opal_memory_base_framework, 0);
95+
if (OPAL_SUCCESS != ret) {
96+
/* failed to initialize memory framework - just exit */
97+
MCA_COMMON_UCX_VERBOSE(1, "failed to initialize memory base framework: %d, "
98+
"memory hooks will not be used", ret);
99+
return;
100+
}
93101

94102
/* Set memory hooks */
95103
if (opal_common_ucx.opal_mem_hooks &&

0 commit comments

Comments
 (0)