P4C
The P4 Compiler
Loading...
Searching...
No Matches
split_greedy_parser_states.h
1
19#ifndef BACKENDS_TOFINO_BF_P4C_PARDE_LOWERED_SPLIT_GREEDY_PARSER_STATES_H_
20#define BACKENDS_TOFINO_BF_P4C_PARDE_LOWERED_SPLIT_GREEDY_PARSER_STATES_H_
21
22#include "bf-p4c/parde/clot/clot_info.h"
23#include "ir/visitor.h"
24
25namespace Parde::Lowered {
26
61
62 private:
75 IR::BFN::ParserState *split_state(IR::BFN::ParserState *state, cstring new_state_name);
76
103 void split_statements(const IR::Vector<IR::BFN::ParserPrimitive> in,
106 int &last_statements_shift_bit,
107 std::optional<bool> &last_statements_partial_proc);
108
124 bool partial_hdr_err_proc_verify(const IR::Vector<IR::BFN::ParserPrimitive> *statements,
125 const IR::Vector<IR::BFN::Select> *selects,
126 const IR::Vector<IR::BFN::Transition> *transitions,
127 std::optional<bool> *partial_proc_value);
128
134 bool state_pkt_too_short_verify(const IR::BFN::ParserState *state,
135 bool &select_args_incompatible);
136
137 IR::BFN::ParserState *postorder(IR::BFN::ParserState *state) override;
138};
139
140} // namespace Parde::Lowered
141
142#endif /* BACKENDS_TOFINO_BF_P4C_PARDE_LOWERED_SPLIT_GREEDY_PARSER_STATES_H_ */
Definition vector.h:59
Definition visitor.h:424
Definition cstring.h:85
This pass is used to ensure that there will be no conflicting partial_hdr_err_proc at the time the Lo...
Definition split_greedy_parser_states.h:59
Definition lower_parser.cpp:72