[MEDIUM] optimize I/O by detecting system starvation
authorWilly Tarreau <w@1wt.eu>
Sun, 3 Jun 2007 12:10:36 +0000 (14:10 +0200)
committerWilly Tarreau <w@1wt.eu>
Sun, 3 Jun 2007 14:05:39 +0000 (16:05 +0200)
commitab3e1d313cc581ffa96530579cfa6580b2248f50
tree34045058be2ca2d2e4ef3f472a2e9538dd7261a6
parentfa64558402913053c0559423590e667a2be27eac
[MEDIUM] optimize I/O by detecting system starvation

Compare the results of recv/send with the parameter passed and
detect whether the system has no free buffer space for send()
or has no data anymore for recv(). This dramatically reduces
the number of syscalls (by about 23%).
src/stream_sock.c
tests/io_limits.txt [new file with mode: 0644]