* Re: [Linux-kernel-mentees][PATCH 0/2] reorder members of structures in virtio_net for optimization [not found] <20200930051722.389587-1-anant.thazhemadam@gmail.com> @ 2020-10-03 2:06 ` David Miller 2020-10-03 18:43 ` Michael S. Tsirkin 0 siblings, 1 reply; 2+ messages in thread From: David Miller @ 2020-10-03 2:06 UTC (permalink / raw) To: anant.thazhemadam Cc: hawk, daniel, mst, netdev, john.fastabend, ast, virtualization, kuba, bpf, linux-kernel-mentees, linux-kernel From: Anant Thazhemadam <anant.thazhemadam@gmail.com> 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. _______________________________________________ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization ^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [Linux-kernel-mentees][PATCH 0/2] reorder members of structures in virtio_net for optimization 2020-10-03 2:06 ` [Linux-kernel-mentees][PATCH 0/2] reorder members of structures in virtio_net for optimization David Miller @ 2020-10-03 18:43 ` Michael S. Tsirkin 0 siblings, 0 replies; 2+ messages in thread From: Michael S. Tsirkin @ 2020-10-03 18:43 UTC (permalink / raw) To: David Miller Cc: anant.thazhemadam, hawk, daniel, netdev, john.fastabend, ast, virtualization, kuba, bpf, linux-kernel-mentees, linux-kernel On Fri, Oct 02, 2020 at 07:06:38PM -0700, David Miller wrote: > From: Anant Thazhemadam <anant.thazhemadam@gmail.com> > 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. Agree wholeheartedly. -- MST _______________________________________________ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization ^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-10-03 18:43 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20200930051722.389587-1-anant.thazhemadam@gmail.com>
2020-10-03 2:06 ` [Linux-kernel-mentees][PATCH 0/2] reorder members of structures in virtio_net for optimization David Miller
2020-10-03 18:43 ` Michael S. Tsirkin
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).