All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel.org>
To: ecree.xilinx@gmail.com, habetsm.xilinx@gmail.com
Cc: "Íñigo Huguet" <ihuguet@redhat.com>,
	davem@davemloft.net, netdev@vger.kernel.org
Subject: Re: [PATCH net-next resend 0/2] sfc: optimize RXQs count and affinities
Date: Fri, 18 Feb 2022 21:19:11 -0800	[thread overview]
Message-ID: <20220218211911.432f3811@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com> (raw)
In-Reply-To: <20220216094139.15989-1-ihuguet@redhat.com>

On Wed, 16 Feb 2022 10:41:37 +0100 Íñigo Huguet wrote:
> In sfc driver one RX queue per physical core was allocated by default.
> Later on, IRQ affinities were set spreading the IRQs in all NUMA local
> CPUs.
> 
> However, with that default configuration it result in a non very optimal
> configuration in many modern systems. Specifically, in systems with hyper
> threading and 2 NUMA nodes, affinities are set in a way that IRQs are
> handled by all logical cores of one same NUMA node. Handling IRQs from
> both hyper threading siblings has no benefit, and setting affinities to one
> queue per physical core is neither a very good idea because there is a
> performance penalty for moving data across nodes (I was able to check it
> with some XDP tests using pktgen).
> 
> This patches reduce the default number of channels to one per physical
> core in the local NUMA node. Then, they set IRQ affinities to CPUs in
> the local NUMA node only. This way we save hardware resources since
> channels are limited resources. We also leave more room for XDP_TX
> channels without hitting driver's limit of 32 channels per interface.
> 
> Running performance tests using iperf with a SFC9140 device showed no
> performance penalty for reducing the number of channels.
> 
> RX XDP tests showed that performance can go down to less than half if
> the IRQ is handled by a CPU in a different NUMA node, which doesn't
> happen with the new defaults from this patches.

Martin, Ed, any thoughts?

      parent reply	other threads:[~2022-02-19  5:19 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-28 15:19 [PATCH net-next 0/2] sfc: optimize RXQs count and affinities Íñigo Huguet
2022-01-28 15:19 ` [PATCH net-next 1/2] sfc: default config to 1 channel/core in local NUMA node only Íñigo Huguet
2022-01-28 22:27   ` Jakub Kicinski
2022-02-07 15:03     ` Íñigo Huguet
2022-02-07 16:53       ` Jakub Kicinski
2022-02-10  9:35         ` Íñigo Huguet
2022-02-10 16:22           ` Jakub Kicinski
2022-02-11 11:05             ` Íñigo Huguet
2022-02-11 19:01               ` Jakub Kicinski
2022-02-14  7:22                 ` Íñigo Huguet
2022-02-19 13:53                 ` Martin Habets
2022-01-28 15:19 ` [PATCH net-next 2/2] sfc: set affinity hints " Íñigo Huguet
2022-02-16  9:41 ` [PATCH net-next resend 0/2] sfc: optimize RXQs count and affinities Íñigo Huguet
2022-02-16  9:41   ` [PATCH net-next resend 1/2] sfc: default config to 1 channel/core in local NUMA node only Íñigo Huguet
2022-02-19 13:50     ` Martin Habets
2022-02-16  9:41   ` [PATCH net-next resend 2/2] sfc: set affinity hints " Íñigo Huguet
2022-02-19 13:51     ` Martin Habets
2022-02-19  5:19   ` Jakub Kicinski [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220218211911.432f3811@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com \
    --to=kuba@kernel.org \
    --cc=davem@davemloft.net \
    --cc=ecree.xilinx@gmail.com \
    --cc=habetsm.xilinx@gmail.com \
    --cc=ihuguet@redhat.com \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.