blob: b90e0d68c5f5f30945ea3411cc1f6aa915ba9129 [file] [log] [blame]
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001{
2 "program" : "basic.p4",
3 "__meta__" : {
4 "version" : [2, 7],
5 "compiler" : "https://github.com/p4lang/p4c"
6 },
7 "header_types" : [
8 {
9 "name" : "scalars_0",
10 "id" : 0,
11 "fields" : [
12 ["tmp", 32, false],
13 ["tmp_0", 32, false],
Frank Wangd7e3b4b2017-09-24 13:37:54 +090014 ["port_meters_ingress_ingress_color_0", 32, false],
15 ["host_meter_control_tmp_1", 1, false],
16 ["host_meter_control_tmp_2", 1, false],
17 ["tmp_1", 32, false],
18 ["tmp_2", 32, false],
19 ["port_meters_egress_egress_color_0", 32, false],
Carmelo Casconeca94bcf2017-10-27 14:16:59 -070020 ["local_metadata_t.l4_src_port", 16, false],
21 ["local_metadata_t.l4_dst_port", 16, false],
Frank Wangd7e3b4b2017-09-24 13:37:54 +090022 ["local_metadata_t.next_hop_id", 16, false],
23 ["local_metadata_t.meter_tag", 32, false],
24 ["_padding_2", 6, false]
Carmelo Casconeca94bcf2017-10-27 14:16:59 -070025 ]
26 },
27 {
Jonghwan Hyun4a9a6712017-11-13 14:43:55 -080028 "name" : "packet_out_header_t",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -070029 "id" : 1,
30 "fields" : [
Jonghwan Hyun4a9a6712017-11-13 14:43:55 -080031 ["egress_port", 9, false],
32 ["_padding", 7, false]
33 ]
34 },
35 {
36 "name" : "packet_in_header_t",
37 "id" : 2,
38 "fields" : [
39 ["ingress_port", 9, false],
40 ["_padding_0", 7, false]
41 ]
42 },
43 {
44 "name" : "ethernet_t",
45 "id" : 3,
46 "fields" : [
Carmelo Casconeca94bcf2017-10-27 14:16:59 -070047 ["dst_addr", 48, false],
48 ["src_addr", 48, false],
49 ["ether_type", 16, false]
50 ]
51 },
52 {
53 "name" : "ipv4_t",
Jonghwan Hyun4a9a6712017-11-13 14:43:55 -080054 "id" : 4,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -070055 "fields" : [
56 ["version", 4, false],
57 ["ihl", 4, false],
Jonghwan Hyun8be03392017-12-04 15:48:44 -080058 ["dscp", 6, false],
59 ["ecn", 2, false],
Carmelo Casconeca94bcf2017-10-27 14:16:59 -070060 ["len", 16, false],
61 ["identification", 16, false],
62 ["flags", 3, false],
63 ["frag_offset", 13, false],
64 ["ttl", 8, false],
65 ["protocol", 8, false],
66 ["hdr_checksum", 16, false],
67 ["src_addr", 32, false],
68 ["dst_addr", 32, false]
69 ]
70 },
71 {
72 "name" : "tcp_t",
Jonghwan Hyun4a9a6712017-11-13 14:43:55 -080073 "id" : 5,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -070074 "fields" : [
75 ["src_port", 16, false],
76 ["dst_port", 16, false],
77 ["seq_no", 32, false],
78 ["ack_no", 32, false],
79 ["data_offset", 4, false],
80 ["res", 3, false],
81 ["ecn", 3, false],
82 ["ctrl", 6, false],
83 ["window", 16, false],
84 ["checksum", 16, false],
85 ["urgent_ptr", 16, false]
86 ]
87 },
88 {
89 "name" : "udp_t",
Jonghwan Hyun4a9a6712017-11-13 14:43:55 -080090 "id" : 6,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -070091 "fields" : [
92 ["src_port", 16, false],
93 ["dst_port", 16, false],
94 ["length_", 16, false],
95 ["checksum", 16, false]
96 ]
97 },
98 {
Carmelo Casconeca94bcf2017-10-27 14:16:59 -070099 "name" : "standard_metadata",
100 "id" : 7,
101 "fields" : [
102 ["ingress_port", 9, false],
103 ["egress_spec", 9, false],
104 ["egress_port", 9, false],
105 ["clone_spec", 32, false],
106 ["instance_type", 32, false],
107 ["drop", 1, false],
108 ["recirculate_port", 16, false],
109 ["packet_length", 32, false],
110 ["enq_timestamp", 32, false],
111 ["enq_qdepth", 19, false],
112 ["deq_timedelta", 32, false],
113 ["deq_qdepth", 19, false],
114 ["ingress_global_timestamp", 48, false],
115 ["lf_field_list", 32, false],
116 ["mcast_grp", 16, false],
117 ["resubmit_flag", 1, false],
118 ["egress_rid", 16, false],
119 ["checksum_error", 1, false],
120 ["_padding_1", 4, false]
121 ]
122 }
123 ],
124 "headers" : [
125 {
126 "name" : "scalars",
127 "id" : 0,
128 "header_type" : "scalars_0",
129 "metadata" : true,
130 "pi_omit" : true
131 },
132 {
133 "name" : "standard_metadata",
134 "id" : 1,
135 "header_type" : "standard_metadata",
136 "metadata" : true,
137 "pi_omit" : true
138 },
139 {
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700140 "name" : "packet_out",
Jonghwan Hyun4a9a6712017-11-13 14:43:55 -0800141 "id" : 2,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700142 "header_type" : "packet_out_header_t",
143 "metadata" : false,
144 "pi_omit" : true
145 },
146 {
147 "name" : "packet_in",
Jonghwan Hyun4a9a6712017-11-13 14:43:55 -0800148 "id" : 3,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700149 "header_type" : "packet_in_header_t",
150 "metadata" : false,
151 "pi_omit" : true
Jonghwan Hyun4a9a6712017-11-13 14:43:55 -0800152 },
153 {
154 "name" : "ethernet",
155 "id" : 4,
156 "header_type" : "ethernet_t",
157 "metadata" : false,
158 "pi_omit" : true
159 },
160 {
161 "name" : "ipv4",
162 "id" : 5,
163 "header_type" : "ipv4_t",
164 "metadata" : false,
165 "pi_omit" : true
166 },
167 {
168 "name" : "tcp",
169 "id" : 6,
170 "header_type" : "tcp_t",
171 "metadata" : false,
172 "pi_omit" : true
173 },
174 {
175 "name" : "udp",
176 "id" : 7,
177 "header_type" : "udp_t",
178 "metadata" : false,
179 "pi_omit" : true
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700180 }
181 ],
182 "header_stacks" : [],
183 "header_union_types" : [],
184 "header_unions" : [],
185 "header_union_stacks" : [],
186 "field_lists" : [],
187 "errors" : [
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900188 ["NoError", 1],
189 ["PacketTooShort", 2],
190 ["NoMatch", 3],
191 ["StackOutOfBounds", 4],
192 ["HeaderTooShort", 5],
193 ["ParserTimeout", 6]
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700194 ],
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900195 "enums" : [
196 {
197 "name" : "MeterColor_t",
198 "entries" : [
199 ["GREEN", 0],
200 ["RED", 2],
201 ["YELLOW", 1]
202 ]
203 }
204 ],
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700205 "parsers" : [
206 {
207 "name" : "parser",
208 "id" : 0,
209 "init_state" : "start",
210 "parse_states" : [
211 {
212 "name" : "start",
213 "id" : 0,
214 "parser_ops" : [],
215 "transitions" : [
216 {
217 "value" : "0x00ff",
218 "mask" : null,
219 "next_state" : "parse_packet_out"
220 },
221 {
222 "value" : "default",
223 "mask" : null,
224 "next_state" : "parse_ethernet"
225 }
226 ],
227 "transition_key" : [
228 {
229 "type" : "field",
230 "value" : ["standard_metadata", "ingress_port"]
231 }
232 ]
233 },
234 {
235 "name" : "parse_packet_out",
236 "id" : 1,
237 "parser_ops" : [
238 {
239 "parameters" : [
240 {
241 "type" : "regular",
242 "value" : "packet_out"
243 }
244 ],
245 "op" : "extract"
246 }
247 ],
248 "transitions" : [
249 {
250 "value" : "default",
251 "mask" : null,
252 "next_state" : "parse_ethernet"
253 }
254 ],
255 "transition_key" : []
256 },
257 {
258 "name" : "parse_ethernet",
259 "id" : 2,
260 "parser_ops" : [
261 {
262 "parameters" : [
263 {
264 "type" : "regular",
265 "value" : "ethernet"
266 }
267 ],
268 "op" : "extract"
269 }
270 ],
271 "transitions" : [
272 {
273 "value" : "0x0800",
274 "mask" : null,
275 "next_state" : "parse_ipv4"
276 },
277 {
278 "value" : "default",
279 "mask" : null,
280 "next_state" : null
281 }
282 ],
283 "transition_key" : [
284 {
285 "type" : "field",
286 "value" : ["ethernet", "ether_type"]
287 }
288 ]
289 },
290 {
291 "name" : "parse_ipv4",
292 "id" : 3,
293 "parser_ops" : [
294 {
295 "parameters" : [
296 {
297 "type" : "regular",
298 "value" : "ipv4"
299 }
300 ],
301 "op" : "extract"
302 }
303 ],
304 "transitions" : [
305 {
306 "value" : "0x06",
307 "mask" : null,
308 "next_state" : "parse_tcp"
309 },
310 {
311 "value" : "0x11",
312 "mask" : null,
313 "next_state" : "parse_udp"
314 },
315 {
316 "value" : "default",
317 "mask" : null,
318 "next_state" : null
319 }
320 ],
321 "transition_key" : [
322 {
323 "type" : "field",
324 "value" : ["ipv4", "protocol"]
325 }
326 ]
327 },
328 {
329 "name" : "parse_tcp",
330 "id" : 4,
331 "parser_ops" : [
332 {
333 "parameters" : [
334 {
335 "type" : "regular",
336 "value" : "tcp"
337 }
338 ],
339 "op" : "extract"
340 },
341 {
342 "parameters" : [
343 {
344 "type" : "field",
345 "value" : ["scalars", "local_metadata_t.l4_src_port"]
346 },
347 {
348 "type" : "field",
349 "value" : ["tcp", "src_port"]
350 }
351 ],
352 "op" : "set"
353 },
354 {
355 "parameters" : [
356 {
357 "type" : "field",
358 "value" : ["scalars", "local_metadata_t.l4_dst_port"]
359 },
360 {
361 "type" : "field",
362 "value" : ["tcp", "dst_port"]
363 }
364 ],
365 "op" : "set"
366 }
367 ],
368 "transitions" : [
369 {
370 "value" : "default",
371 "mask" : null,
372 "next_state" : null
373 }
374 ],
375 "transition_key" : []
376 },
377 {
378 "name" : "parse_udp",
379 "id" : 5,
380 "parser_ops" : [
381 {
382 "parameters" : [
383 {
384 "type" : "regular",
385 "value" : "udp"
386 }
387 ],
388 "op" : "extract"
389 },
390 {
391 "parameters" : [
392 {
393 "type" : "field",
394 "value" : ["scalars", "local_metadata_t.l4_src_port"]
395 },
396 {
397 "type" : "field",
398 "value" : ["udp", "src_port"]
399 }
400 ],
401 "op" : "set"
402 },
403 {
404 "parameters" : [
405 {
406 "type" : "field",
407 "value" : ["scalars", "local_metadata_t.l4_dst_port"]
408 },
409 {
410 "type" : "field",
411 "value" : ["udp", "dst_port"]
412 }
413 ],
414 "op" : "set"
415 }
416 ],
417 "transitions" : [
418 {
419 "value" : "default",
420 "mask" : null,
421 "next_state" : null
422 }
423 ],
424 "transition_key" : []
425 }
426 ]
427 }
428 ],
429 "deparsers" : [
430 {
431 "name" : "deparser",
432 "id" : 0,
433 "source_info" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900434 "filename" : "include/parsers.p4",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700435 "line" : 72,
436 "column" : 8,
437 "source_fragment" : "deparser"
438 },
439 "order" : ["packet_in", "ethernet", "ipv4", "tcp", "udp"]
440 }
441 ],
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900442 "meter_arrays" : [
443 {
444 "name" : "port_meters_ingress.ingress_port_meter",
445 "id" : 0,
446 "source_info" : {
447 "filename" : "include/port_meters.p4",
448 "line" : 23,
449 "column" : 32,
450 "source_fragment" : "ingress_port_meter"
451 },
452 "is_direct" : false,
453 "size" : 511,
454 "rate_count" : 2,
455 "type" : "bytes"
456 },
457 {
458 "name" : "host_meter_control.host_meter",
459 "id" : 1,
460 "source_info" : {
461 "filename" : "include/host_meter_table.p4",
462 "line" : 27,
463 "column" : 43,
464 "source_fragment" : "host_meter"
465 },
466 "is_direct" : true,
467 "rate_count" : 2,
468 "type" : "bytes",
469 "size" : 1024,
470 "binding" : "host_meter_control.host_meter_table",
471 "result_target" : ["scalars", "local_metadata_t.meter_tag"]
472 },
473 {
474 "name" : "port_meters_egress.egress_port_meter",
475 "id" : 2,
476 "source_info" : {
477 "filename" : "include/port_meters.p4",
478 "line" : 37,
479 "column" : 32,
480 "source_fragment" : "egress_port_meter"
481 },
482 "is_direct" : false,
483 "size" : 511,
484 "rate_count" : 2,
485 "type" : "bytes"
486 }
487 ],
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700488 "counter_arrays" : [
489 {
490 "name" : "port_counters_ingress.ingress_port_counter",
491 "id" : 0,
492 "source_info" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900493 "filename" : "include/port_counters.p4",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700494 "line" : 26,
495 "column" : 38,
496 "source_fragment" : "ingress_port_counter"
497 },
498 "size" : 511,
499 "is_direct" : false
500 },
501 {
502 "name" : "table0_control.table0_counter",
503 "id" : 1,
504 "is_direct" : true,
505 "binding" : "table0_control.table0"
506 },
507 {
508 "name" : "wcmp_control.wcmp_table_counter",
509 "id" : 2,
510 "is_direct" : true,
511 "binding" : "wcmp_control.wcmp_table"
512 },
513 {
514 "name" : "port_counters_egress.egress_port_counter",
515 "id" : 3,
516 "source_info" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900517 "filename" : "include/port_counters.p4",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700518 "line" : 36,
519 "column" : 38,
520 "source_fragment" : "egress_port_counter"
521 },
522 "size" : 511,
523 "is_direct" : false
524 }
525 ],
526 "register_arrays" : [],
527 "calculations" : [],
528 "learn_lists" : [],
529 "actions" : [
530 {
531 "name" : "set_egress_port",
532 "id" : 0,
533 "runtime_data" : [
534 {
535 "name" : "port",
536 "bitwidth" : 9
537 }
538 ],
539 "primitives" : [
540 {
541 "op" : "assign",
542 "parameters" : [
543 {
544 "type" : "field",
545 "value" : ["standard_metadata", "egress_spec"]
546 },
547 {
548 "type" : "runtime_data",
549 "value" : 0
550 }
551 ],
552 "source_info" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900553 "filename" : "include/actions.p4",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700554 "line" : 28,
555 "column" : 36,
556 "source_fragment" : "port; ..."
557 }
558 }
559 ]
560 },
561 {
562 "name" : "set_egress_port",
563 "id" : 1,
564 "runtime_data" : [
565 {
566 "name" : "port",
567 "bitwidth" : 9
568 }
569 ],
570 "primitives" : [
571 {
572 "op" : "assign",
573 "parameters" : [
574 {
575 "type" : "field",
576 "value" : ["standard_metadata", "egress_spec"]
577 },
578 {
579 "type" : "runtime_data",
580 "value" : 0
581 }
582 ],
583 "source_info" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900584 "filename" : "include/actions.p4",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700585 "line" : 28,
586 "column" : 36,
587 "source_fragment" : "port; ..."
588 }
589 }
590 ]
591 },
592 {
593 "name" : "send_to_cpu",
594 "id" : 2,
595 "runtime_data" : [],
596 "primitives" : [
597 {
598 "op" : "assign",
599 "parameters" : [
600 {
601 "type" : "field",
602 "value" : ["standard_metadata", "egress_spec"]
603 },
604 {
605 "type" : "hexstr",
606 "value" : "0x00ff"
607 }
608 ],
609 "source_info" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900610 "filename" : "include/defines.p4",
611 "line" : 28,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700612 "column" : 24,
613 "source_fragment" : "255; ..."
614 }
615 }
616 ]
617 },
618 {
619 "name" : "_drop",
620 "id" : 3,
621 "runtime_data" : [],
622 "primitives" : [
623 {
624 "op" : "drop",
625 "parameters" : [],
626 "source_info" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900627 "filename" : "include/actions.p4",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700628 "line" : 32,
629 "column" : 4,
630 "source_fragment" : "mark_to_drop()"
631 }
632 }
633 ]
634 },
635 {
636 "name" : "NoAction",
637 "id" : 4,
638 "runtime_data" : [],
639 "primitives" : []
640 },
641 {
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900642 "name" : "NoAction",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700643 "id" : 5,
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900644 "runtime_data" : [],
645 "primitives" : []
646 },
647 {
648 "name" : "table0_control.set_next_hop_id",
649 "id" : 6,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700650 "runtime_data" : [
651 {
652 "name" : "next_hop_id",
653 "bitwidth" : 16
654 }
655 ],
656 "primitives" : [
657 {
658 "op" : "assign",
659 "parameters" : [
660 {
661 "type" : "field",
662 "value" : ["scalars", "local_metadata_t.next_hop_id"]
663 },
664 {
665 "type" : "runtime_data",
666 "value" : 0
667 }
668 ],
669 "source_info" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900670 "filename" : "include/table0.p4",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700671 "line" : 30,
672 "column" : 8,
673 "source_fragment" : "local_metadata.next_hop_id = next_hop_id"
674 }
675 }
676 ]
677 },
678 {
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900679 "name" : "host_meter_control.read_meter",
680 "id" : 7,
681 "runtime_data" : [],
682 "primitives" : []
683 },
684 {
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700685 "name" : "act",
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900686 "id" : 8,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700687 "runtime_data" : [],
688 "primitives" : [
689 {
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900690 "op" : "drop",
691 "parameters" : [],
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700692 "source_info" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900693 "filename" : "include/port_meters.p4",
694 "line" : 29,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700695 "column" : 12,
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900696 "source_fragment" : "mark_to_drop()"
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700697 }
698 }
699 ]
700 },
701 {
702 "name" : "act_0",
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900703 "id" : 9,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700704 "runtime_data" : [],
705 "primitives" : [
706 {
707 "op" : "assign",
708 "parameters" : [
709 {
710 "type" : "field",
711 "value" : ["scalars", "tmp"]
712 },
713 {
714 "type" : "expression",
715 "value" : {
716 "type" : "expression",
717 "value" : {
718 "op" : "&",
719 "left" : {
720 "type" : "field",
721 "value" : ["standard_metadata", "ingress_port"]
722 },
723 "right" : {
724 "type" : "hexstr",
725 "value" : "0xffffffff"
726 }
727 }
728 }
729 }
730 ]
731 },
732 {
733 "op" : "count",
734 "parameters" : [
735 {
736 "type" : "counter_array",
737 "value" : "port_counters_ingress.ingress_port_counter"
738 },
739 {
740 "type" : "field",
741 "value" : ["scalars", "tmp"]
742 }
743 ],
744 "source_info" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900745 "filename" : "include/port_counters.p4",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700746 "line" : 29,
747 "column" : 8,
748 "source_fragment" : "ingress_port_counter.count((bit<32>) standard_metadata.ingress_port)"
749 }
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700750 },
751 {
752 "op" : "assign",
753 "parameters" : [
754 {
755 "type" : "field",
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900756 "value" : ["scalars", "tmp_0"]
757 },
758 {
759 "type" : "expression",
760 "value" : {
761 "type" : "expression",
762 "value" : {
763 "op" : "&",
764 "left" : {
765 "type" : "field",
766 "value" : ["standard_metadata", "ingress_port"]
767 },
768 "right" : {
769 "type" : "hexstr",
770 "value" : "0xffffffff"
771 }
772 }
773 }
774 }
775 ]
776 },
777 {
778 "op" : "execute_meter",
779 "parameters" : [
780 {
781 "type" : "meter_array",
782 "value" : "port_meters_ingress.ingress_port_meter"
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700783 },
784 {
785 "type" : "field",
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900786 "value" : ["scalars", "tmp_0"]
787 },
788 {
789 "type" : "field",
790 "value" : ["scalars", "port_meters_ingress_ingress_color_0"]
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700791 }
792 ],
793 "source_info" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900794 "filename" : "include/port_meters.p4",
795 "line" : 27,
796 "column" : 8,
797 "source_fragment" : "ingress_port_meter.execute_meter<MeterColor_t>((bit<32>)standard_metadata.ingress_port, ingress_color)"
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700798 }
799 }
800 ]
801 },
802 {
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900803 "name" : "act_1",
804 "id" : 10,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -0700805 "runtime_data" : [],
806 "primitives" : [
807 {
808 "op" : "assign",
809 "parameters" : [
810 {
811 "type" : "field",
Frank Wangd7e3b4b2017-09-24 13:37:54 +0900812 "value" : ["standard_metadata", "egress_spec"]
813 },
814 {
815 "type" : "field",
816 "value" : ["packet_out", "egress_port"]
817 }
818 ],
819 "source_info" : {
820 "filename" : "include/packet_io.p4",
821 "line" : 27,
822 "column" : 12,
823 "source_fragment" : "standard_metadata.egress_spec = hdr.packet_out.egress_port"
824 }
825 },
826 {
827 "op" : "remove_header",
828 "parameters" : [
829 {
830 "type" : "header",
831 "value" : "packet_out"
832 }
833 ],
834 "source_info" : {
835 "filename" : "include/packet_io.p4",
836 "line" : 28,
837 "column" : 12,
838 "source_fragment" : "hdr.packet_out.setInvalid()"
839 }
840 }
841 ]
842 },
843 {
844 "name" : "act_2",
845 "id" : 11,
846 "runtime_data" : [],
847 "primitives" : [
848 {
849 "op" : "assign",
850 "parameters" : [
851 {
852 "type" : "field",
853 "value" : ["scalars", "host_meter_control_tmp_1"]
854 },
855 {
856 "type" : "expression",
857 "value" : {
858 "type" : "expression",
859 "value" : {
860 "op" : "b2d",
861 "left" : null,
862 "right" : {
863 "type" : "bool",
864 "value" : true
865 }
866 }
867 }
868 }
869 ]
870 }
871 ]
872 },
873 {
874 "name" : "act_3",
875 "id" : 12,
876 "runtime_data" : [],
877 "primitives" : [
878 {
879 "op" : "assign",
880 "parameters" : [
881 {
882 "type" : "field",
883 "value" : ["scalars", "host_meter_control_tmp_1"]
884 },
885 {
886 "type" : "expression",
887 "value" : {
888 "type" : "expression",
889 "value" : {
890 "op" : "b2d",
891 "left" : null,
892 "right" : {
893 "type" : "bool",
894 "value" : false
895 }
896 }
897 }
898 }
899 ]
900 }
901 ]
902 },
903 {
904 "name" : "act_4",
905 "id" : 13,
906 "runtime_data" : [],
907 "primitives" : [
908 {
909 "op" : "assign",
910 "parameters" : [
911 {
912 "type" : "field",
913 "value" : ["scalars", "host_meter_control_tmp_2"]
914 },
915 {
916 "type" : "expression",
917 "value" : {
918 "type" : "expression",
919 "value" : {
920 "op" : "b2d",
921 "left" : null,
922 "right" : {
923 "type" : "bool",
924 "value" : false
925 }
926 }
927 }
928 }
929 ],
930 "source_info" : {
931 "filename" : "include/host_meter_table.p4",
932 "line" : 46,
933 "column" : 12,
934 "source_fragment" : "host_meter_table.apply().hit && local_metadata.meter_tag == 2"
935 }
936 }
937 ]
938 },
939 {
940 "name" : "act_5",
941 "id" : 14,
942 "runtime_data" : [],
943 "primitives" : [
944 {
945 "op" : "assign",
946 "parameters" : [
947 {
948 "type" : "field",
949 "value" : ["scalars", "host_meter_control_tmp_2"]
950 },
951 {
952 "type" : "expression",
953 "value" : {
954 "type" : "expression",
955 "value" : {
956 "op" : "b2d",
957 "left" : null,
958 "right" : {
959 "type" : "expression",
960 "value" : {
961 "op" : "==",
962 "left" : {
963 "type" : "field",
964 "value" : ["scalars", "local_metadata_t.meter_tag"]
965 },
966 "right" : {
967 "type" : "hexstr",
968 "value" : "0x00000002"
969 }
970 }
971 }
972 }
973 }
974 }
975 ],
976 "source_info" : {
977 "filename" : "include/host_meter_table.p4",
978 "line" : 46,
979 "column" : 12,
980 "source_fragment" : "host_meter_table.apply().hit && local_metadata.meter_tag == 2"
981 }
982 }
983 ]
984 },
985 {
986 "name" : "act_6",
987 "id" : 15,
988 "runtime_data" : [],
989 "primitives" : [
990 {
991 "op" : "drop",
992 "parameters" : [],
993 "source_info" : {
994 "filename" : "include/host_meter_table.p4",
995 "line" : 47,
996 "column" : 12,
997 "source_fragment" : "mark_to_drop()"
998 }
999 }
1000 ]
1001 },
1002 {
1003 "name" : "act_7",
1004 "id" : 16,
1005 "runtime_data" : [],
1006 "primitives" : [
1007 {
1008 "op" : "drop",
1009 "parameters" : [],
1010 "source_info" : {
1011 "filename" : "include/port_meters.p4",
1012 "line" : 43,
1013 "column" : 12,
1014 "source_fragment" : "mark_to_drop()"
1015 }
1016 }
1017 ]
1018 },
1019 {
1020 "name" : "act_8",
1021 "id" : 17,
1022 "runtime_data" : [],
1023 "primitives" : [
1024 {
1025 "op" : "assign",
1026 "parameters" : [
1027 {
1028 "type" : "field",
1029 "value" : ["scalars", "tmp_1"]
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001030 },
1031 {
1032 "type" : "expression",
1033 "value" : {
1034 "type" : "expression",
1035 "value" : {
1036 "op" : "&",
1037 "left" : {
1038 "type" : "field",
1039 "value" : ["standard_metadata", "egress_port"]
1040 },
1041 "right" : {
1042 "type" : "hexstr",
1043 "value" : "0xffffffff"
1044 }
1045 }
1046 }
1047 }
1048 ]
1049 },
1050 {
1051 "op" : "count",
1052 "parameters" : [
1053 {
1054 "type" : "counter_array",
1055 "value" : "port_counters_egress.egress_port_counter"
1056 },
1057 {
1058 "type" : "field",
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001059 "value" : ["scalars", "tmp_1"]
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001060 }
1061 ],
1062 "source_info" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001063 "filename" : "include/port_counters.p4",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001064 "line" : 39,
1065 "column" : 8,
1066 "source_fragment" : "egress_port_counter.count((bit<32>) standard_metadata.egress_port)"
1067 }
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001068 },
1069 {
1070 "op" : "assign",
1071 "parameters" : [
1072 {
1073 "type" : "field",
1074 "value" : ["scalars", "tmp_2"]
1075 },
1076 {
1077 "type" : "expression",
1078 "value" : {
1079 "type" : "expression",
1080 "value" : {
1081 "op" : "&",
1082 "left" : {
1083 "type" : "field",
1084 "value" : ["standard_metadata", "egress_port"]
1085 },
1086 "right" : {
1087 "type" : "hexstr",
1088 "value" : "0xffffffff"
1089 }
1090 }
1091 }
1092 }
1093 ]
1094 },
1095 {
1096 "op" : "execute_meter",
1097 "parameters" : [
1098 {
1099 "type" : "meter_array",
1100 "value" : "port_meters_egress.egress_port_meter"
1101 },
1102 {
1103 "type" : "field",
1104 "value" : ["scalars", "tmp_2"]
1105 },
1106 {
1107 "type" : "field",
1108 "value" : ["scalars", "port_meters_egress_egress_color_0"]
1109 }
1110 ],
1111 "source_info" : {
1112 "filename" : "include/port_meters.p4",
1113 "line" : 41,
1114 "column" : 8,
1115 "source_fragment" : "egress_port_meter.execute_meter<MeterColor_t>((bit<32>)standard_metadata.egress_port, egress_color)"
1116 }
1117 }
1118 ]
1119 },
1120 {
1121 "name" : "act_9",
1122 "id" : 18,
1123 "runtime_data" : [],
1124 "primitives" : [
1125 {
1126 "op" : "add_header",
1127 "parameters" : [
1128 {
1129 "type" : "header",
1130 "value" : "packet_in"
1131 }
1132 ],
1133 "source_info" : {
1134 "filename" : "include/packet_io.p4",
1135 "line" : 38,
1136 "column" : 12,
1137 "source_fragment" : "hdr.packet_in.setValid()"
1138 }
1139 },
1140 {
1141 "op" : "assign",
1142 "parameters" : [
1143 {
1144 "type" : "field",
1145 "value" : ["packet_in", "ingress_port"]
1146 },
1147 {
1148 "type" : "field",
1149 "value" : ["standard_metadata", "ingress_port"]
1150 }
1151 ],
1152 "source_info" : {
1153 "filename" : "include/packet_io.p4",
1154 "line" : 39,
1155 "column" : 12,
1156 "source_fragment" : "hdr.packet_in.ingress_port = standard_metadata.ingress_port"
1157 }
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001158 }
1159 ]
1160 }
1161 ],
1162 "pipelines" : [
1163 {
1164 "name" : "ingress",
1165 "id" : 0,
1166 "source_info" : {
1167 "filename" : "basic.p4",
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001168 "line" : 37,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001169 "column" : 8,
1170 "source_fragment" : "ingress"
1171 },
1172 "init_table" : "tbl_act",
1173 "tables" : [
1174 {
1175 "name" : "tbl_act",
1176 "id" : 0,
1177 "key" : [],
1178 "match_type" : "exact",
1179 "type" : "simple",
1180 "max_size" : 1024,
1181 "with_counters" : false,
1182 "support_timeout" : false,
1183 "direct_meters" : null,
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001184 "action_ids" : [9],
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001185 "actions" : ["act_0"],
1186 "base_default_next" : "node_3",
1187 "next_tables" : {
1188 "act_0" : "node_3"
1189 },
1190 "default_entry" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001191 "action_id" : 9,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001192 "action_const" : true,
1193 "action_data" : [],
1194 "action_entry_const" : true
1195 }
1196 },
1197 {
1198 "name" : "tbl_act_0",
1199 "id" : 1,
1200 "key" : [],
1201 "match_type" : "exact",
1202 "type" : "simple",
1203 "max_size" : 1024,
1204 "with_counters" : false,
1205 "support_timeout" : false,
1206 "direct_meters" : null,
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001207 "action_ids" : [8],
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001208 "actions" : ["act"],
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001209 "base_default_next" : "node_5",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001210 "next_tables" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001211 "act" : "node_5"
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001212 },
1213 "default_entry" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001214 "action_id" : 8,
1215 "action_const" : true,
1216 "action_data" : [],
1217 "action_entry_const" : true
1218 }
1219 },
1220 {
1221 "name" : "tbl_act_1",
1222 "id" : 2,
1223 "key" : [],
1224 "match_type" : "exact",
1225 "type" : "simple",
1226 "max_size" : 1024,
1227 "with_counters" : false,
1228 "support_timeout" : false,
1229 "direct_meters" : null,
1230 "action_ids" : [10],
1231 "actions" : ["act_1"],
1232 "base_default_next" : null,
1233 "next_tables" : {
1234 "act_1" : null
1235 },
1236 "default_entry" : {
1237 "action_id" : 10,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001238 "action_const" : true,
1239 "action_data" : [],
1240 "action_entry_const" : true
1241 }
1242 },
1243 {
1244 "name" : "table0_control.table0",
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001245 "id" : 3,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001246 "source_info" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001247 "filename" : "include/table0.p4",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001248 "line" : 33,
1249 "column" : 10,
1250 "source_fragment" : "table0"
1251 },
1252 "key" : [
1253 {
1254 "match_type" : "ternary",
1255 "target" : ["standard_metadata", "ingress_port"],
1256 "mask" : null
1257 },
1258 {
1259 "match_type" : "ternary",
1260 "target" : ["ethernet", "src_addr"],
1261 "mask" : null
1262 },
1263 {
1264 "match_type" : "ternary",
1265 "target" : ["ethernet", "dst_addr"],
1266 "mask" : null
1267 },
1268 {
1269 "match_type" : "ternary",
1270 "target" : ["ethernet", "ether_type"],
1271 "mask" : null
1272 },
1273 {
1274 "match_type" : "ternary",
1275 "target" : ["ipv4", "src_addr"],
1276 "mask" : null
1277 },
1278 {
1279 "match_type" : "ternary",
1280 "target" : ["ipv4", "dst_addr"],
1281 "mask" : null
1282 },
1283 {
1284 "match_type" : "ternary",
1285 "target" : ["ipv4", "protocol"],
1286 "mask" : null
1287 },
1288 {
1289 "match_type" : "ternary",
1290 "target" : ["scalars", "local_metadata_t.l4_src_port"],
1291 "mask" : null
1292 },
1293 {
1294 "match_type" : "ternary",
1295 "target" : ["scalars", "local_metadata_t.l4_dst_port"],
1296 "mask" : null
1297 }
1298 ],
1299 "match_type" : "ternary",
1300 "type" : "simple",
1301 "max_size" : 1024,
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001302 "with_counters" : true,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001303 "support_timeout" : false,
1304 "direct_meters" : null,
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001305 "action_ids" : [0, 2, 6, 3],
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001306 "actions" : ["set_egress_port", "send_to_cpu", "table0_control.set_next_hop_id", "_drop"],
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001307 "base_default_next" : "host_meter_control.host_meter_table",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001308 "next_tables" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001309 "set_egress_port" : "host_meter_control.host_meter_table",
1310 "send_to_cpu" : "host_meter_control.host_meter_table",
1311 "table0_control.set_next_hop_id" : "host_meter_control.host_meter_table",
1312 "_drop" : "host_meter_control.host_meter_table"
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001313 },
1314 "default_entry" : {
1315 "action_id" : 3,
1316 "action_const" : true,
1317 "action_data" : [],
1318 "action_entry_const" : true
1319 }
1320 },
1321 {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001322 "name" : "host_meter_control.host_meter_table",
1323 "id" : 4,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001324 "source_info" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001325 "filename" : "include/host_meter_table.p4",
1326 "line" : 33,
1327 "column" : 10,
1328 "source_fragment" : "host_meter_table"
1329 },
1330 "key" : [
1331 {
1332 "match_type" : "lpm",
1333 "target" : ["ethernet", "src_addr"],
1334 "mask" : null
1335 }
1336 ],
1337 "match_type" : "lpm",
1338 "type" : "simple",
1339 "max_size" : 1024,
1340 "with_counters" : false,
1341 "support_timeout" : false,
1342 "direct_meters" : "host_meter_control.host_meter",
1343 "action_ids" : [7, 4],
1344 "actions" : ["host_meter_control.read_meter", "NoAction"],
1345 "base_default_next" : null,
1346 "next_tables" : {
1347 "__HIT__" : "tbl_act_2",
1348 "__MISS__" : "tbl_act_3"
1349 },
1350 "default_entry" : {
1351 "action_id" : 4,
1352 "action_const" : false,
1353 "action_data" : [],
1354 "action_entry_const" : false
1355 }
1356 },
1357 {
1358 "name" : "tbl_act_2",
1359 "id" : 5,
1360 "key" : [],
1361 "match_type" : "exact",
1362 "type" : "simple",
1363 "max_size" : 1024,
1364 "with_counters" : false,
1365 "support_timeout" : false,
1366 "direct_meters" : null,
1367 "action_ids" : [11],
1368 "actions" : ["act_2"],
1369 "base_default_next" : "node_11",
1370 "next_tables" : {
1371 "act_2" : "node_11"
1372 },
1373 "default_entry" : {
1374 "action_id" : 11,
1375 "action_const" : true,
1376 "action_data" : [],
1377 "action_entry_const" : true
1378 }
1379 },
1380 {
1381 "name" : "tbl_act_3",
1382 "id" : 6,
1383 "key" : [],
1384 "match_type" : "exact",
1385 "type" : "simple",
1386 "max_size" : 1024,
1387 "with_counters" : false,
1388 "support_timeout" : false,
1389 "direct_meters" : null,
1390 "action_ids" : [12],
1391 "actions" : ["act_3"],
1392 "base_default_next" : "node_11",
1393 "next_tables" : {
1394 "act_3" : "node_11"
1395 },
1396 "default_entry" : {
1397 "action_id" : 12,
1398 "action_const" : true,
1399 "action_data" : [],
1400 "action_entry_const" : true
1401 }
1402 },
1403 {
1404 "name" : "tbl_act_4",
1405 "id" : 7,
1406 "key" : [],
1407 "match_type" : "exact",
1408 "type" : "simple",
1409 "max_size" : 1024,
1410 "with_counters" : false,
1411 "support_timeout" : false,
1412 "direct_meters" : null,
1413 "action_ids" : [13],
1414 "actions" : ["act_4"],
1415 "base_default_next" : "node_14",
1416 "next_tables" : {
1417 "act_4" : "node_14"
1418 },
1419 "default_entry" : {
1420 "action_id" : 13,
1421 "action_const" : true,
1422 "action_data" : [],
1423 "action_entry_const" : true
1424 }
1425 },
1426 {
1427 "name" : "tbl_act_5",
1428 "id" : 8,
1429 "key" : [],
1430 "match_type" : "exact",
1431 "type" : "simple",
1432 "max_size" : 1024,
1433 "with_counters" : false,
1434 "support_timeout" : false,
1435 "direct_meters" : null,
1436 "action_ids" : [14],
1437 "actions" : ["act_5"],
1438 "base_default_next" : "node_14",
1439 "next_tables" : {
1440 "act_5" : "node_14"
1441 },
1442 "default_entry" : {
1443 "action_id" : 14,
1444 "action_const" : true,
1445 "action_data" : [],
1446 "action_entry_const" : true
1447 }
1448 },
1449 {
1450 "name" : "tbl_act_6",
1451 "id" : 9,
1452 "key" : [],
1453 "match_type" : "exact",
1454 "type" : "simple",
1455 "max_size" : 1024,
1456 "with_counters" : false,
1457 "support_timeout" : false,
1458 "direct_meters" : null,
1459 "action_ids" : [15],
1460 "actions" : ["act_6"],
1461 "base_default_next" : "node_16",
1462 "next_tables" : {
1463 "act_6" : "node_16"
1464 },
1465 "default_entry" : {
1466 "action_id" : 15,
1467 "action_const" : true,
1468 "action_data" : [],
1469 "action_entry_const" : true
1470 }
1471 },
1472 {
1473 "name" : "wcmp_control.wcmp_table",
1474 "id" : 10,
1475 "source_info" : {
1476 "filename" : "include/wcmp.p4",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001477 "line" : 30,
1478 "column" : 10,
1479 "source_fragment" : "wcmp_table"
1480 },
1481 "key" : [
1482 {
1483 "match_type" : "exact",
1484 "target" : ["scalars", "local_metadata_t.next_hop_id"],
1485 "mask" : null
1486 }
1487 ],
1488 "match_type" : "exact",
1489 "type" : "indirect_ws",
1490 "action_profile" : "wcmp_control.wcmp_selector",
1491 "max_size" : 1024,
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001492 "with_counters" : true,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001493 "support_timeout" : false,
1494 "direct_meters" : null,
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001495 "action_ids" : [1, 5],
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001496 "actions" : ["set_egress_port", "NoAction"],
1497 "base_default_next" : null,
1498 "next_tables" : {
1499 "set_egress_port" : null,
1500 "NoAction" : null
1501 }
1502 }
1503 ],
1504 "action_profiles" : [
1505 {
1506 "name" : "wcmp_control.wcmp_selector",
1507 "id" : 0,
1508 "max_size" : 64,
1509 "selector" : {
1510 "algo" : "crc16",
1511 "input" : [
1512 {
1513 "type" : "field",
1514 "value" : ["ipv4", "src_addr"]
1515 },
1516 {
1517 "type" : "field",
1518 "value" : ["ipv4", "dst_addr"]
1519 },
1520 {
1521 "type" : "field",
1522 "value" : ["ipv4", "protocol"]
1523 },
1524 {
1525 "type" : "field",
1526 "value" : ["scalars", "local_metadata_t.l4_src_port"]
1527 },
1528 {
1529 "type" : "field",
1530 "value" : ["scalars", "local_metadata_t.l4_dst_port"]
1531 }
1532 ]
1533 }
1534 }
1535 ],
1536 "conditionals" : [
1537 {
1538 "name" : "node_3",
1539 "id" : 0,
1540 "source_info" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001541 "filename" : "include/port_meters.p4",
1542 "line" : 28,
1543 "column" : 12,
1544 "source_fragment" : "ingress_color == MeterColor_t.RED"
1545 },
1546 "expression" : {
1547 "type" : "expression",
1548 "value" : {
1549 "op" : "==",
1550 "left" : {
1551 "type" : "field",
1552 "value" : ["scalars", "port_meters_ingress_ingress_color_0"]
1553 },
1554 "right" : {
1555 "type" : "hexstr",
1556 "value" : "0x00000002"
1557 }
1558 }
1559 },
1560 "true_next" : "tbl_act_0",
1561 "false_next" : "node_5"
1562 },
1563 {
1564 "name" : "node_5",
1565 "id" : 1,
1566 "source_info" : {
1567 "filename" : "include/packet_io.p4",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001568 "line" : 26,
1569 "column" : 12,
1570 "source_fragment" : "standard_metadata.ingress_port == CPU_PORT"
1571 },
1572 "expression" : {
1573 "type" : "expression",
1574 "value" : {
1575 "op" : "==",
1576 "left" : {
1577 "type" : "field",
1578 "value" : ["standard_metadata", "ingress_port"]
1579 },
1580 "right" : {
1581 "type" : "hexstr",
1582 "value" : "0x00ff"
1583 }
1584 }
1585 },
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001586 "true_next" : "tbl_act_1",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001587 "false_next" : "table0_control.table0"
1588 },
1589 {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001590 "name" : "node_11",
1591 "id" : 2,
1592 "expression" : {
1593 "type" : "expression",
1594 "value" : {
1595 "op" : "not",
1596 "left" : null,
1597 "right" : {
1598 "type" : "expression",
1599 "value" : {
1600 "op" : "d2b",
1601 "left" : null,
1602 "right" : {
1603 "type" : "field",
1604 "value" : ["scalars", "host_meter_control_tmp_1"]
1605 }
1606 }
1607 }
1608 }
1609 },
1610 "true_next" : "tbl_act_4",
1611 "false_next" : "tbl_act_5"
1612 },
1613 {
1614 "name" : "node_14",
1615 "id" : 3,
1616 "expression" : {
1617 "type" : "expression",
1618 "value" : {
1619 "op" : "d2b",
1620 "left" : null,
1621 "right" : {
1622 "type" : "field",
1623 "value" : ["scalars", "host_meter_control_tmp_2"]
1624 }
1625 }
1626 },
1627 "true_next" : "tbl_act_6",
1628 "false_next" : "node_16"
1629 },
1630 {
1631 "name" : "node_16",
1632 "id" : 4,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001633 "source_info" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001634 "filename" : "include/wcmp.p4",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001635 "line" : 48,
1636 "column" : 12,
1637 "source_fragment" : "local_metadata.next_hop_id != 0"
1638 },
1639 "expression" : {
1640 "type" : "expression",
1641 "value" : {
1642 "op" : "!=",
1643 "left" : {
1644 "type" : "field",
1645 "value" : ["scalars", "local_metadata_t.next_hop_id"]
1646 },
1647 "right" : {
1648 "type" : "hexstr",
1649 "value" : "0x0000"
1650 }
1651 }
1652 },
1653 "false_next" : null,
1654 "true_next" : "wcmp_control.wcmp_table"
1655 }
1656 ]
1657 },
1658 {
1659 "name" : "egress",
1660 "id" : 1,
1661 "source_info" : {
1662 "filename" : "basic.p4",
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001663 "line" : 55,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001664 "column" : 8,
1665 "source_fragment" : "egress"
1666 },
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001667 "init_table" : "tbl_act_7",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001668 "tables" : [
1669 {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001670 "name" : "tbl_act_7",
1671 "id" : 11,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001672 "key" : [],
1673 "match_type" : "exact",
1674 "type" : "simple",
1675 "max_size" : 1024,
1676 "with_counters" : false,
1677 "support_timeout" : false,
1678 "direct_meters" : null,
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001679 "action_ids" : [17],
1680 "actions" : ["act_8"],
1681 "base_default_next" : "node_21",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001682 "next_tables" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001683 "act_8" : "node_21"
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001684 },
1685 "default_entry" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001686 "action_id" : 17,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001687 "action_const" : true,
1688 "action_data" : [],
1689 "action_entry_const" : true
1690 }
1691 },
1692 {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001693 "name" : "tbl_act_8",
1694 "id" : 12,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001695 "key" : [],
1696 "match_type" : "exact",
1697 "type" : "simple",
1698 "max_size" : 1024,
1699 "with_counters" : false,
1700 "support_timeout" : false,
1701 "direct_meters" : null,
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001702 "action_ids" : [16],
1703 "actions" : ["act_7"],
1704 "base_default_next" : "node_23",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001705 "next_tables" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001706 "act_7" : "node_23"
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001707 },
1708 "default_entry" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001709 "action_id" : 16,
1710 "action_const" : true,
1711 "action_data" : [],
1712 "action_entry_const" : true
1713 }
1714 },
1715 {
1716 "name" : "tbl_act_9",
1717 "id" : 13,
1718 "key" : [],
1719 "match_type" : "exact",
1720 "type" : "simple",
1721 "max_size" : 1024,
1722 "with_counters" : false,
1723 "support_timeout" : false,
1724 "direct_meters" : null,
1725 "action_ids" : [18],
1726 "actions" : ["act_9"],
1727 "base_default_next" : null,
1728 "next_tables" : {
1729 "act_9" : null
1730 },
1731 "default_entry" : {
1732 "action_id" : 18,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001733 "action_const" : true,
1734 "action_data" : [],
1735 "action_entry_const" : true
1736 }
1737 }
1738 ],
1739 "action_profiles" : [],
1740 "conditionals" : [
1741 {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001742 "name" : "node_21",
1743 "id" : 5,
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001744 "source_info" : {
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001745 "filename" : "include/port_meters.p4",
1746 "line" : 42,
1747 "column" : 12,
1748 "source_fragment" : "egress_color == MeterColor_t.RED"
1749 },
1750 "expression" : {
1751 "type" : "expression",
1752 "value" : {
1753 "op" : "==",
1754 "left" : {
1755 "type" : "field",
1756 "value" : ["scalars", "port_meters_egress_egress_color_0"]
1757 },
1758 "right" : {
1759 "type" : "hexstr",
1760 "value" : "0x00000002"
1761 }
1762 }
1763 },
1764 "true_next" : "tbl_act_8",
1765 "false_next" : "node_23"
1766 },
1767 {
1768 "name" : "node_23",
1769 "id" : 6,
1770 "source_info" : {
1771 "filename" : "include/packet_io.p4",
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001772 "line" : 37,
1773 "column" : 12,
1774 "source_fragment" : "standard_metadata.egress_port == CPU_PORT"
1775 },
1776 "expression" : {
1777 "type" : "expression",
1778 "value" : {
1779 "op" : "==",
1780 "left" : {
1781 "type" : "field",
1782 "value" : ["standard_metadata", "egress_port"]
1783 },
1784 "right" : {
1785 "type" : "hexstr",
1786 "value" : "0x00ff"
1787 }
1788 }
1789 },
1790 "false_next" : null,
Frank Wangd7e3b4b2017-09-24 13:37:54 +09001791 "true_next" : "tbl_act_9"
Carmelo Casconeca94bcf2017-10-27 14:16:59 -07001792 }
1793 ]
1794 }
1795 ],
1796 "checksums" : [],
1797 "force_arith" : [],
1798 "extern_instances" : [],
1799 "field_aliases" : [
1800 [
1801 "queueing_metadata.enq_timestamp",
1802 ["standard_metadata", "enq_timestamp"]
1803 ],
1804 [
1805 "queueing_metadata.enq_qdepth",
1806 ["standard_metadata", "enq_qdepth"]
1807 ],
1808 [
1809 "queueing_metadata.deq_timedelta",
1810 ["standard_metadata", "deq_timedelta"]
1811 ],
1812 [
1813 "queueing_metadata.deq_qdepth",
1814 ["standard_metadata", "deq_qdepth"]
1815 ],
1816 [
1817 "intrinsic_metadata.ingress_global_timestamp",
1818 ["standard_metadata", "ingress_global_timestamp"]
1819 ],
1820 [
1821 "intrinsic_metadata.lf_field_list",
1822 ["standard_metadata", "lf_field_list"]
1823 ],
1824 [
1825 "intrinsic_metadata.mcast_grp",
1826 ["standard_metadata", "mcast_grp"]
1827 ],
1828 [
1829 "intrinsic_metadata.resubmit_flag",
1830 ["standard_metadata", "resubmit_flag"]
1831 ],
1832 [
1833 "intrinsic_metadata.egress_rid",
1834 ["standard_metadata", "egress_rid"]
1835 ]
1836 ]
1837}