QCEC might unexpectedly segfault when circuits to not contain measurements (that allow to infer the output permutation).
The observed exception is
libc++abi: terminating with uncaught exception of type std::invalid_argument: Alternating checker must not be used for circuits that both have non-idle ancillary qubits. Use the construction checker instead.
However, the circuits in question do not contain non-idle ancillaries, which indicates that one of the checks does not fully support the absence of measurements. Should be fairly easy to fix.
Expected behavior
QCEC should not segfault on circuits compiled without measurements at the end of the circuit.
How to Reproduce
Run
from mqt import qcec
from qiskit import QuantumCircuit, transpile
from qiskit.providers.fake_provider import FakeAthens
circ = QuantumCircuit(1)
circ.x(0)
circTransp = transpile(circ, backend=FakeAthens())
result = qcec.verify(circ,circTransp)
mqt.qcec version
latest
OS
any
Python version
any
C++ compiler
any
Additional environment information
No response
Description
QCEC might unexpectedly segfault when circuits to not contain measurements (that allow to infer the output permutation). The observed exception is
However, the circuits in question do not contain non-idle ancillaries, which indicates that one of the checks does not fully support the absence of measurements. Should be fairly easy to fix.
Expected behavior
QCEC should not segfault on circuits compiled without measurements at the end of the circuit.
How to Reproduce
Run