Remove VM-locking yield mode per discussion

This commit is contained in:
Tim Mickel 2016-06-30 16:57:12 -04:00
parent 9a7ab57f6f
commit 6daee9a70e
4 changed files with 2 additions and 44 deletions
src/engine

View file

@ -52,21 +52,13 @@ Thread.STATUS_RUNNING = 0;
*/
Thread.STATUS_YIELD = 1;
/**
* Thread status for a yielded thread that should block all other threads.
* This is desirable when an asynchronous capability should appear to take
* a synchronous amount of time (e.g., color touching color).
* @const
*/
Thread.STATUS_YIELD_BLOCK = 2;
/**
* Thread status for a finished/done thread.
* Thread is moved to this state when the interpreter
* can proceed with execution.
* @const
*/
Thread.STATUS_DONE = 3;
Thread.STATUS_DONE = 2;
/**
* Push stack and update stack frames appropriately.
@ -139,13 +131,6 @@ Thread.prototype.yield = function () {
this.status = Thread.STATUS_YIELD;
};
/**
* Yields the thread and blocks other threads until unyielded.
*/
Thread.prototype.yieldAndBlock = function () {
this.status = Thread.STATUS_YIELD_BLOCK;
};
/**
* Add an execution-synced timeouts for this thread.
* See also: util/yieldtimers.js:timeout