skip to main content
research-article

A fast compiler for NetKAT

Published:29 August 2015Publication History
Skip Abstract Section

Abstract

High-level programming languages play a key role in a growing number of networking platforms, streamlining application development and enabling precise formal reasoning about network behavior. Unfortunately, current compilers only handle "local" programs that specify behavior in terms of hop-by-hop forwarding behavior, or modest extensions such as simple paths. To encode richer "global" behaviors, programmers must add extra state -- something that is tricky to get right and makes programs harder to write and maintain. Making matters worse, existing compilers can take tens of minutes to generate the forwarding state for the network, even on relatively small inputs. This forces programmers to waste time working around performance issues or even revert to using hardware-level APIs. This paper presents a new compiler for the NetKAT language that handles rich features including regular paths and virtual networks, and yet is several orders of magnitude faster than previous compilers. The compiler uses symbolic automata to calculate the extra state needed to implement "global" programs, and an intermediate representation based on binary decision diagrams to dramatically improve performance. We describe the design and implementation of three essential compiler stages: from virtual programs (which specify behavior in terms of virtual topologies) to global programs (which specify network-wide behavior in terms of physical topologies), from global programs to local programs (which specify behavior in terms of single-switch behavior), and from local programs to hardware-level forwarding tables. We present results from experiments on real-world benchmarks that quantify performance in terms of compilation time and forwarding table size.

