[Bug 248652] netmap: pkt-gen TX huge pps difference between 11-STABLE and 12-STABLE/CURRENT on ix & ixl NIC

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Mon Aug 31 22:06:03 UTC 2020


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=248652

--- Comment #9 from Vincenzo Maffione <vmaffione at FreeBSD.org> ---
Thanks a lot for the tests.
I think the way netmap tx is handled right now needs improvement.

As far as I can tell, in your setup TX interrupts are simply not used (ix and
ixl seem to use softirq for TX interrupt processing).
Your experiments with increasing kern.hz cause the interrupt rate of the OS
timer to increase, and therefore causing the iflib_timer() routine to be called
more often. Being called more often, the TX ring is cleaned up (TX credits
update) more often and therefore the application can submit new TX packets more
often, hence the improved pps.

However, clearly increasing kern.hz is not a viable approach.
I think we should try to use a separate timer for netmap TX credits update,
using higher resolution (e.g. callout_reset_sbt_on()), and maybe try to
dynamically adjust the timer period to become smaller when transmitting at high
rate, and lower when transmitting ad low rate.
I'll try to come up with an experimental patch in the next days.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
You are the assignee for the bug.


More information about the freebsd-net mailing list