TL;DR
This paper introduces DASCOT, a novel compiler for surface code quantum computers that significantly improves the efficiency of quantum computations by intelligently mapping logical qubits to physical qubits and routing operations. By exploiting the dependency structure of quantum circuits, DASCOT achieves near-optimal compilation, minimizing execution time and enabling more complex quantum algorithms.
What Problem Does This Paper Address?
Quantum computers promise revolutionary advancements, but they are currently plagued by errors. Surface codes are a leading approach to error correction, encoding logical qubits using a grid of physical qubits. However, compiling quantum circuits for these architectures is a complex challenge known as the Surface Code Mapping and Routing (SCMR) problem. This problem involves two key tasks: mapping logical qubits to physical locations on the device and routing the communication paths for two-qubit gates. Inefficient compilation can lead to significantly longer execution times, increasing the probability of errors and limiting the complexity of algorithms that can be run. Existing compilers often struggle with optimizing for execution time, handling all types of gates (especially T gates), and adapting to various hardware architectures. This paper tackles the SCMR problem with the goal of minimizing the total execution time for fault-tolerant quantum computers.
Methods
DASCOT employs a two-stage approach: dependency-aware mapping and dependency-aware routing, both leveraging simulated annealing for optimization.
- Dependency-Aware Mapping: Instead of treating all qubit interactions equally, DASCOT constructs a "layered interaction graph." This graph captures the dependency structure of the circuit, allowing the compiler to prioritize mappings that minimize conflicts between gates that must be executed sequentially. This is a departure from previous methods that often used a "flattened" view of interactions.
- Dependency-Aware Routing: This stage focuses on optimizing the order in which gates are routed within a time step. DASCOT formulates this as a discrete optimization problem, searching for the routing order that maximizes progress towards circuit execution. It prioritizes "critical" gates – those that unlock deeper layers of the circuit – to avoid creating long execution tails. Simulated annealing is used to explore the vast space of possible routing orders.
- Simulated Annealing: This classic optimization algorithm is used in both mapping and routing to find near-optimal solutions for computationally hard problems. It allows for a trade-off between computation time and solution quality.
- SAT-Based Optimal Baseline: For small circuits, the authors developed an optimal solver using SAT encoding to provide a benchmark for evaluating the performance of their approximate DASCOT algorithm.
Datasets
The authors evaluated DASCOT on a benchmark suite of 232 application circuits, including those from RevLib, Quipper, and ScaffoldCC. They also extended this suite with implementations of major quantum algorithms like Shor's Algorithm, Quantum Fourier Transform (QFT), QAOA, and Grover's Algorithm. Additionally, they generated synthetic "dense" and "low-density" circuits to specifically test the impact of circuit density.
Key Insights and Ideas
- Dependency is Key: The most crucial insight is that understanding the dependency structure between quantum gates is paramount for efficient compilation. Gates that logically depend on each other cannot be executed in parallel, and this constraint must inform both mapping and routing decisions.
- Layered Interactions Matter: Treating all qubit interactions equally is suboptimal. By considering interactions within specific "layers" of a circuit (groups of gates that can be executed in parallel), DASCOT can make better mapping choices that avoid future routing conflicts.
- Routing Order is Critical: The order in which gates are routed within a time step significantly impacts the overall execution time. Prioritizing critical gates and exploring different routing orders is more effective than simple greedy approaches.
- Architecture Flexibility: DASCOT is designed to be flexible and support various surface code architectures, from sparse to compact layouts, acknowledging that different architectures present different trade-offs between qubit footprint and execution time.
Key Results
- Outperforms Prior Work: DASCOT matches or outperforms Autobraid (a state-of-the-art SCMR algorithm) on 84% of benchmarks, with significant gains on dense circuits, including up to a 31% improvement on Quantum Fourier Transform circuits.
- Near-Optimal Solutions: For circuits where an optimal solution could be computed (69 cases), DASCOT solutions were within 25% of optimal for all but 5 instances.
- Scalability: DASCOT can handle circuits with thousands of gates within minutes and can be tuned for different optimality/scalability trade-offs. It can compile Bernstein-Vazirani circuits with up to 10,000 qubits and QFT circuits up to 200 qubits.
- Ablation Study: Both the dependency-aware mapping and routing components contribute significantly to DASCOT's performance. The routing optimization, in particular, yields consistent gains, improving results on 90% of circuits by an average of 6%.
Limitations and Future Work
- NP-Completeness: The SCMR problem is NP-complete, meaning that finding a truly optimal solution for large circuits is computationally infeasible. DASCOT provides near-optimal solutions.
- Heterogeneous Architectures: The authors plan to extend their model to support heterogeneous multi-chip fault-tolerant quantum architectures, which present more nuanced challenges as not all CNOT gates are equivalent.
- SWAP Operations: While not explicitly handled, the authors note that SWAP operations (used to change qubit mappings) could potentially be incorporated, though they are expensive and might negate benefits.
- Limited Optimal Solutions: The SAT-based optimal solver could only find solutions for a limited number of circuits due to time and memory constraints.
Summary updated