Controller loops

Doug Way dway at mat.net
Fri Sep 4 20:13:23 UTC 1998


 
On Fri, 4 Sep 1998 vuletich at ar.ibm.com wrote: 
 
> We know that Squeak uses all the available CPU time even when it is not
> doing anything. 
 
Yes, and this is disturbing.  I often like to iconize Squeak to work on
other things, which this makes difficult. 
 
> I found that this frees almost all the processor time to other programs
> in a multitasking OS. All that is needed is to have the
> ioRelinquishProcessorForMicroseconds() function in the VM properly
> implemented. I tried it and works OK in Windows and OS/2 versions of
> Squeak. 
 
I tried it on Unix (SGI/Irix 6.3) and Windows NT 4.0, and your fix seems
to work fine.  Very cool!  Didn't seem to have any noticable effect on
performance.  (Oddly, the CPU meter under NT indicated that vanilla Squeak
2.1 didn't use 100% CPU for some reason... it does on the other platforms
I've seen, though.) 
 
> Does this modification deserve to be in the base image? 
 
Yes, ASAP.  Even if there are minor side effects, this fixes a significant
problem.  If there's a better/more elegant fix, it could be added later. 
 
- Doug Way
  dway at mat.net
  dway at transom.com
  http://www.transom.com





More information about the Squeak-dev mailing list