From e57ab2a7bfb69c0ef9b5b7fa8e53e20a500e7c6c Mon Sep 17 00:00:00 2001 From: Keith Packard Date: Thu, 25 Oct 2012 13:42:10 -0700 Subject: altos: Provide ao_task_alarm_tick to reduce per-tick cost Cache the next wakeup time and check that before jumping to the task code. Signed-off-by: Keith Packard --- src/core/ao_task.h | 1 + 1 file changed, 1 insertion(+) (limited to 'src/core/ao_task.h') diff --git a/src/core/ao_task.h b/src/core/ao_task.h index b3f152a0..049f69a7 100644 --- a/src/core/ao_task.h +++ b/src/core/ao_task.h @@ -82,6 +82,7 @@ ao_add_task(__xdata struct ao_task * task, void (*start)(void), __code char *nam #if HAS_TASK_QUEUE /* Called on timer interrupt to check alarms */ +extern uint16_t ao_task_alarm_tick; void ao_task_check_alarm(uint16_t tick); #endif -- cgit v1.2.3