P4C
The P4 Compiler
|
Represents a PHV-allocation context: a parser, a table, or a deparser. More...
#include <phv_fields.h>
Public Types | |
enum class | Type { PARSER , TABLE , DEPARSER } |
Public Member Functions | |
bool | is_deparser () const |
bool | is_parser () const |
bool | is_table () const |
cstring | typeStr () const |
Static Public Member Functions | |
static const AllocContext * | of_unit (const IR::BFN::Unit *unit) |
Public Attributes | |
const IR::MAU::Table * | table |
Populated iff type is TABLE. | |
Type | type |
Static Public Attributes | |
static const AllocContext * | DEPARSER |
static const AllocContext * | PARSER |
Represents a PHV-allocation context: a parser, a table, or a deparser.
|
inlinestatic |
Factory method for producing an AllocContext from a Unit.
unit | is expected to be a parser, a deparser, or a table. Anything else is a compiler bug. |
|
static |
|
static |