aboutsummaryrefslogtreecommitdiff
path: root/src/util/perf_crypto_hash.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2013-03-23 19:46:17 +0000
committerChristian Grothoff <christian@grothoff.org>2013-03-23 19:46:17 +0000
commit05ac77fefc694bb3bdf507c4836f9c41e874f1f7 (patch)
tree3c25f39f9ec62afce3e509e6e72d4c31d6416d9a /src/util/perf_crypto_hash.c
parent728a3f8c8a1098dea35732c3ad59fb8d60ee8e0f (diff)
downloadgnunet-05ac77fefc694bb3bdf507c4836f9c41e874f1f7.tar.gz
gnunet-05ac77fefc694bb3bdf507c4836f9c41e874f1f7.zip
-cleanup
Diffstat (limited to 'src/util/perf_crypto_hash.c')
-rw-r--r--src/util/perf_crypto_hash.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/util/perf_crypto_hash.c b/src/util/perf_crypto_hash.c
index d1f4c9dc1..8cf7f8748 100644
--- a/src/util/perf_crypto_hash.c
+++ b/src/util/perf_crypto_hash.c
@@ -25,10 +25,10 @@
25 */ 25 */
26#include "platform.h" 26#include "platform.h"
27#include "gnunet_common.h" 27#include "gnunet_common.h"
28#include "gnunet_crypto_lib.h" 28#include "gnunet_util_lib.h"
29#include "gnunet_time_lib.h"
30#include <gauger.h> 29#include <gauger.h>
31 30
31
32static void 32static void
33perfHash () 33perfHash ()
34{ 34{
@@ -50,6 +50,7 @@ perfHash ()
50 GNUNET_free (buf); 50 GNUNET_free (buf);
51} 51}
52 52
53
53int 54int
54main (int argc, char *argv[]) 55main (int argc, char *argv[])
55{ 56{
@@ -57,9 +58,9 @@ main (int argc, char *argv[])
57 58
58 start = GNUNET_TIME_absolute_get (); 59 start = GNUNET_TIME_absolute_get ();
59 perfHash (); 60 perfHash ();
60 printf ("Hash perf took %llu ms\n", 61 printf ("Hash perf took %s\n",
61 (unsigned long long) 62 GNUNET_STRINGS_relative_time_to_string (GNUNET_TIME_absolute_get_duration (start),
62 GNUNET_TIME_absolute_get_duration (start).rel_value); 63 GNUNET_YES));
63 GAUGER ("UTIL", "Cryptographic hashing", 64 GAUGER ("UTIL", "Cryptographic hashing",
64 1024 * 64 * 1024 / (1 + 65 1024 * 64 * 1024 / (1 +
65 GNUNET_TIME_absolute_get_duration 66 GNUNET_TIME_absolute_get_duration
@@ -67,4 +68,4 @@ main (int argc, char *argv[])
67 return 0; 68 return 0;
68} 69}
69 70
70/* end of hashperf.c */ 71/* end of perf_crypto_hash.c */