Mäntylä Bad Smells in Software – a Taxonomy and an Empirical Study

In this work, the bad code smells are studied empirically and their relationship to source code metrics is evaluated. This work also presents an initial taxonomy for the bad code smell, which improves their understandability and feasibility The bad code smells, presented by Martin Fowler and Kent Beck, are dissatisfactory structures in the source code of software that decrease software quality by making it less maintainable. The maintainability of software is important, because it is one of the factors affecting the cost of the future development activities. The literature study looks at the concept of software maintainability, discusses how software maintainability can be measured, and provides motivation and migration techniques to achieve more maintainable software. Based on the literature study, this work proposes a taxonomy for the bad code smells and evaluates the measurability of each bad code smell with source code metrics. A survey is used to collect the developers' opinions on the existence of bad code smells in particular software modules. The results of this survey show that the developers' opinions on a particular smell in a particular software module are not very uniform. The survey also provides more support to the theoretical taxonomy by showing that there are many strong correlations within the taxonomy's categories. This study also compares the results of the smell survey to the source code metrics collected with automatic tools. The results show that developers' evaluations of the bad code smells do not correlate with the actual source code metrics. This means that the smell evaluations from developers are not very reliable and that there is a need for automatic smell measurement.

[1]  W. Royce Managing the development of large software systems: concepts and techniques , 2021, ICSE '87.

[2]  Anas N. Al-Rabadi,et al.  A comparison of modified reconstructability analysis and Ashenhurst‐Curtis decomposition of Boolean functions , 2004 .

[3]  E. Burton Swanson,et al.  The dimensions of maintenance , 1976, ICSE '76.

[4]  Meir M. Lehman,et al.  On understanding laws, evolution, and conservation in the large-program life cycle , 1984, J. Syst. Softw..

[5]  G. D. Frewin,et al.  M.H. Halstead's Software Science - a critical examination , 1982, ICSE '82.

[6]  Paul Rook,et al.  Controlling software projects , 1986, Softw. Eng. J..

[7]  Dennis G. Kafura,et al.  The Use of Software Complexity Metrics in Software Maintenance , 1987, IEEE Transactions on Software Engineering.

[8]  Robert B. Grady,et al.  Software Metrics: Establishing a Company-Wide Program , 1987 .

[9]  H. Dieter Rombach,et al.  A Controlled Expeniment on the Impact of Software Structure on Maintainability , 1987, IEEE Transactions on Software Engineering.

[10]  Elaine J. Weyuker,et al.  Evaluating Software Complexity Measures , 2010, IEEE Trans. Software Eng..

[11]  R. S. Arnold,et al.  Software restructuring , 1989, Proc. IEEE.

[12]  Robert L. Glass,et al.  Measuring software design quality , 1990 .

[13]  Chris F. Kemerer,et al.  Towards a metrics suite for object oriented design , 2017, OOPSLA '91.

[14]  Tetsuo Tamai,et al.  Software lifetime and its evolution process over generations , 1992, Proceedings Conference on Software Maintenance 1992.

[15]  Paul Oman,et al.  Constructing and testing software maintainability assessment models , 1993, [1993] Proceedings First International Software Metrics Symposium.

[16]  Sallie M. Henry,et al.  Object-oriented metrics that predict maintainability , 1993, J. Syst. Softw..

[17]  Sallie M. Henry,et al.  Maintenance metrics for the object oriented paradigm , 1993, [1993] Proceedings First International Software Metrics Symposium.

[18]  Paul W. Oman,et al.  Using metrics to evaluate software system maintainability , 1994, Computer.

[19]  Paul W. Oman,et al.  Using software maintainability models to track code health , 1994, Proceedings 1994 International Conference on Software Maintenance.

[20]  Robert B. Grady,et al.  Successfully applying software metrics , 1994, Computer.

[21]  Paul W. Oman,et al.  The application of software maintainability models in industrial software systems , 1995, J. Syst. Softw..

[22]  Stephen R. Schach,et al.  Object-oriented and classical software engineering , 1995 .

[23]  John W. Daly,et al.  Issues on the Object-Oriented Paradigm: A Questionnaire Survey , 1995 .

[24]  Harry M. Sneed,et al.  Planning the Reengineering of Legacy Systems , 1995, IEEE Softw..

[25]  N. V. Balasubramanian Object-oriented metrics , 1996, Proceedings 1996 Asia-Pacific Software Engineering Conference.

[26]  Victor R. Basili,et al.  A Validation of Object-Oriented Design Metrics as Quality Indicators , 1996, IEEE Trans. Software Eng..

[27]  Siu Leung Chung,et al.  An Economic Model to Estimate Software Rewriting and Replacement Times , 1996, IEEE Trans. Software Eng..

