]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MEDIUM: task: perform a single tree lookup per run queue batch
authorWilly Tarreau <w@1wt.eu>
Wed, 10 Oct 2018 14:39:22 +0000 (16:39 +0200)
committerWilly Tarreau <w@1wt.eu>
Wed, 10 Oct 2018 14:42:46 +0000 (16:42 +0200)
commit0b25d5e99fa0442302eae1b9bd43e28cda5516a1
treee19ba3c525f8e44129697b50976e46591c9ca0b9
parentff57f1bbcf8af1e6389520aa845df5aa97ef55b6
MEDIUM: task: perform a single tree lookup per run queue batch

The run queue is designed to perform a single tree lookup and to
use multiple passes to eb32sc_next(). The scheduler rework took a
conservative approach first but this is not needed anymore and it
increases the processing cost of process_runnable_tasks() and even
the time during which the RQ lock is held if the global queue is
heavily loaded. Let's simply move the initial lookup to the entry
of the loop like the previous scheduler used to do. This has reduced
by a factor of 5.5 the number of calls to eb32sc_lookup_get() there.
src/task.c