Page MenuHomeFreeBSD

mbuf: move leaf_rcv union farther back in the pkthdr
ClosedPublic

Authored by gallatin on Tue, Oct 13, 12:11 AM.
Tags
None
Referenced Files
F176454366: D60691.diff
Sun, Oct 18, 11:56 PM
Unknown Object (File)
Sun, Oct 18, 10:32 AM
Unknown Object (File)
Sun, Oct 18, 5:14 AM
Unknown Object (File)
Sat, Oct 17, 8:46 PM
Unknown Object (File)
Sat, Oct 17, 3:11 PM
Unknown Object (File)
Sat, Oct 17, 2:00 PM
Unknown Object (File)
Fri, Oct 16, 1:00 PM
Unknown Object (File)
Fri, Oct 16, 9:28 AM
Subscribers

Details

Summary

When the leaf_rcv union was introduced to support ktls RX offload, it was put at
the front of the pkthhdr, and pushed the commonly accessed csum_flags and
rsstype into the next cacheline.

Given that csum_flags is accessed on every pkt sent and every pkt freed,
but the leaf_rcv fields are only used for ktls rx offload, it makes more sense
to have csum_flags in a cacheline that is already likely to be hot.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

People will probably start asking to bump __FreeBSD_version because this change layout of the structure directly used by drivers.

This revision is now accepted and ready to land.Tue, Oct 13, 3:36 AM