MAJOR: ring: drop the now unneeded lock
authorWilly Tarreau <w@1wt.eu>
Wed, 28 Feb 2024 16:06:39 +0000 (17:06 +0100)
committerWilly Tarreau <w@1wt.eu>
Mon, 25 Mar 2024 17:34:19 +0000 (17:34 +0000)
commit9e99cfbeb66f4a8c470780aad19a677652d5c04b
tree985dcba3a414c59bc83960fb0aaf1e17bef62ebb
parentcb482f92c4caa401dbc0ed7c564efa275af3b5c1
MAJOR: ring: drop the now unneeded lock

It was only used to protect the list which is now an mt_list so it
doesn't provide any required protection anymore. It obviously also
used to provide strict ordering between the writer and the reader
when the writer started to update the messages, but that's now
covered by the oredered tail updates and updates to the readers
count to protect the area.

The message rate on small thread counts (up to 12) saw a boost of
roughly 5% while on large counts while for large counts it lost
about 2% due to some contention now becoming visible elsewhere.
Typical measures are 6.13M -> 6.61M at 3C6T, and 1.88 -> 1.92M at
24C48T on the EPYC.
include/haproxy/ring-t.h
src/ring.c
src/sink.c