[sldev] Multithreading, Garbage collection, Caching

David Fries david at fries.net
Sun Mar 18 08:43:37 PDT 2007

On Sun, Mar 18, 2007 at 05:06:07PM +0200, Skal Tura wrote:
> Also, you are wrong about the part that there is no use using multiple
> threads without multiple
> cores, performance wise.
> Well, what happens in a single-thread, single-process app when some function
> all of sudden
> freezes for a moment, waiting for Disk I/O, Network I/O or something along
> those lines?
> Whole app freezes for that time period. This is MOST likely what i'm
> experiencing.

If you properly code your program to use non-blocking network and IO
then the need for more threads than cpus goes away.  Some problems
lend themselves to multiple threads, but saying that one thread has to
block like that is just wrong.  Granted you can write a program that
would block, but blame the programmer, multiple threads could block
just as easily.

David Fries <david at fries.net>
http://fries.net/~david/ (PGP encryption key available)

More information about the SLDev mailing list