From: Peter C. M. <pcm...@em...> - 2005-05-02 18:07:32
|
Yes, but before I do, I just want to think a few minutes about the livelock detection - it seems awfully close -- Peter On May 2, 2005, at 11:01 AM, Willem Visser wrote: > I meant in POR transitions, but the same will happen in atomic steps. > > This is a pathological case I admit, but it is a problem - if someone > writes a program with a meaningless endless loop, then even under a > normal VM this will be bad. However if someone writes a meaningless > endless loop in one thread and a bug in another thread then we'll never > find the bug if the meaningless thread gets scheduled first. > > I think the counter would be good - it will fix this problem. But set > it > real high so that we don't unnecessarily break por-steps. > >> -----Original Message----- >> From: Peter C. Mehlitz [mailto:pcm...@em...] >> Sent: Monday, May 02, 2005 10:49 AM >> To: wv...@em... >> Cc: jp...@em... >> Subject: Re: Endless loops and POR? >> >> You mean POR transitions or atomic sections? You're right that we >> currently have no "progress" check, but why wouldn't a normal VM loop >> endlessly in this case? Or do you mean starvation, where another > thread >> would exit, but a daemon does endless loops w/o boundary steps so the >> first one doesn't get scheduled? Right, that would be a problem >> >> should be easy to implement though, a simple counter should do. Can >> actually be requested from outside (ThreadInfo.yield()) >> >>> Do you know whether there is a flag/option to break loops in atomic >>> steps? If not then we still have the bug that you could cycle > forever >>> in >>> a loop that accesses no external variables and doesn't change state > - >>> no >>> this is rare, but someone found it :-) > |