add support for connection private data, off by default
This commit was SVN r14878.
Этот коммит содержится в:
родитель
42c74b2cf7
Коммит
8ecbc71ed2
@ -79,6 +79,7 @@ struct mca_btl_udapl_component_t {
|
||||
int32_t udapl_eager_rdma_win; /**< number of eager RDMA fragments
|
||||
recieved before returning credits to
|
||||
sender */
|
||||
int32_t udapl_conn_priv_data; /**< use connect priv data for proc data */
|
||||
int32_t udapl_async_events; /**< dequeue asynchronous events */
|
||||
int32_t udapl_buffer_alignment; /**< preferred communication buffer alignment, in bytes */
|
||||
opal_list_t udapl_procs; /**< list of udapl proc structures */
|
||||
|
@ -402,7 +402,8 @@ static int mca_btl_udapl_accept_connect(mca_btl_udapl_module_t* btl,
|
||||
return OMPI_ERROR;
|
||||
}
|
||||
|
||||
rc = dat_cr_accept(cr_handle, endpoint, 0, NULL);
|
||||
rc = dat_cr_accept(cr_handle, endpoint, sizeof(mca_btl_udapl_addr_t),
|
||||
&btl->udapl_addr);
|
||||
if(DAT_SUCCESS != rc) {
|
||||
char* major;
|
||||
char* minor;
|
||||
@ -794,10 +795,17 @@ int mca_btl_udapl_component_progress()
|
||||
case DAT_CONNECTION_EVENT_ESTABLISHED:
|
||||
/* Both the client and server side of a connection generate
|
||||
this event */
|
||||
|
||||
mca_btl_udapl_sendrecv(btl,
|
||||
if (mca_btl_udapl_component.udapl_conn_priv_data) {
|
||||
/* use dat private data to exchange process data */
|
||||
mca_btl_udapl_endpoint_finish_connect(btl,
|
||||
event.event_data.connect_event_data.private_data,
|
||||
NULL,
|
||||
event.event_data.connect_event_data.ep_handle);
|
||||
|
||||
} else {
|
||||
/* explicitly exchange process data */
|
||||
mca_btl_udapl_sendrecv(btl,
|
||||
event.event_data.connect_event_data.ep_handle);
|
||||
}
|
||||
count++;
|
||||
break;
|
||||
case DAT_CONNECTION_EVENT_PEER_REJECTED:
|
||||
|
@ -592,7 +592,7 @@ void mca_btl_udapl_endpoint_connect(mca_btl_udapl_endpoint_t* endpoint)
|
||||
|
||||
rc = dat_ep_connect(endpoint->endpoint_eager, &endpoint->endpoint_addr.addr,
|
||||
endpoint->endpoint_addr.port, mca_btl_udapl_component.udapl_timeout,
|
||||
0, NULL, 0, DAT_CONNECT_DEFAULT_FLAG);
|
||||
sizeof(mca_btl_udapl_addr_t), &btl->udapl_addr, 0, DAT_CONNECT_DEFAULT_FLAG);
|
||||
if(DAT_SUCCESS != rc) {
|
||||
char* major;
|
||||
char* minor;
|
||||
@ -650,7 +650,8 @@ int mca_btl_udapl_endpoint_finish_connect(struct mca_btl_udapl_module_t* btl,
|
||||
!memcmp(addr, &ep->endpoint_addr, sizeof(DAT_SOCK_ADDR))) {
|
||||
OPAL_THREAD_LOCK(&ep->endpoint_lock);
|
||||
if(MCA_BTL_UDAPL_CONN_EAGER == ep->endpoint_state) {
|
||||
ep->endpoint_connection_seq = *connection_seq;
|
||||
ep->endpoint_connection_seq = (NULL != connection_seq) ?
|
||||
*connection_seq:0;
|
||||
ep->endpoint_eager = endpoint;
|
||||
rc = mca_btl_udapl_endpoint_finish_eager(ep);
|
||||
} else if(MCA_BTL_UDAPL_CONN_MAX == ep->endpoint_state) {
|
||||
@ -662,7 +663,8 @@ int mca_btl_udapl_endpoint_finish_connect(struct mca_btl_udapl_module_t* btl,
|
||||
* receive the sendrecv messages from the max connection
|
||||
* before the eager connection.
|
||||
*/
|
||||
if (ep->endpoint_connection_seq < *connection_seq) {
|
||||
if (NULL == connection_seq ||
|
||||
ep->endpoint_connection_seq < *connection_seq) {
|
||||
/* normal order connection matching */
|
||||
ep->endpoint_max = endpoint;
|
||||
} else {
|
||||
@ -720,9 +722,10 @@ static int mca_btl_udapl_endpoint_finish_eager(
|
||||
}
|
||||
|
||||
rc = dat_ep_connect(endpoint->endpoint_max,
|
||||
&endpoint->endpoint_addr.addr, endpoint->endpoint_addr.port,
|
||||
mca_btl_udapl_component.udapl_timeout,
|
||||
0, NULL, 0, DAT_CONNECT_DEFAULT_FLAG);
|
||||
&endpoint->endpoint_addr.addr, endpoint->endpoint_addr.port,
|
||||
mca_btl_udapl_component.udapl_timeout,
|
||||
sizeof(mca_btl_udapl_addr_t),&btl->udapl_addr , 0,
|
||||
DAT_CONNECT_DEFAULT_FLAG);
|
||||
if(DAT_SUCCESS != rc) {
|
||||
char* major;
|
||||
char* minor;
|
||||
|
@ -200,6 +200,13 @@ int mca_btl_udapl_register_mca_params(void)
|
||||
REGINT_GE_ONE), tmp_rc, rc);
|
||||
mca_btl_udapl_component.udapl_timeout = (uint32_t) ival;
|
||||
|
||||
CHECK_PARAM_REGISTER_RETURN_VALUE(mca_btl_udapl_reg_int("conn_priv_data",
|
||||
"Use connect private data to establish connections "
|
||||
"(not supported by all uDAPL implementations).",
|
||||
0,
|
||||
&mca_btl_udapl_component.udapl_conn_priv_data,
|
||||
REGINT_GE_ZERO), tmp_rc, rc);
|
||||
|
||||
CHECK_PARAM_REGISTER_RETURN_VALUE(mca_btl_udapl_reg_int("async_events",
|
||||
"The asynchronous event queue will only be "
|
||||
"checked after entering progress this number of times.",
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user