Skip to content

Commit 25bdd11

Browse files
committed
MTL_OFI: Changed Recv cancel to be non-blocking
Updated the OFI MTL's Recv cancel to be a non-blocking call to match the MPI spec. Given fi_cancel succeeded, then it is expected that the user will wait on the request to read the result of if the cancel has completed. Signed-off-by: Spruit, Neil R <neil.r.spruit@intel.com
1 parent 8e83f95 commit 25bdd11

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

ompi/mca/mtl/ofi/mtl_ofi.h

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1197,14 +1197,8 @@ ompi_mtl_ofi_cancel(struct mca_mtl_base_module_t *mtl,
11971197
ret = fi_cancel((fid_t)ompi_mtl_ofi.ofi_ctxt[ctxt_id].rx_ep,
11981198
&ofi_req->ctx);
11991199
if (0 == ret) {
1200-
/**
1201-
* Wait for the request to be cancelled.
1202-
*/
1203-
while (!ofi_req->super.ompi_req->req_status._cancelled) {
1204-
opal_progress();
1205-
if (ofi_req->req_started)
1206-
goto ofi_cancel_not_possible;
1207-
}
1200+
if (ofi_req->req_started)
1201+
goto ofi_cancel_not_possible;
12081202
} else {
12091203
ofi_cancel_not_possible:
12101204
/**

0 commit comments

Comments
 (0)