P4C
The P4 Compiler
Loading...
Searching...
No Matches
add_alias_allocation.h
1
19#ifndef BF_P4C_PHV_ADD_ALIAS_ALLOCATION_H_
20#define BF_P4C_PHV_ADD_ALIAS_ALLOCATION_H_
21
22#include "bf-p4c/phv/phv_fields.h"
23
24namespace PHV {
25
32 PhvInfo &phv;
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 /* BF_P4C_PHV_ADD_ALIAS_ALLOCATION_H_ */
Definition node.h:95
Definition visitor.h:400
Definition visitor.h:78
Definition ordered_set.h:32
Create allocation objects (PHV::AllocSlice) for alias source fields in preparation for assembly outpu...
Definition add_alias_allocation.h:31
Definition phv_fields.h:154
Definition phv_fields.h:1095
The namespace encapsulating PHV-related stuff.
Definition gateway.h:32