Hi Torsten,
[I'm assuming didn't mean to reply on the list and not just to me, so I'm replying on the list.]
On 20/04/2020 11:51, Manuel Pegourie-Gonnard via mbed-tls wrote:
For reference, this module includes the following functions, which are used in the following places:
- mbedtls_timing_hardclock() implements cycle counting (on selected architectures, not including M-class), used only in
programs/test/benchmark.c
I used mbedtls_timing_hardclock() for my own benchmarking experiments on Linux and Windows, but couldn't get it to run on the target machine. So I've use my own ms counter instead. So, it could be easily removed as part of the library.
Good to know, thanks for sharing this data point.
Question: How do you want to do the benchmarking instead? With the same code, but outside the library?
Yes, I was thinking that the functions that are only used in benchmark.c could be defined in benchmark.c, and the functions that are only used in udp_proxy.c could be defined in udp_proxy.c.
(Or actually for the latter, we might want to start using them in ssl_client2.c and ssl_server2.c as well, as including millisecond timestamps in the debug output would be usefull to debug some issues. In that case, we'll probably put those functions in a new file, used by udp_proxy, ssl_client2 and ssl_server2 (just like query_config.c is currently used by ssl_client2, ssl_server2 and query_compile_time_config).)
Regards, Manuel.