Problem Statement
Quantum LDPC codes such as the bivariate bicycle codes of Bravyi et al. store many logical qubits in few physical qubits, but they are only useful if their syndromes can be decoded accurately and fast enough. The problem is to find a decoder that, for general quantum LDPC codes under circuit-level noise, (i) reaches logical error rates close to those of an optimal decoder, (ii) processes each round of syndrome data in less time than the hardware takes to produce it, with a bounded worst case, and (iii) fits on classical hardware that can sit next to the quantum device. Recent papers name the lack of a practical decoder as a barrier to using these codes (Hillmann et al.) and describe reconciling accuracy with real-time constraints as the central difficulty (Qing et al., preprint).
Mathematical Formulation
A circuit with noise is summarised by a detector error model: a check matrix whose columns are fault mechanisms and whose rows are detectors, a logical-observable matrix , and prior probabilities . A fault configuration produces the syndrome and flips the observables by . A decoder maps to a guess . The optimal (maximum-likelihood coset) decoder outputs
and its failure probability is the benchmark. A practical decoder is judged by its failure probability per round relative to , by its time per round relative to the syndrome cycle time , and by its worst-case latency.
Consider a stabilizer circuit that repeatedly measures the checks of a code.
A detector is a set of measurement outcomes whose parity is the same in every noiseless run of the circuit. Typical detectors compare the outcome of one check in two consecutive rounds. A logical observable is a set of measurement outcomes whose parity equals the outcome of a logical measurement.
A detector error model with detectors, observables and error mechanisms consists of
- probabilities ;
- a matrix , where when mechanism flips detector ;
- a matrix , where when mechanism flips observable .
The model asserts that an error is a vector whose entries are independent with , that the observed detection events are , and that the logical observables are flipped by . A decoder receives and outputs a prediction of .
The model is graph-like when every column of has weight 1 or 2. It is then drawn as a decoding graph: one vertex per detector, one extra boundary vertex, and one edge per mechanism joining the two detectors it flips, or the detector and the boundary. With columns of larger weight the model is a decoding hypergraph. Under circuit noise the graph has one layer of vertices per round of syndrome extraction; edges inside a layer are data-qubit errors, edges between consecutive layers are measurement errors, and diagonal edges come from faults in the middle of an extraction circuit. This space-time picture goes back to Dennis, Kitaev, Landahl and Preskill; the file format and the automatic derivation from a circuit are those of Stim.
- Stabilizer circuits with Pauli noise, so that each fault flips a fixed set of measurement outcomes.
- Error mechanisms are treated as independent; correlated mechanisms have to be listed as single mechanisms with their joint effect.
Exact optimal decoding is computationally hard in general:
Consider the two problems of degenerate maximum-likelihood decoding: given the generators of a stabilizer code on qubits and a syndrome, output (i) a most likely error with that syndrome, or (ii) an element of a most likely coset of the stabilizer group.
- Hsieh and Le Gall (2011). For the Pauli channel in which every qubit independently suffers an error with probability and a error with probability , where , problems (i) and (ii) are both NP-hard. In particular, taking degeneracy into account does not make decoding easier in the worst case.
- Kuo and Lu (2020). For the depolarizing channel, where the and parts of an error are correlated, finding a most likely error and finding a correction that minimises the probability of a decoding error are NP-hard. Bounded-distance decoding of stabilizer codes is NP-hard for every channel model.
Both proofs are polynomial-time reductions from decoding problems for classical binary linear codes, whose NP-completeness is due to Berlekamp, McEliece and van Tilborg. In the reduction of Hsieh and Le Gall a classical parity-check matrix is embedded in a stabilizer code so that, for the constructed instances, the probability of a coset factorises and a most likely coset reveals a minimum-weight solution of the classical problem. Problem (ii) is in fact harder than NP-hard: see the #P-completeness theorem.
- Worst case over all stabilizer codes, specified by their generators, and over all syndromes. Nothing is implied for a particular family such as surface codes.
- Memoryless Pauli noise with a fixed error rate below , and perfect syndrome measurement.
If decoding is slower than syndrome generation, a backlog builds up:
Let be the wall-clock time for which syndrome data have accumulated, undecoded, when the -th decoder-dependent operation is reached. Decoding that backlog takes . The quantum computer cannot idle without protection, so it keeps producing syndrome data during the wait, and at the next such operation the undecoded data cover at least . Hence and . For the running time grows exponentially in the number of decoder-dependent operations; for the backlog shrinks geometrically and the decoder keeps up. The argument is given by Terhal, and Skoric et al. show that decoding overlapping windows in parallel removes the constraint on a single decoder's speed.
- Syndrome data are generated at a constant rate and decoded sequentially at a constant rate .
- The computation contains operations, such as the Clifford correction that follows a magic-state injection, that cannot start until all earlier syndrome data have been decoded; error correction continues while the computation waits.
Background
For the surface code, matching-based decoders are fast and accurate because each fault flips at most two detectors per basis. Quantum LDPC codes lack this structure: under circuit noise their detector error models have high-weight columns and many short cycles, and the codes are highly degenerate. Plain belief propagation then often fails to converge (Poulin and Chung). Panteleev and Kalachev adapted ordered-statistics post-processing (Fossorier and Lin) to quantum codes, and BP+OSD became the general-purpose standard (Roffe et al.); the bivariate bicycle memory experiments of Bravyi et al. used it.
Input and output. A check matrix , prior probabilities and a syndrome in the column space of . The output is a vector with .
Stage 1: belief propagation. Messages are exchanged along the edges of the Tanner graph of for a fixed number of iterations. With log-likelihood ratios , the check-to-variable message of the sum-product rule is
and the posterior estimate for mechanism is . If the hard decision satisfies , it is returned.
Stage 2: ordered-statistics decoding. Otherwise order the columns of from most to least likely to be in error (increasing ) and, going through them in that order, select a maximal linearly independent set of columns. Order-0 OSD returns the unique solution of with outside . Higher orders also try low-weight patterns on some columns outside , solve for each time, and keep the candidate of largest prior probability. The method adapts the classical algorithm of Fossorier and Lin and was introduced for quantum codes by Panteleev and Kalachev.
Complexity. Each belief-propagation iteration costs time proportional to the number of non-zero entries of . Stage 2 is Gaussian elimination, bit operations in the worst case, and dominates when it is invoked.
What it is exact for. Sum-product marginals are exact when the Tanner graph is a tree; the Tanner graphs of quantum codes are generally loopy (Poulin and Chung). OSD guarantees that the output reproduces the syndrome, not that it is the most likely error or lies in the most likely coset. The decoder is a heuristic whose accuracy is established numerically.
Accuracy. Post-processing improves the logical error rate of plain belief propagation on quantum LDPC codes by several orders of magnitude in the examples of Panteleev and Kalachev. Roffe et al. find thresholds for several families of hypergraph product codes and for the toric code. BP+OSD on the circuit-level hypergraph is the decoder used to establish the threshold of the bivariate bicycle codes.
- A check matrix of an error model with independent mechanisms and prior probabilities ; no restriction on column weight.
Significance
Decoding is on the critical path of every logical operation whose next step depends on a measurement outcome. A decoder that is accurate but slow forfeits the overhead savings that make quantum LDPC codes attractive; a fast but inaccurate decoder lowers the effective distance.
Why It Remains Difficult
- Hardness. Optimal decoding is NP-hard, and its degenerate version #P-complete, in the worst case, so any efficient decoder is a heuristic whose gap to optimal must be measured.
- Cubic post-processing. OSD needs Gaussian elimination on a matrix with as many columns as fault mechanisms; this dominates run time and is hard to parallelise (Wolanski and Barber).
- BP failure modes. Short cycles and degeneracy cause oscillations and trapping sets; fixes must be found empirically for each code family (Müller et al., preprint).
- Model mismatch. Correlated noise can change logical error rates by orders of magnitude and reorder decoders even when marginal error rates are exact (Dangi and Chatterjee, preprint).
- Throughput and latency. The decoder must keep pace with the syndrome stream, or the wait before feed-forward operations grows exponentially (Terhal); windowed schemes trade latency for throughput (Skoric et al.), and slow outlier instances matter as well as the mean.
Assumptions
Most benchmarks use uniform circuit-level depolarising noise, a fixed syndrome extraction circuit, and a memory experiment (no logical gates). Decoding during logical operations (surgery, gate gadgets) produces different detector error models and is less studied.
Known Results
- BP+OSD with combination sweep is the accuracy reference for bivariate bicycle codes (Bravyi et al.).
- Ambiguity clustering splits the problem after BP into independent clusters; at 0.3% circuit noise it is reported up to 27 times faster than BP+OSD at matched accuracy, decoding the 144-qubit gross code in 135 µs per round on an M2 CPU (Wolanski and Barber, preprint).
- Localized statistics decoding (BP+LSD) solves local regions in parallel and matches state-of-the-art accuracy with lower run-time complexity below threshold (Hillmann et al.).
- Relay-BP chains BP runs with disordered, partly negative memory strengths and is reported to outperform BP+OSD with combination sweep on bivariate bicycle codes while remaining a pure message-passing algorithm suited to FPGA or ASIC (Müller et al., preprint).
- 2025–2026 follow-ups (preprints). Syndrome preprocessing speeds up BP+OSD by about 10 times and Relay-BP and BP+LSD by more than 2 times on the code at low error rates (Fan et al.). Dithered BP reports accuracy comparable to Relay-BP with fewer multiplications (Cai et al.). An FPGA ensemble of min-sum decoders for a code reaches BP+OSD accuracy with one core and Relay-BP accuracy with three, with average latency 5.1 µs and worst case 97.9 µs at when BP is capped at 30 iterations (Kell et al.). SCOPE reports a logical error rate of for the code at and a register-transfer-level BP core with 173.8 ns mean latency at (Qing et al.).
To our knowledge no decoder has yet been shown, in peer-reviewed work, to be both within a small factor of optimal and real-time with bounded worst-case latency for a family of quantum LDPC codes of growing distance.
Existing Approaches
BP with post-processing (OSD, LSD, clustering); BP with memory, damping or randomisation (Relay-BP, dithering, ensembles); sliding-window and parallel-window schemes for streaming (Skoric et al.); hardware implementations on FPGA and ASIC (Battistel et al.).
Current Limitations
Comparisons use different codes, noise models, shot counts and hardware, so reported speed-ups are hard to compare. Among the papers cited here, mean latency is reported more often than worst-case latency, and most benchmarks are memory experiments on a few fixed codes, often the code, rather than families of growing distance or logical operations.
Possible Research Directions
- Estimate for small bivariate bicycle codes (for example with tensor networks or exhaustive coset sums) to measure how far heuristics are from optimal.
- Decoders robust to correlated and drifting noise, or that learn priors on line.
- Decoders for the detector error models of qLDPC surgery and gate gadgets.
- Provable latency bounds for message-passing decoders.
Required Knowledge
Quantum decoders, quantum LDPC codes, fault-tolerant quantum computing, classical belief propagation and ordered-statistics decoding.
Required Computational Resources
A workstation running Stim and open-source BP decoders can reproduce memory curves at in hours. Low logical error rates need or more shots per point. Latency claims need FPGA or ASIC tool chains.
Suggested Experiments
- Generate the detector error model of the bivariate bicycle memory circuit with Stim and decode with BP+OSD and plain BP; record logical error per round and wall-clock time per round, including the 99.9th percentile.
- Add one modern decoder (BP+LSD or a Relay-BP implementation) and compare on the same shots.
- Repeat with a correlated-noise model to test robustness.
Baseline Methods
BP+OSD with combination sweep; BP+LSD; Relay-BP; for surface-code sanity checks, minimum-weight perfect matching and belief-matching (Higgott et al.).
Evaluation Metrics
Logical error rate per round at fixed physical error rate; ratio to the best known decoder (or to where computable); mean and tail decoding time per round relative to the syndrome cycle; hardware resources (cores, FPGA area, power).
Success Criteria
Solved would mean: a decoder for a broad class of quantum LDPC codes, with logical error rates within a small constant factor of optimal under circuit-level noise, whose worst-case time per round stays below the syndrome cycle time on hardware deployable next to the device, demonstrated for codes of increasing distance and during logical operations. Partial progress: closing the accuracy gap to BP+OSD at microsecond latency, which several 2025–2026 preprints report for specific codes.