Lune

ISCA2020Top-tier venue

SQUARE: Strategic Quantum Ancilla Reuse for Modular Quantum Programs via Cost-Effective Uncomputation

Yongshan Ding, Xin-Chuan Wu, Adam Holmes, Ash Wiseth, Diana Franklin, Margaret Martonosi, Frederic T. Chong

Abstract

Compiling high-level quantum programs to machines that are size constrained (i.e. limited number of quantum bits) and time constrained (i.e. limited number of quantum operations) is challenging. In this paper, we present SQUARE (Strategic QUantum Ancilla REuse), a compilation infrastructure that tackles allocation and reclamation of scratch qubits (called ancilla) in modular quantum programs. At its core, SQUARE strategically performs uncomputation to create opportunities for qubit reuse.Current Noisy Intermediate-Scale Quantum (NISQ) computers and forward-looking Fault-Tolerant (FT) quantum computers have fundamentally different constraints such as data locality, instruction parallelism, and communication overhead. Our heuristic-based ancilla-reuse algorithm balances these considerations and fits computations into resource-constrained NISQ or FT quantum machines, throttling parallelism when necessary. To precisely capture the workload of a program, we propose an improved metric, the “active quantum volume,” and use this metric to evaluate the effectiveness of our algorithm. Our results show that SQUARE improves the average success rate of NISQ applications by 1. 47X. Surprisingly, the additional gates for uncomputation create ancilla with better locality, and result in substantially fewer swap gates and less gate noise overall. SQUARE also achieves an average reduction of 1. 5X (and up to 9. 6X) in active quantum volume for FT machines.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

13 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • Tower: data structures in Quantum superposition cites Unqomp: synthesizing uncomputation in Quantum circuits
  • CaQR: A Compiler-Assisted Approach for Qubit Reuse through Dynamic Circuit cites 2QAN: a quantum compiler for 2-local qubit hamiltonian simulation algorithms
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers13

  1. QuantumNAS: Noise-Adaptive Search for Robust Quantum CircuitsHanrui Wang, Yongshan Ding, Jiaqi Gu, Yujun Lin et al.HPCA 2022 · 199 citations
  2. 2QAN: a quantum compiler for 2-local qubit hamiltonian simulation algorithmsLingling Lao, Dan E. BrowneISCA 2022 · 37 citations
  3. Unqomp: synthesizing uncomputation in Quantum circuitsAnouk Paradis, Benjamin Bichsel, Samuel Steffen, Martin T. VechevPLDI 2021 · 34 citations
  4. CaQR: A Compiler-Assisted Approach for Qubit Reuse through Dynamic CircuitFei Hua, Yuwei Jin, Yan-Hao Chen, Suhas Vittal et al.ASPLOS 2023 · 27 citations
  5. Tower: data structures in Quantum superpositionCharles Yuan, Michael CarbinOOPSLA 2022 · 26 citations

Related papers

  1. Optimizing Ancilla-Based Quantum Circuits with SPARERitvik Sharma, Sara AchourPLDI 2025
  2. Time-optimal Qubit mappingChi Zhang, Ari B. Hayes, Longfei Qiu, Yuwei Jin et al.ASPLOS 2021 · 72 citations
  3. DDRoute: a Novel Depth-Driven Approach to the Qubit Routing ProblemAlessandro Annechini, Marco Venere, Donatella Sciuto, Marco D. SantambrogioDAC 2025 · 2 citations
  4. Borrowing Dirty Qubits in Quantum ProgramsBonan Su, Li Zhou, Yuan Feng, Mingsheng YingASPLOS 2026 · 1 citation
  5. Optimizing quantum circuit synthesis for permutations using recursionCynthia Chen, Bruno Schmitt, Helena Zhang, Lev S. Bishop et al.DAC 2022 · 3 citations
Dusk over the sea between two cliffs drawn in fine vertical lines