]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MINOR: cpu-topo: add a CPU policy setting to the global section
authorWilly Tarreau <w@1wt.eu>
Mon, 3 Mar 2025 12:44:11 +0000 (13:44 +0100)
committerWilly Tarreau <w@1wt.eu>
Fri, 14 Mar 2025 17:33:16 +0000 (18:33 +0100)
commit156430ceb60f603d67ab60271ab8586fe4500a0e
tree660d7529e0743e909f4c5199fbd6e3500814b8f1
parent9a8e8af11a7fa605d9b43f1a39df5d0e71d49ac8
MINOR: cpu-topo: add a CPU policy setting to the global section

We'll need to let the user decide what's best for their workload, and in
order to do this we'll have to provide tunable options. For that, we're
introducing struct ha_cpu_policy which contains a name, a description
and a function pointer. The purpose will be to use that function pointer
to choose the best CPUs to use and now to set the number of threads and
thread-groups, that will be called during the thread setup phase. The
only supported policy for now is "none" which doesn't set/touch anything
(i.e. all available CPUs are used).
include/haproxy/cpu_topo-t.h
include/haproxy/cpu_topo.h
src/cpu_topo.c
src/thread.c