arXiv:2609.04483cs.SESep 2026

Manuscript Offprint

arXiv:2609.04483

Integrating Crash Report Mining and LLMs for Bug Localization and Repair: An Industrial Report

Marcos Medeiros, Uirá Kulesza, Christoph Treude, Daniel Lucena, Rafael Gomes, Roberta Coelho, Eiji Adachi, Rodrigo Bonifacio

Marcos Medeiros*, Uirá Kulesza*, Christoph Treude†, Daniel Lucena*, Rafael Gomes*, Roberta Coelho*, Eiji Adachi*, Rodrigo Bonifacio‡

*Federal University of Rio Grande do Norte (Natal, Brazil)

Email: {marcosamm, rlucena.daniel, rafaggsique}@gmail.com, {uira, roberta}@dimap.ufrn.br, ejijadachi@imd.ufrn.br

†Singapore Management University (Singapore, Singapore)

Email: ctreude@smu.edu.sg

‡Federal University of Pernambuco (Recife, Brazil)

Email: rbonifacio@cin.ufpe.br

Abstract—Analyzing crash-report bugs in large-scale industrial software systems requires substantial maintenance effort, particularly in production environments where developers must handle large volumes of crash reports and source code artifacts to localize and fix their root causes. While recent studies have shown that Large Language Models (LLMs) can assist with maintenance tasks, little is known about their effectiveness in supporting developers in analyzing crash-report bugs and repairing bugs associated with groups of crash reports in industrial settings. To address this gap, we investigate whether integrating crash report mining techniques—specifically stack trace clustering and suspicious file and method ranking—with LLMs can support crash localization and repair in production environments. We conduct a retrospective evaluation of five LLMs under four prompt configurations. After that, we chose the best model to run on 38 crash bugs collected from two large Java enterprise systems. We further analyze the structural characteristics and explanatory patterns of LLM-generated responses and assess localization and repair effectiveness through manual validation. Our results show that the best-performing configuration localizes up to 71% and correctly repairs 52% of crash bugs on the full dataset. These findings provide empirical evidence that combining crash report mining with LLM-based repair can effectively support debugging activities in industrial maintenance workflows.

Index Terms—Software crash, Bug correlation, Bug localization, LLM, Bug fixing

I. INTRODUCTION

Crash reports and stack traces are widely used by developers to analyze system failures and support bug localization and resolution tasks [1]–[5]. However, as crash reports accumulate over time, large-scale analysis becomes increasingly challenging [1], [6]. For example, Firefox receives millions of crash reports every month [7], [8]. In practice, developers must manually inspect stack traces and navigate large codebases to identify the root cause of a crash, which becomes increasingly costly as the volume of crash reports grows. To reduce this effort, prior research has investigated crash report aggregation techniques and shown that they can support bug localization and repair activities [5], [9]–[22].

In parallel, the evolution and popularization of Large Language Models (LLMs) have enabled developers to leverage these systems for co-development and software quality assessment, particularly in program repair tasks [23], [24]. Recent studies have explored the application of artificial intelligence to several software engineering tasks and report promising results [25]–[33]. Despite these advances, prior work [25]–[27] indicates that LLMs require sufficient contextual information and guidance to effectively locate and fix crash bugs. However, providing unrestricted access to entire codebases is often impractical in industrial environments due to cost, confidentiality, and LLM context window limitations. Thus, a key challenge is how to provide LLMs with structured and prioritized contextual information that narrows the search space while preserving relevance to the failure.

Crash report mining techniques, such as stack trace clustering and suspicious file and method ranking, provide structured contextual information by identifying artifacts most likely associated with a crash. However, empirical studies conducted in industrial settings remain scarce [34], [35]. To the best of our knowledge, no previous work has systematically integrated crash mining with suspicious file and method ranking to provide structured contextual input to LLMs in a workflow validated on industrial production systems.

In this work, we present and empirically evaluate a pipeline that integrates crash report mining with LLMs to support crash bug localization and repair under realistic industrial constraints. The proposed workflow consists of three stages: crash report clustering, suspicious file and method ranking, and LLM-based patch suggestion. Our study focuses on large-scale web-based systems implemented using Java Enterprise technologies and adopts a retrospective evaluation to assess how effectively LLMs can locate and fix bugs from crash report data. Our findings reveal that LLMs frequently suggest plausible fixes, even though structural heterogeneity makes automated patch integration infeasible. Surprisingly, the most explanation-prone model achieved the best localization and repair accuracy, while the most prompt-compliant model underperformed. The main contributions are:

  • A novel approach that integrates crash report clustering and suspicious file and method ranking to provide structured contextual input for LLMs performing crash bug localization and repair.

  • An ablation-based evaluation on the impact of contextual information (stack traces, stack messages, and ranking information) on LLM-based crash localization and repair.

  • A validation of our approach that compares its ability to locate and fix crash root causes against developer

corrective commits used as ground truth, showing that combining crash report mining with LLM-based repair effectively supports debugging in an industrial context.

The remainder of this paper is organized as follows. Section II presents the proposed bug localization and fixing approach. Section III describes the target systems, LLM models, prompt combinations, evaluation metrics, and study procedures. Section IV presents and discusses the results, followed by threats to validity in Section V, related work in Section VI, and conclusions in Section VII.

References (44)