-
Notifications
You must be signed in to change notification settings - Fork 80
LDWG Meeting minutes: January 22, 2018
- Left shift (mbudiu-vmw) https://github.com/p4lang/p4-spec/pull/543/
Issue: Proposes to make arithmetic shift left and logical shift left identical.
Mihai: Only possible objection could be hardware that cannot implement signed shift left.
There were no objections so we approved it.
Action Item: merge.
- Equality (mbudiu-vmw) https://github.com/p4lang/p4-spec/pull/544
Issue: when is equality defined on two structs?
Andy F: only question is the phrase “exact same type”
Mihai: same type is non-trivial, e.g. with unions and typedefs.
Andy K: Is equality defined on varbits? This might cause trouble for some headers.
Mihai: We should define equality on varbits. Targets that do not support this can subset. Varbits would be required to have the same static and dynamic types (including length).
Action Item: Mihai to amend the PR with additional detail on when two types are equal.
Reviewers: Andy Keep, James Coole
- Header stacks (jnfoster) https://github.com/p4lang/p4-spec/pull/501
Issue: P4_14 and P4_16 and BMv2 were all inconsistent wrt treatment of header stacks.
Main thrust of proposed change modifies the behavior of add_header and remove_header to simplify them — they only access element in place.
Action Item: Nate is to fix description of extract with next; Andy F to review.
- Operator precedence (ChrisDodd) https://github.com/p4lang/p4-spec/issues/551
Issue: while working on a weird problem in a P4_14 program, discovered that operator precedence in P4_14 is not consistent with C. Since P4_16 has type checking, modifying precedence is not going to change any existing programs.
Chris: should we further change the precedence? For example, of arithmetic vs. bit-wise?
Action Item: ChrisDodd to make a pull request to make consistent with P4_14 (and not with C), and to explore whether further changes are appropriate.
- Reserved properties (jafingerhut) https://github.com/p4lang/p4-spec/issues/514
Issue: there are four table properties specified in the P4_16 spec, but size and implementation are not. In the PSA WG, all new table properties have been prefixed by “psa_” to avoid collisions. This raises the question of whether it should be called “psa_size” or if we can rely on common use of “size”?
Action Item: Andy Fingerhut to write a proposal for making this a recommended property.
Review: Vladimir
- Dispatching on table results (James Coole) https://github.com/p4lang/p4-spec/issues/485
Issue: cannot use both action hit and action run for the same table apply. And can’t save the value because there is not a type for that kind of data.
Proposal: add these types as first-class citizens in the language.
Action Item: James to consult with a small group to work on a concrete proposal, including discussing feasibility in p4c front-end and bmv2. (Or assume that this functionality is suitably lowered, assuming bmv2 is a faithful reflection of the capabilities of some targets.)
Other participants: Andy K, Mihai
- Documentation (chrispsommers)
Want to have better language support for documentation, in order to have a precise description of things like the P4 Runtime APIs.
Three proposals: Doxygen-style comments Annotations Add new constructs?
Mihai: Should make a list of important use cases. This is a good idea.
Chris: playing with tools to extract information from P4 Runtime.
Chis: Annotations are easy because the compiler already supports them, but they are somewhat clunky — e.g, if you are referring to complex data.
Mihai: for example cross-referencing.
Andy F: does P4_16 spec allow multi-line strings?
Mihai: I think it does, but the C Preprocessor may complain about them.
Nate: having examples from PSA or from P4 Runtime would sharpen the discussion.
Calin: used comments with some conventions.
{ Mihai, Calin }: Please do the thing that’s right for the language in the long term.
Action Item: Chris to discuss with P4 Runtime group.
- Generics (jnfoster)
Problem: can’t write generic parsers, controls, etc.
Outstanding issues: syntax for “type families”, structure of hierarchy.
Mihai: keep in mind that people who program networks may not be familiar with generics.
Proposal: bring back generics and add bounded types.
- Serializable types (keep)
Issues: emit-able types are not serializable, since validity bit is discarded.
Mihai: main use-case seems to be control-plane.
Andy K: examples like converting between structs and bit vectors.
Mihai: another example seems to be table initializers (keys + actions, drawn from a union).
Action Item: smaller task force group to reconvene.
- Value Sets (hanw) Action Item: Han to discuss at next meeting.
- Virtual Functions (cc10512) Issue with variable capture? Action Item: Calin, Mihai and Antonin to have a sidebar.
- Optional Arguments (mihai) Action Item: Chris to present on February 5th.
- Named Parameters (TBD)
Action Item: Mihai to make a list of experimental features.
Feb 5th, 2018 or fall back to 12th.