arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2311.17705cs.SE
收藏

Q-PAC:量子缺陷修复模式的自动化检测

Q-PAC: Automated Detection of Quantum Bug-Fix Patterns

Pranav K. Nayak, Krishn V. Kher, M. Bharat Chandra, M. V. Panduranga Rao, Lei Zhang

AI总结:

本文提出Q-PAC自动化框架,利用抽象语法树、语法过滤器和语义检查在IBM Qiskit量子代码中检测缺陷修复模式,实验验证其有效性,并作为Q-Repair研究议程的第一阶段推动量子软件质量提升。

摘要:

背景:过去在经典软件背景下已经对缺陷修复模式检测进行了研究。然而,尽管量子软件正在快速发展,文献中仍然缺乏用于识别、分析和检测缺陷修复模式的自动化方法和工具。据我们所知,我们先前发表在SEKE'23上的工作首次利用经典技术来检测量子代码中的缺陷修复模式。目标:为了扩展我们之前的工作,我们提出了一个研究议程(Q-Repair),包括一系列测试和调试方法,以提高量子软件的质量。最终目标是利用机器学习技术自动预测现有量子缺陷的修复模式。方法:作为该议程第一阶段的一部分,我们扩展了初步研究,并提出了一个更全面的自动化框架,称为Q-PAC,用于检测IBM Qiskit量子代码中的缺陷修复模式。在该框架中,我们使用抽象语法树、语法过滤器和语义检查开发了七个缺陷修复模式检测器。结果:为了演示我们的方法,我们使用真实世界和手工构建的缺陷与修复示例,在各种量子缺陷修复模式上运行Q-PAC。实验结果表明,Q-PAC能够有效识别IBM Qiskit中的缺陷修复模式。结论:我们希望我们对量子缺陷修复检测的初步研究能够引起研究人员和从业者对量子软件工程的关注。因此,我们还在GitHub上将Q-PAC作为开源软件发布。我们希望鼓励其他研究人员致力于诸如Q-Repair等研究方向,以提高量子编程的质量。

英文摘要:

Context: Bug-fix pattern detection has been investigated in the past in the context of classical software. However, while quantum software is developing rapidly, the literature still lacks automated methods and tools to identify, analyze, and detect bug-fix patterns. To the best of our knowledge, our work previously published in SEKE'23 was the first to leverage classical techniques to detect bug-fix patterns in quantum code. Objective: To extend our previous effort, we present a research agenda (Q-Repair), including a series of testing and debugging methodologies, to improve the quality of quantum software. The ultimate goal is to utilize machine learning techniques to automatically predict fix patterns for existing quantum bugs. Method: As part of the first stage of the agenda, we extend our initial study and propose a more comprehensive automated framework, called Q-PAC, for detecting bug-fix patterns in IBM Qiskit quantum code. In the framework, we develop seven bug-fix pattern detectors using abstract syntax trees, syntactic filters, and semantic checks. Results: To demonstrate our method, we run Q-PAC on a variety of quantum bug-fix patterns using both real-world and handcrafted examples of bugs and fixes. The experimental results show that Q-PAC can effectively identify bug-fix patterns in IBM Qiskit. Conclusion: We hope our initial study on quantum bug-fix detection can bring awareness of quantum software engineering to both researchers and practitioners. Thus, we also publish Q-PAC as an open-source software on GitHub. We would like to encourage other researchers to work on research directions (such as Q-Repair) to improve the quality of the quantum programming.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