zephyrproject-rtos / zscilib

An open-source scientific computing library for embedded systems running Zephyr OS or standalone.
https://zephyrproject-rtos.github.io/zscilib/
Apache License 2.0
141 stars 27 forks source link

api: Add Instrumentation API #20

Closed microbuilder closed 3 years ago

microbuilder commented 3 years ago

This commit adds an optional instrumentation header file that provides approximate execution times for larger chunks of code. It is based on the high-precision timer in Zephyr, so isn't as granular or accurate as something like DWT on the M3/M4/M7/M33, but is platform-agnostic.

It updates the benchmarking sample to use this new header.

Signed-off-by: Kevin Townsend kevin@ktownsend.com