arXiv:2609.33255
NxM-Version Programming for Quantum Software: High-Level Components across Frameworks and Engines
Neilson Carlos Leite Ramalho, Higor Amario de Souza, Anthony Accioly, Valter Vieira de Camargo, Marcos Lordello Chaim
Abstract
Quantum computing has in recent years evolved from a purely theoretical field to an active area in both academia and industry. As a result, Quantum Software Engineering has emerged as an area that aims to organize the process of building, testing, and running quantum software. However, writing quantum software still requires programming with quantum gates and qubits, as well as knowledge specific to quantum software frameworks such as Qiskit, Cirq, Qrisp, pyQuil and PennyLane, each of which reaches quantum hardware through its own toolchain. We present Quanifi, which packages the high-level routines of these frameworks as components on the Apache NiFi dataflow canvas. The components exchange circuits as OpenQASM 2.0, so a circuit built by one framework can be executed by another. This allows for two types of redundancy: several frameworks implement the same algorithm, and several engines (simulators or real hardware) execute the same circuit. We describe N$\times$M program execution, which crosses the two: a single NiFi flow runs each of the $N$ implementations on each of the $M$ engines, and because every result is labelled with its implementation and its engine, a disagreement can be linked to an implementation, to an engine, or to a single implementation-engine pair. We ran Grover's algorithm built by three frameworks on three quantum computers from IBM, IQM and Quantum Inspire, and a matrix of three adder builders on one IQM device reached through two routes. N$\times$M execution helped us discover three real defects: an incorrect gate-set declaration in the Quantum Inspire adapter, execution consistent with negated $R_x$ angles on Tuna-17, and circuit modification through Open Quantum. The latter two returned wrong answers without reporting an error. We reported all three defects and Open Quantum's provider confirmed and fixed its QASM parsing defect.
AI Summary
The paper asks how to compose high-level quantum routines across software frameworks and use implementation and execution diversity to detect faults. Quanifi wraps five frameworks in Apache NiFi, providing 108 visual-dataflow processors and OpenQASM 2.0 interchange. Its $N\times M$ execution scheme runs each of $N$ implementations on each of $M$ engines, retaining provenance to localize disagreements to builders, engines, or particular pairs. The evaluation runs three Grover builders on IBM, IQM, and Quantum Inspire devices, using two- and four-qubit cases with 1,024 shots per circuit. Including readout controls and duplicate circuits, each batch contains 20 circuits per device. After workarounds, two-qubit success probabilities are 0.92–0.96; four-qubit results are near random guessing on IQM and Quantum Inspire, with no consistent gate-count ordering across devices and calibrations. Follow-up probes identify execution consistent with negated $R_x$ angles on Tuna-17 and an adapter advertising unsupported gates. A second comparison sends identical adder and gate-test files to IQM Garnet directly and through Open Quantum, at 512 shots each. Some service-mediated runs produce wrong outcomes with probabilities of 0.97–1.00 while direct runs succeed. The provider confirms and fixes a QASM parsing defect; the two Quantum Inspire reports remain unconfirmed. Limitations include small circuits, known-answer checks, a shared Qiskit transpiler, incomplete calibration diversity, and interchange-semantic differences. General fault-detection performance and accessibility are not evaluated; financial cost and latency are not measured. Execution cost scales as $NM$, plus controls.
Written by gpt-6.1-sol from the paper's full text. Automated: it can be wrong.