[Vm-dev] Running Alien on Windows
siguctua at gmail.com
Tue May 4 01:51:59 UTC 2010
Btw, i am still insist that making interpret() reentrant and calling
ioProcessEvents() outside of it, so it won't interfere with interpreter's
state/temps/stack etc . would be much better and safer.
> This cames from newspeak sources:
> /* - Vassili, May 2008:
> * The following is significantly revised compared to the original
> Squeak implementation.
> * The ioProcessEvent() function called from inside the interpreter
> loop is now guarded
> * with a lock called inIoProcessEvents. When the lock is > 0 the
> function is effectively
> * disabled. The lock is incremented on entering a callback and
> decremented on returning
> * from a callback. The lock is also accessible at the image level,
> and Smalltalk code
> * in the image can turn off this asynchronous event delivery. In that
> case it should
> * make its own arrangements to pick up and deliver events. For that,
> an unguarded version
> * of the same function is provided called primDrainEventQueue() which
> is accessible
> * as a primitive from inside the image.
> /* This counter prevents reentering the ioProcessEvents message pump. It is
> * also incremented in the callback machinery (in thunkEntry) since the image
> * may be running its own message pump for the native GUI.
> int inIoProcessEvents = 0;
> int ioProcessEvents(void)
> int result;
> if (inIoProcessEvents)
> return 1;
> if (fRunService && !fWindows95)
> return 1;
> result = primDrainEventQueue();
> if (inIoProcessEvents > 0)
> return result;
> So, since it may require more patching in order to support this flag, i just
> commented its use by alien plugin and finally were able to
> successfully build it.
> I am not sure if it in working state or not.
> For those who wanna test it, you can get it here:
> (i placed it there temporarily, so please, pick it up because i will
> remove it in a few days)
> Best regards,
> Igor Stasenko AKA sig.
Igor Stasenko AKA sig.
More information about the Vm-dev