Papers
Topics
Authors
Recent
Search
2000 character limit reached

Halving the cost of QROM

Published 19 May 2026 in quant-ph | (2605.20334v1)

Abstract: Table lookup, often referred to as quantum read only memory (QROM), is one of the most widely used subroutines in quantum algorithms, and constitutes the majority share of algorithmic overheads in most practical applications of quantum computers. It involves the coherent loading of $N$ bitstrings of length $b$ in superposition, and naively has a non-Clifford cost of $N$ Toffolis. It is known that given access to $b\, λ$ dirty qubits, one can reduce the Toffoli cost of QROM to $2\frac{N}λ + 4b(λ- 1)$. In this work, we first present an optimization to reduce this cost to $2\frac{N}λ + 2b(λ- 1) + 2λ-6$ by replacing the SelectSwap" architecture withSelectCopy". We then provide a further optimization for the qubit-constrained regime where the Toffoli cost is typically $\sim 2\frac{N}λ$, and reduce it to $\sim (1+\frac{1}{b})\frac{N}λ$, cutting the cost by approximately $50\%$ and effectively matching the performance of clean-qubit QROM using dirty qubits for practical values of $b$. Lastly, we provide a parametric family of methods that allow the interpolation of the prefactor of the $\frac{N}λ $ term from $2$ to ($\, 1+\frac{1}{b}\,$) to obtain the best cost for different qubit availability regimes.

Summary

  • The paper presents a novel SelectCopy paradigm that halves the Toffoli cost in QROM compared to the previous SelectSwap method.
  • It replaces redundant multiplexed swaps with direct controlled copies, reducing both circuit depth and CNOT requirements without increasing the ancilla count.
  • The approach supports iterative QROM invocations and tunable batching strategies, optimizing resource tradeoffs for quantum simulation and chemistry applications.

Halving the Toffoli Cost of Quantum Read-Only Memory

Introduction

Quantum Read-Only Memory (QROM) serves as a pivotal building block in quantum algorithms, underpinning procedures such as Hamiltonian simulation, quantum signal processing (QSP), state preparation, unitary synthesis, quantum differential equation solvers, and quantum linear system solvers. The resource requirements of QROM, dominated by Toffoli gate count and ancillary qubit usage, often represent the leading overhead in practical quantum applications. The prevailing approach for efficient QROM leverages dirty ancilla qubits (ancillas in unknown states) to reduce gate complexity, yet incurs a multiplicative cost factor compared to clean-qubit constructions—a bottleneck persisting for several years. This paper presents a set of novel techniques that halve the Toffoli complexity of QROM in the dirty-qubit regime, achieving practical parity with clean-qubit performance for the dominant parameter settings.

Technical Contributions and Algorithmic Improvements

The core innovation is the transition from the "SelectSwap" to "SelectCopy" architectures, fundamentally changing how classical bitstrings are loaded into quantum registers using dirty ancillae. The SelectCopy paradigm eliminates redundant multiplexed swaps (two per lookup in SelectSwap) and replaces these with direct controlled copies, yielding a Toffoli cost reduction:

2Nλ+4b(λ−1)→2Nλ+2b(λ−1)+2λ−62\frac{N}{\lambda} + 4b(\lambda-1) \rightarrow 2\frac{N}{\lambda} + 2b(\lambda-1) + 2\lambda-6

where NN is the number of bitstrings, bb is the bitstring length, and λ\lambda the depth of dirty ancilla utilization. Crucially, the new construction sustains the same ancilla count—b(λ−1)b(\lambda-1) dirty ancillary qubits—while immediately improving circuit depth and reducing CNOT requirements (from 4bλ4b\lambda to zero).

The paper further develops a parametric family of methods by partitioning the QROM lookup into α\alpha sequential subroutines, each loading fewer bits. For α=b\alpha = b, the dominant Toffoli term in the dirty-qubit regime is reduced to:

(1+1b)Nλ(1+\frac{1}{b})\frac{N}{\lambda}

matching clean-qubit performance and achieving approximately 50% cost reduction for large NN relative to NN0 (the practical parameter regime for quantum chemistry and simulation). The choice of NN1 is tunable and can be adapted per instance to optimize resource tradeoffs. Figure 1

