P4C
The P4 Compiler
|
#include <resolve_negative_extract.h>
Public Member Functions | |
CollectNegativeExtractOutOfBufferStates (const CollectParserInfo &pi) | |
void | end_apply () override |
profile_t | init_apply (const IR::Node *node) override |
bool | preorder (const IR::BFN::PacketRVal *rval) override |
Public Attributes | |
unsigned | max_buff_size = 0 |
const CollectParserInfo & | parserInfo |
std::map< cstring, unsigned > | state_to_shift |
In-buffer offsets of states. | |
Colect all negative extract states that can't be satisfied by delaying shifts alone (i.e., the negative offsets exceed the parser window size). These negative extracts require delaying shift and redistributing the extracts. For these states, calculate the amount to delay shifts by.
The shift delay/extract restribution occurs between directly-connected nodes (parent + child). Shifts/extracts will not be distributed across more than one level of hierarchy.