Page MenuHomeFreeBSD

Use new FIB4 KPI in ip_tryforward()
ClosedPublic

Authored by ae on Nov 15 2016, 9:21 AM.
Tags
None
Referenced Files
Unknown Object (File)
Nov 17 2024, 3:30 PM
Unknown Object (File)
Oct 29 2024, 11:46 AM
Unknown Object (File)
Oct 14 2024, 8:23 AM
Unknown Object (File)
Oct 5 2024, 1:37 AM
Unknown Object (File)
Oct 2 2024, 5:30 AM
Unknown Object (File)
Oct 2 2024, 4:24 AM
Unknown Object (File)
Sep 30 2024, 12:30 PM
Unknown Object (File)
Sep 30 2024, 1:33 AM
Subscribers

Details

Summary

ip_tryforward() is used in run to completion forwarding scenario. Current rtalloc API has serious problem on system with many CPU cores and, especially, when network cards has many concurrent working queues. Lock contention on the rtentry's mutex kills the performance.
This patch changes ip_tryforward() to use new FIB4 KPI. The main benefit this KPI gets from holding all needed information in the on-stack allocated structure, so there is no need to hold rtentry mutex, thus there is no lock contention.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

ae retitled this revision from to Use new FIB4 KPI in ip_tryforward().
ae updated this object.
ae edited the test plan for this revision. (Show Details)
ae added reviewers: melifaro, olivier.
ae set the repository for this revision to rS FreeBSD src repository - subversion.
olivier edited edge metadata.

I can't understand the code, but regarding only the performance benefit it's great :-)

Improvement on a 8 cores Intel Xeon with Chelsio, full details:

graph.png (768×1 px, 54 KB)

Improvement on a 4cores Atom, full detail :

graph.png (768×1 px, 21 KB)

Improvement on a 8 cores Atom with Chelsio, full details:

graph.png (1×1 px, 47 KB)

This revision is now accepted and ready to land.Nov 16 2016, 6:39 AM
This revision was automatically updated to reflect the committed changes.