I think any interoperability should have a reasonable limitations.
Otherwise, there is no way how to guarantee the system stability.

Squeak and Cog virtual machines can't run multiple native threads
interpreting smalltalk code, which means that
any callback(s) will be forced to be handled in single (VM) thread.

Apparently callbacks from foreign threads require a special checks to
be added to detect it and then serialize the call to vm thread.

And therefore, handling callback in different thread will require a
synchronization with it, which kills an idea of
invoking callback from different thread in a first place.

So, even if Alien will implement support of callbacks in non-VM
thread(s), the value of such feature are questionable,
because it simply kills the attempt(s) of foreign language to gain
performance benefits through exploiting multithreading.

Allowing to interpret smalltalk using multiple threads is another
story - see RoarVM :)

So, unless you running RoarVM, i don't see that it is reasonable to
support cross-thread callbacks.

-- 
Best regards,
Igor Stasenko AKA sig.

Reply via email to