diff options
author | Eric Dumazet <edumazet@google.com> | 2022-07-07 19:18:46 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2022-07-08 14:21:08 +0100 |
commit | c2dd4059dc31ee6f5b83c8d2064bb1f1f465bcec (patch) | |
tree | ca262868da3fc1e3880a78ec3efc9beaa7522810 /net/unix/af_unix.c | |
parent | 8e1514579246ddc36ba0b860fc8bdd03be085aee (diff) |
net: minor optimization in __alloc_skb()
TCP allocates 'fast clones' skbs for packets in tx queues.
Currently, __alloc_skb() initializes the companion fclone
field to SKB_FCLONE_CLONE, and leaves other fields untouched.
It makes sense to defer this init much later in skb_clone(),
because all fclone fields are copied and hot in cpu caches
at that time.
This removes one cache line miss in __alloc_skb(), cost seen
on an host with 256 cpus all competing on memory accesses.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/unix/af_unix.c')
0 files changed, 0 insertions, 0 deletions