<div dir="ltr">Hi Jaromir,<div><br></div><div>I knew that I had some old code which dealt with this, which I looked up and found this comment I wrote years ago:</div><div>_____</div><div> "In Feb, 2016, Eliot changed process scheduling from longest suspended process getting priority, to the prior process which was running when it was pre-empted by a higher-priority process.<br>        This means that rudimentary concurrency control can be implemented without Semaphores, but just by yielding at an appropriate time.<br>   The following sets it back to longest-waiting getting next run-priority."<br>        Smalltalk processPreemptionYields: true.<br></div><div>_____</div><div><br></div><div>I prefer the legacy Smalltalk behavior, i.e., set to true, because you get concurrency across processes at equal priority, but I am looking forward to expert clarification on whether I'm running a "broken policy".  I'm hoping Eliot only meant that in some specific usage context.  If so, I'm not sure why we would've chosen to make the non-backward-compatible behavior the default.</div><div><br></div><div> - Chris</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Feb 1, 2021 at 12:16 AM jaromir <<a href="mailto:m@jaromir.net" target="_blank">m@jaromir.net</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">> processPreemptionYields = true is a clearly broken policy (as your<br>
transcript bugs show) and is only supported for backwards compatibility. <br>
<br>
Thanks! May I ask why processPreemptionYields = true should be a broken<br>
policy? The Transcript is broken, can be fixed and the bug disappears. I'd<br>
say one's code should better be independent of the processPreemptionYields<br>
setting anyway. Assuming the order of processes is always guaranteed by<br>
processPreemptionYields = false may lead e.g. to using Processor yield<br>
rather than semaphores to synchronize processes etc. (I try to test my code<br>
against both settings to make sure it works)<br>
<br>
Thanks again,<br>
Jaromir<br>
<br>
<br>
<br>
--<br>
Sent from: <a href="http://forum.world.st/Squeak-Dev-f45488.html" rel="noreferrer" target="_blank">http://forum.world.st/Squeak-Dev-f45488.html</a><br>
<br>
</blockquote></div>