This is the mail archive of the cygwin-developers@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Improving setitimer resolution


On Thu, Jul 17, 2003 at 12:30:26AM -0400, Pierre A. Humblet wrote:
>At 12:08 AM 7/17/2003 -0400, Christopher Faylor wrote:
>>On Wed, Jul 16, 2003 at 11:05:50PM -0400, Pierre A. Humblet wrote:
>>>I am trying to improve the resolution of the Cygwin timers
>>>(setitimer, alarm, ualarm) by using the multimedia timers,
>>>which have 1 ms resolution.
>>
>>What is different about using multimedia timers here?  I had to abandon
>>them for settimeofday due to the fact that suspending the computer caused
>>timing anomalies.
>
>Ability to produce short delays and better resolution, as shown in 
>previous mail.

I understand *why* you want to do this but I thought that multimedia timers
suffered when the computer was suspended.  That would make them unuseful for
setitimer.

However, I was misremembering the history of gettimeofdaty.  I thought
I'd first used multimedia timers in gettimeofday but cvs spelunking just
seems to uncover the use of QueryPerformanceCounter.  So, I'm turned
around.  I used timeGetTime later on to retrieve millisecond resolution
where I'd previously used QueryPerformanceCounter to retrieve
microsecond precision.  strace still uses QueryPerformanceCounter.

So, nevermind.  My query was misinformed.

cgf


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]