MINOR: dynbuf: make the buffer wait queue per thread
authorWilly Tarreau <w@1wt.eu>
Sat, 20 Feb 2021 10:38:56 +0000 (11:38 +0100)
committerWilly Tarreau <w@1wt.eu>
Wed, 10 Mar 2021 14:11:16 +0000 (15:11 +0100)
commit2214f349a81b14e8a3c129de5a45682fb8c628de
tree6f1ffe022dcbceb57a44b7327949a512e07f752a
parent55d78a76f653a9a1dcfa2ce5100fbe57ef4f5d5f
MINOR: dynbuf: make the buffer wait queue per thread

The buffer wait queue used to be global historically but this doest not
make any sense anymore given that the most common use case is to have
thread-local pools. Thus there's no point waking up waiters of other
threads after releasing an entry, as they won't benefit from it.

Let's move the queue head to the thread_info structure and use
ti->buffer_wq from now on.

(cherry picked from commit e8e5091510f667feeb36f68b8d2f4d9e8cf00dc0)
Signed-off-by: Willy Tarreau <w@1wt.eu>
include/haproxy/channel.h
include/haproxy/dynbuf.h
include/haproxy/tinfo-t.h
src/check.c
src/dynbuf.c
src/flt_spoe.c
src/mux_fcgi.c
src/mux_h1.c
src/mux_h2.c
src/stream.c