Source code optimization using equivalent mutants

Jorge López, Natalia Kushik, Nina Yevtushenko

Research output: Contribution to journalArticlepeer-review

Abstract

Context: A mutant is a program obtained by syntactically modifying a program's source code; an equivalent mutant is a mutant, which is functionally equivalent to the original program. Mutants are primarily used in mutation testing, and when deriving a test suite, obtaining an equivalent mutant is considered to be highly negative, although these equivalent mutants could be used for other purposes. Objective: We present an approach that considers equivalent mutants valuable, and utilizes them for source code optimization. Source code optimization enhances a program's source code preserving its behavior. Method: We showcase a procedure to achieve source code optimization based on equivalent mutants and discuss proper mutation operators. Results: Experimental evaluation with Java and C programs demonstrates the applicability of the proposed approach. Conclusion: An algorithmic approach for source code optimization using equivalent mutants is proposed. It is showcased that whenever applicable, the approach can outperform traditional compiler optimizations.

Original languageEnglish
Pages (from-to)138-141
Number of pages4
JournalInformation and Software Technology
Volume103
DOIs
Publication statusPublished - 1 Nov 2018
Externally publishedYes

Keywords

  • Mutation (software) testing
  • Program / code optimization

Fingerprint

Dive into the research topics of 'Source code optimization using equivalent mutants'. Together they form a unique fingerprint.

Cite this