Boost logo

Boost :

From: Larry Evans (cppljevans_at_[hidden])
Date: 2005-11-26 07:45:47

On 11/25/2005 05:05 PM, simon meiklejohn wrote:
> Deferral here means
> 1. Do something later
> 2. Let something else decide which thread will execute the work
> Its also handy where multiple entities in a program need to call into
> eachother, potentially recursively
> (A calls B calls A calls B) Better to break this recursion with queues of
> work items.

I'm guessing it could be used to demonstrate a multi-threaded program
could deadlock. IOW, the different threads in a program could be
"divided" into work_items which execute atomicly. Then by precisely
specifying the order in which the work_items in different threads are
executed, you demonstrate that the original program could deadlock.
I remember doing something like this with signals, where each
work_item, at the end of it's code, set a signal which the handler
caught and then dispatched to the next work_item, or something like

> So - any interest in more concrete code? More detailed explanations and
> scenarios?


Boost list run by bdawes at, gregod at, cpdaniel at, john at