Page MenuHomeFreeBSD

netgraph/ng_bridge: Avoid cache thrashing
ClosedPublic

Authored by donner on Feb 11 2021, 11:12 PM.
Tags
None
Referenced Files
F141921826: D28601.id89143.diff
Mon, Jan 12, 1:46 PM
Unknown Object (File)
Sat, Jan 10, 4:41 PM
Unknown Object (File)
Fri, Dec 26, 7:19 AM
Unknown Object (File)
Dec 12 2025, 2:32 PM
Unknown Object (File)
Nov 28 2025, 4:10 AM
Unknown Object (File)
Nov 18 2025, 12:39 PM
Unknown Object (File)
Nov 18 2025, 12:39 PM
Unknown Object (File)
Nov 18 2025, 12:39 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.