Re: fixed time slices?



The minimum wait interval unless you explicitly change it is 10ms plus some
overhead for getting in and out of the kernel, etc. So 15ms is about what
I would expect. Use the multimedia timers if you want to go below 10ms.


--
Don Burn (MVP, Windows DDK)
Windows 2k/XP/2k3 Filesystem and Driver Consulting
Website: http://www.windrvr.com
Blog: http://msmvps.com/blogs/WinDrvr
Remove StopSpam to reply

"Jan Bruns" <testzugang_janbruns@xxxxxxxx> wrote in message
news:467ada27$0$6441$9b4e6d93@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Hallo.

I've noticed that my XP computer seems to handle time-slices
difrent from what I think it used to.

The rule I remember it should be is like defined in the SDK:

| If a higher-priority thread becomes available to run, the system
| ceases to execute the lower-priority thread (without allowing it
| to finish using its time slice), and assigns a full time slice
| to the higher-priority thread.

But now, if I create a process/thread that does nothing but this:

repeat
for i := 0 to n do begin
setWaitableTimer(timer,...);
waitForSingleObjectEx(timer,...);
end;
write_time;
unitl false;


it turns out that the minimum wait intervall seems to be 15ms,
and other timer-inveralls are rounded up to something near a
multiple of that minimum wait intervall, even if I set a
high priority to that process and the system is otherwise idle.

The same thing happens using sleep().

What's going on here?

Gruss

Jan Bruns




.



Relevant Pages

  • Re: fixed time slices?
    ... | If a higher-priority thread becomes available to run, ... | to finish using its time slice), and assigns a full time slice ... if I create a process/thread that does nothing but this: ... it turns out that the minimum wait intervall seems to be 15ms, ...
    (microsoft.public.win32.programmer.kernel)
  • fixed time slices?
    ... | If a higher-priority thread becomes available to run, ... | to finish using its time slice), and assigns a full time slice ... if I create a process/thread that does nothing but this: ... it turns out that the minimum wait intervall seems to be 15ms, ...
    (microsoft.public.win32.programmer.kernel)