opal/common/ucx: replace opal_mutex_t with opal_recursive_mutex_t
Signed-off-by: Xin Zhao <xinz@mellanox.com>
Этот коммит содержится в:
родитель
aa26a724ed
Коммит
2d3cffe1a3
@ -57,7 +57,7 @@ _winfo_create(opal_common_ucx_wpool_t *wpool)
|
||||
goto release_worker;
|
||||
}
|
||||
|
||||
OBJ_CONSTRUCT(&winfo->mutex, opal_mutex_t);
|
||||
OBJ_CONSTRUCT(&winfo->mutex, opal_recursive_mutex_t);
|
||||
winfo->worker = worker;
|
||||
winfo->endpoints = NULL;
|
||||
winfo->comm_size = 0;
|
||||
@ -142,7 +142,7 @@ opal_common_ucx_wpool_init(opal_common_ucx_wpool_t *wpool,
|
||||
return rc;
|
||||
}
|
||||
|
||||
OBJ_CONSTRUCT(&wpool->mutex, opal_mutex_t);
|
||||
OBJ_CONSTRUCT(&wpool->mutex, opal_recursive_mutex_t);
|
||||
OBJ_CONSTRUCT(&wpool->tls_list, opal_list_t);
|
||||
|
||||
status = ucp_config_read("MPI", NULL, &config);
|
||||
@ -399,7 +399,7 @@ opal_common_ucx_wpctx_create(opal_common_ucx_wpool_t *wpool, int comm_size,
|
||||
|
||||
WPOOL_DBG_OUT(_dbg_ctx, "ctx_create: ctx = %p\n", (void*)ctx);
|
||||
|
||||
OBJ_CONSTRUCT(&ctx->mutex, opal_mutex_t);
|
||||
OBJ_CONSTRUCT(&ctx->mutex, opal_recursive_mutex_t);
|
||||
OBJ_CONSTRUCT(&ctx->tls_workers, opal_list_t);
|
||||
ctx->released = 0;
|
||||
ctx->refcntr = 1; /* application holding the context */
|
||||
|
@ -22,7 +22,7 @@ BEGIN_C_DECLS
|
||||
typedef struct {
|
||||
/* Ref counting & locking*/
|
||||
int refcnt;
|
||||
opal_mutex_t mutex;
|
||||
opal_recursive_mutex_t mutex;
|
||||
|
||||
/* UCX data */
|
||||
ucp_context_h ucp_ctx;
|
||||
@ -42,7 +42,7 @@ typedef struct {
|
||||
} opal_common_ucx_wpool_t;
|
||||
|
||||
typedef struct {
|
||||
opal_mutex_t mutex;
|
||||
opal_recursive_mutex_t mutex;
|
||||
opal_atomic_int32_t refcntr;
|
||||
|
||||
/* the reference to a Worker pool this context belongs to*/
|
||||
@ -79,7 +79,7 @@ typedef struct {
|
||||
} opal_common_ucx_wpmem_t;
|
||||
|
||||
typedef struct {
|
||||
opal_mutex_t mutex;
|
||||
opal_recursive_mutex_t mutex;
|
||||
volatile int released;
|
||||
ucp_worker_h worker;
|
||||
ucp_ep_h *endpoints;
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user