透過混合式配對資料訓練 C 語言編譯錯誤修復器

Training a compile-error fixer with mixed bad-good pairs for the C language

檔案

日期

2023

類型

語言

英文

摘要

評估源代碼的質量通常涉及諸如檢測錯誤的編譯器之類的工具。 然而,缺乏可用於自動修復這些錯誤的強大商業工具。
近年來,硬件性能的快速增長使得深度學習技術能夠為各種NP完全[1]問題提供近似解決方案,包括自動程序修復。
這項研究的重點是構建一個“編譯器錯誤修復器”,這是一個相對更容易評估的自動化程序修復的子領域。 我們可以使用編譯器來確定我們的修復程序是否有效。
我們確定了這個問題的兩個主要挑戰:(1)源代碼的長度不可預測,(2)收集足夠數量的真實“錯誤修復”對。 為了應對這些挑戰,我們設計了一種混合方法,用於從產品線的內部代碼庫中收集(或生成)好壞對。 根據C代碼的長度是否超過某個閾值,我們採用兩套模型(完整代碼或分段代碼)來處理該問題。
最終,在現實世界的持續集成工作流程實踐中,我們實現了 28.4% 的編譯通過率。
Assessing the quality of source code typically involves tools like compilers that detect
errors. However, there is a lack of robust commercial tools available for automatically
fixing these errors.
In recent years, the rapid growth of hardware performance has enabled deep learn-
ing techniques to provide approximate solutions for various NP-complete[1] problems,
including automated program repair.
This research focuses on building a ”compiler error fixer,” a sub-domain of automated
program repair that is relatively easier to evaluate. We can use a compiler to determine
if our fixer is effective or not.
We identified two major challenges in this problem: (1) the unpredictable length of
source code, and (2) collecting a sufficient amount of real ”error-fix” pairs. To address
these challenges, we designed a mixed method for collecting (or generating) bad-good
pairs from in-house codebases of product lines. Based on whether the length of the C
code exceeds a certain threshold, we employed two sets of models (full code or segmented
code) to handle the problem.
Ultimately, in practice of real world continuous integration workflow, we achieved a
28.4% compile pass rate.
顯示完整詮釋資料 統計資料

引用此條目

Huang, P. (2023). Training a compile-error fixer with mixed bad-good pairs for the C language. https://thesis.lib.nycu.edu.tw/handle/20.500.14371/509

BibTeX RIS

引用文字依 APA 第 7 版格式自動產生,使用前請再核對。

分享

永久網址:https://thesis.lib.nycu.edu.tw/handle/20.500.14371/509