diff options
author | Martin Schanzenbach <mschanzenbach@posteo.de> | 2021-05-03 12:24:53 +0200 |
---|---|---|
committer | Martin Schanzenbach <mschanzenbach@posteo.de> | 2021-05-03 12:24:53 +0200 |
commit | 9b1065bcad0e82350e3e72e474ae425293defe42 (patch) | |
tree | 662a612de10cbc4b195b0161680f3a2cf3198d7d /src/gnsrecord/test_gnsrecord_crypto.c | |
parent | ae3ce5eaf5df138e41337c7cf4d964a031b3008d (diff) |
-remove (hopefully) unnecessary clamping
Diffstat (limited to 'src/gnsrecord/test_gnsrecord_crypto.c')
-rw-r--r-- | src/gnsrecord/test_gnsrecord_crypto.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/gnsrecord/test_gnsrecord_crypto.c b/src/gnsrecord/test_gnsrecord_crypto.c index 9394f562d..b9b2b5ba5 100644 --- a/src/gnsrecord/test_gnsrecord_crypto.c +++ b/src/gnsrecord/test_gnsrecord_crypto.c @@ -148,15 +148,29 @@ run (void *cls, { struct GNUNET_IDENTITY_PrivateKey privkey; struct GNUNET_IDENTITY_PrivateKey privkey_ed; + struct GNUNET_TIME_Absolute start; + struct GNUNET_TIME_Absolute end; privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); + start = GNUNET_TIME_absolute_get (); test_with_type (&privkey); + end = GNUNET_TIME_absolute_get (); + printf ("Time: %llu ms\n", (unsigned long long) + GNUNET_TIME_absolute_get_difference (start, + end).rel_value_us); privkey_ed.type = htonl (GNUNET_GNSRECORD_TYPE_EDKEY); GNUNET_CRYPTO_eddsa_key_create (&privkey_ed.eddsa_key); + start = GNUNET_TIME_absolute_get (); test_with_type(&privkey_ed); + end = GNUNET_TIME_absolute_get (); + printf ("Time: %llu ms\n", (unsigned long long) + GNUNET_TIME_absolute_get_difference (start, + end).rel_value_us); + + } |