19#ifndef BACKENDS_TOFINO_BF_P4C_MAU_POWER_SPEC_H_
20#define BACKENDS_TOFINO_BF_P4C_MAU_POWER_SPEC_H_
36 virtual double get_max_power()
const = 0;
42 virtual double get_absolute_max_power_threshold()
const = 0;
50 virtual double get_tcam_scaling_factor()
const = 0;
51 virtual double get_voltage_scaling_factor()
const = 0;
52 virtual double get_ram_read_power()
const = 0;
53 virtual double get_ram_write_power()
const = 0;
54 virtual double get_tcam_search_power()
const = 0;
55 virtual double get_map_ram_read_power()
const = 0;
56 virtual double get_map_ram_write_power()
const = 0;
57 virtual double get_deferred_ram_read_power()
const = 0;
58 virtual double get_deferred_ram_write_power()
const = 0;
64 virtual int get_base_predication_delay()
const {
return 11; }
65 virtual int get_tcam_delay()
const {
return 2; }
66 virtual int get_selector_delay()
const {
return 8; }
67 virtual int get_meter_lpf_delay()
const {
return 4; }
68 virtual int get_stateful_delay()
const {
return 4; }
69 virtual int get_mau_corner_turn_delay()
const = 0;
75 virtual int get_action_latency_contribution()
const {
return 2; }
88 virtual int get_deparser_max_phv_valid()
const = 0;
89 virtual int get_cycles_to_issue_credit_to_pmarb()
const = 0;
90 virtual int get_pmarb_cycles_from_receive_credit_to_issue_phv_to_mau()
const = 0;
97 double get_max_power()
const override {
return 40.0; }
99 double get_absolute_max_power_threshold()
const override {
return 22.0; }
109 double get_tcam_scaling_factor()
const override {
120 double get_tcam_search_power()
const override {
return 0.0398 * get_tcam_scaling_factor(); }
123 double get_deferred_ram_read_power()
const override {
126 double get_deferred_ram_write_power()
const override {
130 int get_mau_corner_turn_delay()
const override {
return 4; }
136 return get_deparser_max_phv_valid() - get_cycles_to_issue_credit_to_pmarb() -
137 get_pmarb_cycles_from_receive_credit_to_issue_phv_to_mau();
139 int get_deparser_max_phv_valid()
const override {
return 288; }
140 int get_cycles_to_issue_credit_to_pmarb()
const override {
return 28; }
141 int get_pmarb_cycles_from_receive_credit_to_issue_phv_to_mau()
const override {
return 11; }
153 double get_max_power()
const override {
return 52.0; }
155 double get_absolute_max_power_threshold()
const override {
return 10.0; }
163 double get_tcam_scaling_factor()
const override {
return 1.0 * get_voltage_scaling_factor(); }
164 double get_voltage_scaling_factor()
const override {
166 double measured_voltage = 0.750;
168 double user_voltage = 0.750;
171 return (user_voltage / measured_voltage) * (user_voltage / measured_voltage);
177 double get_tcam_search_power()
const override {
return 0.0185 * get_tcam_scaling_factor(); }
180 double get_deferred_ram_read_power()
const override {
183 double get_deferred_ram_write_power()
const override {
199 return get_action_latency_contribution();
221 int get_cycles_to_issue_credit_to_pmarb()
const override {
return 0; }
222 int get_pmarb_cycles_from_receive_credit_to_issue_phv_to_mau()
const override {
return 0; }
228 JBayHMauPowerSpec() {}
229 double get_max_power()
const override {
return 15.6; }
236 double get_max_power()
const override {
return 31.2; }
Definition power_spec.h:233
Definition power_spec.h:149
int get_deparser_max_phv_valid() const override
Definition power_spec.h:220
int get_concurrent_latency_contribution() const override
Definition power_spec.h:198
double get_excess_power_threshold() const override
Definition power_spec.h:154
int get_min_required_egress_mau_latency() const override
Definition power_spec.h:205
double get_ram_scaling_factor() const override
Definition power_spec.h:162
int get_deparser_throughput_scaling_starts() const override
Definition power_spec.h:214
int get_mau_corner_turn_delay() const override
Definition power_spec.h:191
Definition power_spec.h:239
Definition power_spec.h:32
virtual int get_concurrent_latency_contribution() const =0
virtual int get_base_delay() const
Definition power_spec.h:63
virtual int get_deparser_throughput_scaling_starts() const =0
virtual double get_ram_scaling_factor() const =0
virtual int get_min_required_egress_mau_latency() const =0
virtual double get_excess_power_threshold() const =0
Definition power_spec.h:93
double get_ram_scaling_factor() const override
Definition power_spec.h:106
int get_concurrent_latency_contribution() const override
Definition power_spec.h:131
double get_voltage_scaling_factor() const override
Definition power_spec.h:115
double get_excess_power_threshold() const override
Definition power_spec.h:98
int get_deparser_throughput_scaling_starts() const override
Definition power_spec.h:135
int get_min_required_egress_mau_latency() const override
Definition power_spec.h:132