Circuit Transformations for Quantum Architectures

Authors Andrew M. Childs , Eddie Schoute , Cem M. Unsal

Thumbnail PDF


  • Filesize: 0.7 MB
  • 24 pages

Document Identifiers

Author Details

Andrew M. Childs
  • Joint Center for Quantum Information and Computer Science, University of Maryland, USA
  • Institute for Advanced Computer Studies, University of Maryland, USA
  • Department for Computer Science, University of Maryland, USA
Eddie Schoute
  • Joint Center for Quantum Information and Computer Science, University of Maryland, USA
  • Institute for Advanced Computer Studies, University of Maryland, USA
  • Department for Computer Science, University of Maryland, USA
Cem M. Unsal
  • Department of Mathematics, University of Maryland, USA


The authors would like to thank Aniruddha Bapat for insights on the hierarchical product of graphs and suggestions for tightening the routing lower bound for these graphs. We would also like to thank Drew Risinger for helpful formative discussions.

Cite AsGet BibTex

Andrew M. Childs, Eddie Schoute, and Cem M. Unsal. Circuit Transformations for Quantum Architectures. In 14th Conference on the Theory of Quantum Computation, Communication and Cryptography (TQC 2019). Leibniz International Proceedings in Informatics (LIPIcs), Volume 135, pp. 3:1-3:24, Schloss Dagstuhl – Leibniz-Zentrum für Informatik (2019)


Quantum computer architectures impose restrictions on qubit interactions. We propose efficient circuit transformations that modify a given quantum circuit to fit an architecture, allowing for any initial and final mapping of circuit qubits to architecture qubits. To achieve this, we first consider the qubit movement subproblem and use the ROUTING VIA MATCHINGS framework to prove tighter bounds on parallel routing. In practice, we only need to perform partial permutations, so we generalize ROUTING VIA MATCHINGS to that setting. We give new routing procedures for common architecture graphs and for the generalized hierarchical product of graphs, which produces subgraphs of the Cartesian product. Secondly, for serial routing, we consider the TOKEN SWAPPING framework and extend a 4-approximation algorithm for general graphs to support partial permutations. We apply these routing procedures to give several circuit transformations, using various heuristic qubit placement subroutines. We implement these transformations in software and compare their performance for large quantum circuits on grid and modular architectures, identifying strategies that work well in practice.

Subject Classification

ACM Subject Classification
  • Computer systems organization → Quantum computing
  • Hardware → Quantum computation
  • Mathematics of computing → Graph theory
  • Applied computing → Physics
  • General and reference → General conference proceedings
  • Networks
  • quantum circuit
  • quantum architectures
  • circuit mapping


  • Access Statistics
  • Total Accesses (updated on a weekly basis)
    PDF Downloads


  1. M. Ajtai, J. Komlós, and E. Szemerédi. An O(n log n) sorting network. In Proceedings of the fifteenth annual ACM symposium on Theory of computing - STOC quotesingle83. ACM Press, 1983. URL:
  2. Noga Alon, F. R. K. Chung, and R. L. Graham. Routing Permutations on Graphs via Matchings. SIAM Journal on Discrete Mathematics, 7(3):513-530, May 1994. URL:
  3. Indranil Banerjee and Dana Richards. New Results on Routing via Matchings on Graphs. In Fundamentals of Computation Theory, pages 69-81. Springer Berlin Heidelberg, 2017. URL:
  4. Indranil Banerjee, Dana Richards, and Igor Shinkar. Sorting Networks on Restricted Topologies. In SOFSEM 2019: Theory and Practice of Computer Science, pages 54-66. Springer International Publishing, 2019. URL:
  5. Aniruddha Bapat, Zachary Eldredge, James R. Garrison, Abhinav Deshpande, Frederic T. Chong, and Alexey V. Gorshkov. Unitary entanglement construction in hierarchical networks. Physical Review A, 98(6), 2018. URL:
  6. L. Barrière, C. Dalfó, M. A. Fiol, and M. Mitjana. The generalized hierarchical product of graphs. Discrete Mathematics, 309(12):3871-3881, June 2009. URL:
  7. R. Beals, S. Brierley, O. Gray, A. W. Harrow, S. Kutin, N. Linden, D. Shepherd, and M. Stather. Efficient distributed quantum computing. Proceedings of the Royal Society A: Mathematical, Physical and Engineering Sciences, 469(2153), 2013. URL:
  8. Luciano Bello, Jim Challenger, Andrew Cross, Ismael Faro, Jay Gambetta, Juan Gomez, Ali Javadi-Abhari, Paco Martin, Diego Moreda, Jesus Perez, Erick Winston, and Chris Wood. Qiskit, 2017. URL:
  9. Sergio Boixo, Sergei V. Isakov, Vadim N. Smelyanskiy, Ryan Babbush, Nan Ding, Zhang Jiang, Michael J. Bremner, John M. Martinis, and Hartmut Neven. Characterizing quantum supremacy in near-term devices. Nature Physics, 14(6):595-600, 2018. URL:
  10. Édouard Bonnet, Tillmann Miltzow, and Paweł Rzążewski. Complexity of Token Swapping and its Variants. Algorithmica, 80(9):2656-2682, October 2017. URL:
  11. Adam Bouland, Bill Fefferman, Chinmay Nirkhe, and Umesh Vazirani. On the complexity and verification of quantum random circuit sampling. Nature Physics, October 2018. URL:
  12. Teresa Brecht, Wolfgang Pfaff, Chen Wang, Yiwen Chu, Luigi Frunzio, Michel H. Devoret, and Robert J. Schoelkopf. Multilayer microwave integrated quantum circuits for scalable quantum computing. npj Quantum Information, 2(16002), 2016. URL:
  13. Stephen Brierley. Efficient Implementation of Quantum Circuits with Limited Qubit Interactions. Quantum Info. Comput., 17(13-14):1096-1104, November 2017. Google Scholar
  14. Andrew M. Childs, Dmitri Maslov, Yunseong Nam, Neil J. Ross, and Yuan Su. Toward the first quantum simulation with quantum speedup. Proceedings of the National Academy of Sciences, 115(38):9456-9461, 2018. URL:
  15. Byung-Soo Choi and Rodney van Meter. On the Effect of Quantum Interaction Distance on Quantum Addition Circuits. ACM Journal on Emerging Technologies in Computing Systems, 7(3):1-17, August 2011. URL:
  16. Byung-Soo Choi and Rodney van Meter. A Θ(√N)-depth Quantum Adder on the 2D NTC Quantum Computer Architecture. J. Emerg. Technol. Comput. Syst., 8(3):24:1-24:22, August 2012. URL:
  17. Robert W. Floyd. Algorithm 97: Shortest path. Communications of the ACM, 5(6):345, June 1962. URL:
  18. Austin G. Fowler, Simon J. Devitt, and Lloyd C. L. Hollenberg. Implementation of Shor’s Algorithm on a Linear Nearest Neighbour Qubit Array. Quant. Info. Comput. 4, 237-251 (2004), 2004. Google Scholar
  19. Google Quantum AI Lab. A Preview of Bristlecone, Google’s New Quantum Processor. URL:
  20. Jeff Heckey, Shruti Patil, Ali JavadiAbhari, Adam Holmes, Daniel Kudrow, Kenneth R. Brown, Diana Franklin, Frederic T. Chong, and Margaret Martonosi. Compiler Management of Communication and Parallelism for Quantum Computation. In Proceedings of the Twentieth International Conference on Architectural Support for Programming Languages and Operating Systems - ASPLOS quotesingle15. ACM Press, 2015. URL:
  21. Steven Herbert. On the depth overhead incurred when running quantum algorithms on near-term quantum computers with limited qubit connectivity. Google Scholar
  22. Yuichi Hirata, Masaki Nakanishi, Shigeru Yamashita, and Yasuhiko Nakashima. An Efficient Method to Convert Arbitrary Quantum Circuits to Ones on a Linear Nearest Neighbor Architecture. In 2009 Third International Conference on Quantum, Nano and Micro Technologies. IEEE, February 2009. URL:
  23. John E. Hopcroft and Richard M. Karp. An n^5/2 Algorithm for Maximum Matchings in Bipartite Graphs. SIAM Journal on Computing, 2(4):225-231, December 1973. URL:
  24. IBM Q Team. IBM Q Experience Devices, 2018. URL:
  25. Donald E. Knuth. Networks for Sorting, volume 3 of The Art of Computer Programming, pages 219-247. Addison-Wesley Professional, second edition, 1998. Google Scholar
  26. Manfred Kunde. Optimal sorting on multi-dimensionally mesh-connected computers. In STACS 87, pages 408-419. Springer-Verlag, 1987. URL:
  27. Samuel A. Kutin, David Petrie Moulton, and Lawren M. Smithline. Computation at a distance. Chicago Journal of Theoretical Computer Science, 13(1):1-17, 2007. URL:
  28. L. Lao, B. van Wee, I. Ashraf, J. van Someren, N. Khammassi, K. Bertels, and C. G. Almudever. Mapping of lattice surgery-based quantum circuits on surface code architectures. Quantum Science and Technology, 4(1):015005, September 2018. URL:
  29. Gushu Li, Yufei Ding, and Yuan Xie. Tackling the Qubit Mapping Problem for NISQ-Era Quantum Devices. Google Scholar
  30. Chia-Chun Lin, Susmita Sur-Kolay, and Niraj K. Jha. PAQCS: Physical design-aware fault-tolerant quantum circuit synthesis. IEEE Transactions on Very Large Scale Integration (VLSI) Systems, 23(7):1221-1234, July 2015. URL:
  31. Norbert M. Linke, Dmitri Maslov, Martin Roetteler, Shantanu Debnath, Caroline Figgatt, Kevin A. Landsman, Kenneth Wright, and Christopher Monroe. Experimental comparison of two quantum computing architectures. Proceedings of the National Academy of Sciences, 114(13):3305-3310, March 2017. URL:
  32. Guang Hao Low and Isaac L. Chuang. Optimal Hamiltonian Simulation by Quantum Signal Processing. Physical Review Letters, 118(1), January 2017. URL:
  33. Aaron Lye, Robert Wille, and Rolf Drechsler. Determining the minimal number of swap gates for multi-dimensional nearest neighbor quantum circuits. In The 20th Asia and South Pacific Design Automation Conference. IEEE, January 2015. URL:
  34. D. Maslov, S. M. Falconer, and M. Mosca. Quantum Circuit Placement. IEEE Transactions on Computer-Aided Design of Integrated Circuits and Systems, 27(4):752-763, 2008. URL:
  35. Dmitri Maslov. Linear depth stabilizer and quantum Fourier transformation circuits with no auxiliary qubits in finite-neighbor quantum architectures. Physical Review A, 76(5), November 2007. URL:
  36. Tzvetan S. Metodi, Darshan D. Thaker, Andrew W. Cross, Frederic T. Chong, and Isaac L. Chuang. Scheduling physical operations in a quantum information processor. In Eric J. Donkor, Andrew R. Pirich, and Howard E. Brandt, editors, Quantum Information and Computation IV, page 6244. SPIE, 2006. URL:
  37. Silvio Micali and Vijay V. Vazirani. An O(√\lvert V \rvert\lvert E \rvert) algoithm for finding maximum matching in general graphs. In 21st Annual Symposium on Foundations of Computer Science (sfcs 1980). IEEE, October 1980. URL:
  38. Tillmann Miltzow, Lothar Narins, Yoshio Okamoto, Günter Rote, Antonis Thomas, and Takeaki Uno. Approximation and Hardness for Token Swapping. In Piotr Sankowski and Christos Zaroliagis, editors, Annual European Symposium on Algorithms, volume 24, pages 185:1-185:15. Leibniz International Proceedings in Informatics (LIPIcs), 2016. Google Scholar
  39. C. Monroe and J. Kim. Scaling the Ion Trap Quantum Processor. Science, 339(6124):1164-1169, 2013. URL:
  40. C. Monroe, R. Raussendorf, A. Ruthven, K. R. Brown, P. Maunz, L.-M. Duan, and J. Kim. Large-scale modular quantum-computer architecture with atomic memory and photonic interconnects. Physical Review A, 89(2), February 2014. URL:
  41. Prakash Murali, Jonathan M. Baker, Ali Javadi Abhari, Frederic T. Chong, and Margaret Martonosi. Noise-Adaptive Compiler Mappings for Noisy Intermediate-Scale Quantum Computers, 2019. Google Scholar
  42. Flemming Nielson, Hanne Riis Nielson, and Chris Hankin. Principles of Program Analysis. Springer Berlin Heidelberg, 1999. URL:
  43. M. Pedram and A. Shafaei. Layout Optimization for Quantum Circuits with Linear Nearest Neighbor Architectures. IEEE Circuits and Systems Magazine, 16(2):62-74, 2016. URL:
  44. Rigetti. QPU Specifications, 2018. URL:
  45. David J. Rosenbaum. Optimal Quantum Circuits for Nearest-Neighbor Architectures. In Simone Severini and Fernando Brandao, editors, 8th Conference on the Theory of Quantum Computation, Communication and Cryptography (TQC 2013), volume 22 of Leibniz International Proceedings in Informatics (LIPIcs), pages 294-307, Dagstuhl, Germany, 2013. Schloss Dagstuhl-Leibniz-Zentrum fuer Informatik. URL:
  46. Mehdi Saeedi, Robert Wille, and Rolf Drechsler. Synthesis of quantum circuits for linear nearest neighbor architectures. Quantum Information Processing, 10(3):355-377, June 2011. URL:
  47. Eddie Schoute, Cem Unsal, and Andrew Childs. arct, 2019. URL:
  48. Alireza Shafaei, Mehdi Saeedi, and Massoud Pedram. Qubit placement to minimize communication overhead in 2D quantum architectures. In 2014 19th Asia and South Pacific Design Automation Conference (ASP-DAC). IEEE, January 2014. URL:
  49. Farrokh Vatan and Colin Williams. Optimal quantum circuits for general two-qubit gates. Physical Review A, 69(3), 2004. URL:
  50. Davide Venturelli, Minh Do, Eleanor Rieffel, and Jeremy Frank. Compiling quantum circuits to realistic hardware architectures using temporal planners. Quantum Science and Technology, 3(2):025004, February 2018. URL:
  51. G. Vidal, K. Hammerer, and J. I. Cirac. Interaction Cost of Nonlocal Gates. Physical Review Letters, 88(23), 2002. URL:
  52. Mark Whitney, Nemanja Isailovic, Yatish Patel, and John Kubiatowicz. Automated generation of layout and control for quantum circuits. In Proceedings of the 4th international conference on Computing frontiers - CF quotesingle07, pages 83-94. ACM Press, 2007. URL:
  53. Robert Wille, Oliver Keszocze, Marcel Walter, Patrick Rohrs, Anupam Chattopadhyay, and Rolf Drechsler. Look-ahead schemes for nearest neighbor optimization of 1D and 2D quantum circuits. In 2016 21st Asia and South Pacific Design Automation Conference (ASP-DAC). IEEE, January 2016. URL:
  54. Robert Wille, Aaron Lye, and Rolf Drechsler. Exact Reordering of Circuit Lines for Nearest Neighbor Quantum Architectures. IEEE Transactions on Computer-Aided Design of Integrated Circuits and Systems, 33(12):1818-1831, December 2014. URL:
  55. Katsuhisa Yamanaka, Erik D. Demaine, Takehiro Ito, Jun Kawahara, Masashi Kiyomi, Yoshio Okamoto, Toshiki Saitoh, Akira Suzuki, Kei Uchizawa, and Takeaki Uno. Swapping Labeled Tokens on Graphs. In Lecture Notes in Computer Science, pages 364-375. Springer International Publishing, 2014. URL:
  56. Louxin Zhang. Optimal Bounds for Matching Routing on Trees. SIAM Journal on Discrete Mathematics, 12(1):64-77, January 1999. URL:
  57. Alwin Zulehner, Alexandru Paler, and Robert Wille. An Efficient Methodology for Mapping Quantum Circuits to the IBM QX Architectures. IEEE Transactions on Computer-Aided Design of Integrated Circuits and Systems, 2018. URL:
  58. Alwin Zulehner and Robert Wille. Compiling SU(4) quantum circuits to IBM QX architectures. In Proceedings of the 24th Asia and South Pacific Design Automation Conference on - ASPDAC quotesingle19, pages 185-190. ACM Press, 2019. URL:
Questions / Remarks / Feedback

Feedback for Dagstuhl Publishing

Thanks for your feedback!

Feedback submitted

Could not send message

Please try again later or send an E-mail