Challenges
Datasets
Workspaces
Papers
Discussions
Leaderboard
Log inSign up
Challenges
Datasets
Workspaces
Papers
Discussions
Leaderboard
Blog
Job Board
Q3AS

© 2026 Aqora Quantum S.A.S.

TermsPrivacyLegal Notice

International Conference on Architectural Support for Programming Languages and Operating Systems (ASPLOS)

Erasynth: Improving Quantum Uncomputation with Structural Measurements

Mingfei Zhang, Anbang Wu, Pu Pang, Liqiang Lu, Zongwu Wang, Fangxin Liu, Zihan Liu, Yu Feng, Jingwen Leng, Minyi Guo

Published Nov 4, 2026• 0 citations
Publisher

Abstract

In quantum computing, safely clearing temporary ancilla qubits, a process known as uncomputation, is essential to prevent irreversible computational errors caused by entanglement. The typical uncomputation process removes entanglement by reversing gates used to correlate ancilla and (program) data, potentially doubling circuit depth and gate counts. The alternative approach introduces measurements to directly reset ancilla to the ground state and has the potential of reducing uncomputation overhead. Unfortunately, existing measurement-based methods may need to correct the minus sign of exponentially many quantum state terms due to measurement uncertainty, instead incurring larger gate overhead. Our insight to further reduce the uncomputation overhead is to integrate the idea of both methods. To some extent, the unitary-based method is highly structural, reflecting the circuit's computation-uncomputation symmetry, while the measurement-based method introduces randomness due to the uncertainty of the involved qubit set and the resulting phase corrections. Either being too structural or too random introduces high overhead for uncomputation. This work improves existing methods by incorporating structural circuit analysis to suppress the randomness of measurements. This work proposes Erasynth, which analyzes the circuit context and identifies the best timing of applying measurements to release ancilla; unveils the optimal strategy to release ancilla according to the dimension of involved quantum data subspace; prunes and only corrects the key data subspace suffering from measurement-induced phase flip. Experimental evaluations show that Erasynth reduces CX gates by up to 37.48%/97.56% and T gates by up to 50.0%/98.54% over the unitary-based/measurement-based baseline, while also reducing circuit depth by up to 75.62%/98.89%.

DOI
10.1145/3845814.3850084

Related papers

MBUndo: Sound, Automatic, and Efficient Measurement-Based Uncomputation for Quantum Circuits

Shengyuan Yang, Charles Yuan

Quantum programs that use temporary values, known as \emph{ancilla} qubits, must explicitly \emph{uncompute} each ancilla back to zero to ensure that the program produces correct outputs. Conventional uncomputation uses unitary quantum gates, whereas leading quantum algorithms now leverage \emph{measurement-based uncomputation} (MBU), which replaces costly unitary $T$ gates with cheaper measurements and phase corrections. Current quantum programming frameworks can use measurement to uncompute specific gates such as Toffoli. No automatic transformation, however, accepts an arbitrary circuit whose ancillas are computed and uncomputed via the standard approach and converts the circuit to use MBU\@. Researchers instead apply MBU to individual circuit designs by hand, which limits algorithm development and compiler optimization. Such a transformation has not existed due to two fundamental unknowns: where MBU applies and which gates realize MBU for an arbitrary computation. To solve these, we first present a static analysis that identifies, for each ancilla qubit, each circuit position where measurement is sound --- subsuming basic assumptions that MBU only applies at the end of a circuit. Next, we present circuit transformations that soundly turn unitary uncomputation gates into efficient phase corrections after measurement --- generalizing rewrite rules from prior literature that are either limited to a single gate or not applicable to a general circuit. We present \textsf{MBUndo}, an integrated compiler pass that automatically converts circuits to measurement-based uncomputation. It requires no user annotations other than which qubits are ancillas, the same as needed by existing uncomputation synthesizers, and can enhance their output circuits. We evaluate \textsf{MBUndo} on 22 benchmarks to reveal \emph{T} gate reductions of ${>}36.5\%$ over uncomputation synthesizers.

cs.PLCross-listedarXiv:2611.02345•Nov 3, 2026•0 citations

