in reply to Perl 5.8.2 thread is much worse

Just to comment about sysread(). If I'm not wrong, for sockets you can't try to read more than 1024*8 bytes per time with sysread()! At least with Perl-5.6.1 the bug exists. But since you are using the system resource I don't know if this is really a bug.

Soo, for portability use read(), and you will ensure that you are reading all the data. (As documented in the Perl POD).

Graciliano M. P.
"Creativity is the expression of the liberty".