Commit 011a8bad authored by Shane Snyder's avatar Shane Snyder
Browse files

more ssg example tweaks

parent 47fa9f8a
CFLAGS += `pkg-config --cflags margo ssg`
LDFLAGS += `pkg-config --libs margo ssg`
all:: ssg-token-ring-solved ssg-token-ring-stub
all:: ssg-token-ring2 ssg-token-ring1
ssg-token-ring-solved.o: ssg-token-ring-solved.c
mpicc $(CFLAGS) -c ssg-token-ring-solved.c
ssg-token-ring2.o: ssg-token-ring2.c
mpicc $(CFLAGS) -c ssg-token-ring2.c
ssg-token-ring-solved: ssg-token-ring-solved.o
mpicc ssg-token-ring-solved.o -o ssg-token-ring-solved $(LDFLAGS)
ssg-token-ring2: ssg-token-ring2.o
mpicc ssg-token-ring2.o -o ssg-token-ring2 $(LDFLAGS)
ssg-token-ring-stub.o: ssg-token-ring-stub.c
mpicc $(CFLAGS) -c ssg-token-ring-stub.c
ssg-token-ring1.o: ssg-token-ring1.c
mpicc $(CFLAGS) -c ssg-token-ring1.c
ssg-token-ring-stub: ssg-token-ring-stub.o
mpicc ssg-token-ring-stub.o -o ssg-token-ring-stub $(LDFLAGS)
ssg-token-ring1: ssg-token-ring1.o
mpicc ssg-token-ring1.o -o ssg-token-ring1 $(LDFLAGS)
clean::
rm -f ssg-token-ring-solved ssg-token-ring-stub ssg-token-ring-solved.o ssg-token-ring-stub.o
rm -f ssg-token-ring2 ssg-token-ring1 ssg-token-ring2.o ssg-token-ring1.o
......@@ -120,6 +120,8 @@ static void token_forward_recv(hg_handle_t h)
if (serv_data->self_rank > 0)
token_forward(serv_data);
printf("Member %d shutting down\n", serv_data->self_rank);
/* XXX rather than shutting down immediately, send RPCs back through
* the ring to shutdown in reverse order (i.e., 3, 2, 1, 0) */
ssg_group_destroy(serv_data->gid);
......
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