Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changes for language spec update? Allow ranges to be specified by serializable enums #451

Open
jafingerhut opened this issue Aug 15, 2023 · 0 comments
Labels
1.5 Issues and PRs that we want to go into 1.5 p4-language-compatibility An issue related to compatibility between P4_16 language spec and P4Runtime API spec

Comments

@jafingerhut
Copy link
Contributor

jafingerhut commented Aug 15, 2023

This issue should be closed exactly when the bullet item “Allow ranges to be specified by serializable enums” in Section 1.1 "P4 Language Version Applicability" is addressed and removed.

This issue is related to the following change made from v1.2.3 to v1.2.4 of the P4_16 language specification:

  • Allow ranges to be specified by serializable enums (Section 8.15.4).

The emphasized text in the next sentence is the changed part. Before a range was restricted to endpoints with type int, bit<W>, or int<W>. By saying instead a "numeric type", that also allows serializable enum values to be the endpoints of ranges. Note that these ranges are in P4_16 source code, e.g. in parser select branches, or in entries definitions of tables with keys having match_kind range, so this might not affect the P4Runtime API at all.

The infix operator .. takes two arguments of the same numeric type T (Section 7.4),

(see https://p4.org/p4-spec/docs/P4-16-v1.2.4.html#sec-summary-of-changes-made-in-version-124 for the item in context of the full list of changes, but there are separate Github issues for each that might impact the P4Runtime API specification).

@jafingerhut jafingerhut added the p4-language-compatibility An issue related to compatibility between P4_16 language spec and P4Runtime API spec label Aug 15, 2023
@smolkaj smolkaj added the 1.4.0 Issues and PRs that we want to go into 1.4.0 label Jun 14, 2024
@smolkaj smolkaj added 1.5 Issues and PRs that we want to go into 1.5 and removed 1.4.0 Issues and PRs that we want to go into 1.4.0 labels Aug 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1.5 Issues and PRs that we want to go into 1.5 p4-language-compatibility An issue related to compatibility between P4_16 language spec and P4Runtime API spec
Projects
None yet
Development

No branches or pull requests

2 participants