Boost logo

Boost Users :

Subject: Re: [Boost-users] Thread object pointers. (solved)
From: Richard Damon (Richard_at_[hidden])
Date: 2010-08-03 20:33:08


On Tue, 3 Aug 2010 17:22:37 -0700, Albert Schueller
<schuelaw_at_[hidden]> wrote:

>> It matters because that's precisely what "join" is supposed
>> to do...... halt the calling thread until the "joined" thread is done.
>
>Why, in LISTING 1, doesn't
>
> thrd1.join();
> thrd2.join();
> thrd3.join();
>
>do the same thing, i.e. hold until thrd1 is complete, then do thrd2,
>then thrd3?
>
>Albert

It does, but AFTER starting all there threads.

Listing 1 does a:

Start1
Start2
Starr3
Join1
Join2
Join3

Listing 2 does
Start1
Join1
Start2
Join2
Start3
Join3

Richard Damon


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net