Vendor Logo

Open Networking Foundation – bmv2

The second version of the reference P4 software switch is nicknamed bmv2 (for behavioral model version 2). The software switch is written in C++11. It takes as input a JSON file generated from your P4 program by a P4 compiler and interprets it to implement the packet-processing behavior specified by that P4 program.

The bmv2 repository contains code for several variations of the behavioral model, e.g. simple_switchsimple_switch_grpc, and psa_switch.

bmv2 is not meant to be a production-grade software switch. It is meant to be used as a tool for developing, testing, and debugging P4 data planes and control plane software written for them. As such, the performance of bmv2 – in terms of throughput and latency – is significantly less than that of a production-grade software switch like Open vSwitch.

For more information, visit the bmv2 repository.