mbox series

[libnetfilter_queue,v2,0/1] Speed-up

Message ID 20210518030848.17694-1-duncan_roe@optusnet.com.au
Headers show
Series Speed-up | expand

Message

Duncan Roe May 18, 2021, 3:08 a.m. UTC
Hi Pablo,

The RFC didn't elicit any comments in 2 weeks so I guess the new function
prototypes are acceptable.

This update replaces use of __thread variables wih passing down the needed info
via the data arg. This saves 5 seconds CPU over 100,000,000 packets on my AMD
Ryzen 7. The original data arg is also passed down.

Please apply this patch when next you find time to look at user space,

Cheers ... Duncan.

Duncan Roe (1):
  Eliminate packet copy when constructing struct pkt_buff

 examples/nf-queue.c                    | 22 ++++++-
 include/libnetfilter_queue/Makefile.am |  1 +
 include/libnetfilter_queue/callback.h  | 11 ++++
 include/libnetfilter_queue/pktbuff.h   |  2 +
 src/Makefile.am                        |  1 +
 src/extra/callback.c                   | 60 +++++++++++++++++++
 src/extra/pktbuff.c                    | 80 ++++++++++++++++++--------
 7 files changed, 149 insertions(+), 28 deletions(-)
 create mode 100644 include/libnetfilter_queue/callback.h
 create mode 100644 src/extra/callback.c

--
2.17.5