Skip to content

gro: micro-optimize dev_gro_receive()

Alexander Lobakin lkml netdev 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest3 patches 1 replyIn review
  2. v14 patches 4 repliesSuperseded

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3gro: simplify gro_list_prepare()net/core/dev.c+4 -80 replies
2/3gro: consistentify napi->gro_hash[x] access in dev_gro_receive()net/core/dev.c+11 -110 replies
3/3gro: give 'hash' variable in dev_gro_receive() a less confusing namenet/core/dev.c+6 -60 replies

Reviews trailers per patch

None of the 3 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchEric Dumazet
SeriesR-b
1/3
2/3
3/3

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH v2 net-next 0/3] gro: micro-optimize dev_gro_receive()

This random series addresses some of suboptimal constructions used in the main GRO entry point.
The main body is gro_list_prepare() simplification and pointer usage optimization in dev_gro_receive() itself. Being mostly cosmetic, it gives like +10 Mbps on my setup to both TCP and UDP (both single- and multi-flow).

Since v1 [0]:
- drop the replacement of bucket index calculation with reciprocal_scale() since it makes absolutely no sense (Eric);
- improve stack usage in dev_gro_receive() (Eric);
- reverse the order of patches to avoid changes superseding.

[0] https://lore.kernel.org/netdev/[email protected]

Alexander Lobakin (3):
gro: simplify gro_list_prepare()
gro: consistentify napi->gro_hash[x] access in dev_gro_receive()
gro: give 'hash' variable in dev_gro_receive() a less confusing name

 net/core/dev.c | 40 ++++++++++++++++++----------------------
 1 file changed, 18 insertions(+), 22 deletions(-)

--
2.30.2