P4C
The P4 Compiler
|
PHV-related info about structs, i.e. collections of header or metadata fields. More...
#include <phv_fields.h>
Public Member Functions | |
StructInfo (bool metadata, gress_t gress) | |
StructInfo (bool metadata, gress_t gress, int first_field_id, int size) | |
boost::integer_range< int > | field_ids () const |
Returns the half-open range of field IDs for this struct. | |
Public Attributes | |
int | first_field_id |
gress_t | gress |
Gress of this struct. | |
bool | metadata |
True if this is a metadata struct; false for headers. | |
int | size |
PHV-related info about structs, i.e. collections of header or metadata fields.
int PhvInfo::StructInfo::first_field_id |
PHV::Field ID (i.e. index into by_id
) of the first field of this struct. Struct fields are assigned contiguous IDs. This field is not valid when size == 0
.
int PhvInfo::StructInfo::size |
Number of fields in this struct. May be 0
for structs with no fields.