I have a virtualized scenario with three virtual machines. Two of them act as hosts sending and receiving packets. The remaining in between has the image provided in https://github.com/jafingerhut/p4-guide/blob/master/bin/README-install-troubleshooting.md. The scenario is | Host 1 <—> P4 Node <----> Host 2 |
I have tested performance by running the basic forwarding P4 program in the virtual machine and doing iperf tests between hosts. Throughput roughly achieves 1 Mbps. I understand that bmv2 is not intended to be a production software switch but I expected higher throughput. Is this usual behavior?
Moreover, I installed a new virtual machine to run the tests included in p4c, following the instructions you provide in the link I posted before:
$ cd p4c/build
$ make -j2 check |& tee make-check-out.txt
There are different command line options that can be used:
when compiling the simple_switch_grpc process, and
when running the simple_switch_grpc process
that can affect how quickly it can process packets. If you have not read this article before, and you are trying to get the best performance out of simple_switch_grpc possible (without changing its source code), I recommend reading it: behavioral-model/performance.md at main · p4lang/behavioral-model · GitHub
Regarding most of the p4c tests failing, that should not affect the performance of the simple_switch_grpc process, but it doesn’t sound good for your ability to use the P4 compiler. I test the install-p4dev-v5.sh and install-p4dev-v6.sh scripts mentioned at the link you gave in your message every month, and late last month all of the tests except about 70 of them passed (about 2500 passed, with only ebpf and ubpf tests failing, which is normal because my scripts do not install the necessary software for ebpf and ubpf-specific tests to pass).