<div dir="ltr">Hi Sebastián,<div><br></div><div> and welcome! Forgive me for not replying earlier.<br><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Oct 12, 2015 at 4:54 AM, Sebastián Krynski <span dir="ltr"><<a href="mailto:skrynski@gmail.com" target="_blank">skrynski@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"> <br><div dir="ltr"><div style="font-size:12.8px">Hello my name is Sebastián Krynski from Buenos Aires, Argentina.<br></div><div style="font-size:12.8px">Just writing to let you know that I'm starting to work on adding an atomic swap operator in Pharo , guaranteed not to be interrupted by the VM. The operator will be used this way:</div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">a :=: b</div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">meaning 'swap variable a with variable b'.</div><div style="font-size:12.8px">In order to do this I will be modifying the VM and the Compiler .</div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">I'm working under the direction of INRIA and Gabriela Arévalo.</div></div></blockquote></div><br>Give my regards to Gabriela!</div><div class="gmail_extra"><br></div><div class="gmail_extra">One thing is to consider multiple approaches. My friend Maurice Rabb (in the cc line) did a concurrent VM for a smalltalk-like language a few years ago now and he used something more akin to compare-and-swap. e.g.</div><div class="gmail_extra"><br clear="all"><div> var ?= value := expr</div><div><br></div><div>would set var to expire if it held the value var and answer true, otherwise it would not change the value of var and answer false.</div><div><br></div><div>Talk also to Igor Stasenko (also in the cc line) who has thought a lot about this and has written a prototype image-level scheduler based on (IIRC) a couple of different atomic operators.</div><div><br></div><div>Another thing to think about is goals. Making it convenient to implement lock-free data structures such as a lock-free thread-safe dictionary would be very good. Make sure you look at Cliff Click's work, e.g. at Azul such as <a href="https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=1&ved=0CB4QFjAAahUKEwj3vIfxzr3IAhUL-2MKHXtEAmY&url=http%3A%2F%2Fweb.stanford.edu%2Fclass%2Fee380%2FAbstracts%2F070221_LockFreeHash.pdf&usg=AFQjCNGruiZgjaUdA04f35QacGEAtW1bBA&sig2=CoqRwB1XF6Up1lPFdtZI5g">A Lock-Free, Wait-Free Hash Table</a>. Google <a href="https://www.google.com/search?client=safari&rls=en&q=cliff+click+azul+lock-free+data+structures&ie=UTF-8&oe=UTF-8">cliff click azul lock-free data structures</a>.</div><div><br></div><div>Finally, decide where you want to discuss this. My preference is for you to at least include vm-dev, since this is definitely to do with the byte code set and the VM. But the data structure piece and the use is more generally useful. So I see no problem including vm-dev, pharos-dev and the general purpose squeak list. The more the merrier.</div><div><br></div><div><br></div><div>A couple of questions: How long will your work with Gabriela last? Is this a master's project or a PhD or...?</div><div><br></div><div>Good luck!</div><div>_,,,^..^,,,_<br></div><div class="gmail_signature"><div dir="ltr"><div><span style="font-size:small;border-collapse:separate"><div>best, Eliot</div></span></div></div></div>
</div></div></div>