TY - GEN
T1 - Testing compilers for programmable switches through switch hardware simulation
AU - Wong, Michael D.
AU - Varma, Aatish Kishan
AU - Sivaraman, Anirudh
N1 - Publisher Copyright:
© 2020 ACM.
PY - 2020/11/23
Y1 - 2020/11/23
N2 - Programmable switches have emerged as powerful and flexible alternatives to fixed-function forwarding devices. But because of the unique hardware constraints of network switches, the design and implementation of compilers targeting these devices is tedious and error-prone. Despite the important role that compilers play in software development, there is a dearth of tools for testing compilers for programmable network devices. We present Druzhba, a programmable switch simulator used for testing compilers targeting programmable packet-processing substrates. We show that we can model the low-level behavior of a switch's programmable hardware. We further show how compiler developers can target Druzhba as a compiler backend. Generated machine code programs are fed into Druzhba and tested using a fuzzing-based approach that allows compiler developers to test the correctness of their compilers. Using a program-synthesis-based compiler as a case study, we demonstrate how Druzhba has been successful in testing compiler-generated machine code for our simulated switch pipeline instruction set.
AB - Programmable switches have emerged as powerful and flexible alternatives to fixed-function forwarding devices. But because of the unique hardware constraints of network switches, the design and implementation of compilers targeting these devices is tedious and error-prone. Despite the important role that compilers play in software development, there is a dearth of tools for testing compilers for programmable network devices. We present Druzhba, a programmable switch simulator used for testing compilers targeting programmable packet-processing substrates. We show that we can model the low-level behavior of a switch's programmable hardware. We further show how compiler developers can target Druzhba as a compiler backend. Generated machine code programs are fed into Druzhba and tested using a fuzzing-based approach that allows compiler developers to test the correctness of their compilers. Using a program-synthesis-based compiler as a case study, we demonstrate how Druzhba has been successful in testing compiler-generated machine code for our simulated switch pipeline instruction set.
KW - compilers
KW - programmable data plane
KW - programmable switches
KW - simulation
KW - software testing
UR - http://www.scopus.com/inward/record.url?scp=85097612852&partnerID=8YFLogxK
UR - http://www.scopus.com/inward/citedby.url?scp=85097612852&partnerID=8YFLogxK
U2 - 10.1145/3386367.3431309
DO - 10.1145/3386367.3431309
M3 - Conference contribution
AN - SCOPUS:85097612852
T3 - CoNEXT 2020 - Proceedings of the 16th International Conference on Emerging Networking EXperiments and Technologies
SP - 211
EP - 217
BT - CoNEXT 2020 - Proceedings of the 16th International Conference on Emerging Networking EXperiments and Technologies
PB - Association for Computing Machinery, Inc
T2 - 16th ACM Conference on Emerging Networking Experiment and Technologies, CoNEXT 2020
Y2 - 1 December 2020 through 4 December 2020
ER -