[e-lang] GridLock
Dr. Pierre Vignéras
pierre at vigneras.name
Fri Feb 2 03:17:33 CST 2007
On Thursday 01 February 2007 23:23, Kevin Reid wrote:
> On Feb 1, 2007, at 2:01, Dr. Pierre Vignéras wrote:
> > I have some questions concerning GridLock (mentionned in Event-Loop
> > Concurrency http://www.erights.org/elib/concurrency/event-loop.html).
>
> ...
>
> > Are GridLocks E related? I mean do we found GridLocks in a traditional
> > thread-based concurrent OO Application? (I guess yes, and so they
> > are not E related).
> A program with a gridlock bug has at least one buffer and a procedure
> for emptying it which fills some buffer (not necessarily the same one).
So this means that is it not related to E.
> Note that a buffer does not necessarily hold just bits: for example,
> if a program starts threads which end up waiting for some condition
> before proceeding, the collection of waiting threads constitutes a
> buffer.
I don't see where this is different to a deadlock. What are the basic
conditions for a gridlock (what is actually locking)? In your example, it
seems that we have a sort of producer/consumer algorithm.
By the way, you use the term gridlock. Why Grid?
> > Are GridLocks deterministics? (I guess no)
>
> They're deterministic if the available space of the particular buffer
> is deterministic and every process which fills it is deterministic.
Ok.
> > In the case of a gridlock, can we recover from it at runtime (For
> > example, by increasing the buffer space and restarting something
> > (request or thread, ...))?
No reply? ;-)
> > How to prevent gridlocks?
>
> By designing a program so that parts of it which empty buffers can
> make progress without additional buffer space.
Still not clear to me.
Regards and Thanks for your help.
--
Dr. Pierre Vignéras
http://www.vigneras.name/pierre
More information about the e-lang
mailing list