From 889865bbf8a302c8d942a7dfbf753f60bbae76c5 Mon Sep 17 00:00:00 2001 From: Patrick Pelissier Date: Tue, 22 Aug 2017 23:22:46 +0200 Subject: [PATCH] Add size argument for hash bench. --- bench/bench-mlib.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bench/bench-mlib.c b/bench/bench-mlib.c index 29d51919..f17b9363 100644 --- a/bench/bench-mlib.c +++ b/bench/bench-mlib.c @@ -405,13 +405,13 @@ int main(int argc, const char *argv[]) if (n == 60) test_function("Buffer time", 1000000, test_buffer); if (n == 70) { - const size_t n = 100000000; + n = (argc > 2) ? atoi(argv[2]) : 100000000; test_hash_prepare(n); test_function("M_HASH time", n, test_hash); test_hash_final(); } if (n == 71) { - const size_t n = 100000000; + n = (argc > 2) ? atoi(argv[2]) : 100000000; test_hash_prepare(n); test_function("CORE_HASH time", n, test_core_hash); test_hash_final();