P4 (programming language): Difference between revisions

Content deleted Content added
mNo edit summary
m categorization/tagging using AWB
Line 12:
| file_ext = .p4
}}
 
 
 
'''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-licenced]] language and is maintained by a non-profit organization called the P4 Language Consortium. The language was originally described in a SIGCOMM 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”.
Line 23 ⟶ 21:
==Target independence==
 
P4 programs are designed to be '''implementation-independent''', meaning they can be compiled against many different types of execution machines such as general-purpose CPUs, FPGAs, system(s)-on-chip, network processors, and ASICs. These different types of machines are known as P4 '''targets''', and each target must be provided along with a [[compiler]] that converts the P4 source code into an executable format. As many of the initial targets for P4 programs were used for simple packet switching it is very common to hear the term “P4 switch” used, even though “P4 target” is more formally correct.
 
==Protocol independence==
P4 is designed to be '''protocol-independent''', meaning that the language has no native support even for common protocols such as IP, Ethernet, TCP, VxLAN, or MPLS. Instead, the P4 programmer describes the header formats and field names of the required protocols in the program, which are in turn interpreted and processed by the compiled program and target device.
 
==Reconfigurability==
 
Protocol independence and the abstract language model allow for '''reconfigurability''' – P4 targets should be able to change the way they process packets (perhaps multiple times) after they are deployed. This capability is traditionally associated with forwarding planes built on [[History of general-purpose CPUs|general-purpose CPUs]] or [[network processor|network processors]]s, rather than the fixed function [[Application-specific integrated circuit|ASICs]]. Although within the language there is nothing to prevent a given target from optimizing around a certain set of protocols, these optimizations are invisible to the language author and may ultimately reduce the system’s flexibility and reconfigurability goals.
 
 
 
==External links==
Line 39 ⟶ 35:
==References==
{{reflist}}
 
{{Uncategorized|date=April 2015}}