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:
a :=: b
meaning 'swap variable a with variable b'.
In order to do this I will be modifying the VM and the Compiler .
Sound cool! But isn���t that the same as
a become: b
? I even think that
tmp := a.
a := b.
b := tmp
is equivalent, since the VM only interrupts message sends, and in this case only byte code would be generated?
That���s not my area of expertise, so please correct me.
Cheers,
Max
I'm working under the direction of INRIA and Gabriela Ar��valo.