[P4] Fwd: Actions in P4-16

Tejfel Máté matej at caesar.elte.hu
Thu Nov 9 13:36:09 CET 2017




-------- Továbbított üzenet --------
Tárgy: 	Actions in P4-16
Dátum: 	Tue, 7 Nov 2017 17:16:50 +0000
Feladó: 	Dumitrescu, Cristian <cristian.dumitrescu at intel.com>
Címzett: 	Sándor Laki <lakis at inf.elte.hu>, Tejfel Máté 
<matej at caesar.elte.hu>, 'Horpácsi Dániel' <daniel-h at elte.hu>
CC: 	Gergely.Pongracz at Ericsson.com <Gergely.Pongracz at Ericsson.com>, 
Kinsella, Ray <ray.kinsella at intel.com>, Ferriter, Cian 
<cian.ferriter at intel.com>, Zhu, Heqing <heqing.zhu at intel.com>



Hi guys,

I have read the P4-16 spec and I have some questions on actions, it 
would be great to have your input:

1.Action implementations. My takeaway is that actions are implemented 
using the two mechanisms below, did I miss any other mechanism?

a.Statements and expressions. Similar to writing a C function. Departure 
from P4-14, where actions could only be built using a (small) predefined 
set of primitive actions.

i.Inputs: packet headers, packet meta-data, table entry data

ii.Outputs: packet headers, packet meta-data, (table entry data?)

b.Extern object instantiations and extern functions. This allows pushing 
out of the language some P4-14 objects such as: meters, registers, counters.

2.For a given table, several actions can be defined; each table entry 
(including the default entry) has exactly one action from the action 
list of the table, right?

a.If entry X does operations {A, B, C, D, E} and entry Y does operations 
{A, B, C, D, F}, we need to implement actionX (doing A, B, C, D,E) and 
actionY (doing A, B, C, D, F) explicitly and map them to entries X and 
Y, as opposed to saying: entry X executes actions A, B, C, D, E and 
entry Y executes actions A, B, C, D, F, right?

3.Action portability. If we use extern objects and functions, the 
actions are not that portable anymore, right? They become target 
specific and P4 program can only work for that target.

4.Can an action modify the table entry data or is table entry data 
read-only?

a.Example: implement a packet counter per flow; pkt hits table entry, a 
counter stored in the entry gets incremented. Is this possible in P4-16?

5.Do you have examples of P4-16 actions that you could share? The more 
examples the better.

6.Can somebody give me an example for the “implementation” key word from 
section 12.2.1.5 Additional properties and the associated concept of 
action profile, please ?

7.When should we expect P4-16 support in the T4P4S compiler?

Thanks very much for your help!

Regards,

Cristian

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://plc.inf.elte.hu/pipermail/p4/attachments/20171109/81ab2d83/attachment.html>


More information about the P4 mailing list