Skip to content

Commit e4cbb02

Browse files
edumazetdavem330
authored andcommitted
net: add a prefetch in socket backlog processing
TCP or UDP stacks have big enough latencies that prefetching next pointer is worth it. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 5dac94e commit e4cbb02

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

‎net/core/sock.c‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1700,6 +1700,7 @@ static void __release_sock(struct sock *sk)
17001700
do {
17011701
struct sk_buff *next = skb->next;
17021702

1703+
prefetch(next);
17031704
WARN_ON_ONCE(skb_dst_is_noref(skb));
17041705
skb->next = NULL;
17051706
sk_backlog_rcv(sk, skb);

0 commit comments

Comments
 (0)