Comments (3)
Just to note: given mutable state (e.g., registers, or even a header stack) and any form of recirculation, it probably won't be decidable whether a table is bidirectional or unidirectional.
from pna.
If this is more subtle than I am imagining, it is probably best to talk about this in person rather than over Github issues, but all I am thinking of here is that in a single execution of a P4 control, it should be possible to symbolically and statically determine from the source code of that control a logical condition under which a table is applied if it is true, and not applied if it is false.
I realize that not all formulas are this simple, but a straightforward example is:
if ((stdmeta.direction == PNA_Direction_t.NET_TO_HOST) && (meta.foo == 5)) {
t1.apply();
}
This is clearly a unidirectional table, since the condition implies that the stdmeta.direction must be NET_TO_HOST.
There are other such logical formulas where it definitely does NOT imply that stdmeta.direction is always one value, or always the other (e.g. the condition (hdr.ipv4.dstAddr > 50), at least in the absence of knowledge of any relationship between that input field and the direction of the packet). If there truly are undecidable cases, then I'd say that a compiler should call it a bidirectional table in the absence of straightforward provable evidence that it is unidirectional.
from pna.
Why use annotation? Use a new table property to specify if a table is used for incoming or outgoing or both direction. For Network Packet Broker, only hardware is used with a symmetric hash which matches both directions.
from pna.
Related Issues (20)
- Any desire to define behavior of add_on_miss=true table WITHOUT data plane deletions of expired entries? HOT 2
- Create functionally correct example demonstrating IPsec encryption and decryption
- Full payload checksum
- Should PNA support resubmit operation? Also: document details of recirculate operation behavior
- What do crypto offsets apply to? Packet as parsed, or packet after deparsing?
- The types of the generics in crypto_accelerator extern maybe should be a static type instead of a generics
- Add text to PNA specification on encrypt/decrypt operations HOT 4
- Add XOR hash function(s)
- Address the issue of pipelines that can have packets "pass each other up" in the middle of the pipeline HOT 1
- Add text explaining how to delete entries from the dataplane, and describe `ExpireTimeProfileId_t`.
- Minor bug in IPsec example program
- Remove last remaining occurrences of HOST_TO_NET and NET_TO_HOST from spec
- Add glossary, and consider using "inline accelerator" consistently when referring to encrypt/decrypt block
- Devise an explicit convention to document which parts of pna.p4 are intended to be vendor-customizable vs. not
- Proposal for setting packets and bytes counter widths separately HOT 5
- Lack of documentation on the optional bytes counter increment parameter HOT 7
- Should it be possible to recirculate mirrored copies of a packet ? HOT 1
- How to pass an extern object instance of type X as a parameter to a method call that is a method of type X HOT 1
- PNA spec declares headers on deparser are RO HOT 2
- PNA/PSA extern restrictions HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pna.