Hmmm, ok, seems I was in error, the reason is still not clear as to why it doesn't work properly, but it seems that the threads are taking so long to spawn that it seems like the process is serial. It seems to take about a second for threads->new() to return, very odd, but it doesn't always happen as a small script I wrote to prove myself wrong ran fine (as long as I joined everything by the end of the block).
Any ideas? It seems whatever way I try and implement this, it is just not going to work. Ray -----Original Message----- From: Elizabeth Mattijsen [mailto:[EMAIL PROTECTED]] Sent: 23 July 2002 15:31 To: Arthur Bergman Cc: Ray Hilton; [EMAIL PROTECTED] Subject: Re: threads in threads? At 04:26 PM 7/23/02 +0200, Arthur Bergman wrote: >>Hmmm.. are they testing serialization as well? I just realized that the >>multi-thread job submission test in Thread::Pool just tests whether the >>jobs are handled in the right order, but not whether they're really >>handled in parallel. On the other hand, some tests would take a _lot_ >>longer than they would when done in parallel, so I guess it does >>parallellize properly... >You have a big SMP box or something? Who? Me? Nope, small single CPU Linux box, left over from the time I had plenty of machines like that... It's just if you have a very small testing task (such as simply returning a value), I found that many tasks get handled by a single thread before context switching takes place. A random sleep() stops that quite nicely... ;-) Liz
