tesseract++ 0.0.1
N-dimensional tensor library for embedded systems
Loading...
Searching...
No Matches
cycle_counter_generic.h
Go to the documentation of this file.
1#pragma once
2
8namespace detail
9{
10
18 {
19 unsigned long long total_cycles = 0;
20 unsigned long long runs = 0;
21
22 FORCE_INLINE void start() noexcept {}
23 FORCE_INLINE void stop() noexcept { ++runs; }
24
25 void reset() noexcept
26 {
27 total_cycles = 0;
28 runs = 0;
29 }
30
31 double avg_cycles() const { return 0.0; }
32 };
33
34} // namespace detail
#define FORCE_INLINE
Hint the compiler to always inline a function.
Definition config.h:26
Definition BaseExpr.h:4
Stub cycle counter for platforms without hardware timer access.
Definition cycle_counter_generic.h:18
unsigned long long runs
Definition cycle_counter_generic.h:20
FORCE_INLINE void start() noexcept
Definition cycle_counter_generic.h:22
unsigned long long total_cycles
Definition cycle_counter_generic.h:19
void reset() noexcept
Definition cycle_counter_generic.h:25
FORCE_INLINE void stop() noexcept
Definition cycle_counter_generic.h:23
double avg_cycles() const
Definition cycle_counter_generic.h:31