-
Notifications
You must be signed in to change notification settings - Fork 334
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add support for P4_16 header unions (#341)
There is a P4_16 proposal to add header unions to the language. This patch adds support for them in bmv2 and defines the appropriate JSON input format when using header unions. Having first-class support for unions in bmv2 allows for easier debugging, with potentially better log messages. The most important use of header unions is when using stacks / arrays of them. This enables writing programs able to serialize / deserialize TLV-style protocol options (e.g. IPv4 options). Which is why this patch adds support for stacks of header unions, which actually took the biggest effort. Header unions and header union stacks are modeled after header stacks. The JSON documentation was updated to reflect this change, and the version number was bumped up to 2.10
- Loading branch information
1 parent
55b2b04
commit 593026c
Showing
35 changed files
with
2,824 additions
and
331 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.