P4 (programming language): Difference between revisions

Content deleted Content added
m per WP:HYPHEN, sub-subsection 3, points 3,4,6, replaced: widely- → widely , etc. using AWB
Line 14:
}}
 
'''P4''' is a [[programming language]] designed to allow programming of packet forwarding dataplanes. In contrast to a general purpose language such as C or python, P4 is a [[___domain-specific language]] with a number of constructs optimized around network data forwarding. P4 is an [[open source|open-source]], [[Permissive free software licence|permissively- licensed]] language and is maintained by a non-profit organization called the P4 Language Consortium. The language was originally described in a SIGCOMM CCR paper in 2014 titled “Programming Protocol-Independent Packet Processors”<ref>{{cite web|url=http://www.sigcomm.org/node/3503|title=P4: Programming Protocol-Independent Packet Processors|date=July 2014|accessdate=7 April 2015}}</ref> – the alliterative name shortens to “P4”.
 
== Language overview and design considerations ==
Line 39:
===Headers===
 
Header definitions describe packet formats and provide names for the fields within the packet. The language allows customized header names and fields of arbitrary length, although many header definitions use widely- known protocol names and fields widths. For example, an 802.3 ethernet header definition might be called “ethernet” and consist of the a 48-bit field named “dest” followed by a 48-bit “src” field, followed by a 16-bit “type” field. The names in a header definition are used later in the P4 program to reference these fields.
 
===Parsers===