netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next 0/5] sched: convert queues to single-linked list
@ 2016-09-17 22:57 Florian Westphal
  2016-09-17 22:57 ` [PATCH net-next 1/5] pie: use qdisc_dequeue_head wrapper Florian Westphal
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: Florian Westphal @ 2016-09-17 22:57 UTC (permalink / raw)
  To: netdev

During Netfilter Workshop 2016 Eric Dumazet pointed out that qdisc
schedulers use doubly-linked lists, even though single-linked list
would be enough.

The double-linked skb lists incur one extra write on enqueue/dequeue
operations (to change ->prev pointer of next list elem).

This series converts qdiscs to single-linked version, listhead
maintains pointers to first (for dequeue) and last skb (for enqueue).

Most qdiscs don't queue at all and instead use a leaf qdisc (typically
pfifo_fast) so only a few schedulers needed changes.

I briefly tested netem and htb and they seemed fine.

UDP_STREAM netperf with 64 byte packets via veth+pfifo_fast shows
a small (~2%) improvement.

Florian Westphal (5):
      pie: use qdisc_dequeue_head wrapper
      sched: don't use skb queue helpers
      sched: remove qdisc arg from __qdisc_dequeue_head
      sched: replace __skb_dequeue with __qdisc_dequeue_head
      sched: add and use qdisc_skb_head helpers

 include/net/sch_generic.h |   72 +++++++++++++++++++++++++++++++++++-----------
 net/sched/sch_codel.c     |    4 +-
 net/sched/sch_fifo.c      |    4 +-
 net/sched/sch_generic.c   |   30 +++++++++++--------
 net/sched/sch_htb.c       |   24 ++++++++++++---
 net/sched/sch_netem.c     |   20 +++++++++---
 net/sched/sch_pie.c       |    4 +-
 7 files changed, 115 insertions(+), 43 deletions(-)

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2016-09-19  5:47 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-09-17 22:57 [PATCH net-next 0/5] sched: convert queues to single-linked list Florian Westphal
2016-09-17 22:57 ` [PATCH net-next 1/5] pie: use qdisc_dequeue_head wrapper Florian Westphal
2016-09-17 22:57 ` [PATCH net-next 2/5] sched: don't use skb queue helpers Florian Westphal
2016-09-17 22:57 ` [PATCH net-next 3/5] sched: remove qdisc arg from __qdisc_dequeue_head Florian Westphal
2016-09-17 22:57 ` [PATCH net-next 4/5] sched: replace __skb_dequeue with __qdisc_dequeue_head Florian Westphal
2016-09-17 22:57 ` [PATCH net-next 5/5] sched: add and use qdisc_skb_head helpers Florian Westphal
2016-09-19  5:47 ` [PATCH net-next 0/5] sched: convert queues to single-linked list David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).