tcp: move inet->rx_dst_ifindex to sk->sk_rx_dst_ifindex
Increase cache locality by moving rx_dst_ifindex next to sk->sk_rx_dst This is part of an effort to reduce cache line misses in TCP fast path. This removes one cache line miss in early demux. Signed-off-by: Eric Dumazet <edumazet@google.com> Acked-by: Soheil Hassas Yeganeh <soheil@google.com> Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
committed by
Jakub Kicinski
parent
fd559a943e
commit
0c0a5ef809
@@ -259,6 +259,7 @@ struct bpf_local_storage;
|
||||
* @sk_rcvbuf: size of receive buffer in bytes
|
||||
* @sk_wq: sock wait queue and async head
|
||||
* @sk_rx_dst: receive input route used by early demux
|
||||
* @sk_rx_dst_ifindex: ifindex for @sk_rx_dst
|
||||
* @sk_dst_cache: destination cache
|
||||
* @sk_dst_pending_confirm: need to confirm neighbour
|
||||
* @sk_policy: flow policy
|
||||
@@ -430,6 +431,8 @@ struct sock {
|
||||
struct xfrm_policy __rcu *sk_policy[2];
|
||||
#endif
|
||||
struct dst_entry *sk_rx_dst;
|
||||
int sk_rx_dst_ifindex;
|
||||
|
||||
struct dst_entry __rcu *sk_dst_cache;
|
||||
atomic_t sk_omem_alloc;
|
||||
int sk_sndbuf;
|
||||
|
||||
Reference in New Issue
Block a user