Thread (1 message) 1 message, 1 author, 2020-03-26

Re: Re: [PATCH net-next] net/packet: fix TPACKET_V3 performance issue in case of TSO

From: Willem de Bruijn <willemdebruijn.kernel@gmail.com>
Date: 2020-03-26 01:16:58

On Wed, Mar 25, 2020 at 10:46 AM yang_y_yi [off-list ref] wrote:
Yes, hrtimer is better, but it will change current API semantics.

req.tp_retire_blk_tov means millisecond, if we change it as microsecond, it will break ABI.
That can be resolved by adding a new feature flag that reinterprets
the field in the request.

#define TP_FT_REQ_USEC      0x2

Please remember to use plain text and don't top paste.


At 2020-03-25 22:37:59, "Willem de Bruijn" [off-list ref] wrote:
quoted
On Wed, Mar 25, 2020 at 10:10 AM [off-list ref] wrote:
quoted
From: Yi Yang <redacted>

TPACKET_V3 performance is very very bad in case of TSO, it is even
worse than non-TSO case. For Linux kernels which set CONFIG_HZ to
1000, req.tp_retire_blk_tov = 1 can help improve it a bit, but some
Linux distributions set CONFIG_HZ to 250, so req.tp_retire_blk_tov = 1
actually means req.tp_retire_blk_tov = 4, it won't have any help.

This fix patch can fix the aforementioned performance issue, it can
boost the performance from 3.05Gbps to 16.9Gbps, a very huge
improvement. It will retire current block as early as possible in
case of TSO in order that userspace application can consume it
in time.

Signed-off-by: Yi Yang <redacted>
I'm not convinced that special casing TSO packets is the right solution here.

We should consider converting TPACKET_V3 to hrtimer and allow usec
resolution block timer.

Would that solve your issue?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help