| { |
| "header_types" : [ |
| { |
| "name" : "scalars_0", |
| "id" : 0, |
| "fields" : [ |
| ["tmp", 32, false], |
| ["tmp_0", 32, false], |
| ["port_meters_ingress_ingress_color_0", 8, false], |
| ["host_meter_control_meter_tag_0", 8, false], |
| ["tmp_1", 32, false], |
| ["tmp_2", 32, false], |
| ["port_meters_egress_egress_color_0", 8, false], |
| ["local_metadata_t.l4_src_port", 16, false], |
| ["local_metadata_t.l4_dst_port", 16, false], |
| ["local_metadata_t.next_hop_id", 16, false] |
| ] |
| }, |
| { |
| "name" : "standard_metadata", |
| "id" : 1, |
| "fields" : [ |
| ["ingress_port", 9, false], |
| ["egress_spec", 9, false], |
| ["egress_port", 9, false], |
| ["clone_spec", 32, false], |
| ["instance_type", 32, false], |
| ["drop", 1, false], |
| ["recirculate_port", 16, false], |
| ["packet_length", 32, false], |
| ["enq_timestamp", 32, false], |
| ["enq_qdepth", 19, false], |
| ["deq_timedelta", 32, false], |
| ["deq_qdepth", 19, false], |
| ["ingress_global_timestamp", 48, false], |
| ["egress_global_timestamp", 48, false], |
| ["lf_field_list", 32, false], |
| ["mcast_grp", 16, false], |
| ["resubmit_flag", 32, false], |
| ["egress_rid", 16, false], |
| ["checksum_error", 1, false], |
| ["recirculate_flag", 32, false], |
| ["parser_error", 32, false], |
| ["_padding_0", 5, false] |
| ] |
| }, |
| { |
| "name" : "packet_out_header_t", |
| "id" : 2, |
| "fields" : [ |
| ["egress_port", 9, false], |
| ["_padding", 7, false] |
| ] |
| }, |
| { |
| "name" : "packet_in_header_t", |
| "id" : 3, |
| "fields" : [ |
| ["ingress_port", 9, false], |
| ["_padding", 7, false] |
| ] |
| }, |
| { |
| "name" : "ethernet_t", |
| "id" : 4, |
| "fields" : [ |
| ["dst_addr", 48, false], |
| ["src_addr", 48, false], |
| ["ether_type", 16, false] |
| ] |
| }, |
| { |
| "name" : "ipv4_t", |
| "id" : 5, |
| "fields" : [ |
| ["version", 4, false], |
| ["ihl", 4, false], |
| ["dscp", 6, false], |
| ["ecn", 2, false], |
| ["len", 16, false], |
| ["identification", 16, false], |
| ["flags", 3, false], |
| ["frag_offset", 13, false], |
| ["ttl", 8, false], |
| ["protocol", 8, false], |
| ["hdr_checksum", 16, false], |
| ["src_addr", 32, false], |
| ["dst_addr", 32, false] |
| ] |
| }, |
| { |
| "name" : "tcp_t", |
| "id" : 6, |
| "fields" : [ |
| ["src_port", 16, false], |
| ["dst_port", 16, false], |
| ["seq_no", 32, false], |
| ["ack_no", 32, false], |
| ["data_offset", 4, false], |
| ["res", 3, false], |
| ["ecn", 3, false], |
| ["ctrl", 6, false], |
| ["window", 16, false], |
| ["checksum", 16, false], |
| ["urgent_ptr", 16, false] |
| ] |
| }, |
| { |
| "name" : "udp_t", |
| "id" : 7, |
| "fields" : [ |
| ["src_port", 16, false], |
| ["dst_port", 16, false], |
| ["length_", 16, false], |
| ["checksum", 16, false] |
| ] |
| } |
| ], |
| "headers" : [ |
| { |
| "name" : "scalars", |
| "id" : 0, |
| "header_type" : "scalars_0", |
| "metadata" : true, |
| "pi_omit" : true |
| }, |
| { |
| "name" : "standard_metadata", |
| "id" : 1, |
| "header_type" : "standard_metadata", |
| "metadata" : true, |
| "pi_omit" : true |
| }, |
| { |
| "name" : "packet_out", |
| "id" : 2, |
| "header_type" : "packet_out_header_t", |
| "metadata" : false, |
| "pi_omit" : true |
| }, |
| { |
| "name" : "packet_in", |
| "id" : 3, |
| "header_type" : "packet_in_header_t", |
| "metadata" : false, |
| "pi_omit" : true |
| }, |
| { |
| "name" : "ethernet", |
| "id" : 4, |
| "header_type" : "ethernet_t", |
| "metadata" : false, |
| "pi_omit" : true |
| }, |
| { |
| "name" : "ipv4", |
| "id" : 5, |
| "header_type" : "ipv4_t", |
| "metadata" : false, |
| "pi_omit" : true |
| }, |
| { |
| "name" : "tcp", |
| "id" : 6, |
| "header_type" : "tcp_t", |
| "metadata" : false, |
| "pi_omit" : true |
| }, |
| { |
| "name" : "udp", |
| "id" : 7, |
| "header_type" : "udp_t", |
| "metadata" : false, |
| "pi_omit" : true |
| } |
| ], |
| "header_stacks" : [], |
| "header_union_types" : [], |
| "header_unions" : [], |
| "header_union_stacks" : [], |
| "field_lists" : [], |
| "errors" : [ |
| ["NoError", 1], |
| ["PacketTooShort", 2], |
| ["NoMatch", 3], |
| ["StackOutOfBounds", 4], |
| ["HeaderTooShort", 5], |
| ["ParserTimeout", 6] |
| ], |
| "enums" : [], |
| "parsers" : [ |
| { |
| "name" : "parser", |
| "id" : 0, |
| "init_state" : "start", |
| "parse_states" : [ |
| { |
| "name" : "start", |
| "id" : 0, |
| "parser_ops" : [], |
| "transitions" : [ |
| { |
| "type" : "hexstr", |
| "value" : "0x00ff", |
| "mask" : null, |
| "next_state" : "parse_packet_out" |
| }, |
| { |
| "value" : "default", |
| "mask" : null, |
| "next_state" : "parse_ethernet" |
| } |
| ], |
| "transition_key" : [ |
| { |
| "type" : "field", |
| "value" : ["standard_metadata", "ingress_port"] |
| } |
| ] |
| }, |
| { |
| "name" : "parse_packet_out", |
| "id" : 1, |
| "parser_ops" : [ |
| { |
| "parameters" : [ |
| { |
| "type" : "regular", |
| "value" : "packet_out" |
| } |
| ], |
| "op" : "extract" |
| } |
| ], |
| "transitions" : [ |
| { |
| "value" : "default", |
| "mask" : null, |
| "next_state" : "parse_ethernet" |
| } |
| ], |
| "transition_key" : [] |
| }, |
| { |
| "name" : "parse_ethernet", |
| "id" : 2, |
| "parser_ops" : [ |
| { |
| "parameters" : [ |
| { |
| "type" : "regular", |
| "value" : "ethernet" |
| } |
| ], |
| "op" : "extract" |
| } |
| ], |
| "transitions" : [ |
| { |
| "type" : "hexstr", |
| "value" : "0x0800", |
| "mask" : null, |
| "next_state" : "parse_ipv4" |
| }, |
| { |
| "value" : "default", |
| "mask" : null, |
| "next_state" : null |
| } |
| ], |
| "transition_key" : [ |
| { |
| "type" : "field", |
| "value" : ["ethernet", "ether_type"] |
| } |
| ] |
| }, |
| { |
| "name" : "parse_ipv4", |
| "id" : 3, |
| "parser_ops" : [ |
| { |
| "parameters" : [ |
| { |
| "type" : "regular", |
| "value" : "ipv4" |
| } |
| ], |
| "op" : "extract" |
| } |
| ], |
| "transitions" : [ |
| { |
| "type" : "hexstr", |
| "value" : "0x06", |
| "mask" : null, |
| "next_state" : "parse_tcp" |
| }, |
| { |
| "type" : "hexstr", |
| "value" : "0x11", |
| "mask" : null, |
| "next_state" : "parse_udp" |
| }, |
| { |
| "value" : "default", |
| "mask" : null, |
| "next_state" : null |
| } |
| ], |
| "transition_key" : [ |
| { |
| "type" : "field", |
| "value" : ["ipv4", "protocol"] |
| } |
| ] |
| }, |
| { |
| "name" : "parse_tcp", |
| "id" : 4, |
| "parser_ops" : [ |
| { |
| "parameters" : [ |
| { |
| "type" : "regular", |
| "value" : "tcp" |
| } |
| ], |
| "op" : "extract" |
| }, |
| { |
| "parameters" : [ |
| { |
| "type" : "field", |
| "value" : ["scalars", "local_metadata_t.l4_src_port"] |
| }, |
| { |
| "type" : "field", |
| "value" : ["tcp", "src_port"] |
| } |
| ], |
| "op" : "set" |
| }, |
| { |
| "parameters" : [ |
| { |
| "type" : "field", |
| "value" : ["scalars", "local_metadata_t.l4_dst_port"] |
| }, |
| { |
| "type" : "field", |
| "value" : ["tcp", "dst_port"] |
| } |
| ], |
| "op" : "set" |
| } |
| ], |
| "transitions" : [ |
| { |
| "value" : "default", |
| "mask" : null, |
| "next_state" : null |
| } |
| ], |
| "transition_key" : [] |
| }, |
| { |
| "name" : "parse_udp", |
| "id" : 5, |
| "parser_ops" : [ |
| { |
| "parameters" : [ |
| { |
| "type" : "regular", |
| "value" : "udp" |
| } |
| ], |
| "op" : "extract" |
| }, |
| { |
| "parameters" : [ |
| { |
| "type" : "field", |
| "value" : ["scalars", "local_metadata_t.l4_src_port"] |
| }, |
| { |
| "type" : "field", |
| "value" : ["udp", "src_port"] |
| } |
| ], |
| "op" : "set" |
| }, |
| { |
| "parameters" : [ |
| { |
| "type" : "field", |
| "value" : ["scalars", "local_metadata_t.l4_dst_port"] |
| }, |
| { |
| "type" : "field", |
| "value" : ["udp", "dst_port"] |
| } |
| ], |
| "op" : "set" |
| } |
| ], |
| "transitions" : [ |
| { |
| "value" : "default", |
| "mask" : null, |
| "next_state" : null |
| } |
| ], |
| "transition_key" : [] |
| } |
| ] |
| } |
| ], |
| "parse_vsets" : [], |
| "deparsers" : [ |
| { |
| "name" : "deparser", |
| "id" : 0, |
| "source_info" : { |
| "filename" : "include/parsers.p4", |
| "line" : 72, |
| "column" : 8, |
| "source_fragment" : "deparser" |
| }, |
| "order" : ["packet_in", "ethernet", "ipv4", "tcp", "udp"] |
| } |
| ], |
| "meter_arrays" : [ |
| { |
| "name" : "ingress.port_meters_ingress.ingress_port_meter", |
| "id" : 0, |
| "source_info" : { |
| "filename" : "include/port_meters.p4", |
| "line" : 23, |
| "column" : 32, |
| "source_fragment" : "ingress_port_meter" |
| }, |
| "is_direct" : false, |
| "size" : 511, |
| "rate_count" : 2, |
| "type" : "bytes" |
| }, |
| { |
| "name" : "ingress.host_meter_control.host_meter", |
| "id" : 1, |
| "source_info" : { |
| "filename" : "include/host_meter_table.p4", |
| "line" : 27, |
| "column" : 46, |
| "source_fragment" : "host_meter" |
| }, |
| "is_direct" : true, |
| "rate_count" : 2, |
| "type" : "bytes", |
| "size" : 1024, |
| "binding" : "ingress.host_meter_control.host_meter_table", |
| "result_target" : ["scalars", "host_meter_control_meter_tag_0"] |
| }, |
| { |
| "name" : "egress.port_meters_egress.egress_port_meter", |
| "id" : 2, |
| "source_info" : { |
| "filename" : "include/port_meters.p4", |
| "line" : 37, |
| "column" : 32, |
| "source_fragment" : "egress_port_meter" |
| }, |
| "is_direct" : false, |
| "size" : 511, |
| "rate_count" : 2, |
| "type" : "bytes" |
| } |
| ], |
| "counter_arrays" : [ |
| { |
| "name" : "ingress.port_counters_ingress.ingress_port_counter", |
| "id" : 0, |
| "source_info" : { |
| "filename" : "include/port_counters.p4", |
| "line" : 26, |
| "column" : 38, |
| "source_fragment" : "ingress_port_counter" |
| }, |
| "size" : 511, |
| "is_direct" : false |
| }, |
| { |
| "name" : "ingress.table0_control.table0_counter", |
| "id" : 1, |
| "is_direct" : true, |
| "binding" : "ingress.table0_control.table0", |
| "source_info" : { |
| "filename" : "include/table0.p4", |
| "line" : 27, |
| "column" : 50, |
| "source_fragment" : "table0_counter" |
| } |
| }, |
| { |
| "name" : "ingress.wcmp_control.wcmp_table_counter", |
| "id" : 2, |
| "is_direct" : true, |
| "binding" : "ingress.wcmp_control.wcmp_table", |
| "source_info" : { |
| "filename" : "include/wcmp.p4", |
| "line" : 27, |
| "column" : 50, |
| "source_fragment" : "wcmp_table_counter" |
| } |
| }, |
| { |
| "name" : "egress.port_counters_egress.egress_port_counter", |
| "id" : 3, |
| "source_info" : { |
| "filename" : "include/port_counters.p4", |
| "line" : 36, |
| "column" : 38, |
| "source_fragment" : "egress_port_counter" |
| }, |
| "size" : 511, |
| "is_direct" : false |
| } |
| ], |
| "register_arrays" : [], |
| "calculations" : [], |
| "learn_lists" : [], |
| "actions" : [ |
| { |
| "name" : "_drop", |
| "id" : 0, |
| "runtime_data" : [], |
| "primitives" : [ |
| { |
| "op" : "drop", |
| "parameters" : [], |
| "source_info" : { |
| "filename" : "include/actions.p4", |
| "line" : 24, |
| "column" : 4, |
| "source_fragment" : "mark_to_drop()" |
| } |
| } |
| ] |
| }, |
| { |
| "name" : "NoAction", |
| "id" : 1, |
| "runtime_data" : [], |
| "primitives" : [] |
| }, |
| { |
| "name" : "NoAction", |
| "id" : 2, |
| "runtime_data" : [], |
| "primitives" : [] |
| }, |
| { |
| "name" : "ingress.table0_control.set_next_hop_id", |
| "id" : 3, |
| "runtime_data" : [ |
| { |
| "name" : "next_hop_id", |
| "bitwidth" : 16 |
| } |
| ], |
| "primitives" : [ |
| { |
| "op" : "assign", |
| "parameters" : [ |
| { |
| "type" : "field", |
| "value" : ["scalars", "local_metadata_t.next_hop_id"] |
| }, |
| { |
| "type" : "runtime_data", |
| "value" : 0 |
| } |
| ], |
| "source_info" : { |
| "filename" : "include/table0.p4", |
| "line" : 30, |
| "column" : 8, |
| "source_fragment" : "local_metadata.next_hop_id = next_hop_id" |
| } |
| } |
| ] |
| }, |
| { |
| "name" : "ingress.table0_control.send_to_cpu", |
| "id" : 4, |
| "runtime_data" : [], |
| "primitives" : [ |
| { |
| "op" : "assign", |
| "parameters" : [ |
| { |
| "type" : "field", |
| "value" : ["standard_metadata", "egress_spec"] |
| }, |
| { |
| "type" : "hexstr", |
| "value" : "0x00ff" |
| } |
| ], |
| "source_info" : { |
| "filename" : "include/defines.p4", |
| "line" : 28, |
| "column" : 24, |
| "source_fragment" : "255; ..." |
| } |
| } |
| ] |
| }, |
| { |
| "name" : "ingress.table0_control.set_egress_port", |
| "id" : 5, |
| "runtime_data" : [ |
| { |
| "name" : "port", |
| "bitwidth" : 9 |
| } |
| ], |
| "primitives" : [ |
| { |
| "op" : "assign", |
| "parameters" : [ |
| { |
| "type" : "field", |
| "value" : ["standard_metadata", "egress_spec"] |
| }, |
| { |
| "type" : "runtime_data", |
| "value" : 0 |
| } |
| ], |
| "source_info" : { |
| "filename" : "include/table0.p4", |
| "line" : 38, |
| "column" : 8, |
| "source_fragment" : "standard_metadata.egress_spec = port" |
| } |
| } |
| ] |
| }, |
| { |
| "name" : "ingress.host_meter_control.read_meter", |
| "id" : 6, |
| "runtime_data" : [], |
| "primitives" : [] |
| }, |
| { |
| "name" : "ingress.wcmp_control.set_egress_port", |
| "id" : 7, |
| "runtime_data" : [ |
| { |
| "name" : "port", |
| "bitwidth" : 9 |
| } |
| ], |
| "primitives" : [ |
| { |
| "op" : "assign", |
| "parameters" : [ |
| { |
| "type" : "field", |
| "value" : ["standard_metadata", "egress_spec"] |
| }, |
| { |
| "type" : "runtime_data", |
| "value" : 0 |
| } |
| ], |
| "source_info" : { |
| "filename" : "include/wcmp.p4", |
| "line" : 31, |
| "column" : 8, |
| "source_fragment" : "standard_metadata.egress_spec = port" |
| } |
| } |
| ] |
| }, |
| { |
| "name" : "act", |
| "id" : 8, |
| "runtime_data" : [], |
| "primitives" : [ |
| { |
| "op" : "drop", |
| "parameters" : [], |
| "source_info" : { |
| "filename" : "include/port_meters.p4", |
| "line" : 29, |
| "column" : 12, |
| "source_fragment" : "mark_to_drop()" |
| } |
| } |
| ] |
| }, |
| { |
| "name" : "act_0", |
| "id" : 9, |
| "runtime_data" : [], |
| "primitives" : [ |
| { |
| "op" : "assign", |
| "parameters" : [ |
| { |
| "type" : "field", |
| "value" : ["scalars", "tmp"] |
| }, |
| { |
| "type" : "expression", |
| "value" : { |
| "type" : "expression", |
| "value" : { |
| "op" : "&", |
| "left" : { |
| "type" : "field", |
| "value" : ["standard_metadata", "ingress_port"] |
| }, |
| "right" : { |
| "type" : "hexstr", |
| "value" : "0xffffffff" |
| } |
| } |
| } |
| } |
| ], |
| "source_info" : { |
| "filename" : "include/port_counters.p4", |
| "line" : 29, |
| "column" : 35, |
| "source_fragment" : "(bit<32>) standard_metadata.ingress_port" |
| } |
| }, |
| { |
| "op" : "count", |
| "parameters" : [ |
| { |
| "type" : "counter_array", |
| "value" : "ingress.port_counters_ingress.ingress_port_counter" |
| }, |
| { |
| "type" : "field", |
| "value" : ["scalars", "tmp"] |
| } |
| ], |
| "source_info" : { |
| "filename" : "include/port_counters.p4", |
| "line" : 29, |
| "column" : 8, |
| "source_fragment" : "ingress_port_counter.count((bit<32>) standard_metadata.ingress_port)" |
| } |
| }, |
| { |
| "op" : "assign", |
| "parameters" : [ |
| { |
| "type" : "field", |
| "value" : ["scalars", "tmp_0"] |
| }, |
| { |
| "type" : "expression", |
| "value" : { |
| "type" : "expression", |
| "value" : { |
| "op" : "&", |
| "left" : { |
| "type" : "field", |
| "value" : ["standard_metadata", "ingress_port"] |
| }, |
| "right" : { |
| "type" : "hexstr", |
| "value" : "0xffffffff" |
| } |
| } |
| } |
| } |
| ], |
| "source_info" : { |
| "filename" : "include/port_meters.p4", |
| "line" : 27, |
| "column" : 53, |
| "source_fragment" : "(bit<32>)standard_metadata.ingress_port" |
| } |
| }, |
| { |
| "op" : "execute_meter", |
| "parameters" : [ |
| { |
| "type" : "meter_array", |
| "value" : "ingress.port_meters_ingress.ingress_port_meter" |
| }, |
| { |
| "type" : "field", |
| "value" : ["scalars", "tmp_0"] |
| }, |
| { |
| "type" : "field", |
| "value" : ["scalars", "port_meters_ingress_ingress_color_0"] |
| } |
| ], |
| "source_info" : { |
| "filename" : "include/port_meters.p4", |
| "line" : 27, |
| "column" : 8, |
| "source_fragment" : "ingress_port_meter.execute_meter<MeterColor>((bit<32>)standard_metadata.ingress_port, ingress_color)" |
| } |
| } |
| ] |
| }, |
| { |
| "name" : "act_1", |
| "id" : 10, |
| "runtime_data" : [], |
| "primitives" : [ |
| { |
| "op" : "assign", |
| "parameters" : [ |
| { |
| "type" : "field", |
| "value" : ["standard_metadata", "egress_spec"] |
| }, |
| { |
| "type" : "field", |
| "value" : ["packet_out", "egress_port"] |
| } |
| ], |
| "source_info" : { |
| "filename" : "include/packet_io.p4", |
| "line" : 27, |
| "column" : 12, |
| "source_fragment" : "standard_metadata.egress_spec = hdr.packet_out.egress_port" |
| } |
| }, |
| { |
| "op" : "remove_header", |
| "parameters" : [ |
| { |
| "type" : "header", |
| "value" : "packet_out" |
| } |
| ], |
| "source_info" : { |
| "filename" : "include/packet_io.p4", |
| "line" : 28, |
| "column" : 12, |
| "source_fragment" : "hdr.packet_out.setInvalid()" |
| } |
| } |
| ] |
| }, |
| { |
| "name" : "act_2", |
| "id" : 11, |
| "runtime_data" : [], |
| "primitives" : [ |
| { |
| "op" : "assign", |
| "parameters" : [ |
| { |
| "type" : "field", |
| "value" : ["scalars", "host_meter_control_meter_tag_0"] |
| }, |
| { |
| "type" : "hexstr", |
| "value" : "0x00" |
| } |
| ], |
| "source_info" : { |
| "filename" : "include/defines.p4", |
| "line" : 31, |
| "column" : 36, |
| "source_fragment" : "8w0; ..." |
| } |
| } |
| ] |
| }, |
| { |
| "name" : "act_3", |
| "id" : 12, |
| "runtime_data" : [], |
| "primitives" : [ |
| { |
| "op" : "drop", |
| "parameters" : [], |
| "source_info" : { |
| "filename" : "include/host_meter_table.p4", |
| "line" : 48, |
| "column" : 12, |
| "source_fragment" : "mark_to_drop()" |
| } |
| } |
| ] |
| }, |
| { |
| "name" : "act_4", |
| "id" : 13, |
| "runtime_data" : [], |
| "primitives" : [ |
| { |
| "op" : "drop", |
| "parameters" : [], |
| "source_info" : { |
| "filename" : "include/port_meters.p4", |
| "line" : 43, |
| "column" : 12, |
| "source_fragment" : "mark_to_drop()" |
| } |
| } |
| ] |
| }, |
| { |
| "name" : "act_5", |
| "id" : 14, |
| "runtime_data" : [], |
| "primitives" : [ |
| { |
| "op" : "assign", |
| "parameters" : [ |
| { |
| "type" : "field", |
| "value" : ["scalars", "tmp_1"] |
| }, |
| { |
| "type" : "expression", |
| "value" : { |
| "type" : "expression", |
| "value" : { |
| "op" : "&", |
| "left" : { |
| "type" : "field", |
| "value" : ["standard_metadata", "egress_port"] |
| }, |
| "right" : { |
| "type" : "hexstr", |
| "value" : "0xffffffff" |
| } |
| } |
| } |
| } |
| ], |
| "source_info" : { |
| "filename" : "include/port_counters.p4", |
| "line" : 39, |
| "column" : 34, |
| "source_fragment" : "(bit<32>) standard_metadata.egress_port" |
| } |
| }, |
| { |
| "op" : "count", |
| "parameters" : [ |
| { |
| "type" : "counter_array", |
| "value" : "egress.port_counters_egress.egress_port_counter" |
| }, |
| { |
| "type" : "field", |
| "value" : ["scalars", "tmp_1"] |
| } |
| ], |
| "source_info" : { |
| "filename" : "include/port_counters.p4", |
| "line" : 39, |
| "column" : 8, |
| "source_fragment" : "egress_port_counter.count((bit<32>) standard_metadata.egress_port)" |
| } |
| }, |
| { |
| "op" : "assign", |
| "parameters" : [ |
| { |
| "type" : "field", |
| "value" : ["scalars", "tmp_2"] |
| }, |
| { |
| "type" : "expression", |
| "value" : { |
| "type" : "expression", |
| "value" : { |
| "op" : "&", |
| "left" : { |
| "type" : "field", |
| "value" : ["standard_metadata", "egress_port"] |
| }, |
| "right" : { |
| "type" : "hexstr", |
| "value" : "0xffffffff" |
| } |
| } |
| } |
| } |
| ], |
| "source_info" : { |
| "filename" : "include/port_meters.p4", |
| "line" : 41, |
| "column" : 52, |
| "source_fragment" : "(bit<32>)standard_metadata.egress_port" |
| } |
| }, |
| { |
| "op" : "execute_meter", |
| "parameters" : [ |
| { |
| "type" : "meter_array", |
| "value" : "egress.port_meters_egress.egress_port_meter" |
| }, |
| { |
| "type" : "field", |
| "value" : ["scalars", "tmp_2"] |
| }, |
| { |
| "type" : "field", |
| "value" : ["scalars", "port_meters_egress_egress_color_0"] |
| } |
| ], |
| "source_info" : { |
| "filename" : "include/port_meters.p4", |
| "line" : 41, |
| "column" : 8, |
| "source_fragment" : "egress_port_meter.execute_meter<MeterColor>((bit<32>)standard_metadata.egress_port, egress_color)" |
| } |
| } |
| ] |
| }, |
| { |
| "name" : "act_6", |
| "id" : 15, |
| "runtime_data" : [], |
| "primitives" : [ |
| { |
| "op" : "add_header", |
| "parameters" : [ |
| { |
| "type" : "header", |
| "value" : "packet_in" |
| } |
| ], |
| "source_info" : { |
| "filename" : "include/packet_io.p4", |
| "line" : 38, |
| "column" : 12, |
| "source_fragment" : "hdr.packet_in.setValid()" |
| } |
| }, |
| { |
| "op" : "assign", |
| "parameters" : [ |
| { |
| "type" : "field", |
| "value" : ["packet_in", "ingress_port"] |
| }, |
| { |
| "type" : "field", |
| "value" : ["standard_metadata", "ingress_port"] |
| } |
| ], |
| "source_info" : { |
| "filename" : "include/packet_io.p4", |
| "line" : 39, |
| "column" : 12, |
| "source_fragment" : "hdr.packet_in.ingress_port = standard_metadata.ingress_port" |
| } |
| } |
| ] |
| } |
| ], |
| "pipelines" : [ |
| { |
| "name" : "ingress", |
| "id" : 0, |
| "source_info" : { |
| "filename" : "basic.p4", |
| "line" : 37, |
| "column" : 8, |
| "source_fragment" : "ingress" |
| }, |
| "init_table" : "tbl_act", |
| "tables" : [ |
| { |
| "name" : "tbl_act", |
| "id" : 0, |
| "key" : [], |
| "match_type" : "exact", |
| "type" : "simple", |
| "max_size" : 1024, |
| "with_counters" : false, |
| "support_timeout" : false, |
| "direct_meters" : null, |
| "action_ids" : [9], |
| "actions" : ["act_0"], |
| "base_default_next" : "node_3", |
| "next_tables" : { |
| "act_0" : "node_3" |
| }, |
| "default_entry" : { |
| "action_id" : 9, |
| "action_const" : true, |
| "action_data" : [], |
| "action_entry_const" : true |
| } |
| }, |
| { |
| "name" : "tbl_act_0", |
| "id" : 1, |
| "key" : [], |
| "match_type" : "exact", |
| "type" : "simple", |
| "max_size" : 1024, |
| "with_counters" : false, |
| "support_timeout" : false, |
| "direct_meters" : null, |
| "action_ids" : [8], |
| "actions" : ["act"], |
| "base_default_next" : "node_5", |
| "next_tables" : { |
| "act" : "node_5" |
| }, |
| "default_entry" : { |
| "action_id" : 8, |
| "action_const" : true, |
| "action_data" : [], |
| "action_entry_const" : true |
| } |
| }, |
| { |
| "name" : "tbl_act_1", |
| "id" : 2, |
| "key" : [], |
| "match_type" : "exact", |
| "type" : "simple", |
| "max_size" : 1024, |
| "with_counters" : false, |
| "support_timeout" : false, |
| "direct_meters" : null, |
| "action_ids" : [10], |
| "actions" : ["act_1"], |
| "base_default_next" : null, |
| "next_tables" : { |
| "act_1" : null |
| }, |
| "default_entry" : { |
| "action_id" : 10, |
| "action_const" : true, |
| "action_data" : [], |
| "action_entry_const" : true |
| } |
| }, |
| { |
| "name" : "ingress.table0_control.table0", |
| "id" : 3, |
| "source_info" : { |
| "filename" : "include/table0.p4", |
| "line" : 41, |
| "column" : 10, |
| "source_fragment" : "table0" |
| }, |
| "key" : [ |
| { |
| "match_type" : "ternary", |
| "name" : "standard_metadata.ingress_port", |
| "target" : ["standard_metadata", "ingress_port"], |
| "mask" : null |
| }, |
| { |
| "match_type" : "ternary", |
| "name" : "hdr.ethernet.src_addr", |
| "target" : ["ethernet", "src_addr"], |
| "mask" : null |
| }, |
| { |
| "match_type" : "ternary", |
| "name" : "hdr.ethernet.dst_addr", |
| "target" : ["ethernet", "dst_addr"], |
| "mask" : null |
| }, |
| { |
| "match_type" : "ternary", |
| "name" : "hdr.ethernet.ether_type", |
| "target" : ["ethernet", "ether_type"], |
| "mask" : null |
| }, |
| { |
| "match_type" : "ternary", |
| "name" : "hdr.ipv4.src_addr", |
| "target" : ["ipv4", "src_addr"], |
| "mask" : null |
| }, |
| { |
| "match_type" : "ternary", |
| "name" : "hdr.ipv4.dst_addr", |
| "target" : ["ipv4", "dst_addr"], |
| "mask" : null |
| }, |
| { |
| "match_type" : "ternary", |
| "name" : "hdr.ipv4.protocol", |
| "target" : ["ipv4", "protocol"], |
| "mask" : null |
| }, |
| { |
| "match_type" : "ternary", |
| "name" : "local_metadata.l4_src_port", |
| "target" : ["scalars", "local_metadata_t.l4_src_port"], |
| "mask" : null |
| }, |
| { |
| "match_type" : "ternary", |
| "name" : "local_metadata.l4_dst_port", |
| "target" : ["scalars", "local_metadata_t.l4_dst_port"], |
| "mask" : null |
| } |
| ], |
| "match_type" : "ternary", |
| "type" : "simple", |
| "max_size" : 1024, |
| "with_counters" : true, |
| "support_timeout" : false, |
| "direct_meters" : null, |
| "action_ids" : [5, 4, 3, 0], |
| "actions" : ["ingress.table0_control.set_egress_port", "ingress.table0_control.send_to_cpu", "ingress.table0_control.set_next_hop_id", "_drop"], |
| "base_default_next" : "tbl_act_2", |
| "next_tables" : { |
| "ingress.table0_control.set_egress_port" : "tbl_act_2", |
| "ingress.table0_control.send_to_cpu" : "tbl_act_2", |
| "ingress.table0_control.set_next_hop_id" : "tbl_act_2", |
| "_drop" : "tbl_act_2" |
| }, |
| "default_entry" : { |
| "action_id" : 0, |
| "action_const" : true, |
| "action_data" : [], |
| "action_entry_const" : true |
| } |
| }, |
| { |
| "name" : "tbl_act_2", |
| "id" : 4, |
| "key" : [], |
| "match_type" : "exact", |
| "type" : "simple", |
| "max_size" : 1024, |
| "with_counters" : false, |
| "support_timeout" : false, |
| "direct_meters" : null, |
| "action_ids" : [11], |
| "actions" : ["act_2"], |
| "base_default_next" : "ingress.host_meter_control.host_meter_table", |
| "next_tables" : { |
| "act_2" : "ingress.host_meter_control.host_meter_table" |
| }, |
| "default_entry" : { |
| "action_id" : 11, |
| "action_const" : true, |
| "action_data" : [], |
| "action_entry_const" : true |
| } |
| }, |
| { |
| "name" : "ingress.host_meter_control.host_meter_table", |
| "id" : 5, |
| "source_info" : { |
| "filename" : "include/host_meter_table.p4", |
| "line" : 33, |
| "column" : 10, |
| "source_fragment" : "host_meter_table" |
| }, |
| "key" : [ |
| { |
| "match_type" : "lpm", |
| "name" : "hdr.ethernet.src_addr", |
| "target" : ["ethernet", "src_addr"], |
| "mask" : null |
| } |
| ], |
| "match_type" : "lpm", |
| "type" : "simple", |
| "max_size" : 1024, |
| "with_counters" : false, |
| "support_timeout" : false, |
| "direct_meters" : "ingress.host_meter_control.host_meter", |
| "action_ids" : [6, 1], |
| "actions" : ["ingress.host_meter_control.read_meter", "NoAction"], |
| "base_default_next" : "node_10", |
| "next_tables" : { |
| "ingress.host_meter_control.read_meter" : "node_10", |
| "NoAction" : "node_10" |
| }, |
| "default_entry" : { |
| "action_id" : 1, |
| "action_const" : false, |
| "action_data" : [], |
| "action_entry_const" : false |
| } |
| }, |
| { |
| "name" : "tbl_act_3", |
| "id" : 6, |
| "key" : [], |
| "match_type" : "exact", |
| "type" : "simple", |
| "max_size" : 1024, |
| "with_counters" : false, |
| "support_timeout" : false, |
| "direct_meters" : null, |
| "action_ids" : [12], |
| "actions" : ["act_3"], |
| "base_default_next" : "node_12", |
| "next_tables" : { |
| "act_3" : "node_12" |
| }, |
| "default_entry" : { |
| "action_id" : 12, |
| "action_const" : true, |
| "action_data" : [], |
| "action_entry_const" : true |
| } |
| }, |
| { |
| "name" : "ingress.wcmp_control.wcmp_table", |
| "id" : 7, |
| "source_info" : { |
| "filename" : "include/wcmp.p4", |
| "line" : 34, |
| "column" : 10, |
| "source_fragment" : "wcmp_table" |
| }, |
| "key" : [ |
| { |
| "match_type" : "exact", |
| "name" : "local_metadata.next_hop_id", |
| "target" : ["scalars", "local_metadata_t.next_hop_id"], |
| "mask" : null |
| } |
| ], |
| "match_type" : "exact", |
| "type" : "indirect_ws", |
| "action_profile" : "ingress.wcmp_control.wcmp_selector", |
| "max_size" : 1024, |
| "with_counters" : true, |
| "support_timeout" : false, |
| "direct_meters" : null, |
| "action_ids" : [7, 2], |
| "actions" : ["ingress.wcmp_control.set_egress_port", "NoAction"], |
| "base_default_next" : null, |
| "next_tables" : { |
| "ingress.wcmp_control.set_egress_port" : null, |
| "NoAction" : null |
| } |
| } |
| ], |
| "action_profiles" : [ |
| { |
| "name" : "ingress.wcmp_control.wcmp_selector", |
| "id" : 0, |
| "source_info" : { |
| "filename" : "include/wcmp.p4", |
| "line" : 28, |
| "column" : 55, |
| "source_fragment" : "wcmp_selector" |
| }, |
| "max_size" : 64, |
| "selector" : { |
| "algo" : "crc16", |
| "input" : [ |
| { |
| "type" : "field", |
| "value" : ["ipv4", "src_addr"] |
| }, |
| { |
| "type" : "field", |
| "value" : ["ipv4", "dst_addr"] |
| }, |
| { |
| "type" : "field", |
| "value" : ["ipv4", "protocol"] |
| }, |
| { |
| "type" : "field", |
| "value" : ["scalars", "local_metadata_t.l4_src_port"] |
| }, |
| { |
| "type" : "field", |
| "value" : ["scalars", "local_metadata_t.l4_dst_port"] |
| } |
| ] |
| } |
| } |
| ], |
| "conditionals" : [ |
| { |
| "name" : "node_3", |
| "id" : 0, |
| "source_info" : { |
| "filename" : "include/port_meters.p4", |
| "line" : 28, |
| "column" : 12, |
| "source_fragment" : "ingress_color == MeterColor_RED" |
| }, |
| "expression" : { |
| "type" : "expression", |
| "value" : { |
| "op" : "==", |
| "left" : { |
| "type" : "field", |
| "value" : ["scalars", "port_meters_ingress_ingress_color_0"] |
| }, |
| "right" : { |
| "type" : "hexstr", |
| "value" : "0x02" |
| } |
| } |
| }, |
| "true_next" : "tbl_act_0", |
| "false_next" : "node_5" |
| }, |
| { |
| "name" : "node_5", |
| "id" : 1, |
| "source_info" : { |
| "filename" : "include/packet_io.p4", |
| "line" : 26, |
| "column" : 12, |
| "source_fragment" : "standard_metadata.ingress_port == CPU_PORT" |
| }, |
| "expression" : { |
| "type" : "expression", |
| "value" : { |
| "op" : "==", |
| "left" : { |
| "type" : "field", |
| "value" : ["standard_metadata", "ingress_port"] |
| }, |
| "right" : { |
| "type" : "hexstr", |
| "value" : "0x00ff" |
| } |
| } |
| }, |
| "true_next" : "tbl_act_1", |
| "false_next" : "ingress.table0_control.table0" |
| }, |
| { |
| "name" : "node_10", |
| "id" : 2, |
| "source_info" : { |
| "filename" : "include/host_meter_table.p4", |
| "line" : 47, |
| "column" : 12, |
| "source_fragment" : "meter_tag == MeterColor_RED" |
| }, |
| "expression" : { |
| "type" : "expression", |
| "value" : { |
| "op" : "==", |
| "left" : { |
| "type" : "field", |
| "value" : ["scalars", "host_meter_control_meter_tag_0"] |
| }, |
| "right" : { |
| "type" : "hexstr", |
| "value" : "0x02" |
| } |
| } |
| }, |
| "true_next" : "tbl_act_3", |
| "false_next" : "node_12" |
| }, |
| { |
| "name" : "node_12", |
| "id" : 3, |
| "source_info" : { |
| "filename" : "include/wcmp.p4", |
| "line" : 52, |
| "column" : 12, |
| "source_fragment" : "local_metadata.next_hop_id != 0" |
| }, |
| "expression" : { |
| "type" : "expression", |
| "value" : { |
| "op" : "!=", |
| "left" : { |
| "type" : "field", |
| "value" : ["scalars", "local_metadata_t.next_hop_id"] |
| }, |
| "right" : { |
| "type" : "hexstr", |
| "value" : "0x0000" |
| } |
| } |
| }, |
| "false_next" : null, |
| "true_next" : "ingress.wcmp_control.wcmp_table" |
| } |
| ] |
| }, |
| { |
| "name" : "egress", |
| "id" : 1, |
| "source_info" : { |
| "filename" : "basic.p4", |
| "line" : 55, |
| "column" : 8, |
| "source_fragment" : "egress" |
| }, |
| "init_table" : "tbl_act_4", |
| "tables" : [ |
| { |
| "name" : "tbl_act_4", |
| "id" : 8, |
| "key" : [], |
| "match_type" : "exact", |
| "type" : "simple", |
| "max_size" : 1024, |
| "with_counters" : false, |
| "support_timeout" : false, |
| "direct_meters" : null, |
| "action_ids" : [14], |
| "actions" : ["act_5"], |
| "base_default_next" : "node_17", |
| "next_tables" : { |
| "act_5" : "node_17" |
| }, |
| "default_entry" : { |
| "action_id" : 14, |
| "action_const" : true, |
| "action_data" : [], |
| "action_entry_const" : true |
| } |
| }, |
| { |
| "name" : "tbl_act_5", |
| "id" : 9, |
| "key" : [], |
| "match_type" : "exact", |
| "type" : "simple", |
| "max_size" : 1024, |
| "with_counters" : false, |
| "support_timeout" : false, |
| "direct_meters" : null, |
| "action_ids" : [13], |
| "actions" : ["act_4"], |
| "base_default_next" : "node_19", |
| "next_tables" : { |
| "act_4" : "node_19" |
| }, |
| "default_entry" : { |
| "action_id" : 13, |
| "action_const" : true, |
| "action_data" : [], |
| "action_entry_const" : true |
| } |
| }, |
| { |
| "name" : "tbl_act_6", |
| "id" : 10, |
| "key" : [], |
| "match_type" : "exact", |
| "type" : "simple", |
| "max_size" : 1024, |
| "with_counters" : false, |
| "support_timeout" : false, |
| "direct_meters" : null, |
| "action_ids" : [15], |
| "actions" : ["act_6"], |
| "base_default_next" : null, |
| "next_tables" : { |
| "act_6" : null |
| }, |
| "default_entry" : { |
| "action_id" : 15, |
| "action_const" : true, |
| "action_data" : [], |
| "action_entry_const" : true |
| } |
| } |
| ], |
| "action_profiles" : [], |
| "conditionals" : [ |
| { |
| "name" : "node_17", |
| "id" : 4, |
| "source_info" : { |
| "filename" : "include/port_meters.p4", |
| "line" : 42, |
| "column" : 12, |
| "source_fragment" : "egress_color == MeterColor_RED" |
| }, |
| "expression" : { |
| "type" : "expression", |
| "value" : { |
| "op" : "==", |
| "left" : { |
| "type" : "field", |
| "value" : ["scalars", "port_meters_egress_egress_color_0"] |
| }, |
| "right" : { |
| "type" : "hexstr", |
| "value" : "0x02" |
| } |
| } |
| }, |
| "true_next" : "tbl_act_5", |
| "false_next" : "node_19" |
| }, |
| { |
| "name" : "node_19", |
| "id" : 5, |
| "source_info" : { |
| "filename" : "include/packet_io.p4", |
| "line" : 37, |
| "column" : 12, |
| "source_fragment" : "standard_metadata.egress_port == CPU_PORT" |
| }, |
| "expression" : { |
| "type" : "expression", |
| "value" : { |
| "op" : "==", |
| "left" : { |
| "type" : "field", |
| "value" : ["standard_metadata", "egress_port"] |
| }, |
| "right" : { |
| "type" : "hexstr", |
| "value" : "0x00ff" |
| } |
| } |
| }, |
| "false_next" : null, |
| "true_next" : "tbl_act_6" |
| } |
| ] |
| } |
| ], |
| "checksums" : [], |
| "force_arith" : [], |
| "extern_instances" : [], |
| "field_aliases" : [ |
| [ |
| "queueing_metadata.enq_timestamp", |
| ["standard_metadata", "enq_timestamp"] |
| ], |
| [ |
| "queueing_metadata.enq_qdepth", |
| ["standard_metadata", "enq_qdepth"] |
| ], |
| [ |
| "queueing_metadata.deq_timedelta", |
| ["standard_metadata", "deq_timedelta"] |
| ], |
| [ |
| "queueing_metadata.deq_qdepth", |
| ["standard_metadata", "deq_qdepth"] |
| ], |
| [ |
| "intrinsic_metadata.ingress_global_timestamp", |
| ["standard_metadata", "ingress_global_timestamp"] |
| ], |
| [ |
| "intrinsic_metadata.egress_global_timestamp", |
| ["standard_metadata", "egress_global_timestamp"] |
| ], |
| [ |
| "intrinsic_metadata.lf_field_list", |
| ["standard_metadata", "lf_field_list"] |
| ], |
| [ |
| "intrinsic_metadata.mcast_grp", |
| ["standard_metadata", "mcast_grp"] |
| ], |
| [ |
| "intrinsic_metadata.resubmit_flag", |
| ["standard_metadata", "resubmit_flag"] |
| ], |
| [ |
| "intrinsic_metadata.egress_rid", |
| ["standard_metadata", "egress_rid"] |
| ], |
| [ |
| "intrinsic_metadata.recirculate_flag", |
| ["standard_metadata", "recirculate_flag"] |
| ] |
| ], |
| "program" : "basic.p4", |
| "__meta__" : { |
| "version" : [2, 18], |
| "compiler" : "https://github.com/p4lang/p4c" |
| } |
| } |