[squeak-dev] The Inbox: Compiler-mt.456.mcz

Marcel Taeumel marcel.taeumel at hpi.de
Tue Feb 2 13:22:34 UTC 2021


>  Try to remove the primitive from #yield and then it works ok

Yes, removing the primitive form #yield will introduce one (or more) suspension points because of the (rather complex) fallback implementation. Yet, I cannot do that in a test. :-)

Best,
Marcel
Am 02.02.2021 14:14:14 schrieb jaromir <m at jaromir.net>:
> However, I have no idea why the following happens:
>
> x := 0.
> [ [ x := 1 ] forkAt: 41 ] valueUnpreemptively.
> y := x == 1. "false :-("
>
>
> Or this:
>
> x := 0.
> [ [ x := 1 ] forkAt: 41 ] valueUnpreemptively.
> Transcript showln: 'foo'.
> y := x == 1. "false :-("

The reason is the #yield primitive 167 - it doesn't reflect the change of
priority as done in #valueUnpreemptively... Try to remove the primitive from
#yield and then it works ok
Regards,
Jaromir



--
Sent from: http://forum.world.st/Squeak-Dev-f45488.html

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20210202/ed0e6e56/attachment-0001.html>


More information about the Squeak-dev mailing list