Figure 1

Figure 1: Improvement factor for Toffoli cost as a function of number of elements NN2, bitstring length NN3, and dirty qubit count, showing reduction from the previous state-of-the-art to the optimal SelectCopy parameterization.

Additionally, the algorithm supports efficient sequential QROM invocations (useful in block-encoding and tensor hypercontraction), condensing multiple loads/unloads by applying XOR-based reuse of dirty registers. The paper proves that the dominant Toffoli iteration for NN4 sequential QROMs is reduced from NN5 to NN6, and generalizes the approach for arbitrary bit batch sizes.

Circuit Architecture Analysis

The SelectCopy technique exploits the insight that multiplexed copy operations, controlled on address subregisters, can directly transfer the required bitstring fragment from the dirty ancilla to the output register with half the gate overhead relative to swap-based methods. By careful decomposition of the address register, the construction achieves optimal scheduling for the loading, copying, and restoring operations necessary in coherent table lookup.

(Figure 2)

Figure 2: Circuit comparison between SelectSwap (prior art) and SelectCopy (current work); SelectCopy halves swap costs by direct controlled copy onto output.

For iterative QROM (partitioned bit packets), the architecture is further generalized to allow NN7 bit groups, with each iteration efficiently loading and subsequently restoring the output register bits via controlled XOR with the dirty qubits. The restore operation is deterministic and precisely tracks the propagation of ancilla-induced bit errors, employing temporary AND ancillas synchronized by unary iteration.

(Figure 3)

Figure 3: Visualization of iterative QROM at NN8, with sequential bit packet loads and controlled restore operations.

Empirical and Analytical Results

Numerical results, as depicted in Figure 1, show that the cost advantage factor improves monotonically with increasing NN9 for both extremes (bb0, bb1) and for the optimal bb2. In regimes where dirty qubits are limited and bb3 is sufficiently large, the reduction approaches the theoretical halving predicted analytically. The prefactor bb4 for the dominant term is smoothly interpolated to bb5 as bb6 increases—demonstrating robustness of the optimization across a broad practical parameter range.

The algorithmic improvements are rigorously analyzed and proven for both power-of-two and arbitrary bit-lengths, with explicit Toffoli and ancillary qubit cost formulas provided (see theorem in the appendix).

Practical and Theoretical Implications

These advancements yield immediate practical benefits for quantum algorithm design, particularly in fault-tolerant quantum simulation, where QROM complexity is a chief limiting factor in chemistry, optimization, and linear system applications. By matching clean-qubit Toffoli scaling in the dirty-qubit regime, the methods lower the threshold for quantum advantage in real-world settings, reduce quantum resource requirements, and enable broader applicability of high-level quantum routines.

Theoretically, the SelectCopy paradigm suggests potential for further synthesis and data loading circuit optimization, especially when combined with improved integer division techniques to lift constraints on bb7 (ancilla depth). Such generalizations could unlock reductions in cases where qubit budget mismatches power-of-two scaling, as recent work on quantum arithmetic provides (Mukhopadhyay et al., 18 Mar 2026).

The methods are implemented and available in PennyLane, enabling immediate deployment in quantum software stacks.

Conclusion

This paper introduces the first major reduction in QROM implementation cost in over half a decade by replacing SelectSwap with SelectCopy, developing a parametric batching scheme, and rigorously optimizing multiplexed copy operations. The Toffoli cost is halved in the dirty-qubit regime for practical parameter settings, matching clean-qubit performance and substantiating strong empirical results across relevant use cases. These techniques have broad implications for quantum algorithm design, resource estimation, and hardware feasibility. Future work should explore further generalization and synergy with quantum arithmetic circuits for optimal qubit utilization (2605.20334).

Paper to Video (Beta)

No one has generated a video about this paper yet.

Whiteboard

No one has generated a whiteboard explanation for this paper yet.

Open Problems

We haven't generated a list of open problems mentioned in this paper yet.

Collections

Sign up for free to add this paper to one or more collections.

Tweets

Sign up for free to view the 2 tweets with 7 likes about this paper.

Reddit

  1. Halving the cost of QROM (3 points, 4 comments)