Benchmarks print their own name

This commit is contained in:
Ryan Dahl 2011-05-09 21:38:03 -07:00
parent 1b85c9f211
commit 9f652d4729
5 changed files with 9 additions and 15 deletions

View File

@ -19,15 +19,13 @@
* IN THE SOFTWARE. * IN THE SOFTWARE.
*/ */
BENCHMARK_DECLARE (size_handle) BENCHMARK_DECLARE (sizes)
BENCHMARK_DECLARE (size_req)
BENCHMARK_DECLARE (ping_pongs) BENCHMARK_DECLARE (ping_pongs)
BENCHMARK_DECLARE (pump) BENCHMARK_DECLARE (pump)
HELPER_DECLARE (echo_server) HELPER_DECLARE (echo_server)
TASK_LIST_START TASK_LIST_START
BENCHMARK_ENTRY (size_handle) BENCHMARK_ENTRY (sizes)
BENCHMARK_ENTRY (size_req)
BENCHMARK_ENTRY (ping_pongs) BENCHMARK_ENTRY (ping_pongs)
BENCHMARK_HELPER (ping_pongs, echo_server) BENCHMARK_HELPER (ping_pongs, echo_server)

View File

@ -84,7 +84,7 @@ static void pinger_close_cb(oio_handle_t* handle, int status) {
ASSERT(status == 0); ASSERT(status == 0);
pinger = (pinger_t*)handle->data; pinger = (pinger_t*)handle->data;
printf("%d pings\n", pinger->pongs); printf("ping_pongs: %d pings\n", pinger->pongs);
free(pinger); free(pinger);

View File

@ -22,13 +22,9 @@
#include "task.h" #include "task.h"
#include "../oio.h" #include "../oio.h"
BENCHMARK_IMPL(size_handle) {
LOGF("%lu oio_handle_t\n", sizeof(oio_handle_t)); BENCHMARK_IMPL(sizes) {
return 0; LOGF("oio_handle_t: %lu bytes\n", sizeof(oio_handle_t));
} LOGF("oio_req_t: %lu bytes\n", sizeof(oio_req_t));
BENCHMARK_IMPL(size_req) {
LOGF("%lu oio_req_t\n", sizeof(oio_req_t));
return 0; return 0;
} }

View File

@ -56,4 +56,4 @@ int main(int argc, char **argv) {
return 0; return 0;
} }
} }

View File

@ -152,7 +152,7 @@ finalize:
break; break;
default: default:
LOGF("%s: ", test->task_name); //LOGF("%s: ", test->task_name);
process_copy_output(main_process, fileno(stderr)); process_copy_output(main_process, fileno(stderr));
break; break;
} }