[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ProgSoc] Threads



Glenn Williamson wrote:

>We've got an app here that _needs_ to be fairly real-time and responsive,
>unfortunately it's fairly clunky and slow .. I noticed once that it ran
>upwards of 50 concurrent threads .. is that too many? Is it a lot? Is there
>a suggested maximum number of concurrent threads?
>
>It's on MacOS-X 10.1.5, 256Mb RAM, 2 x PowerPC G4. Beastly enough (for a
>Mac, anyway).
>  
>
There's a pretty good chance that's too many threads, yes.  I just 
finished a performance tuning competition run by Intel on Dual Xeon 
boxes & got a 5x throughput increase by cutting the number of processing 
threads from 42 to 6.  (It was to optimize an XML database written in 
Java, but, you know).

The rule of thumb is to start at the number of threads you have 
processors & increase them until your CPU maxes out.  Any more than that 
& you're just thrashing.

- Paul



-
You are subscribed to the progsoc mailing list. To unsubscribe, send a
message containing "unsubscribe" to progsoc-request@nospam.progsoc.uts.edu.au.
If you are having trouble, ask owner-progsoc@nospam.progsoc.uts.edu.au for help.