47#ifndef BACKENDS_TOFINO_BF_P4C_MIDEND_CHECK_DESIGN_PATTERN_H_
48#define BACKENDS_TOFINO_BF_P4C_MIDEND_CHECK_DESIGN_PATTERN_H_
50#include "bf-p4c-options.h"
51#include "frontends/common/resolveReferences/referenceMap.h"
52#include "frontends/p4/methodInstance.h"
53#include "frontends/p4/typeMap.h"
77 : refMap(refMap), typeMap(typeMap) {}
78 bool preorder(
const IR::MethodCallExpression *)
override;
85typedef std::map<const IR::P4Action *, std::vector<const P4::ExternMethod *>> ActionExterns;
92 ActionExterns &directExterns;
96 : refMap(refMap), typeMap(typeMap), directExterns(directExterns) {}
97 bool preorder(
const IR::MethodCallExpression *)
override;
106 ActionExterns &directExterns;
110 ActionExterns &directExterns)
111 : refMap(refMap), directExterns(directExterns) {}
112 bool preorder(IR::P4Table *)
override;
124 ActionExterns directExterns;
127 static const std::map<cstring, cstring> externsToProperties;
146 bool preorder(
const IR::P4Table *)
override;
157 if (BackendOptions().arch !=
"v1model")
Definition check_design_pattern.h:143
Definition ir/pass_manager.h:40
Class used to encode maps from paths to declarations.
Definition referenceMap.h:66
bool preorder(const IR::MethodCallExpression *) override
Definition check_design_pattern.cpp:23
Top level PassManager that governs checking for design patterns.
Definition check_design_pattern.h:153
Definition check_design_pattern.h:104
Definition check_design_pattern.h:123
Checks if the emit function call is valid with the TNA constraints.
Definition check_design_pattern.h:71
Definition check_design_pattern.h:89
The namespace encapsulating Barefoot/Intel-specific stuff.
Definition add_t2na_meta.cpp:21