diff options
author | Paul Selkirk <paul@psgd.org> | 2017-05-13 13:14:56 -0400 |
---|---|---|
committer | Paul Selkirk <paul@psgd.org> | 2017-05-13 13:21:35 -0400 |
commit | a7ee9a7b76a4ec90d9f864adfc4342f13f8bd499 (patch) | |
tree | 4f7743242aae7da758d769ae7e4220a97a096378 /task.h | |
parent | 65b94ef5ba1981c74a99cb43ee768fbf480c698b (diff) | |
parent | 7ef51e89d5a1d7d75cb0b8d3832327beb46319dd (diff) |
Merge branch 'task_metrics' into profiling
Diffstat (limited to 'task.h')
-rw-r--r-- | task.h | 11 |
1 files changed, 11 insertions, 0 deletions
@@ -73,4 +73,15 @@ extern void task_delay(uint32_t delay); extern void task_mutex_lock(task_mutex_t *mutex); extern void task_mutex_unlock(task_mutex_t *mutex); +#ifdef DO_TASK_METRICS +#include <sys/time.h> + +struct task_metrics { + struct timeval avg, max; +}; + +void task_get_metrics(struct task_metrics *tm); +void task_reset_metrics(void); +#endif + #endif /* _TASK_H_ */ |