Hi Przemyslaw,

Przemyslaw Czerpak wrote:
> And I've got the answer. At least on my computer it's a hardware issue.
> In -gc[0-2] mode each threads makes:
> 
>       if( ! --uiPolls )
>          hb_inkeyPoll();
> 
> in main HVM loop. Simple hack even acceptable in ST programs is killing
> the performance in ST ones. Important is not hb_inkeyPoll() call (you can
> comment it but it will not change the results) but --uiPolls.
> Each thread decrements the same memory variable and it causes some horrible
> synchronization issues between CPUs on multi CPU machines which kill the
> performance. It's a hardware issue so I do not know how big overhead it
> may cause on other machines. I'm very interesting in your results.
> Please rebuild Harbour with -DHB_GUI macro or compile speedtst.prg with
> -gc3 and compare results.
> 

I did a full rebuild of latest svn code and I've added -gc3 to my modified
speedtst.prg and here are the results.

 3 - ascan(a,{|x|x==i%ARR_LEN}) ->                        22.03
 2 - ascan(a2,c+chr(i%64+64)) ->                           3.72
============================================================
 0 - total application time:                              55.27
total real time:                                     55.27

So it decreased total time of a little less than some 10%

Best regards.

Maurilio.

-- 
 __________
|  |  | |__| Maurilio Longo
|_|_|_|____| farmaconsult s.r.l.



Attachment: speedtst.log
Description: application/log

_______________________________________________
Harbour mailing list
Harbour@harbour-project.org
http://lists.harbour-project.org/mailman/listinfo/harbour

Reply via email to