]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MINOR: threads/fd: Use a bitfield to know if there are FDs for a thread in the FD...
authorChristopher Faulet <cfaulet@haproxy.com>
Mon, 15 Jan 2018 10:57:03 +0000 (11:57 +0100)
committerWilly Tarreau <w@1wt.eu>
Tue, 23 Jan 2018 14:39:10 +0000 (15:39 +0100)
commit69553fe62c5c69753d1862a3e74740a1ff6c4d8d
tree4ecc068bfdb50d17895c62d6771080cfcfb5de87
parentd80cb4ee1386cb5853170371d11e41284739e9d4
MINOR: threads/fd: Use a bitfield to know if there are FDs for a thread in the FD cache

A bitfield has been added to know if there are some FDs processable by a
specific thread in the FD cache. When a FD is inserted in the FD cache, the bits
corresponding to its thread_mask are set. On each thread, the bitfield is
updated when the FD cache is processed. If there is no FD processed, the thread
is removed from the bitfield by unsetting its tid_bit.

Note that this bitfield is updated but not checked in
fd_process_cached_events. So, when this function is called, the FDs cache is
always processed.

[wt: should be backported to 1.8 as it will help fix a design limitation]
include/proto/fd.h
src/fd.c