P4C
The P4 Compiler
Loading...
Searching...
No Matches
ixbar_info.h
1
19#ifndef BACKENDS_TOFINO_BF_P4C_MAU_IXBAR_INFO_H_
20#define BACKENDS_TOFINO_BF_P4C_MAU_IXBAR_INFO_H_
21
22#include <array>
23
24#include "backends/tofino/bf-p4c/mau/mau_visitor.h"
25#include "backends/tofino/bf-p4c/mau/resource.h"
26#include "lib/safe_vector.h"
27
28namespace BFN {
29
30using namespace P4;
31
36 const PhvInfo &phv;
37 std::map<int, safe_vector<IXBar::Use::Byte>> _stage;
38 std::map<IXBar::Use::Byte, const IR::MAU::Table *> _byteToTables;
39
40 profile_t init_apply(const IR::Node *) override;
41
42 void end_apply(const IR::Node *) override;
43
44 void postorder(const IR::MAU::Table *) override;
45
46 void sort_ixbar_byte();
47 std::string print_ixbar_byte() const;
48
49 public:
50 explicit CollectIXBarInfo(const PhvInfo &phv) : phv(phv) {}
51};
52
53} // namespace BFN
54
55#endif /* BACKENDS_TOFINO_BF_P4C_MAU_IXBAR_INFO_H_ */
Definition ixbar_info.h:35
Definition mau_visitor.h:29
Definition node.h:94
Definition visitor.h:78
Definition phv_fields.h:1095
The namespace encapsulating Barefoot/Intel-specific stuff.
Definition add_t2na_meta.cpp:21
TODO: this is not really specific to BMV2, it should reside somewhere else.
Definition applyOptionsPragmas.cpp:24