[28]  W. Stephen Adolph,et al.  Cash Cow in the Tar Pit: Reengineering a Legacy System , 1996, IEEE Softw..

[29]  Premkumar T. Devanbu,et al.  An Investigation into Coupling Measures for C++ , 1997, Proceedings of the (19th) International Conference on Software Engineering.

[30]  Michael A. Cusumano,et al.  Competing on internet time , 1998 .

[31]  Thomas J. Mowbray,et al.  AntiPatterns: Refactoring Software, Architectures, and Projects in Crisis , 1998 .

[32]  Structured Design , 1999, IBM Syst. J..

[33]  Lionel C. Briand,et al.  Investigating quality factors in object-oriented designs: an industrial case study , 1999, Proceedings of the 1999 International Conference on Software Engineering (IEEE Cat. No.99CB37002).

[34]  Katsuhisa Maruyama,et al.  Automatic method refactoring using weighted dependence graphs , 1999, Proceedings of the 1999 International Conference on Software Engineering (IEEE Cat. No.99CB37002).

[35]  Lionel C. Briand,et al.  A Unified Framework for Coupling Measurement in Object-Oriented Systems , 1999, IEEE Trans. Software Eng..

[36]  Michael A. Cusumano,et al.  Software Development on Internet Time , 1999, Computer.

[37]  Norman E. Fenton,et al.  Quantitative Analysis of Faults and Failures in a Complex Software System , 2000, IEEE Trans. Software Eng..

[38]  Ned Chapin,et al.  Do we know what preventive maintenance is? , 2000, Proceedings 2000 International Conference on Software Maintenance.

[39]  Philippe Kruchten,et al.  The Rational Unified Process: An Introduction, Second Edition , 2000 .

[40]  Keith H. Bennett,et al.  Software maintenance and evolution: a roadmap , 2000, ICSE '00.

[41]  Keith H. Bennett,et al.  A Staged Model for the Software Life Cycle , 2000, Computer.

[42]  Magdalena Balazinska,et al.  Advanced clone-analysis to support object-oriented system refactoring , 2000, Proceedings Seventh Working Conference on Reverse Engineering.

[43]  Harvey P. Siy,et al.  Predicting Fault Incidence Using Software Change History , 2000, IEEE Trans. Software Eng..

[44]  Carolyn B. Seaman,et al.  Practical Software Maintenance , 2000, J. Softw. Maintenance Res. Pract..

[45]  Kumaraswamy Ponnambalam,et al.  A maintainability model for industrial software systems using design level metrics , 2000, Proceedings Seventh Working Conference on Reverse Engineering.

[46]  Oscar Nierstrasz,et al.  Finding refactorings via change metrics , 2000, OOPSLA '00.

[47]  Javam C. Machado,et al.  The prediction of faulty classes using object-oriented design metrics , 2001, J. Syst. Softw..

[48]  Vojislav B. Misic,et al.  Cohesion is structural, coherence is functional: different views, different measures , 2001, Proceedings Seventh International Software Metrics Symposium.

[49]  William G. Griswold,et al.  Automated support for program refactoring using invariants , 2001, Proceedings IEEE International Conference on Software Maintenance. ICSM 2001.

[50]  Claus Lewerentz,et al.  Metrics Based Refactoring , 2001, CSMR.

[51]  Carl K. Chang,et al.  Measuring the intensity of object coupling in C++ programs , 2001, 25th Annual International Computer Software and Applications Conference. COMPSAC 2001.

[52]  D. Mancl Refactoring for software migration , 2001 .

[53]  Hausi A. Müller,et al.  Predicting fault-proneness using OO metrics. An industrial case study , 2002, Proceedings of the Sixth European Conference on Software Maintenance and Reengineering.

[54]  Emilia Mendes,et al.  Comprehension of object-oriented software cohesion: the empirical quagmire , 2002, Proceedings 10th International Workshop on Program Comprehension.

[55]  Alessandro Bianchi,et al.  Iterative Reengineering of Legacy Systems , 2003, IEEE Trans. Software Eng..

[56]  Vijay K. Vaishnavi,et al.  Predicting Maintenance Performance Using Object-Oriented Design Complexity Metrics , 2003, IEEE Trans. Software Eng..

[57]  Lionel C. Briand,et al.  A Unified Framework for Cohesion Measurement in Object-Oriented Systems , 2004, Empirical Software Engineering.

[58]  Lionel C. Briand,et al.  An Experimental Comparison of the Maintainability of Object-Oriented and Structured Design Documents , 2004, Empirical Software Engineering.

[59]  Joel Spolsky Painless Software Schedules , 2004 .

[60]  Jana Polgar,et al.  Object-Oriented Software Metrics , 2005, Encyclopedia of Information Science and Technology.