
Our construction
Oblivious carry runways
The last major algorithmic optimization we apply is the use of oblivious carry runways. The basic problem addressed by runways is that, normally, a carry signal generated at the bottom of a register must propagate all the way to the top of the register. This process can be short-circuited by instead terminating the carry propagation into an appropriately constructed runway. Runways allow large additions to be performed piecewise, with each piece being worked on in parallel, by terminating carries into appropriately placed runways at the end of each piece.
As with the coset representation of modular integers, circuits using oblivious carry runways
approximate the original circuit instead of perfectly reproducing it. But, as we will discuss later,
increasing the runway length cpad exponentially suppresses the approximation error.
Figure 3: How to temporarily reduce oblivious carry runways to a single qubit, in preparation for being used as
the input factor in a multiply-add operation that must iterate over all qubits in the register. The multiply-add
should occur during the ". . . " section in the middle.
That being said, we will point out one optimization not mentioned in that paper which applies here. Note that, ultimately, each register we add carry runways to is going to either be measured or discarded. The last thing that would happen to these registers, before they were measured or discarded, is carry runway removal. However, the carry runway removal process is classical; it can be constructed out of Toffoli gates. As a result, the carry runway removal process does not need to be performed under superposition. The register qubits and runway qubits can simply be measured just before the runways would have been removed, and the runway removal process can be performed by classical post-processing of the measurements.
Note that we use cpad for both the runway length of oblivious carry runways and the padding length of the coset representation. We do this because they have identical error mechanisms, namely unwanted carries into the extra qubits. There is negligible benefit in suppressing one more than the other.
The major benefit of oblivious carry runways, compared to previous techniques for reducing
the depth of addition such as Draper et al.'s logarithmic depth carry-lookahead adder, is
that oblivious carry runways can be introduced gradually without incurring large overheads. The
Toffoli count and workspace overheads are linear in the number of pieces (where
is
the runway spacing) but only logarithmic in
.
For example, if you place a single runway at the midpoint of a 2048-qubit register, then the
number of qubits and the number of Toffolis needed to perform an addition will increase by a
couple percent but the depth of the additions is nearly halved.