References

  1. S. B. Akers. Binary decision diagrams. IEEE Trans. Comput., 27(6):509–516, June 1978. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. Mohammad Al-Fares, Alex Loukissas, and Amin Vahdat. A scalable, commodity, data center network architecture. In SIGCOMM, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. Ali Al-Shabibi, Marc De Leenheer, Matteo Gerola, Ayaka Koshibe, Guru Parulkar, Elio Salvadori, and Bill Snow. OpenVirteX: Make your virtual SDNs programmable. In HotSDN, 2014. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. Carolyn Jane Anderson, Nate Foster, Arjun Guha, Jean-Baptiste Jeannin, Dexter Kozen, Cole Schlesinger, and David Walker. NetKAT: Semantic foundations for networks. In POPL, 2014. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. Valentin Antimirov. Partial derivatives of regular expressions and finite automaton constructions. Theoretical Computer Science, 155(2):291–319, 1996. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. Randal E. Bryant. Graph-based algorithms for boolean function manipulation. IEEE Trans. Comput., 35(8):677–691, August 1986. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. Martin Casado, Teemu Koponen, Rajiv Ramanathan, and Scott Shenker. Virtualizing the network forwarding plane. In PRESTO, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. Andrew D. Ferguson, Arjun Guha, Chen Liang, Rodrigo Fonseca, and Shriram Krishnamurthi. Hierarchical policies for software defined networks. In HotSDN, 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. Andrew D. Ferguson, Arjun Guha, Chen Liang, Rodrigo Fonseca, and Shriram Krishnamurthi. Participatory networking: An api for application control of sdns. In SIGCOMM, 2013. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. Nate Foster, Rob Harrison, Michael J. Freedman, Christopher Monsanto, Jennifer Rexford, Alec Story, and David Walker. Frenetic: A Network Programming Language. In ICFP, 2011. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. Nate Foster, Dexter Kozen, Matthew Milano, Alexandra Silva, and Laure Thompson. A coalgebraic decision procedure for NetKAT. In POPL, 2015. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. Arjun Guha, Mark Reitblatt, and Nate Foster. Machine-verified network controllers. In PLDI, 2013. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. Arpit Gupta, Laurent Vanbever, Muhammad Shahbaz, Sean Donovan, Brandon Schlinker, Nick Feamster, Jennifer Rexford, Scott Shenker, Russ Clark, and Ethan Katz-Bassett. SDX: A software defined internet exchange. In SIGCOMM, 2014. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. Stephen Gutz, Alec Story, Cole Schlesinger, and Nate Foster. Splendid isolation: A slice abstraction for software-defined networks. In HotSDN, 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. Xin Jin, Jennifer Gossels, Jennifer Rexford, and David Walker. Co-Visor: A compositional hypervisor for software-defined networks. In NSDI, 2015. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. Lavanya Jose, Lisa Yan, George Varghese, and Nick McKeown. Compiling packet programs to reconfigurable switches. In NSDI, 2015. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. Ahmed Khurshid, Xuan Zou, Wenxuan Zhou, Matthew Caesar, and P. Brighten Godfrey. Veriflow: Verifying network-wide invariants in real time. In NSDI, 2013. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. Simon Knight, Hung X. Nguyen, Nickolas Falkner, Rhys Bowden, and Matthew Roughan. The internet topology zoo. IEEE Journal on Selected Areas in Communications, 2011.Google ScholarGoogle ScholarCross RefCross Ref
  19. Teemu Koponen, Keith Amidon, Peter Balland, Mart´ın Casado, Anupam Chanda, Bryan Fulton, Jesse Gross Igor Ganichev, Natasha Gude, Paul Ingram, Ethan Jackson, Andrew Lambeth, Romain Lenglet, Shih-Hao Li, Amar Padmanabhan, Justin Pettit, Ben Pfaff, Rajiv Ramanathan, Scott Shenker, Alan Shieh, Jeremy Stribling, Pankaj Thakkar, Dan Wendlandt, Alexander Yip, and Ronghua Zhang. Network virtualization in multi-tenant datacenters. In NSDI, 2014. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. Dexter Kozen. Kleene algebra with tests. Transactions on Programming Languages and Systems, 19(3):427–443, May 1997. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. Alex X. Liu, Fei Chen, JeeHyun Hwang, and Tao Xie. XEngine: A fast and scalable XACML policy evaluation engine. In International Conference on Measurement and Modeling of Computer Systems (SIGMETRICS), 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. Alex X. Liu, Chad R. Meiners, and Eric Torng. TCAM Razor: A systematic approach towards minimizing packet classifiers in TCAMs. TON, 18(2):490–500, April 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. Nick McKeown, Tom Anderson, Hari Balakrishnan, Guru Parulkar, Larry Peterson, Jennifer Rexford, Scott Shenker, and Jonathan Turner. OpenFlow: Enabling innovation in campus networks. SIGCOMM CCR, 38(2):69–74, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. Christopher Monsanto, Nate Foster, Rob Harrison, and David Walker. A compiler and run-time system for network programming languages. In POPL, 2012. Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. Christopher Monsanto, Joshua Reich, Nate Foster, Jennifer Rexford, and David Walker. Composing software-defined networks. In NSDI, 2013. Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. Tim Nelson, Andrew D. Ferguson, Michael J. G. Scheer, and Shriram Krishnamurthi. Tierless programming and reasoning for softwaredefined networks. In NSDI, 2014. Google ScholarGoogle ScholarDigital LibraryDigital Library
  27. Damien Pous. Symbolic algorithms for language equivalence and Kleene Algebra with Tests. In POPL, 2015. Google ScholarGoogle ScholarDigital LibraryDigital Library
  28. ONOS Project. Intent framework, November 2014. Available at http://onos.wpengine.com/wp-content/uploads/2014/11/ ONOS-Intent-Framework.pdf.Google ScholarGoogle Scholar
  29. Open Daylight Project. Group policy, January 2014. Available at https://wiki.opendaylight.org/view/Group_Policy:Main.Google ScholarGoogle Scholar
  30. Cole Schlesinger, Michael Greenberg, and David Walker. Concurrent netcore: From policies to pipelines. In ICFP, 2014. Google ScholarGoogle ScholarDigital LibraryDigital Library
  31. O. Tange. GNU parallel - the command-line power tool. ;login: The USENIX Magazine, 36(1):42–47, Feb 2011.Google ScholarGoogle Scholar
  32. David E. Taylor and Jonathan S. Turner. ClassBench: A packet classification benchmark. TON, 15:499–511, June 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  33. Andreas Voellmy, Junchang Wang, Y. Richard Yang, Bryan Ford, and Paul Hudak. Maple: Simplifying SDN programming using algorithmic policies. In SIGCOMM, 2013. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. A fast compiler for NetKAT

    Recommendations

    Comments

    Login options

    Check if you have access through your login credentials or your institution to get full access on this article.

    Sign in

    Full Access

    PDF Format

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader
    About Cookies On This Site

    We use cookies to ensure that we give you the best experience on our website.

    Learn more

    Got it!