[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANn89i+akEWrHELBkZJQOxok-ZfYy+FNPUWdPEfB6c4YyWLqJA@mail.gmail.com>
Date: Thu, 6 Sep 2018 12:33:58 -0700
From: Eric Dumazet <edumazet@...gle.com>
To: Olof Johansson <olof@...om.net>
Cc: David Miller <davem@...emloft.net>,
Neil Horman <nhorman@...driver.com>,
Marcelo Ricardo Leitner <marcelo.leitner@...il.com>,
Vladislav Yasevich <vyasevich@...il.com>,
Herbert Xu <herbert@...dor.apana.org.au>,
Alexey Kuznetsov <kuznet@....inr.ac.ru>,
Hideaki YOSHIFUJI <yoshfuji@...ux-ipv6.org>,
linux-crypto@...r.kernel.org, LKML <linux-kernel@...r.kernel.org>,
linux-sctp@...r.kernel.org, netdev <netdev@...r.kernel.org>,
linux-decnet-user@...ts.sourceforge.net,
kernel-team <kernel-team@...com>
Subject: Re: [PATCH] net/sock: move memory_allocated over to percpu_counter variables
On Thu, Sep 6, 2018 at 12:21 PM Olof Johansson <olof@...om.net> wrote:
>
> Today these are all global shared variables per protocol, and in
> particular tcp_memory_allocated can get hot on a system with
> large number of CPUs and a substantial number of connections.
>
> Moving it over to a per-cpu variable makes it significantly cheaper,
> and the added overhead when summing up the percpu copies is still smaller
> than the cost of having a hot cacheline bouncing around.
I am curious. We never noticed contention on this variable, at least for TCP.
Please share some numbers with us.
Powered by blists - more mailing lists