dyoo / whalesong

Whalesong: Racket to JavaScript compiler
http://hashcollision.org/whalesong
250 stars 30 forks source link

Trampoline scheduling must get exclusive lock to prevent foreign functions from coming in #70

Closed dyoo closed 12 years ago

dyoo commented 12 years ago

The bug that Jeanette's seeing is due to a nasty bug with makeRestartFunction/scheduleTrampoline, which is supposed to hold an exclusive lock over the evaluator, and exposed functions, which are not waiting properly. I'm seeing calls where the trampoline is waiting to get restored, and suddenly control flow is walking back into code that it shouldn't get into.

dyoo commented 12 years ago

Release 11 has a temporary patch around this issue, but it's not the Right Thing to do.

I'd want to do it with the with-exclusive-lock branch, but I'm not smart enough yet to figure out why the approach is failing. I'll look at this again when I'm less stoooopid.

dyoo commented 12 years ago

It appears to be working with more stability now. Closing issue.