P4C
The P4 Compiler
Loading...
Searching...
No Matches
P4::P4Tools::P4Testgen::Continuation::Guard Struct Reference

#include <continuation.h>

Public Member Functions

 Guard (const IR::Expression *cond)
 
bool operator== (const Guard &other) const
 Delegates to IR equality.
 

Public Attributes

const IR::Expression * cond
 

Detailed Description

Guards are commands that can be inserted into the continuation stack to ensure that the interpreter does not violate a given invariant. If the condition evaluates to false, the path is invalid and the symbolic executor will not traverse it. For example, specific port values are not supported in a hardware target guards can enforce that only the appropriate port variables are chosen. Any other possible path is discarded.