FPGA-Based Real-Time Quantum Error Correction for Shor and Steane Codes
Nasir Ali Nasir Ali
Abstract
Abstract Quantum error correction (QEC) must eventually operate inside the real-timecontrol loop of a quantum processor, where a decoding decision must be avail-able within the coherence budget of the ancilla qubits—typically under onemicrosecond for superconducting devices. Software decoders running on CPUsor GPUs achieve throughputs of at most a few hundred thousand correctionsper second, which falls orders of magnitude short of this requirement. Thispaper presents a family of three monolithic QEC decoder kernels implementedin Vitis HLS and deployed on the Xilinx Alveo U55C FPGA: a 3-bit repetitioncode as a pedagogical warm-up, the full nine-qubit Shor [[9, 1, 3]] code, andthe seven-qubit Steane [[7, 1, 3]] CSS code. All three kernels operate exclusivelyover the AXI-Lite control bus—no high-bandwidth memory is required—andexecute as combinational pipelines with initiation interval II = 1 at 300 MHz,yielding 300 million corrections per second per compute unit. The Shor kerneluses a 256-entry BRAM-backed decoder look-up table (LUT), achieves an HLS-estimated critical-path delay of 2.318 ns against a 3.33 ns target, and consumes1 BRAM18K, 228 LUT6, 190 flip-flops, and zero DSPs in a single SLR. TheSteane kernel integrates three independently selectable decoder architectures inone kernel: a BRAM LUT, a combinational minimum-weight perfect matching(MWPM) solver, and a one-round union-find (UF) cluster decoder; its criticalpath is 1.941 ns. A complete software mirror of each hardware decoder, bit-exact with the FPGA output, is provided for host-side correctness verification.A 27/27 self-test against all single-qubit Pauli errors confirms the Shor decoder,and 21/21 confirms all three Steane decoder modes. Monte Carlo sweeps overthe single-Pauli and IID-depolarising error models, for 105 shots per point, showlogical error rates well below the break-even diagonal for both codes, with LUT,MWPM, and UF decoders producing statistically identical curves for the Steanecode under IID noise with p ≤ 0.10. The entire QEC pipeline, including syn-drome extraction and logical-error readout, fits in under 0.02% of the U55C’s user fabric, leaving the remaining capacity free for co-hosting the companion 30-qubit statevector simulator kernel or for replication of up to 20 identical QECcompute units on a single card.