From c64ea8db135af2d541d56f6bd1ebb689e7915589 Mon Sep 17 00:00:00 2001 From: Cyril SIX Date: Fri, 12 Jul 2019 12:05:38 +0200 Subject: (#143) Rajout de la macro TIMEINIT --- test/monniaux/cycles.h | 1 + 1 file changed, 1 insertion(+) (limited to 'test/monniaux/cycles.h') diff --git a/test/monniaux/cycles.h b/test/monniaux/cycles.h index f072e479..c7978ff4 100644 --- a/test/monniaux/cycles.h +++ b/test/monniaux/cycles.h @@ -43,6 +43,7 @@ static inline cycle_t get_cycle(void) { return 0; } #endif #ifdef MAX_MEASURES + #define TIMEINIT {_last_stop = get_cycle();} #define TIMESTOP(i) {cycle_t cur = get_cycle(); _total_cycles[i] += cur - _last_stop; _last_stop = cur;} #define TIMEPRINT(n) { for (int i = 0; i <= n; i++) printf("(%d) cycles: %" PRIu64 "\n", i, _total_cycles[i]); } #endif -- cgit