[asterisk-dev] [Code Review] Timer for Mach kernels
Tilghman Lesher
tlesher at digium.com
Wed May 26 14:25:24 CDT 2010
> On 2010-05-26 13:23:26, pabelanger wrote:
> > /trunk/res/res_timing_mach.c, lines 214-218
> > <https://reviewboard.asterisk.org/r/665/diff/1/?file=10306#file10306line214>
> >
> > To be removed?
Those are the lines that I had to add to make the Mach timer test correctly on OS X. Technically, we're not supposed to ack timers that have not actually fired, so the ack becomes a wait, with that code there. Really, what should be happening is that the poll() should not return until the event actually fires.
- Tilghman
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/665/#review2087
-----------------------------------------------------------
On 2010-05-19 01:50:38, Tilghman Lesher wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviewboard.asterisk.org/r/665/
> -----------------------------------------------------------
>
> (Updated 2010-05-19 01:50:38)
>
>
> Review request for Asterisk Developers.
>
>
> Summary
> -------
>
> While trying to verify the kqueue implementation on OS X, I coded an alternate timing implementation for OS X, since it's based on a Mach kernel. The end result is that if you uncomment a few lines in the _ack function, you get perfect timing. Unfortunately, this shows that poll(2) in OS X (or really, select(2), since ast_poll on OS X is coded over select(2)) is complete and utter crap.
>
>
> Diffs
> -----
>
> /trunk/configure UNKNOWN
> /trunk/configure.ac 263949
> /trunk/include/asterisk/autoconfig.h.in 263949
> /trunk/res/res_timing_mach.c PRE-CREATION
>
> Diff: https://reviewboard.asterisk.org/r/665/diff
>
>
> Testing
> -------
>
> Verifies correctly on OS X, if you turn on the wait code in the _ack routine.
>
>
> Thanks,
>
> Tilghman
>
>
More information about the asterisk-dev
mailing list