Abstract
Researchers have recently achieved significant advances in deep learning (DL) techniques, which in turn has substantially advanced other research disciplines, such as natural language processing, image processing, speech recognition, and software engineering (SE). Various deep learning techniques have been successfully employed to facilitate software engineering tasks, including code generation, software refactoring, and fault localization. Many papers have also been presented in top conferences and journals, demonstrating the applications of deep learning techniques in resolving various software engineering tasks. However, although several surveys have provided overall pictures of the application of deep learning techniques in software engineering, they focus more on learning techniques—that is, what kind of deep learning techniques are employed and how deep models are trained or fine-tuned for software engineering tasks. We still lack surveys explaining the advances of subareas in software engineering driven by deep learning techniques, as well as challenges and opportunities in each subarea. To this end, in this paper, we present the first task-oriented survey on deep learning-based software engineering. It covers twelve major software engineering subareas significantly impacted by deep learning techniques. Such subareas spread out through the whole lifecycle of software development and maintenance, including requirements engineering, software development, testing, maintenance, and developer collaboration. As we believe that deep learning may provide an opportunity to revolutionize the whole discipline of software engineering, providing one survey covering as many subareas as possible in software engineering can help future research push forward the frontier of deep learning-based software engineering more systematically.
Introduction
Software engineering (SE) has traditionally been a labor-intensive discipline. While automated tools have existed for decades, they often relied on rigid, human-defined rules that struggled with the nuance of natural language requirements or the complex logic of software defects. With the explosion of open-source data on platforms like GitHub, researchers have turned to Deep Learning (DL) to automate these tasks.
This survey marks a significant shift in the field from manual, rule-based tools to "representation learning" models that can understand the complex, graph-like structures of source code and software artifacts. Unlike previous surveys that focus primarily on the underlying DL architectures (e.g., CNNs or Transformers), this work provides a task-oriented perspective, analyzing how DL is actually solving specific SE problems across the entire software lifecycle.
Methodology and Scope
The authors performed an extensive literature review of over 600 papers published between 2000 and 2023. The selection process focused on high-impact research presented at top-tier SE and AI venues.
By analyzing these venues, the survey identifies 12 distinct subareas where DL has made a measurable impact. These tasks range from the early stages of requirements gathering to the final stages of maintenance and developer collaboration.
A Task-Oriented Taxonomy
The core of this survey is organized around 12 major software engineering tasks. The distribution of research across these tasks reveals which areas have seen the most intensive DL application, such as Bug Finding and Program Repair, and which remain emerging frontiers, such as Software Refactoring.
Evolution of Software Artifact Representation
A critical finding of the survey is the evolution of how code is represented for DL models. Researchers have moved beyond treating code as simple text (sequences) to representing it through its structural logic:
- Abstract Syntax Trees (ASTs): Capturing the hierarchical structure of code.
- Control Flow Graphs (CFGs): Mapping the execution paths within a program.
- Program Dependency Graphs (PDGs): Modeling the data and control dependencies between different parts of the code.
This shift allows models to capture the semantic logic of software rather than just its lexical vocabulary.
Key Insights and Benchmarks
- The "Naturalness" of Code: A foundational insight is that code, despite being formal logic, follows repetitive and predictable patterns similar to natural language. This "naturalness" is why Large Language Models (LLMs) have proven so effective at SE tasks.
- Task Duality: Many SE tasks are "duals" (e.g., code-to-summary vs. summary-to-code). Training models on both tasks simultaneously—known as dual learning—has been shown to significantly boost performance.
- Standardized Benchmarks: The survey highlights essential datasets that have accelerated progress, including CodeXGLUE for code intelligence, Defects4J for fault localization, and BigCloneBench for clone detection.
Current Challenges and Future Directions
Despite rapid progress, several critical bottlenecks remain:
- Interpretability (The Black Box Problem): Developers are often hesitant to trust DL-based tools that cannot explain why a specific piece of code is flagged as buggy.
- Hallucination and Security: LLMs can generate code that appears correct but contains subtle security vulnerabilities or non-existent API calls.
- Data Scarcity in Requirements: While code is abundant, high-quality requirements documents are often proprietary, leading to a lack of transparency and data for Requirements Engineering tasks.
- Generalization: Most models are optimized for popular languages like Java or Python, leaving a gap for legacy or low-resource programming languages.
Conclusion
The integration of Deep Learning into Software Engineering is not merely an incremental improvement but a potential revolution. The future of the field lies in the synergy between AI4SE (using AI to build better software) and SE4AI (using SE principles to build more robust AI), leading toward self-healing and more reliable software systems.
Summary updated