Uncomputing Ancilla Qubits in Quantum Circuits

Ashutosh Tiwari, Ranjani G. Sundaram, Himanshu Gupta +2 more

Uncomputation of ancilla qubits is essential in quantum computing to reset auxiliary qubits to a zero state, ensuring their safe discarding and reducing resource overhead. Current methods for uncomputation either rely on manual procedures or use additional ancilla qubits to store intermediate computation results, which increases qubit storage requirements. Additionally, most in-place uncomputation techniques employ an all-or-nothing strategy, wherein they perform uncomputation only when all ancilla qubits in the given circuit can be uncomputed.In this work, we tackle the problem of uncomputing a maximum number of ancilla qubits in a quantum circuit with minimal qubit storage overhead. We propose a novel approach where partial uncomputation—reverting the last ’m’ gates—enables the uncomputation of more qubits. We present three algorithms designed to uncompute the largest possible set of ancilla qubits and demonstrate their effectiveness through experiments on various randomly generated quantum circuits.

International Conference on Quantum Communications, Networking, and Computing (QCNC)•Mar 31, 2025•3 citations

Empirical Validation of Ancilla Recycling via Uncomputation and Loschmidt Echo Decay on NISQ Architectures

Madhan Mohan Agaram

In quantum algorithm design, scratchpad auxiliary (ancilla) qubits represent a critical hardwareoverhead. While intermediate measurements can collapse superpositions destructively, Bennett’s principle of reversible uncomputation allows auxiliary registers to be disentangled unitarily and returned to their ground state |0⟩ for reuse. In this paper, we report empirical hardware benchmarks of coherent ancilla uncomputation and full-cycle state restoration across 12-qubit and 20-qubit registers executed on the 156-qubit superconducting processor ibm_kingston . To evaluate uncomputation under non-trivial amplitude configurations, continuous phase rotations were parameterized using entropy bytes extracted from a classical binary stream. The hardware successfully reset 10 entangled ancilla qubits back to the |0000000000⟩ state with an uncomputation fidelity of 90.30% (903/1000 shots). However, executing a complete forward-and-reverse Loschmidt echo protocol across the full 20-qubit register yielded an exact state restoration fidelity of only 21.40%. This degradation quantitatively illustrates how non-unitary NISQ errors— including 2-qubit gate cross-talk, T1/T2 relaxation, and compounding measurement readout error—destroy exact reversibility as circuit depth doubles. We provide full experimental provenance, calibration context, and job identifiers to establish a reproducible baseline for NISQ ancilla management. Keywords: Ancilla recycling, Quantum uncomputation, Loschmidt echo, NISQ benchmarking, Superconducting qubits,Heavy-hex architecture.

•Oct 27, 2026•0 citations

Measurement-Based Uncomputation from an Error Correction Perspective

Minjun Jeon, Po-Wei Huang, Zhenyu Cai

Coherent uncomputation can be as costly as the computation itself, creating substantial spacetime overheads that can be prohibitive on early fault-tolerant quantum computers. We develop an algebraic framework for measurement-based uncomputation (MBU) through a quantum error-correction picture: measurements of the garbage register induce relative phases analogous to errors causing non-trivial syndromes. Accepting only zero-syndrome outcomes achieves post-selected MBU, removing the need for an uncomputation oracle at the cost of a probabilistic success rate determined by the affine rank of the populated garbage support. This rank can be much smaller than the number of garbage qubits, as illustrated through an example of the HHL algorithm. We then derive a structural condition under which the original uncomputation oracle can be reused to correct the phase for all measurement outcomes. No correction is required for the zero syndrome, while corrections for non-zero syndromes can be further adapted to individual measurement outcomes for simpler circuits, as illustrated by existing modular-arithmetic, QROM, and QRAM MBU constructions. Phase-correction circuits can be further simplified by co-optimising their implementation with the representation of the measurement-induced phases. Selecting which syndrome classes to correct interpolates between post-selected, partially corrected, and deterministic MBU, enabling trade-offs among correction cost, workspace, and repetitions.

quant-pharXiv:2609.31605•Sep 28, 2026•1 citation

