mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2024-12-12 22:44:32 +00:00
1208266356
If a file descriptor is being polled, and it stopped (eg: buffer full or end of response), then re-enabled, currently what happens is that the polling is disabled, then the fd is enabled in speculative mode, an I/O attempt is made, it loses (otherwise the FD would surely not have been polled), and the polled is enabled again. This is too bad, especially with HTTP keep-alive on the server side where all operations are performed at once before going back to the poll loop. Now we improve the behaviour by ensuring that if an fd is still being polled, when it's enabled after having been disabled, we re-enable the polling. Doing so saves a number of syscalls and useless wakeups, and results in a significant performance gain on HTTP keep-alive. A 11% increase has been observed on the HTTP request rate in keep-alive thanks to this. It could be considered as a bug fix, but there was no harm with the current behaviour, except extra syscalls. |
||
---|---|---|
.. | ||
common | ||
import | ||
proto | ||
types |