Automated Repair of C Programs Using Large Language Models
Not on the map. Why?
Abstract (arXiv)
This study explores the potential of Large Language Models (LLMs) in automating the repair of C programs. We present a framework that integrates spectrum-based fault localization (SBFL), runtime feedback, and Chain-of-Thought-structured prompting into an autonomous repair loop. Unlike prior approaches, our method explicitly combines statistical program analysis with LLM reasoning. The iterative repair cycle leverages a structured Chain-of-Thought (CoT) prompting approach, where the model reasons over failing tests, suspicious code regions, and prior patch outcomes, before generating new candidate patches. The model iteratively changes the code, evaluates the results, and incorporates reasoning from previous attempts into subsequent modifications, reducing repeated errors and clarifying why some bugs remain unresolved. Our evaluation spans 3,902 bugs from the Codeflaws benchmark, where our approach achieves 44.93% repair accuracy, representing a 3.61% absolute improvement over strong state-of-the-art APR baselines such as GPT-4 with CoT. This outcome highlights a practical pathway toward integrating statistical program analysis with generative AI in automated debugging.
Key facts. Cited by 2 papers in the map (data through 14 Oct 2026). First posted on arXiv 2 Sep 2025.
Builds on
No reference list yet.
Built on by
Citing papers per year: 2025: 1; 2026: 1.
2 papers.
Similar, not cited
Close in wording, no citation either way
- 2025Large Language Models for Fault Localization: An Empirical Study ↗
- 2026RGFL: Reasoning Guided Fault Localization for Automated Program Repair Using Large Language Models
- 2025T3: Multi-level Tree-based Automatic Program Repair with Large Language Models
- 2026Rethinking Automated Program Repair: The Impact of Bug Complexity, Fault Localization, and LLM Cost-efficiency
- 2025A Survey of LLM-based Automated Program Repair: Taxonomies, Design Paradigms, and Applications
- 2025The Art of Repair: Optimizing Iterative Program Repair with Instruction-Tuned Models
- 2025FeedbackEval: A Benchmark for Evaluating Large Language Models in Feedback-Driven Code Repair Tasks
- 2024Aligning the Objective of LLM-based Program Repair