Re: [linux-audio-dev] Linux and clocks

New Message Reply About this list Date view Thread view Subject view Author view Other groups

Subject: Re: [linux-audio-dev] Linux and clocks
From: Paul Davis (pbd_AT_Op.Net)
Date: Fri Mar 22 2002 - 03:55:31 EET


>I wrote a little program to test the accuracy of clock_nanosleep
>under linux. Running SCHED_FIFO at the highest priority I did
> an absolute clock_nanosleep()

on an unmodified kernel (regardless of the presence of latency
patches), i think it would be odd to expect that clock_nanosleep() to
be effective.

the linux kernel has only one timing source, no matter what patches and
hacks are applied to glibc. that timing source is extremely coarse. i
think you know this.

>took the difference. I noticed that when using a short sleep time
>the results were very good,

yes, because for a SCHED_FIFO or SCHED_RR process, and a sleep of less
than a 1 tick, the kernel spinblocks.

--p


New Message Reply About this list Date view Thread view Subject view Author view Other groups

This archive was generated by hypermail 2b28 : Fri Mar 22 2002 - 03:43:48 EET