For more details and example usage, see Cycle Counter
Functions | |
void | CycleCounterP_init (const uint64_t cpuFreqHz) |
initialize PMU Cycle Counter More... | |
uint32_t | CycleCounterP_getCount32 (void) |
Get 32b CPU cycle counter value. More... | |
void | CycleCounterP_reset (void) |
Enable, reset, clear overflow for CPU cycle counter. More... | |
uint64_t | CycleCounterP_getCount64 (void) |
Get 64b CPU cycle counter value. More... | |
uint64_t | CycleCounterP_nsToTicks (const uint64_t nanosecs) |
API function to convert nanosecs to PMU counter ticks. More... | |
void CycleCounterP_init | ( | const uint64_t | cpuFreqHz | ) |
initialize PMU Cycle Counter
uint32_t CycleCounterP_getCount32 | ( | void | ) |
Get 32b CPU cycle counter value.
Make sure to handle overflow condition in your application.
void CycleCounterP_reset | ( | void | ) |
Enable, reset, clear overflow for CPU cycle counter.
uint64_t CycleCounterP_getCount64 | ( | void | ) |
Get 64b CPU cycle counter value.
Only support with below CPUs,
uint64_t CycleCounterP_nsToTicks | ( | const uint64_t | nanosecs | ) |
API function to convert nanosecs to PMU counter ticks.
nanosecs | time unit in nano sec |