1 /* -----------------------------------------------------------------------------
3 * (c) The GHC Team, 1995-2005
5 * Interval timer service for profiling and pre-emptive scheduling.
7 * ---------------------------------------------------------------------------*/
12 # define TICK_MILLISECS (1000/TICK_FREQUENCY) /* ms per tick */
14 /* Context switch timing constants. Context switches happen after a
15 * whole number of ticks, the default being every tick.
17 #define CS_MIN_MILLISECS TICK_MILLISECS /* milliseconds per slice */
19 typedef void (*TickProc)(int);
21 extern int startTimer(nat ms);
22 extern int stopTimer(void);