Page MenuHomeFreeBSD

netgraph/ng_bridge: Avoid cache thrashing
ClosedPublic

Authored by donner on Feb 11 2021, 11:12 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Dec 1, 8:58 PM
Unknown Object (File)
Mon, Nov 25, 6:46 PM
Unknown Object (File)
Mon, Nov 25, 2:23 PM
Unknown Object (File)
Sat, Nov 23, 7:11 AM
Unknown Object (File)
Thu, Nov 21, 11:08 AM
Unknown Object (File)
Wed, Nov 20, 6:01 PM
Unknown Object (File)
Tue, Nov 19, 3:50 PM
Unknown Object (File)
Thu, Nov 14, 2:19 PM
Subscribers

Details

Summary

Hint the compiler, that the branch is taken at most once per second.
Only in this case the memory line needs to be written. This will
reduce the amount of cache trashing during forward of most frames.

Suggested by: @zec

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

donner retitled this revision from netgraph&/ng_bridge: Avoid cache thrashing to netgraph/ng_bridge: Avoid cache thrashing.Feb 11 2021, 11:13 PM
donner added a reviewer: network.

Rebase after other changes.

This revision is now accepted and ready to land.May 13 2021, 5:00 PM
This revision was automatically updated to reflect the committed changes.