At 02:59 AM 8/4/2006, Gabriel Genellina wrote:
I'm not sure if this really works, but you could try:
- Raise your thread/process's priority using SetPriorityClass or
SetThreadPriority. This is to minimize the (unpredictable) delay of sleep()
I do launch the module with CreateProcess with
At 11:01 AM 8/4/2006, Tim Roberts wrote:
What surprises you? The Win32 Sleep() function takes integer
milliseconds. Thus, .1 will round to 0, which says give up the CPU
only if a higher-priority task is waiting..
The default scheduling interval on your system is 16ms. Some Windows
I have been trying to use sleep() and kernel32.QueryPerformanceCounter
together; I want to delay until a particular tick without trying up the
CPU badly.
However, while time.sleep(.001) relieves the CPU, it has wildly
unpredictable delay, and sleep(.0001) delays almost nothing at all! (I'm