perf_counter: added perf_reset() and perf_reset_all() calls

useful for watching counters after system reaches stable flight
This commit is contained in:
Andrew Tridgell
2013-01-24 10:26:02 +11:00
parent cc74874d7e
commit f4da4bb8ca
2 changed files with 58 additions and 0 deletions
+13
View File
@@ -97,6 +97,14 @@ __EXPORT extern void perf_begin(perf_counter_t handle);
*/
__EXPORT extern void perf_end(perf_counter_t handle);
/**
* Reset a performance event.
*
* This call resets performance counter to initial state
*
* @param handle The handle returned from perf_alloc.
*/
__EXPORT extern void perf_reset(perf_counter_t handle);
/**
* Print one performance counter.
@@ -110,6 +118,11 @@ __EXPORT extern void perf_print_counter(perf_counter_t handle);
*/
__EXPORT extern void perf_print_all(void);
/**
* Reset all of the performance counters.
*/
__EXPORT extern void perf_reset_all(void);
__END_DECLS
#endif