Commit 66d5ff6a authored by Shane Snyder's avatar Shane Snyder
Browse files

indicate group size at lookup time

parent f8a89da6
......@@ -310,13 +310,18 @@ static ssg_t ssg_init_internal(margo_instance_id mid, int self_rank,
s = NULL;
goto fini;
}
SSG_DEBUG(s, "group lookup successful\n");
SSG_DEBUG(s, "group lookup successful (initial size = %d)\n", group_size);
#if USE_SWIM_FD
/* XXX: hack to make rank 1 unresponsive */
int swim_active = 1;
if(self_rank == 1)
swim_active = 0;
// initialize swim failure detector
// TODO: we should probably barrier or sync somehow to avoid rpc failures
// due to timing skew of different ranks initializing swim
s->swim_ctx = swim_init(s, 1);
s->swim_ctx = swim_init(s, swim_active);
if (s->swim_ctx == NULL)
{
ssg_finalize(s);
......
......@@ -188,6 +188,15 @@ static void swim_dping_recv_ult(hg_handle_t handle)
swim_ctx = s->swim_ctx;
assert(swim_ctx != NULL);
/* XXX: make rank 1 unresponsive */
//int drop = rand() % 2;
int drop = 1;
if(s->view.self_rank == 1 && drop)
{
HG_Destroy(handle);
return;
}
hret = HG_Get_input(handle, &dping_req);
if(hret != HG_SUCCESS)
return;
......@@ -315,6 +324,13 @@ static void swim_iping_recv_ult(hg_handle_t handle)
swim_ctx = s->swim_ctx;
assert(swim_ctx != NULL);
/* XXX: make rank 1 unresponsive */
if(s->view.self_rank == 1)
{
HG_Destroy(handle);
return;
}
hret = HG_Get_input(handle, &iping_req);
if(hret != HG_SUCCESS)
return;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment