-
我们已处在“后摩尔定律”时代,经典的以CPU为主的计算架构已经发生了深刻的变革,加速器、协处理器、大小核等计算架构已经成为过去几年里主流服务器、移动设备等的关键计算架构。新型计算模式、计算架构不断涌现,量子计算有可能为基础计算架构带来颠覆性变革,是我国科技战略的重要发展方向,同时也是国际上新的科技战略高地。业界普遍认为量子计算能潜在处理某些用经典计算机几乎不可能完成的任务。如中国科学技术大学研发的“九章”量子计算原型机在求解高斯玻色取样任务中展现了量子计算的优越性[1],也可被应用于机器学习[2-3]、化学研究[4-5]等领域;一些工作也证明了量子计算在海量信息检索[6]、大整数质因数分解[7]等方面与经典计算机相比能产生指数级的加速。
量子计算机利用量子位纠缠态和叠加态,极大的提高了计算的并行性。然而,其与经典计算机相比有着截然不同的计算与应用架构。目前,量子计算芯片的物理量子位(Qubit)有超导、离子阱等材质,超导量子芯片需要大功率制冷设备的协助,才能短时间(500~
1000 us)保持量子一致状态并完成计算[8]。由于目前量子芯片架构及其工艺、量子操作系统、软件栈等要素组件尚处于快速发展阶段,量子计算机尚不能完全展现其巨大优势[9]。
Design of Quantum Operating System (QuOS) and Software Stack
-
摘要: 量子计算机已经逐步进入人们的视野,并被期望能够高效解决经典计算机不能解决的问题。量子计算机潜力巨大,是国内外积极关注的颠覆性计算技术。本文首先总结了国内外量子计算机系统的发展(涉及硬件、软件等多个层次),并归纳目前量子计算系统存在的、需要面对的问题以及相关的解决方案和方向。随后,提出了量子操作系统的设计原则,并介绍了一种量子操作系统QuOS的原型的核心机制。Abstract: Quantum computers have gradually entered people's vision and are expected to be able to efficiently solve problems that classical computers cannot solve. Quantum computers have great potential. This paper first summarizes the development of quantum computer systems (involving hardware, software and other levels), and summarizes the existing or need to face problems of current quantum computing systems. Then, the design principles of quantum operating system are presented, and the core mechanism of a prototype quantum operating system QuOS is introduced.
-
[1] ZHONG H S, Wang H, Deng Y H, et al. Quantum computational advantage using photons[J]. Science, 2020, 370(6523): 1460-1463. doi: 10.1126/science.abe8770 [2] BIAMONTE J , WITTEK P, PANCOTTI N, et al. Quantum machine learning[J]. Nature, 2017, 549(7671): 195-202. [3] LLOYD S, MOHSENI M, REBENTROST P. Quantum algorithms for supervised and unsupervised machine learning[EB/OL]. [2013-11-4]. https://arxiv.org/pdf/1307.0411 [4] KANDALA A, MEZZACAPO A, TEMME K, et al. Hardware-efficient variational quantum eigensolver for small molecules and quantum magnets[J]. Nature, 2017, 549(7671): 242-246. doi: 10.1038/nature23879 [5] PERUZZO A, MCCLEAN J, SHADBOLT P, et al. A variational eigenvalue solver on a photonic quantum processor[J]. Nature Communications, 2014, 5(1): 4213. doi: 10.1038/ncomms5213 [6] Grover L K. A fast quantum mechanical algorithm for database search[C]//Proceedings of the 28th Annual ACM Symposium on Theory of computing (STOC). ACM, 1996: 212-219. [7] SHOR P W. Polynomial-Time algorithms for prime factorization and discrete logarithms on a quantum computer[J]. SIAM Review, 1999, 41(2): 303-332. doi: 10.1137/S0036144598347011 [8] R. V. Meter, M. Oskin. Architectural Implications of Quantum Computing Technologies[J]. ACM Journal on Emerging Technologies in Computing Systems (JETC), 2006, 2(1): 31-63. doi: 10.1145/1126257.1126259 [9] J. Preskill. Quantum Computing in the NISQ era and beyond[J]. Quantum, 2018, 2: 79. doi: 10.22331/q-2018-08-06-79 [10] J. Koch, M. Y. Terri, J. Gambetta, et al. Charge-insensitive qubit design derived from the Cooper pair box[J]. Physical Review A, 2007, 76(4): 042319. [11] S. Debnath, N. M. Linke, C. Figgatt, et al. Demonstration of a small programmable quantum computer with atomic qubits[J]. Nature, 2016, 536(7614): 63-66. doi: 10.1038/nature18648 [12] IBM. IBM quantum services[EB/OL]. [2022-2-24]. https://quantum-computing.ibm.com/services?services=systems. [13] S. S. Tannu, M. K. Qureshi. Not all qubits are created equal: A case for variability-aware policies for NISQ-era quantum computers[C]//Proceedings of the Twenty-Fourth International Conference on Architectural Support for Programming Languages and Operating Systems. 2019: 987-999. [14] IBM. IBM Unveils Breakthrough 127-Qubit Quantum Processor[EB/OL]. [2022-2-24]. https://newsroom.ibm.com/2021-11-16-IBM-Unveils-Breakthrough-127-Qubit-Quantum-Processor. [15] Kelly J. A preview of Bristlecone, Google’s new quantum processor[J]. Google Research Blog, 2018, 5. [16] A. W. Cross, L. S. Bishop, J. A. Smolin, J. M. Gambetta. Open quantum Assembly language[EB/OL]. [2017-6-13]. https://arxiv.org/pdf/1707.03429.pdf [17] J. Heckey, S. Patil, A. JavadiAbhari, A. Holmes, D. Kudrow, K. R. Brown, D. Franklin, F. T. Chong, M. Martonosi. Compiler management of communication and parallelism for quantum computation[C]//Proceedings of the Twentieth International Conference on Architectural Support for Programming Languages and Operating Systems. 2015: 445-456. [18] A. Shafaei, M. Saeedi, M. Pedram. Optimization of quantum circuits for interaction distance in linear nearest neighbor architectures[C]//Proceedings of the 50th annual design automation conference. 2013: 1-6. [19] Wille R, Keszocze O, Walter M, et al. Look-ahead schemes for nearest neighbor optimization of 1D and 2D quantum circuits[C]//2016 21st Asia and South Pacific design automation conference (ASP-DAC). IEEE, 2016: 292-297. [20] Siraichi M Y, Santos V F, Collange C, et al. Qubit allocation[C]//Proceedings of the 2018 International Symposium on Code Generation and Optimization. 2018: 113-125. [21] Zulehner A, Paler A, Wille R. An efficient methodology for mapping quantum circuits to the IBM QX architectures[J]. IEEE Transactions on Computer-Aided Design of Integrated Circuits and Systems, 2018, 38(7): 1226-1236. [22] Murali P, McKay D C, Martonosi M, et al. Software mitigation of crosstalk on noisy intermediate-scale quantum computers[C]//Proceedings of the Twenty-Fifth International Conference on Architectural Support for Programming Languages and Operating Systems. 2020: 1001-1016. [23] Xie L, Zhai J, Zheng W. Mitigating crosstalk in quantum computers through commutativity-based instruction reordering[C]//2021 58th ACM/IEEE Design Automation Conference (DAC). IEEE, 2021: 445-450. [24] Das P, Tannu S S, Nair P J, et al. A case for multi-programming quantum computers[C]//Proceedings of the 52nd Annual IEEE/ACM International Symposium on Microarchitecture. 2019: 291-303. [25] Dou X, Liu L. A new qubits mapping mechanism for multi-programming quantum computing[C]//Proceedings of the ACM International Conference on Parallel Architectures and Compilation Techniques. 2020: 349-350. [26] Liu L, Dou X. Qucloud: A new qubit mapping mechanism for multi-programming quantum computing in cloud environment[C]//2021 IEEE International Symposium on High-Performance Computer Architecture (HPCA). IEEE, 2021: 167-178. [27] Resch S, Gutierrez A, Huh J S, et al. Accelerating variational quantum algorithms using circuit concurrency[J]. arXiv preprint arXiv: 2109.01714, 2021. [28] Barenco A, Bennett C H, Cleve R, et al. Elementary gates for quantum computation[J]. Physical review A, 1995, 52(5): 3457. doi: 10.1103/PhysRevA.52.3457 [29] Vartiainen J J, Möttönen M, Salomaa M M. Efficient decomposition of quantum gates[J]. Physical review letters, 2004, 92(17): 177902. doi: 10.1103/PhysRevLett.92.177902 [30] Jiang J, Sun X, Teng S H, et al. Optimal space-depth trade-off of CNOT circuits in quantum logic synthesis[C]//Proceedings of the Fourteenth Annual ACM-SIAM Symposium on Discrete Algorithms. Society for Industrial and Applied Mathematics, 2020: 213-229. [31] Nash B, Gheorghiu V, Mosca M. Quantum circuit optimizations for NISQ architectures[J]. Quantum Science and Technology, 2020, 5(2): 025010. doi: 10.1088/2058-9565/ab79b1 [32] Wu B, He X, Yang S, et al. Optimization of CNOT circuits under topological constraints[J]. arXiv preprint arXiv: 1910.14478, 2019. [33] 喻志超, 李扬中, 刘磊, 等. 量子计算模拟及优化方法综述[J]. 计算机工程, 2022, 48(1): 11. [34] De Raedt K, Michielsen K, De Raedt H, et al. Massively parallel quantum computer simulator[J]. Computer Physics Communications, 2007, 176(2): 121-136. doi: 10.1016/j.cpc.2006.08.007 [35] Corrigan-Gibbs H, Wu D J, Boneh D. Quantum operating systems[C]//Proceedings of the 16th Workshop on Hot Topics in Operating Systems. 2017: 76-81. [36] Tang W, Tomesh T, Suchara M, et al. Cutqc: using small quantum computers for large quantum circuit evaluations[C]//Proceedings of the 26th ACM International conference on architectural support for programming languages and operating systems. 2021: 473-486. [37] Suchara M, Alexeev Y, Chong F, et al. Hybrid quantum-classical computing architectures[C]//Proceedings of the 3rd International Workshop on Post-Moore Era Supercomputing, 2018. 2018. [38] Ayral T, Le Régent F M, Saleem Z, et al. Quantum divide and compute: Hardware demonstrations and noisy simulations[C]//2020 IEEE Computer Society Annual Symposium on VLSI (ISVLSI). IEEE, 2020: 138-140. [39] Peng T, Harrow A W, Ozols M, et al. Simulating large quantum circuits on a small quantum computer[J]. Physical review letters, 2020, 125(15): 150504. doi: 10.1103/PhysRevLett.125.150504 [40] Bravyi S, Smith G, Smolin J A. Trading classical and quantum computational resources[J]. Physical Review X, 2016, 6(2): 021043. doi: 10.1103/PhysRevX.6.021043 [41] Barends R, Kelly J, Megrant A, et al. Coherent Josephson qubit suitable for scalable quantum integrated circuits[J]. Physical review letters, 2013, 111(8): 080502. doi: 10.1103/PhysRevLett.111.080502 [42] Rigetti C, Devoret M. Fully microwave-tunable universal gates in superconducting qubits with linear couplings and fixed transition frequencies[J]. Physical Review B, 2010, 81(13): 134507. doi: 10.1103/PhysRevB.81.134507 [43] Friis N, Marty O, Maier C, et al. Observation of entangled states of a fully controlled 20-qubit system[J]. Physical Review X, 2018, 8(2): 021012. doi: 10.1103/PhysRevX.8.021012 [44] Maurand R, Jehl X, Kotekar-Patil D, et al. A CMOS silicon spin qubit[J]. Nature communications, 2016, 7(1): 13575. doi: 10.1038/ncomms13575 [45] Hayes A J F, Gilchrist A, Myers C R, et al. Utilizing encoding in scalable linear optics quantum computing[J]. Journal of Optics B: Quantum and Semiclassical Optics, 2004, 6(12): 533. doi: 10.1088/1464-4266/6/12/008 [46] Naik R K, Leung N, Chakram S, et al. Random access quantum information processors using multimode circuit quantum electrodynamics[J]. Nature communications, 2017, 8(1): 1904. doi: 10.1038/s41467-017-02046-6 [47] Duckering C, Baker J M, Schuster D I, et al. Virtualized logical qubits: A 2.5 d architecture for error-corrected quantum computing[C]//2020 53rd Annual IEEE/ACM International Symposium on Microarchitecture (MICRO). IEEE, 2020: 173-185. [48] Rosenberg D, Kim D, Das R, et al. 3D integrated superconducting qubits[J]. npj quantum information, 2017, 3(1): 42. doi: 10.1038/s41534-017-0044-0 [49] Mukai H, Sakata K, Devitt S J, et al. Pseudo-2D superconducting quantum computing circuit for the surface code: proposal and preliminary tests[J]. New Journal of Physics, 2020, 22(4): 043013. doi: 10.1088/1367-2630/ab7d7d [50] Azad U, Papneja A, Saini R, et al. Circuit centric quantum architecture design[J]. IET Quantum Communication, 2021, 2(1): 14-25. doi: 10.1049/qtc2.12004 [51] Li G, Ding Y, Xie Y. Towards efficient superconducting quantum processor architecture design[C]//Proceedings of the Twenty-Fifth International Conference on Architectural Support for Programming Languages and Operating Systems. 2020: 1031-1045. [52] B. Tan and J. Cong, Optimality study of existing quantum computing layout synthesis tools[J]. IEEE Transactions on Computers, 2020, 70(9): 1363-1373. [53] De Moura L, Bjørner N. Z3: An efficient SMT solver[C]//Tools and Algorithms for the Construction and Analysis of Systems: 14th International Conference, TACAS 2008, Held as Part of the Joint European Conferences on Theory and Practice of Software, ETAPS 2008, Budapest, Hungary, March 29-April 6, 2008. Proceedings 14. Springer Berlin Heidelberg, 2008: 337-340. [54] Bjørner N, Phan A D, Fleckenstein L. νz-an optimizing SMT solver[C]//Tools and Algorithms for the Construction and Analysis of Systems: 21st International Conference, TACAS 2015, Held as Part of the European Joint Conferences on Theory and Practice of Software, ETAPS 2015, London, UK, April 11-18, 2015, Proceedings 21. Springer Berlin Heidelberg, 2015: 194-199. [55] Shafaei A, Saeedi M, Pedram M. Qubit placement to minimize communication overhead in 2D quantum architectures[C]//2014 19th Asia and South Pacific Design Automation Conference (ASP-DAC). IEEE, 2014: 495-500. [56] Wille R, Lye A, Drechsler R. Optimal SWAP gate insertion for nearest neighbor quantum circuits[C]//2014 19th Asia and South Pacific Design Automation Conference (ASP-DAC). IEEE, 2014: 489-494. [57] Murali P, Baker J M, Javadi-Abhari A, et al. Noise-adaptive compiler mappings for noisy intermediate-scale quantum computers[C]//Proceedings of the twenty-fourth international conference on architectural support for programming languages and operating systems. 2019: 1015-1029. [58] P. Murali, N. M. Linke, M. Martonosi, A. J. Abhari, N. H. Nguyen, and C. H. Alderete, “Full-stack, real-system quantum computer studies, ” In ISCA, 2019. [59] Murali P, Linke N M, Martonosi M, et al. Full-stack, real-system quantum computer studies: Architectural comparisons and design insights[C]//Proceedings of the 46th International Symposium on Computer Architecture. 2019: 527-540. [60] Bhattacharjee A, Bandyopadhyay C, Wille R, et al. A novel approach for nearest neighbor realization of 2D quantum circuits[C]//2018 IEEE computer society annual symposium on VLSI (ISVLSI). IEEE, 2018: 305-310. [61] Ash-Saki A, Alam M, Ghosh S. QURE: Qubit re-allocation in noisy intermediate-scale quantum computers[C]//Proceedings of the 56th Annual Design Automation Conference 2019. 2019: 1-6. [62] Smith K N, Thornton M A. A quantum computational compiler and design tool for technology-specific targets[C]//Proceedings of the 46th International Symposium on Computer Architecture. 2019: 579-588. [63] Siraichi M Y, Santos V F, Collange C, et al. Qubit allocation as a combination of subgraph isomorphism and token swapping[J]. Proceedings of the ACM on Programming Languages, 2019, 3(OOPSLA): 1-29. [64] Li G, Ding Y, Xie Y. Tackling the qubit mapping problem for NISQ-era quantum devices[C]//Proceedings of the Twenty-Fourth International Conference on Architectural Support for Programming Languages and Operating Systems. 2019: 1001-1014. [65] Ding Y, Gokhale P, Lin S F, et al. Systematic crosstalk mitigation for superconducting qubits via frequency-aware compilation[C]//2020 53rd Annual IEEE/ACM International Symposium on Microarchitecture (MICRO). IEEE, 2020: 201-214. [66] Tannu S S, Qureshi M K. Mitigating measurement errors in quantum computers by exploiting state-dependent bias[C]//Proceedings of the 52nd Annual IEEE/ACM International Symposium on Microarchitecture. 2019: 279-290. [67] Tannu S S, Qureshi M. Ensemble of diverse mappings: Improving reliability of quantum computers by orchestrating dissimilar mistakes[C]//Proceedings of the 52nd Annual IEEE/ACM International Symposium on Microarchitecture. 2019: 253-265. [68] Huang Y, Martonosi M. Statistical assertions for validating patterns and finding bugs in quantum programs[C]//Proceedings of the 46th International Symposium on Computer Architecture. 2019: 541-553. [69] Liu J, Zhou H. Systematic approaches for precise and approximate quantum state runtime assertion[C]//2021 IEEE International Symposium on High-Performance Computer Architecture (HPCA). IEEE, 2021: 179-193. [70] Fowler A G, Mariantoni M, Martinis J M, et al. Surface codes: Towards practical large-scale quantum computation[J]. Physical Review A, 2012, 86(3): 032324. doi: 10.1103/PhysRevA.86.032324 [71] Ding Y, Holmes A, Javadi-Abhari A, et al. Magic-state functional units: Mapping and scheduling multi-level distillation circuits for fault-tolerant quantum architectures[C]//2018 51st Annual IEEE/ACM International Symposium on Microarchitecture (MICRO). IEEE, 2018: 828-840. [72] Javadi-Abhari A, Gokhale P, Holmes A, et al. Optimized surface code communication in superconducting quantum computers[C]//Proceedings of the 50th Annual IEEE/ACM International Symposium on Microarchitecture. 2017: 692-705. [73] Wu B, He X, Yang S, et al. Optimization of CNOT circuits under topological constraints[J]. arXiv preprint arXiv: 1910.14478, 2019. [74] Chen J, Zhang F, Huang C, et al. Classical simulation of intermediate-size quantum circuits[J]. arXiv preprint arXiv: 1805.01450, 2018. [75] Smelyanskiy M, Sawaya N P D, Aspuru-Guzik A. qHiPSTER: The quantum high performance software testing environment[J]. arXiv preprint arXiv: 1601.07195, 2016. [76] Jones T, Brown A, Bush I, et al. QuEST and high performance simulation of quantum computers[J]. Scientific reports, 2019, 9(1): 1-11. doi: 10.1038/s41598-018-37186-2 [77] Pednault E, Gunnels J A, Nannicini G, et al. Pareto-efficient quantum circuit simulation using tensor contraction deferral[J]. arXiv preprint arXiv: 1710.05867, 2017. [78] Li R, Wu B, Ying M, et al. Quantum supremacy circuit simulation on Sunway TaihuLight[J]. IEEE Transactions on Parallel and Distributed Systems, 2019, 31(4): 805-816. [79] Zhang P, Yuan J, Lu X. Quantum computer simulation on multi-GPU incorporating data locality[C]//Algorithms and Architectures for Parallel Processing: 15th International Conference, ICA3PP 2015, Zhangjiajie, China, November 18-20, 2015, Proceedings, Part I 15. Springer International Publishing, 2015: 241-256. [80] Chen Y T, Farquhar C, Parrish R M. Low-rank density-matrix evolution for noisy quantum circuits[J]. npj Quantum Information, 2021, 7(1): 61. doi: 10.1038/s41534-021-00392-4 [81] Liu L, Dou X. QuCloud+: A Holistic Qubit Mapping Scheme for Single/Multi-programming on 2D/3D NISQ Quantum Computers[J]. arXiv preprint arXiv: 2207.14483, 2022.