Przemyslaw, it starts misbehaving with three threads, look at this:
1 200 blocked fd504d64 2 200 blocked fd5080c4 3 200 running fd507008 4 200 ready fd507008 threads 3 and 4 are running and run to completion, thread 2 is blocked since it started, thread 1 is blocked waiting for the other threads to start. ( 200 is priority normal ) This is with 5 threads 1 200 blocked 2 200 blocked 3 200 blocked 4 200 blocked 5 200 running 6 200 ready They're all blocked but the last two. This is with 10 threads 1 200 blocked 2 200 running 3 200 blocked 4 200 blocked 5 200 ready 6 200 blocked 7 200 blocked 8 200 blocked 9 200 blocked 10 200 ready 11 200 ready Now four are running, the others are blocked since they were created ?! Maurilio. Maurilio Longo wrote: > Przemyslaw, > > it does not work, I did a full rebuild then I did build tests/speedtst with > hbmk2 -mt speedtst then I did a few tests. > > 1) speedtst --thread=2 runs ok > 2) speedtst --thread=20 deadlock after some time > 3) speedtst --thread=40 deadlocks as it starts, it creates 40 threads but all > threads are blocked. > > With previous code test 2 and 3 run ok to completion. > > Maurilio. > > [email protected] wrote: >> Revision: 10335 >> >> http://harbour-project.svn.sourceforge.net/harbour-project/?rev=10335&view=rev >> Author: druzus >> Date: 2009-02-18 18:55:32 +0000 (Wed, 18 Feb 2009) >> >> Log Message: >> ----------- >> 2009-02-18 20:00 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl) >> * harbour/include/hbthread.h >> * harbour/source/vm/thread.c >> ! added support for conditional variables working like in PTHREADS >> in OS2 builds - it fixes the problem with possible dead lock or >> starvation effect which can also cause dead lock in some cases. >> OS2 users please test current code. >> >> Modified Paths: >> -------------- >> trunk/harbour/ChangeLog >> trunk/harbour/include/hbthread.h >> trunk/harbour/source/vm/thread.c >> >> >> This was sent by the SourceForge.net collaborative development platform, the >> world's largest Open Source development site. >> _______________________________________________ >> Harbour mailing list >> [email protected] >> http://lists.harbour-project.org/mailman/listinfo/harbour >> > -- __________ | | | |__| Maurilio Longo |_|_|_|____| farmaconsult s.r.l. _______________________________________________ Harbour mailing list [email protected] http://lists.harbour-project.org/mailman/listinfo/harbour