Optimizing Ancilla-Based Quantum Circuits with SPARE

Ritvik Sharma, Sara Achour

Many quantum algorithms instantiate and use ancillas, spare qubits that serve as temporary storage in a quantum circuit. In particular, many recently developed high-level and modular quantum programming languages (QPLs) use ancilla qubits to implement various programming constructs. These are lowered to circuits with nested/cascading compute-uncompute gate sequences that use ancilla qubits to track internal state. We present SPARE, a rewrite-based quantum circuit optimizer that restructures these compute-uncompute gate sequences, leveraging the ancilla qubit state information to optimize the circuit. In this work, we prove the correctness of SPARE’s rewrites and link SPARE’s gate-level transforms to language-level program rewrites, which may be performed on the input language. We evaluate SPARE on QPL-generated quantum circuits against Unqomp and Spire, two optimizing compilers for QPLs. SPARE achieves a reduction of up to 27.3 % in qubit count, 56.7 % in 2 -qubit gates, 68.2 % in 1-qubit gates and 73.9 % in depth against Unqomp, and up to 17.8 % in qubits, 67.3 % in 2-qubit gates, 61.4 % in 1-qubit gates and 59.9 % in depth against Spire. We also evaluate SPARE against the Quartz, Feynman, and PyZX circuit optimizers: SPARE achieves up to a 70.0 % reduction in two-qubit gates, up to a 53.6 % reduction in 1-qubit gates, and up to a 56.7 % reduction in depth compared to the best result from all the gate-level optimizers.

Proceedings of the ACM on Programming Languages•Jun 10, 2025•9 citations

Efficient Quantum Error Mitigation for Unitary k-Designs

Ayush Pancholy, K. Birgitta Whaley

Quantum circuit ensembles that have the properties of unitary k-designs represent applications where there is no obvious bias toward any particular Pauli support, as is the case in simulating systems exhibiting ''quantum chaos,'' which range from quantum dynamics near black holes to gapless spin fluid analysis. However, noisy hardware makes quantum circuits prone to a myriad of error sources, of which depolarizing and coherent error can be particularly destructive. To combat depolarizing error, popular techniques typically involve circuit or gate folding, which can be time-intensive procedures due to increased circuit depth and shot overhead. Other tensor-network-based mitigation techniques suffer from intractability in high-entanglement regimes. In this work, we leverage the structure of unitary k-design Pauli support distributions by introducing a technique we name ''circuit balancing,'' along with gate benchmarking data, in order to estimate circuit-wide depolarization. We describe how to invert the diagnosed circuit depolarization even in the presence of coherent error, via Pauli twirling. We provide asymptotics to estimate the number of twirls needed to maintain a desired output fidelity. We test our method numerically in a variety of simulation settings and find that it can significantly reduce average random circuit infidelity. Further, we employ our methods to find significant infidelity reductions when running a random circuit ensemble on a contemporary superconducting quantum computer, IBM Fez. Overall, we show that the method effectively reduces gate-based error for unitary k-designs without incurring any two-qubit gate overhead.

