Vector Packet Processing (VPP) portability on FreeBSD

Luigi Rizzo rizzo at iet.unipi.it
Mon May 10 13:39:21 UTC 2021


On Monday, May 10, 2021, Rainer Duffner <rainer at ultra-secure.de> wrote:

>
>
> > Am 10.05.2021 um 13:08 schrieb Francois ten Krooden <ftk at Nanoteq.com>:
> >
> > Greetings
> >
> > We have a vested interest in high-speed IPsec VPN on FreeBSD. We have
> started with the porting of VPP (https://fd.io/) to FreeBSD.
> >
> > Currently we have VPP compiled and running with netmap. The speeds we
> measure are nowhere near the performance of a 10Gbps link, at around
> 350kpps for 1500 byte IPv4 packets. We suspect the biggest issue is related
> to how VPP implements huge pages (Linux) and our modifications to support
> super pages on FreeBSD.


350kpps is way too low for being related to tlb
and page size issues.

I suspect that you are
either using the "emulated" netmap mode,
which runs on top of mbufs and may involve
extra data copies on the receive path,
or the test itself is e.g. using TCP and congestion
control or limited window size throttle down
the rate.

I'd retry the test with some open loop traffic
source/sink,  and using first all possible low level
APIs (sockets/mbufs; emulated netmap; native netmap; your vpp port) with
small and large packets and increasing packet rates, to see where the
limits are with each. That should give you good hints to figure out what is
making the performance so bad.
Even better if you can run the test between one known-good endpoint so you
can test separately the tx and tx sides.

Cheers
Luigi


>
> > Apart from the above, there are remaining issues we need to sort out and
> "Linuxisms" that need porting to FreeBSD, but this is going reasonably
> well. We are working in a public Github repository and have started listing
> our issues there alongside the code. Our main working branch is "freebsd" (
> https://github.com/ftk-ntq/vpp/tree/freebsd).
> >
> > Our aim with this mail is to get the discussion started on porting VPP
> to FreeBSD and to invite interested parties to help with the effort. We
> intend to upstream the work hoping that the original authors will adopt our
> ported code and continue maintaining future compatibility with FreeBSD.
> >
> > Some of our questions or comments to start the conversation:
> > 1. netmap vs. DPDK (VPP relies on DPDK by default with the netmap
> integration deprecated). Which will be the best to choose?
> > 2. How to correctly implement using super pages / huge pages in FreeBSD
> in order to allow VPP to allocate contiguous memory blocks for packet
> buffers to process packets from the packet handling framework (netmap/DPDK)?
> > 3. What are suitable alternatives for reading information from procfs
> and sysfs on FreeBSD?
> > 4. Functionality relying on Linux epoll is currently supported using
> epoll-shim. Is this the correct approach?
> >
> > Any help and input to aid in the effort will be greatly appreciated.
>
>
>
>
> IIRC, somebody from Netgate (pfSense) had porting this and/or DPDK as a
> „spare time project“.
>
> Not sure how far that actually proceeded. Maybe somebody else knows more?
>
>
> Thanks for your efforts, in any case.
>
>
>
>
> _______________________________________________
> freebsd-net at freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-net
> To unsubscribe, send any mail to "freebsd-net-unsubscribe at freebsd.org"
>


-- 
-----------------------------------------+-------------------------------
 Prof. Luigi RIZZO, rizzo at iet.unipi.it  . Dip. di Ing. dell'Informazione
 http://www.iet.unipi.it/~luigi/        . Universita` di Pisa
 TEL      +39-050-2217533               . via Diotisalvi 2
 Mobile   +39-338-6809875               . 56122 PISA (Italy)
-----------------------------------------+-------------------------------


More information about the freebsd-net mailing list