Skip to content

Commit

Permalink
Merge pull request #14639 from kaspar030/sys_benchmark_extended_xtime…
Browse files Browse the repository at this point in the history
…r_workaround

sys/benchmark: don't disable interrupts
  • Loading branch information
miri64 committed Jul 28, 2020
2 parents b1bf8ab + f60980b commit 91c2351
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions sys/include/benchmark.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,11 @@ extern "C" {
*/
#define BENCHMARK_FUNC(name, runs, func) \
{ \
unsigned _benchmark_irqstate = irq_disable(); \
uint32_t _benchmark_time = xtimer_now_usec(); \
for (unsigned long i = 0; i < runs; i++) { \
func; \
} \
_benchmark_time = (xtimer_now_usec() - _benchmark_time);\
irq_restore(_benchmark_irqstate); \
benchmark_print_time(_benchmark_time, runs, name); \
}

Expand Down

0 comments on commit 91c2351

Please sign in to comment.