quant-pharXiv:2606.03891•Jun 3, 2026•0 citations
In quantum computing, safely clearing temporary ancilla qubits, a process known as uncomputation, is essential to prevent irreversible computational errors caused by entanglement. The typical uncomputation process removes entanglement by reversing gates used to correlate ancilla and (program) data, potentially doubling circuit depth and gate counts. The alternative approach introduces measurements to directly reset ancilla to the ground state and has the potential of reducing uncomputation overhead. Unfortunately, existing measurement-based methods may need to correct the minus sign of exponentially many quantum state terms due to measurement uncertainty, instead incurring larger gate overhead. Our insight to further reduce the uncomputation overhead is to integrate the idea of both methods. To some extent, the unitary-based method is highly structural, reflecting the circuit's computation-uncomputation symmetry, while the measurement-based method introduces randomness due to the uncertainty of the involved qubit set and the resulting phase corrections. Either being too structural or too random introduces high overhead for uncomputation. This work improves existing methods by incorporating structural circuit analysis to suppress the randomness of measurements. This work proposes Erasynth, which analyzes the circuit context and identifies the best timing of applying measurements to release ancilla; unveils the optimal strategy to release ancilla according to the dimension of involved quantum data subspace; prunes and only corrects the key data subspace suffering from measurement-induced phase flip. Experimental evaluations show that Erasynth reduces CX gates by up to 37.48%/97.56% and T gates by up to 50.0%/98.54% over the unitary-based/measurement-based baseline, while also reducing circuit depth by up to 75.62%/98.89%.
Quantum programs that use temporary values, known as \emph{ancilla} qubits, must explicitly \emph{uncompute} each ancilla back to zero to ensure that the program produces correct outputs. Conventional uncomputation uses unitary quantum gates, whereas leading quantum algorithms now leverage \emph{measurement-based uncomputation} (MBU), which replaces costly unitary TTT gates with cheaper measurements and phase corrections. Current quantum programming frameworks can use measurement to uncompute specific gates such as Toffoli. No automatic transformation, however, accepts an arbitrary circuit whose ancillas are computed and uncomputed via the standard approach and converts the circuit to use MBU\@. Researchers instead apply MBU to individual circuit designs by hand, which limits algorithm development and compiler optimization. Such a transformation has not existed due to two fundamental unknowns: where MBU applies and which gates realize MBU for an arbitrary computation. To solve these, we first present a static analysis that identifies, for each ancilla qubit, each circuit position where measurement is sound --- subsuming basic assumptions that MBU only applies at the end of a circuit. Next, we present circuit transformations that soundly turn unitary uncomputation gates into efficient phase corrections after measurement --- generalizing rewrite rules from prior literature that are either limited to a single gate or not applicable to a general circuit. We present \textsf{MBUndo}, an integrated compiler pass that automatically converts circuits to measurement-based uncomputation. It requires no user annotations other than which qubits are ancillas, the same as needed by existing uncomputation synthesizers, and can enhance their output circuits. We evaluate \textsf{MBUndo} on 22 benchmarks to reveal \emph{T} gate reductions of >36.5%{>}36.5\%>36.5% over uncomputation synthesizers.
Uncomputation of ancilla qubits is essential in quantum computing to reset auxiliary qubits to a zero state, ensuring their safe discarding and reducing resource overhead. Current methods for uncomputation either rely on manual procedures or use additional ancilla qubits to store intermediate computation results, which increases qubit storage requirements. Additionally, most in-place uncomputation techniques employ an all-or-nothing strategy, wherein they perform uncomputation only when all ancilla qubits in the given circuit can be uncomputed.In this work, we tackle the problem of uncomputing a maximum number of ancilla qubits in a quantum circuit with minimal qubit storage overhead. We propose a novel approach where partial uncomputation—reverting the last ’m’ gates—enables the uncomputation of more qubits. We present three algorithms designed to uncompute the largest possible set of ancilla qubits and demonstrate their effectiveness through experiments on various randomly generated quantum circuits.
In quantum algorithm design, scratchpad auxiliary (ancilla) qubits represent a critical hardwareoverhead. While intermediate measurements can collapse superpositions destructively, Bennett’s principle of reversible uncomputation allows auxiliary registers to be disentangled unitarily and returned to their ground state |0⟩ for reuse. In this paper, we report empirical hardware benchmarks of coherent ancilla uncomputation and full-cycle state restoration across 12-qubit and 20-qubit registers executed on the 156-qubit superconducting processor ibm_kingston . To evaluate uncomputation under non-trivial amplitude configurations, continuous phase rotations were parameterized using entropy bytes extracted from a classical binary stream. The hardware successfully reset 10 entangled ancilla qubits back to the |0000000000⟩ state with an uncomputation fidelity of 90.30% (903/1000 shots). However, executing a complete forward-and-reverse Loschmidt echo protocol across the full 20-qubit register yielded an exact state restoration fidelity of only 21.40%. This degradation quantitatively illustrates how non-unitary NISQ errors— including 2-qubit gate cross-talk, T1/T2 relaxation, and compounding measurement readout error—destroy exact reversibility as circuit depth doubles. We provide full experimental provenance, calibration context, and job identifiers to establish a reproducible baseline for NISQ ancilla management. Keywords: Ancilla recycling, Quantum uncomputation, Loschmidt echo, NISQ benchmarking, Superconducting qubits,Heavy-hex architecture.
Coherent uncomputation can be as costly as the computation itself, creating substantial spacetime overheads that can be prohibitive on early fault-tolerant quantum computers. We develop an algebraic framework for measurement-based uncomputation (MBU) through a quantum error-correction picture: measurements of the garbage register induce relative phases analogous to errors causing non-trivial syndromes. Accepting only zero-syndrome outcomes achieves post-selected MBU, removing the need for an uncomputation oracle at the cost of a probabilistic success rate determined by the affine rank of the populated garbage support. This rank can be much smaller than the number of garbage qubits, as illustrated through an example of the HHL algorithm. We then derive a structural condition under which the original uncomputation oracle can be reused to correct the phase for all measurement outcomes. No correction is required for the zero syndrome, while corrections for non-zero syndromes can be further adapted to individual measurement outcomes for simpler circuits, as illustrated by existing modular-arithmetic, QROM, and QRAM MBU constructions. Phase-correction circuits can be further simplified by co-optimising their implementation with the representation of the measurement-induced phases. Selecting which syndrome classes to correct interpolates between post-selected, partially corrected, and deterministic MBU, enabling trade-offs among correction cost, workspace, and repetitions.
Many quantum algorithms instantiate and use ancillas, spare qubits that serve as temporary storage in a quantum circuit. In particular, many recently developed high-level and modular quantum programming languages (QPLs) use ancilla qubits to implement various programming constructs. These are lowered to circuits with nested/cascading compute-uncompute gate sequences that use ancilla qubits to track internal state. We present SPARE, a rewrite-based quantum circuit optimizer that restructures these compute-uncompute gate sequences, leveraging the ancilla qubit state information to optimize the circuit. In this work, we prove the correctness of SPARE’s rewrites and link SPARE’s gate-level transforms to language-level program rewrites, which may be performed on the input language. We evaluate SPARE on QPL-generated quantum circuits against Unqomp and Spire, two optimizing compilers for QPLs. SPARE achieves a reduction of up to 27.3 % in qubit count, 56.7 % in 2 -qubit gates, 68.2 % in 1-qubit gates and 73.9 % in depth against Unqomp, and up to 17.8 % in qubits, 67.3 % in 2-qubit gates, 61.4 % in 1-qubit gates and 59.9 % in depth against Spire. We also evaluate SPARE against the Quartz, Feynman, and PyZX circuit optimizers: SPARE achieves up to a 70.0 % reduction in two-qubit gates, up to a 53.6 % reduction in 1-qubit gates, and up to a 56.7 % reduction in depth compared to the best result from all the gate-level optimizers.
Quantum circuit ensembles that have the properties of unitary k-designs represent applications where there is no obvious bias toward any particular Pauli support, as is the case in simulating systems exhibiting ''quantum chaos,'' which range from quantum dynamics near black holes to gapless spin fluid analysis. However, noisy hardware makes quantum circuits prone to a myriad of error sources, of which depolarizing and coherent error can be particularly destructive. To combat depolarizing error, popular techniques typically involve circuit or gate folding, which can be time-intensive procedures due to increased circuit depth and shot overhead. Other tensor-network-based mitigation techniques suffer from intractability in high-entanglement regimes. In this work, we leverage the structure of unitary k-design Pauli support distributions by introducing a technique we name ''circuit balancing,'' along with gate benchmarking data, in order to estimate circuit-wide depolarization. We describe how to invert the diagnosed circuit depolarization even in the presence of coherent error, via Pauli twirling. We provide asymptotics to estimate the number of twirls needed to maintain a desired output fidelity. We test our method numerically in a variety of simulation settings and find that it can significantly reduce average random circuit infidelity. Further, we employ our methods to find significant infidelity reductions when running a random circuit ensemble on a contemporary superconducting quantum computer, IBM Fez. Overall, we show that the method effectively reduces gate-based error for unitary k-designs without incurring any two-qubit gate overhead.