Thread (5 messages) 5 messages, 3 authors, 2020-10-03

Re: [Linux-kernel-mentees][PATCH 0/2] reorder members of structures in virtio_net for optimization

From: David Miller <davem@davemloft.net>
Date: 2020-10-03 02:06:44
Also in: bpf, linux-kernel-mentees, lkml, virtualization

From: Anant Thazhemadam <redacted>
Date: Wed, 30 Sep 2020 10:47:20 +0530
The structures virtnet_info and receive_queue have byte holes in 
middle, and their members could do with some rearranging 
(order-of-declaration wise) in order to overcome this.

Rearranging the members helps in:
  * elimination the byte holes in the middle of the structures
  * reduce the size of the structure (virtnet_info)
  * have more members stored in one cache line (as opposed to 
    unnecessarily crossing the cacheline boundary and spanning
    different cachelines)

The analysis was performed using pahole.

These patches may be applied in any order.
What effects do these changes have on performance?

The cache locality for various TX and RX paths could be effected.

I'm not applying these patches without some data on the performance
impact.

Thank you.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help