20#ifndef BACKENDS_P4TOOLS_MODULES_TESTGEN_TARGETS_TOFINO_TOFINO2_PROGRAM_INFO_H_
21#define BACKENDS_P4TOOLS_MODULES_TESTGEN_TARGETS_TOFINO_TOFINO2_PROGRAM_INFO_H_
27#include "backends/tofino/bf-p4c/ir/gress.h"
30#include "backends/p4tools/modules/testgen/lib/continuation.h"
31#include "backends/p4tools/modules/testgen/targets/tofino/shared_program_info.h"
33namespace P4::P4Tools::P4Testgen::Tofino {
35class JBayProgramInfo :
public TofinoSharedProgramInfo {
39 std::vector<Continuation::Command> processDeclaration(
const IR::Type_Declaration *typeDecl,
40 size_t pipeIdx)
const;
42 [[nodiscard]] std::vector<std::vector<Continuation::Command>> pipelineCmds(gress_t gress)
const;
44 [[nodiscard]]
const IR::Expression *getValidPortConstraint(
45 const IR::StateVariable &portVar)
const override;
47 [[nodiscard]] std::optional<const IR::Expression *> getPipePortRangeConstraint(
48 const IR::StateVariable &portVar,
size_t pipeIdx)
const override;
61 [[nodiscard]]
const IR::Expression *
dropIsActive()
const override;
63 [[nodiscard]] std::vector<std::vector<Continuation::Command>>
ingressCmds()
const override;
65 [[nodiscard]] std::vector<std::vector<Continuation::Command>>
egressCmds()
const override;
70 DECLARE_TYPEINFO(JBayProgramInfo, TofinoSharedProgramInfo);