From: Alexander Lobakin <aleksander.lobakin@intel.com>
To: Jesper Dangaard Brouer <jbrouer@redhat.com>
Cc: brouer@redhat.com, bpf@vger.kernel.org, netdev@vger.kernel.org,
Stanislav Fomichev <sdf@google.com>,
martin.lau@kernel.org, ast@kernel.org, daniel@iogearbox.net,
yoong.siang.song@intel.com, anthony.l.nguyen@intel.com,
intel-wired-lan@lists.osuosl.org, xdp-hints@xdp-project.net,
Sasha Neftin <sasha.neftin@intel.com>
Subject: [xdp-hints] Re: [PATCH bpf-next V1] igc: enable and fix RX hash usage by netstack
Date: Mon, 27 Feb 2023 15:24:30 +0100 [thread overview]
Message-ID: <2674df91-ec6f-baf7-e2cc-aa0fd807cb2c@intel.com> (raw)
In-Reply-To: <6a7469e1-1db0-2f62-909b-9dcd65c50937@intel.com>
From: Alexander Lobakin <aleksander.lobakin@intel.com>
Date: Fri, 24 Feb 2023 17:41:58 +0100
> From: Jesper Dangaard Brouer <jbrouer@redhat.com>
> Date: Wed, 22 Feb 2023 16:00:30 +0100
[...]
>>>>> Why define those empty if you could do a bound check in the code
>>>>> instead? E.g. `if (unlikely(bigger_than_9)) return PKT_HASH_TYPE_L2`.
>>>>
>>>> Having a branch for this is likely slower. On godbolt I see that this
>>>> generates suboptimal and larger code.
BTW, it's funny that when I proposed an optimization, you said "it makes
no sense on 2.5G NICs", but when you omit bounds checking and just
extend the array with zero fields, it suddenly starts making sense to
save a couple instructions :D
(just an observation)
>>>
>>> But you have to verify HW output anyway, right? Or would like to rely on
>>> that on some weird revision it won't spit BIT(69) on you?
[...]
Thanks,
Olek
next prev parent reply other threads:[~2023-02-27 14:25 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-02-10 15:07 [xdp-hints] " Jesper Dangaard Brouer
2023-02-10 15:23 ` [xdp-hints] " Jesper Dangaard Brouer
2023-02-14 13:21 ` Alexander Lobakin
2023-02-16 16:46 ` Jesper Dangaard Brouer
2023-02-20 15:39 ` Alexander Lobakin
2023-02-22 15:00 ` Jesper Dangaard Brouer
2023-02-24 16:41 ` Alexander Lobakin
2023-02-27 14:24 ` Alexander Lobakin [this message]
2023-02-14 15:00 ` [xdp-hints] Re: [Intel-wired-lan] " Paul Menzel
2023-02-14 15:13 ` Alexander Lobakin
2023-02-16 15:17 ` Jesper Dangaard Brouer
2023-02-16 15:43 ` Alexander Lobakin
2023-02-27 14:53 ` Alexander Lobakin
2023-02-16 13:29 ` Jesper Dangaard Brouer
2023-02-16 15:34 ` Alexander Lobakin
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
List information: https://lists.xdp-project.net/postorius/lists/xdp-hints.xdp-project.net/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2674df91-ec6f-baf7-e2cc-aa0fd807cb2c@intel.com \
--to=aleksander.lobakin@intel.com \
--cc=anthony.l.nguyen@intel.com \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=brouer@redhat.com \
--cc=daniel@iogearbox.net \
--cc=intel-wired-lan@lists.osuosl.org \
--cc=jbrouer@redhat.com \
--cc=martin.lau@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=sasha.neftin@intel.com \
--cc=sdf@google.com \
--cc=xdp-hints@xdp-project.net \
--cc=yoong.siang.song@intel.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox