{"status":"ok","message-type":"work","message-version":"1.0.0","message":{"indexed":{"date-parts":[[2026,8,18]],"date-time":"2026-08-18T01:46:26Z","timestamp":1787017586714,"version":"build-2736575974"},"reference-count":37,"publisher":"Association for Computing Machinery (ACM)","issue":"POPL","license":[{"start":{"date-parts":[[2022,1,12]],"date-time":"2022-01-12T00:00:00Z","timestamp":1641945600000},"content-version":"vor","delay-in-days":0,"URL":"https:\/\/creativecommons.org\/licenses\/by\/4.0\/"}],"funder":[{"DOI":"10.13039\/100000001","name":"National Science Foundation","doi-asserted-by":"publisher","award":["FMitF-1837030,CNS-1703493"],"award-info":[{"award-number":["FMitF-1837030,CNS-1703493"]}],"id":[{"id":"10.13039\/100000001","id-type":"DOI","asserted-by":"publisher"}]}],"content-domain":{"domain":["dl.acm.org"],"crossmark-restriction":true},"short-container-title":["Proc. ACM Program. Lang."],"published-print":{"date-parts":[[2022,1,16]]},"abstract":"<jats:p>\n                    The P4 language and programmable switch hardware, like the Intel Tofino, have made it possible for network engineers to write new programs that customize operation of computer networks, thereby improving performance, fault-tolerance, energy use, and security. Unfortunately,\n                    <jats:italic>possible<\/jats:italic>\n                    does not mean\n                    <jats:italic>easy<\/jats:italic>\n                    \u2014there are many implicit constraints that programmers must obey if they wish their programs to compile to specialized networking hardware. In particular, all computations on the same switch must access data structures in a consistent order, or it will not be possible to lay that data out along the switch\u2019s packet-processing pipeline. In this paper, we define Lucid 2.0, a new language and type system that guarantees programs access data in a consistent order and hence are\n                    <jats:italic>pipeline-safe<\/jats:italic>\n                    . Lucid 2.0 builds on top of the original Lucid language, which is also pipeline-safe, but lacks the features needed for modular construction of data structure libraries. Hence, Lucid 2.0 adds (1) polymorphism and ordering constraints for code reuse; (2) abstract, hierarchical pipeline locations and data types to support information hiding; (3) compile-time constructors, vectors and loops to allow for construction of flexible data structures; and (4) type inference to lessen the burden of program annotations. We develop the meta-theory of Lucid 2.0, prove soundness, and show how to encode constraint checking as an SMT problem. We demonstrate the utility of Lucid 2.0 by developing a suite of useful networking libraries and applications that exploit our new language features, including Bloom filters, sketches, cuckoo hash tables, distributed firewalls, DNS reflection defenses, network address translators (NATs) and a probabilistic traffic monitoring service.\n                  <\/jats:p>","DOI":"10.1145\/3498699","type":"journal-article","created":{"date-parts":[[2022,1,12]],"date-time":"2022-01-12T12:03:12Z","timestamp":1641988992000},"page":"1-28","update-policy":"https:\/\/doi.org\/10.1145\/crossmark-policy","source":"Crossref","is-referenced-by-count":6,"title":["Safe, modular packet pipeline programming"],"prefix":"10.1145","volume":"6","author":[{"ORCID":"https:\/\/orcid.org\/0000-0003-1127-8932","authenticated-orcid":false,"given":"Devon","family":"Loehr","sequence":"first","affiliation":[{"name":"Princeton University, USA"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"given":"David","family":"Walker","sequence":"additional","affiliation":[{"name":"Princeton University, USA"}],"role":[{"vocabulary":"crossref","role":"author"}]}],"member":"320","published-online":{"date-parts":[[2022,1,12]]},"reference":[{"key":"e_1_2_2_1_1","doi-asserted-by":"publisher","DOI":"10.1145\/2740070.2626316"},{"key":"e_1_2_2_2_1","doi-asserted-by":"publisher","DOI":"10.1145\/2578855.2535862"},{"key":"e_1_2_2_3_1","unstructured":"Mario Baldi. 2020. Pensando Announces P4-programmable Platform and Joins P4 Community. https:\/\/opennetworking.org\/news-and-events\/blog\/pensando-announces-p4-programmable-platform-and-joins-p4-community\/.  Mario Baldi. 2020. Pensando Announces P4-programmable Platform and Joins P4 Community. https:\/\/opennetworking.org\/news-and-events\/blog\/pensando-announces-p4-programmable-platform-and-joins-p4-community\/."},{"key":"e_1_2_2_4_1","doi-asserted-by":"publisher","DOI":"10.1145\/2656877.2656890"},{"key":"e_1_2_2_5_1","doi-asserted-by":"publisher","DOI":"10.1145\/2486001.2486011"},{"key":"e_1_2_2_6_1","doi-asserted-by":"publisher","DOI":"10.1007\/11609773_28"},{"key":"e_1_2_2_7_1","volume-title":"Tools and Algorithms for the Construction and Analysis of Systems","author":"de Moura Leonardo","unstructured":"Leonardo de Moura and Nikolaj Bj\u00f8rner . 2008. Z3: An Efficient SMT Solver . In Tools and Algorithms for the Construction and Analysis of Systems , C. R. Ramakrishnan and Jakob Rehof (Eds.). Springer Berlin Heidelberg , Berlin, Heidelberg . 337\u2013340. isbn:978-3-540-78800-3 https:\/\/doi.org\/10.5555\/1792734.1792766 Leonardo de Moura and Nikolaj Bj\u00f8rner. 2008. Z3: An Efficient SMT Solver. In Tools and Algorithms for the Construction and Analysis of Systems, C. R. Ramakrishnan and Jakob Rehof (Eds.). Springer Berlin Heidelberg, Berlin, Heidelberg. 337\u2013340. isbn:978-3-540-78800-3 https:\/\/doi.org\/10.5555\/1792734.1792766"},{"key":"e_1_2_2_8_1","doi-asserted-by":"publisher","DOI":"10.1016\/S1571-0661(04)80088-4"},{"key":"e_1_2_2_9_1","doi-asserted-by":"publisher","DOI":"10.5555\/647923.741212"},{"key":"e_1_2_2_10_1","doi-asserted-by":"publisher","DOI":"10.1145\/2034574.2034812"},{"key":"e_1_2_2_11_1","doi-asserted-by":"publisher","DOI":"10.1145\/3387514.3405879"},{"key":"e_1_2_2_12_1","doi-asserted-by":"publisher","DOI":"10.1145\/3387514.3405852"},{"key":"e_1_2_2_13_1","doi-asserted-by":"publisher","DOI":"10.1145\/319838.319848"},{"key":"e_1_2_2_14_1","doi-asserted-by":"publisher","DOI":"10.1016\/0304-3975(87)90045-4"},{"key":"e_1_2_2_15_1","doi-asserted-by":"publisher","DOI":"10.1145\/3422604.3425933"},{"key":"e_1_2_2_16_1","volume-title":"USENIX Symposium on Networked Systems Design and Implementation. 701\u2013721","author":"Hsu Kuo-Feng","year":"2020","unstructured":"Kuo-Feng Hsu , Ryan Beckett , Ang Chen , Jennifer Rexford , and David Walker . 2020 . Contra: A programmable system for performance-aware routing . In USENIX Symposium on Networked Systems Design and Implementation. 701\u2013721 . Kuo-Feng Hsu, Ryan Beckett, Ang Chen, Jennifer Rexford, and David Walker. 2020. Contra: A programmable system for performance-aware routing. In USENIX Symposium on Networked Systems Design and Implementation. 701\u2013721."},{"key":"e_1_2_2_17_1","doi-asserted-by":"publisher","DOI":"10.1145\/1057387.1057390"},{"key":"e_1_2_2_18_1","unstructured":"Intel. 2020. Intel Tofino 2. https:\/\/www.intel.com\/content\/www\/us\/en\/products\/network-io\/programmable-ethernet-switch\/tofino-2-series.html.  Intel. 2020. Intel Tofino 2. https:\/\/www.intel.com\/content\/www\/us\/en\/products\/network-io\/programmable-ethernet-switch\/tofino-2-series.html."},{"key":"e_1_2_2_19_1","doi-asserted-by":"publisher","DOI":"10.1145\/2740070.2626292"},{"key":"e_1_2_2_20_1","unstructured":"Mohan Kalkunte. 2019. Broadcom\u2019s new Trident 4 and Jericho 2 switch devices offer programmability at scale. https:\/\/www.broadcom.com\/blog\/trident4-and-jericho2-offer-programmability-at-scale.  Mohan Kalkunte. 2019. Broadcom\u2019s new Trident 4 and Jericho 2 switch devices offer programmability at scale. https:\/\/www.broadcom.com\/blog\/trident4-and-jericho2-offer-programmability-at-scale."},{"key":"e_1_2_2_21_1","doi-asserted-by":"publisher","DOI":"10.1145\/2890955.2890968"},{"key":"e_1_2_2_22_1","volume-title":"Jaqen: A High-Performance Switch-Native Approach for Detecting and Mitigating Volumetric DDoS Attacks with Programmable Switches. In USENIX Security Symposium.","author":"Liu Zaoxing","year":"2021","unstructured":"Zaoxing Liu , Hun Namkung , Georgios Nikolaidis , Jeongkeun Lee , Changhoon Kim , Xin Jin , Vladimir Braverman , Minlan Yu , and Vyas Sekar . 2021 . Jaqen: A High-Performance Switch-Native Approach for Detecting and Mitigating Volumetric DDoS Attacks with Programmable Switches. In USENIX Security Symposium. Zaoxing Liu, Hun Namkung, Georgios Nikolaidis, Jeongkeun Lee, Changhoon Kim, Xin Jin, Vladimir Braverman, Minlan Yu, and Vyas Sekar. 2021. Jaqen: A High-Performance Switch-Native Approach for Detecting and Mitigating Volumetric DDoS Attacks with Programmable Switches. In USENIX Security Symposium."},{"key":"e_1_2_2_23_1","doi-asserted-by":"publisher","DOI":"10.1016\/0022-0000(78)90014-4"},{"key":"e_1_2_2_24_1","unstructured":"Tim Nelson Andrew D. Ferguson Michael J.G. Scheer and Shriram Krishnamurthi. 2014. Tierless Programming and Reasoning for Software-Defined Networks. In USENIX Networked Systems Design and Implementation. 519\u2013531. https:\/\/doi.org\/10.5555\/2616448.2616496  Tim Nelson Andrew D. Ferguson Michael J.G. Scheer and Shriram Krishnamurthi. 2014. Tierless Programming and Reasoning for Software-Defined Networks. In USENIX Networked Systems Design and Implementation. 519\u2013531. https:\/\/doi.org\/10.5555\/2616448.2616496"},{"key":"e_1_2_2_25_1","doi-asserted-by":"publisher","DOI":"10.1016\/S1571-0661(04)80088-4"},{"key":"e_1_2_2_26_1","doi-asserted-by":"publisher","DOI":"10.1016\/S1571-0661(04)80088-4"},{"key":"e_1_2_2_27_1","doi-asserted-by":"publisher","DOI":"10.1016\/S1571-0661(04)80088-4"},{"key":"e_1_2_2_28_1","unstructured":"Joshua Reich Christopher Monsanto Nate Foster Jennifer Rexford and David Walker. 2013. Modular sdn programming with pyretic. Technical Reprot of USENIX 30.  Joshua Reich Christopher Monsanto Nate Foster Jennifer Rexford and David Walker. 2013. Modular sdn programming with pyretic. Technical Reprot of USENIX 30."},{"key":"e_1_2_2_29_1","doi-asserted-by":"publisher","DOI":"10.1145\/2692915.2628157"},{"key":"e_1_2_2_30_1","doi-asserted-by":"publisher","DOI":"10.1145\/3373360.3380839"},{"key":"e_1_2_2_31_1","doi-asserted-by":"publisher","DOI":"10.1145\/2934872.2934900"},{"key":"e_1_2_2_32_1","doi-asserted-by":"publisher","DOI":"10.1145\/3452296.3472903"},{"key":"e_1_2_2_33_1","volume-title":"USENIX Annual Technical Conference. 823\u2013835","author":"Sonchack John","year":"2018","unstructured":"John Sonchack , Oliver Michel , Adam J Aviv , Eric Keller , and Jonathan M Smith . 2018 . Scaling hardware accelerated network monitoring to concurrent and dynamic queries with *Flow . In USENIX Annual Technical Conference. 823\u2013835 . https:\/\/doi.org\/10.5555\/3277355.3277435 John Sonchack, Oliver Michel, Adam J Aviv, Eric Keller, and Jonathan M Smith. 2018. Scaling hardware accelerated network monitoring to concurrent and dynamic queries with *Flow. In USENIX Annual Technical Conference. 823\u2013835. https:\/\/doi.org\/10.5555\/3277355.3277435"},{"key":"e_1_2_2_34_1","doi-asserted-by":"publisher","DOI":"10.1145\/291891.291894"},{"key":"e_1_2_2_35_1","doi-asserted-by":"publisher","DOI":"10.1006\/inco.1996.2613"},{"key":"e_1_2_2_36_1","doi-asserted-by":"publisher","DOI":"10.1145\/2534169.2486030"},{"key":"e_1_2_2_37_1","volume-title":"Advanced Topics in Types and Programming Languages","author":"Walker David","unstructured":"David Walker . 2005. Advanced Topics in Types and Programming Languages . The MIT Press , 3\u201344. David Walker. 2005. Advanced Topics in Types and Programming Languages. The MIT Press, 3\u201344."}],"container-title":["Proceedings of the ACM on Programming Languages"],"original-title":[],"language":"en","link":[{"URL":"https:\/\/dl.acm.org\/doi\/10.1145\/3498699","content-type":"unspecified","content-version":"vor","intended-application":"text-mining"},{"URL":"https:\/\/dl.acm.org\/doi\/pdf\/10.1145\/3498699","content-type":"application\/pdf","content-version":"vor","intended-application":"syndication"},{"URL":"https:\/\/dl.acm.org\/doi\/pdf\/10.1145\/3498699","content-type":"unspecified","content-version":"vor","intended-application":"similarity-checking"}],"deposited":{"date-parts":[[2025,6,17]],"date-time":"2025-06-17T15:30:28Z","timestamp":1750174228000},"score":1,"resource":{"primary":{"URL":"https:\/\/dl.acm.org\/doi\/10.1145\/3498699"}},"subtitle":[],"short-title":[],"issued":{"date-parts":[[2022,1,12]]},"references-count":37,"journal-issue":{"issue":"POPL","published-print":{"date-parts":[[2022,1,16]]}},"alternative-id":["10.1145\/3498699"],"URL":"https:\/\/doi.org\/10.1145\/3498699","relation":{},"ISSN":["2475-1421"],"issn-type":[{"value":"2475-1421","type":"electronic"}],"subject":[],"published":{"date-parts":[[2022,1,12]]},"assertion":[{"value":"2022-01-12","order":2,"name":"published","label":"Published","group":{"name":"publication_history","label":"Publication History"}}]}}