From: Mark Hahn Date: 2001-12-20T11:53:55+09:00 Subject: [ruby-talk:29054] Re: A Ruby programmer walked into a bar and ordered a Ruby-Thread > you don't set any thread priorities in Windows? Of course you do. Any good GUI code needs priorities to be properly responsive. What you don't do is ever have a thread request 100% of the cpu. This is bad coding and won't work correctly anywhere. -----Original Message----- From: Phil Tomson [mailto:ptkwt@shell1.aracnet.com] Sent: Wednesday, December 19, 2001 6:49 PM To: ruby-talk ML; undisclosed-recipients: Subject: [ruby-talk:29052] Re: A Ruby programmer walked into a bar and ordered a Ruby-Thread In article , Dave Thomas wrote: >"Mark Hahn" writes: > >> I don't understand the problem. I just ran this on windows: >> >> Thread.new {loop{print 'a';sleep(0.1)}} >> Thread.new {loop{print 'b';sleep(0.214)}} >> sleep(2) > >Try it without the sleeps, but with priorities set differently. Under >Unix, and with big enough loop values, the threads will loop in >accordance with their priorities. Under Windows, one gets exclusive >control. > So the workaround is to make sure that you don't set any thread priorities in Windows? I didn't see any problem with threads on windows when I tried them there, but I didn't give any threads priority either. BTW: is this a cygwin problem? Phil