P4C
The P4 Compiler
Loading...
Searching...
No Matches
add_alias_allocation.h
1
18
19
#ifndef BACKENDS_TOFINO_BF_P4C_PHV_ADD_ALIAS_ALLOCATION_H_
20
#define BACKENDS_TOFINO_BF_P4C_PHV_ADD_ALIAS_ALLOCATION_H_
21
22
#include "backends/tofino/bf-p4c/phv/phv_fields.h"
23
24
namespace
PHV
{
25
31
class
AddAliasAllocation :
public
Inspector
{
32
PhvInfo
&phv;
33
ordered_set<const PHV::Field *>
seen;
34
37
void
addAllocation(
PHV::Field
*source,
PHV::Field
*dest, le_bitrange range);
38
39
profile_t
init_apply(
const
IR::Node
*root)
override
{
40
seen.clear();
41
return
Inspector::init_apply(root);
42
}
43
bool
preorder(
const
IR::BFN::AliasMember *)
override
;
44
bool
preorder(
const
IR::BFN::AliasSlice *)
override
;
45
void
end_apply()
override
;
46
47
public
:
48
explicit
AddAliasAllocation(
PhvInfo
&p) : phv(p) {}
49
};
50
51
}
// namespace PHV
52
53
#endif
/* BACKENDS_TOFINO_BF_P4C_PHV_ADD_ALIAS_ALLOCATION_H_ */
P4::IR::Node
Definition
node.h:94
P4::Inspector
Definition
visitor.h:413
P4::Visitor::profile_t
Definition
visitor.h:78
P4::ordered_set
Definition
ordered_set.h:32
PHV::Field
Definition
phv_fields.h:154
PhvInfo
Definition
phv_fields.h:1095
PHV
The namespace encapsulating PHV-related stuff.
Definition
bf-p4c/mau/gateway.h:32
backends
tofino
bf-p4c
phv
add_alias_allocation.h
Generated by
1.13.2