HAL will be down for maintenance from Friday, June 10 at 4pm through Monday, June 13 at 9am. More information
Skip to Main content Skip to Navigation
Conference papers

Comparing Static Analysis and Code Smells as Defect Predictors: An Empirical Study

Abstract : Background. Industrial software increasingly relies on open source software. Therefore, industrial practitioners need to evaluate the quality of a specific open source product they are considering for adoption. Automated tools greatly help assess open source software quality, by reducing the related costs, but do not provide perfectly reliable indications. Indications from tools can be used to restrict and focus manual code inspections, which are typically expensive and time-consuming, only on the code sections most likely to contain faults. Aim. We investigate the extent of the effectiveness of static analysis bug detectors by themselves and in combination with code smell detectors in guiding inspections. Method. We performed an empirical study, in which we used a bug detector (SpotBugs) and a code smell detector (JDeodorant). Results. Our results show that the selected bug detector is precise enough to justify inspecting the code it flags as possibly buggy. Applying the considered code smell detector makes predictions even more precise, but at the price of a rather low recall. Conclusions. Using the considered tools as inspection drivers proved quite useful. The relatively small size of our study does not allow us to draw universally valid conclusions, but our results should be applicable to source code of any kind, although they were obtained from open source code.
Document type :
Conference papers
Complete list of metadata

Contributor : Hal Ifip Connect in order to contact the contributor
Submitted on : Tuesday, June 8, 2021 - 4:26:13 PM
Last modification on : Tuesday, June 8, 2021 - 5:02:59 PM
Long-term archiving on: : Thursday, September 9, 2021 - 8:07:35 PM


Files produced by the author(s)


Distributed under a Creative Commons Attribution 4.0 International License



Luigi Lavazza, Sandro Morasca, Davide Tosi. Comparing Static Analysis and Code Smells as Defect Predictors: An Empirical Study. 17th IFIP International Conference on Open Source Systems (OSS), May 2021, Lathi/virtual event, Finland. pp.1-15, ⟨10.1007/978-3-030-75251-4_1⟩. ⟨hal-03254066⟩



Record views


Files downloads