Fix low level benchmark

reviewable/pr14459/r1
Vijay Pai 7 years ago
parent 1d71d461df
commit c3e5c56d1a
  1. 6
      test/core/network_benchmarks/low_level_ping_pong.cc

@ -575,7 +575,6 @@ int create_socket(const char* socket_type, fd_pair* client_fds,
static int run_benchmark(const char* socket_type, thread_args* client_args, static int run_benchmark(const char* socket_type, thread_args* client_args,
thread_args* server_args) { thread_args* server_args) {
gpr_thd_id tid;
int rv = 0; int rv = 0;
rv = create_socket(socket_type, &client_args->fds, &server_args->fds); rv = create_socket(socket_type, &client_args->fds, &server_args->fds);
@ -586,9 +585,10 @@ static int run_benchmark(const char* socket_type, thread_args* client_args,
gpr_log(GPR_INFO, "Starting test %s %s %zu", client_args->strategy_name, gpr_log(GPR_INFO, "Starting test %s %s %zu", client_args->strategy_name,
socket_type, client_args->msg_size); socket_type, client_args->msg_size);
gpr_thd_new(&tid, "server_thread", server_thread_wrap, server_args); grpc_core::Thread server("server_thread", server_thread_wrap, server_args);
server.Start();
client_thread(client_args); client_thread(client_args);
gpr_thd_join(tid); server.Join();
return 0; return 0;
} }

Loading…
Cancel
Save