> * At an invocation of yield/sleep, there is a non-zero chance that
> some other thread of equal or higher priority will be allowed to execute.
I'll say again that you can't require priority to play a part here. So if
you feel you must say this then it should just say "some other thread will
be allowed to execute".
> If you had a JVM which didn't
> support these minimal semantics, I can't imagine how you could
> possibly write multithreaded applications for it.
As long as you don't assume semantics for sleep or yield that are not
guaranteed then there is no problem writing multi-threaded applications. Of
course, some may be easier to write if you had stronger guarantees for sleep
and yield, but then some would be easier to write if you had guaranteed
priority preemptive scheduling or ...
JavaMemoryModel mailing list - http://www.cs.umd.edu/~pugh/java/memoryModel
This archive was generated by hypermail 2b29 : Thu Oct 13 2005 - 07:00:37 EDT