diff options
author | Andrew Tridgell <tridge@samba.org> | 2004-03-10 05:05:56 +0000 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2004-03-10 05:05:56 +0000 |
commit | c66a2c1438237002b079b9d6a7c9601f9371f51f (patch) | |
tree | 90f73f8fcf23d4392450562afc377388c575ce6d /source4 | |
parent | 5e31a56e725b41f9759535de0322459baa3ced5f (diff) | |
download | samba-c66a2c1438237002b079b9d6a7c9601f9371f51f.tar.gz samba-c66a2c1438237002b079b9d6a7c9601f9371f51f.tar.bz2 samba-c66a2c1438237002b079b9d6a7c9601f9371f51f.zip |
make the warmup and execute phases clearer
(This used to be commit d49e4407e59a25c8e887b552ed2a58de7a16b6d9)
Diffstat (limited to 'source4')
-rw-r--r-- | source4/torture/nbench/nbio.c | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/source4/torture/nbench/nbio.c b/source4/torture/nbench/nbio.c index fee3af05e4..8a9c36f1d0 100644 --- a/source4/torture/nbench/nbio.c +++ b/source4/torture/nbench/nbio.c @@ -73,16 +73,25 @@ void nb_alarm(void) t = end_timer(); - printf("%4d %8d %.2f MB/sec time %.0f sec \r", - num_clients, lines/nprocs, - 1.0e-6 * nbio_total() / t, - t - warmup); + if (warmup) { + printf("%4d %8d %.2f MB/sec warmup %.0f sec \r", + num_clients, lines/nprocs, + 1.0e-6 * nbio_total() / t, + t); + } else { + printf("%4d %8d %.2f MB/sec execute %.0f sec \r", + num_clients, lines/nprocs, + 1.0e-6 * nbio_total() / t, + t); + } if (warmup && t >= warmup) { start_timer(); warmup = 0; } + fflush(stdout); + signal(SIGALRM, nb_alarm); alarm(1); } |