Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search

[REBOL] Re: forever loops and cpu usage

From: maarten:vrijheid at: 8-Feb-2004 8:49

In a multitasking environment, you take what you can get. So a forever loop tries to eat up the cpu. Inserting a wait 0.002 (I found the number by experiment on Win/Lin two years ago) behaviour is normal. Especially when doing: some-port-list forever [ wait/all compose [ (some-port-list) 0] ..... ] when I changed the 0 to 0.002 I had a high-performance, non-blocking IO-engine that turned into RUgby a few months later. And didn't ate the CPU..... --Maarten Paul Tretter wrote: