fruffy / flay Goto Github PK
View Code? Open in Web Editor NEWLicense: Apache License 2.0
License: Apache License 2.0
In current implementation of addReachabilityMapping
, we always try to initialize for a pair of node
and cond
. However, in cases like this:
action copy_to_cpu(...) {
// An if statement
if (some_cond) {
x = a;
} else {
x = b;
}
// codes to copy to cpu
}
action redirect_to_cpu(...) {
// codes to drop
copy_to_cpu(...) // this calls the previous action
}
the if statement in copy_to_cpu
will be visited twice. And our ReachabilityMap
is compared by SourceIdCmp
. Thus, the second time to call addReachabilityMapping
for this if statement will failed here.
I encountered this issue when trying on Tofino's switch program. And my fix in mind is instead of asserting existence of node
, we should add new condition as disjunction to the reachabilityMap
.
We should keep track off what kind of code we consider dead.
The current implementation of table_executor adds reachability for each action here. But the expression actionHitCondition
is constructed with new IR::LAnd(hitCondition, actionChoice)
, where hitCondition
is for key matching and actionChoice
is for action name.
But for default actions, shall we add something like "if none of the actions matched, the default action will be reached"?
The reason I am thinking of this is that I noticed the removing for tna_operations.p4 looks incorrect. For example, if a packet misses on table forward
, it should be dropped by executing default action miss
. But since forward.apply()
is removed, it won't be dropped.
It is possible to override a non-constant default action and create a new path. We do not model this behavior yet.
We can just generate the necessary entries from the control-plane and reject any other entries.
Use taint tracking for this. We consider data plane variables arbitrary so maybe we can get some performance by collapsing them.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.