j
: Next unread message k
: Previous unread message j a
: Jump to all threads
j l
: Jump to MailingList overview
Processes are not preemptive *at the same priority*. A higher priority process will preempt a lower one when whatever the higher one was waiting on (a Semaphore) becomes ready. So some choices:
- To share time between equal priority processes, use
'Processor yield' from time to time
Alternatively, put up one high priority process that does nothing but:
| delay | delay := Delay forMilliseconds: 50. [true] whileTrue:[delay wait].
Since the scheduler activates the processes in order all processes at the same priority will get a chance to run for 50msecs each. [note: the above seems to be a bit expensive but process switches are rather cheap].
- Andreas
squeak-dev@lists.squeakfoundation.org