+2020-06-02 Niels Möller <nisse@lysator.liu.se>
+
+ * examples/nettle-benchmark.c (main): Delete call to
+ time_overhead. The attempt to measure function call overhead is
+ not very useful or accurate. The benchmarking loop is optimized
+ away by gcc-10, making the benchmark program hang.
+ (bench_nothing, time_overhead): Deleted.
+
2020-04-29 Niels Möller <nisse@lysator.liu.se>
* Released Nettle-3.6.
return elapsed / ncalls - overhead;
}
-static void
-bench_nothing(void *arg UNUSED)
-{
- return;
-}
-
struct bench_memxor_info
{
void *dst;
return p;
}
-static void
-time_overhead(void)
-{
- overhead = time_function(bench_nothing, NULL);
- printf("benchmark call overhead: %7f us", overhead * 1e6);
- if (frequency > 0.0)
- printf("%7.2f cycles\n", overhead * frequency);
- printf("\n");
-}
-
-
static void
time_memxor(void)
bench_salsa20_core();
bench_sha3_permute();
printf("\n");
- time_overhead();
header();