comp.lang.ada
 help / color / mirror / Atom feed
From: michael bode <m.g.bode@web.de>
Subject: Re: Strange behaviour of delay in Windows XP
Date: Fri, 08 Oct 2010 00:10:39 +0200
Date: 2010-10-08T00:10:39+02:00	[thread overview]
Message-ID: <i8lgh1$lpb$1@news.eternal-september.org> (raw)
In-Reply-To: <op.vj7593km0k3wt7@jellix.jlfencey.com>

Am 07.10.2010 23:35, schrieb Vinzent Hoefler:

> Obviously your lab is very CPU intensive. ;)

Or has bad feng shui ;-)

>> Most of the time. Sometimes I got 1.0xxs. There was no noticeable CPU
>> load during the tests.
> 
> That's probably the explanation. Firstly, Windows is by no means an RTOS,
> secondly GNAT's relative delay implementation uses the Sleep call, which
> is quite crude when it comes to clock resolution (15 ms and more).
> Add CPU load, disk activity and things and the delay can easily exceed
> the "expected" time depending on when Windows decides to return from sleep.

There was NO load during all the tests. And 2.7s instead of 1.0? These
are relativly current machines with 3GHz Core2Duo CPU.

> With "delay until" you should get better results. Even adding a task could
> help, because with tasking enabled, GNAT uses a different and more precise
> implementation AFAIK.

Good hint, I will try if delay until has different behaviour.






  reply	other threads:[~2010-10-07 22:10 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-07 21:04 Strange behaviour of delay in Windows XP michael bode
2010-10-07 21:35 ` Vinzent Hoefler
2010-10-07 22:10   ` michael bode [this message]
2010-10-07 22:37 ` Jeffrey Carter
2010-10-08  5:18   ` michael bode
2010-10-08 10:13   ` michael bode
2010-10-08  0:15 ` Randy Brukardt
2010-10-08  5:33   ` michael bode
2010-10-09  6:42     ` Randy Brukardt
2010-10-09  8:18       ` Dmitry A. Kazakov
2010-10-26  1:50   ` Yannick Duchêne (Hibou57)
2010-10-08  7:54 ` Dmitry A. Kazakov
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox