From: Willy Tarreau Date: Mon, 11 Aug 2025 15:36:39 +0000 (+0200) Subject: OPTIM: connection: align connection pools to 64 X-Git-Tag: v3.3-dev7~32 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=c2687f587e95927831b22ae6d8d7a618d2731b5c;p=thirdparty%2Fhaproxy.git OPTIM: connection: align connection pools to 64 The struct connection is used a lot by the muxes during many operations, particularly at the beginning of the struct (flags, ctrl, xprt and mux). We definitely want this one not to be falsely shared with another thread, so let's align the pools to a cache line. --- diff --git a/src/connection.c b/src/connection.c index 0235e3a2a..18b4a4111 100644 --- a/src/connection.c +++ b/src/connection.c @@ -38,7 +38,7 @@ #include -DECLARE_TYPED_POOL(pool_head_connection, "connection", struct connection); +DECLARE_TYPED_POOL(pool_head_connection, "connection", struct connection, 0, 64); DECLARE_TYPED_POOL(pool_head_conn_hash_node, "conn_hash_node", struct conn_hash_node); DECLARE_TYPED_POOL(pool_head_sockaddr, "sockaddr", struct sockaddr_storage); DECLARE_TYPED_POOL(pool_head_pp_tlv_128, "pp_tlv_128", struct conn_tlv_list, HA_PP2_TLV_VALUE_128);