[REBOL] Re: forever loops and cpu usage
From: lmecir:mbox:vol:cz at: 8-Feb-2004 21:59
Paul Tretter napsal(a):
>On WinXP here I can get as precise as .001 on the wait time. However, it
>appears that anything less than that storms the cpu back up to 99 percent.
>I suppose that .001 is the lowest number that the wait function can support.
>I'm curious why you arrived at .002. Was it the balance point for windows
>and linux. I would like others to report on what OS they use and report
>their findings. HOW LOW CAN YOU GO?
I have got a timing function working as follows:
tick-time: time-tick 0.1 ; == 1.00000000002183E-2
, which computes the internal system timer resolution, 0.1 is an
argument asking for 10% relative error at most.
>> time-block [wait 0.02] 0,05
>> time-block [wait 0.01] 0,05
>> time-block [wait 0.005] 0,05
>> time-block [wait 0.002] 0,05
>> time-block [wait 0.001] 0,05
look like showing, that all below the system timer resolution are
to the system timer.
OTOH, times below 0.001 exhibit this:
>> time-block [wait 0.00099] 0,05