Paper
6 June 2024 Can large language model replace static analysis tools
Han Cui
Author Affiliations +
Proceedings Volume 13175, International Conference on Computer Network Security and Software Engineering (CNSSE 2024); 131751B (2024) https://doi.org/10.1117/12.3031920
Event: 4th International Conference on Computer Network Security and Software Engineering (CNSSE 2024), 2024, Sanya, China
Abstract
Static analysis tools are widely used to ensure code quality and security, especially in large software projects. Recently, the advent of Large Language Models (LLM), such as the Generative Pre-trained Transformer (GPT), seems to present a strong ability to handle tasks about static code analysis. This paper aims to answer the question, can large language model replace static analysis tools? We present an extensive evaluation of ChatGPT’s capabilities in identifying and analyzing issues detectable by three well-known Java static analysis tools: PMD, SpotBugs, and SonarQube. Through a series of experiments, we assess the performance of two versions of GPT, GPT-3.5 and GPT-4, across various categories of code issues. We conduct a detailed analysis of the experiment results and discuss the limitation of using ChatGPT to perform as a static analysis tool. The findings during our research suggest that while GPT, especially GPT-4 performs outstanding marks on the dataset we chose, it is improper to fully replace the static code analyzers at the time. Working as the supplementary of static code analyzers can be a nice way to enhance the code quality ensuring projects.
(2024) Published by SPIE. Downloading of the abstract is permitted for personal use only.
Han Cui "Can large language model replace static analysis tools", Proc. SPIE 13175, International Conference on Computer Network Security and Software Engineering (CNSSE 2024), 131751B (6 June 2024); https://doi.org/10.1117/12.3031920
Advertisement
Advertisement
RIGHTS & PERMISSIONS
Get copyright permission  Get copyright permission on Copyright Marketplace
KEYWORDS
Analytical research

Java

Artificial intelligence

Error analysis

Performance modeling

Software engineering

Computer programming

Back to Top