Relative phase toffoli's can be implemented using 4 T gates and T-depth 1 and can be used in place of Toffoli gates in cases where the Toffoli's appear in compute / uncompute pairs (eg: arithmetic circuits) and the relative phase cancels each other out. A useful example of relative phase Toffoli is the CCiX gate defined in https://arxiv.org/abs/1210.0974 as
Other examples of uses of relative phase toffoli's are given in https://arxiv.org/abs/1508.03273. This issue is to add a new leaf bloq for relative phase Toffoli and use it in higher level bloqs instead of the Toffoli gate.
Note that when compiling to a surface code layout, each of the 3 constructions have different costs and so it's important to clearly make the distinction between the 3 leaf bloqs in algorithms that can then be compiled down without ambiguity.
Relative phase toffoli's can be implemented using 4 T gates and T-depth 1 and can be used in place of Toffoli gates in cases where the Toffoli's appear in compute / uncompute pairs (eg: arithmetic circuits) and the relative phase cancels each other out. A useful example of relative phase Toffoli is the CCiX gate defined in https://arxiv.org/abs/1210.0974 as
Other examples of uses of relative phase toffoli's are given in https://arxiv.org/abs/1508.03273. This issue is to add a new leaf bloq for relative phase Toffoli and use it in higher level bloqs instead of the Toffoli gate.
Note that when compiling to a surface code layout, each of the 3 constructions have different costs and so it's important to clearly make the distinction between the 3 leaf bloqs in algorithms that can then be compiled down without ambiguity.