Specialising Software for Different Downstream Applications Using Genetic Improvement and Code Transplantation

Genetic improvement uses automated search to find improved versions of existing software. Genetic improvement has previously been concerned with improving a system with respect to all possible usage scenarios. In this paper, we show how genetic improvement can also be used to achieve specialisation to a specific set of usage scenarios. We use genetic improvement to evolve faster versions of a C++ program, a Boolean satisfiability solver called MiniSAT, specialising it for three different applications, each with their own characteristics. Our specialised solvers achieve between 4 and 36 percent execution time improvement, which is commensurate with efficiency gains achievable using human expert optimisation for the general solver. We also use genetic improvement to evolve faster versions of an image processing tool called ImageMagick, utilising code from GraphicsMagick, another image processing tool which was forked from it. We specialise the format conversion functionality to greyscale images and colour images only. Our specialised versions achieve up to 3 percent execution time improvement.

[1]  John A. Clark,et al.  Multi-objective Improvement of Software Using Co-evolution and Smart Seeding , 2008, SEAL.

[2]  Kalyanmoy Deb,et al.  Multi-objective code-smells detection using good and bad design examples , 2016, Software Quality Journal.

[3]  Enrique Alba,et al.  On the Application of SAT Solvers to the Test Suite Minimization Problem , 2012, SSBSE.

[4]  Steven David Prestwich,et al.  CNF Encodings , 2021, Handbook of Satisfiability.

[5]  Niklas Sörensson,et al.  An Extensible SAT-solver , 2003, SAT.

[6]  Fan Wu,et al.  Deep Parameter Optimisation , 2015, GECCO.

[7]  Frank Tip,et al.  Refactoring Java programs for flexible locking , 2011, 2011 33rd International Conference on Software Engineering (ICSE).

[8]  Aurora Trinidad Ramirez Pozo,et al.  Search Based Software Engineering: Review and analysis of the field in Brazil , 2013, J. Syst. Softw..

[9]  Mark Harman,et al.  Improving CUDA DNA Analysis Software with Genetic Programming , 2015, GECCO.

[10]  Bart Selman,et al.  Backdoors To Typical Case Complexity , 2003, IJCAI.

[11]  Erik Sandewall,et al.  A Partial Evaluator, and its Use as a Programming Tool , 1976, Artif. Intell..

[12]  Lionel C. Briand,et al.  A Systematic Review of the Application and Empirical Investigation of Search-Based Test Case Generation , 2010, IEEE Transactions on Software Engineering.

[13]  Matthew B. Dwyer,et al.  Using partial evaluation to enable verification of concurrent software , 1998, CSUR.

[14]  Tatsuhiro Tsuchiya,et al.  Constructing Test Sets for Pairwise Testing: A SAT-Based Approach , 2011, 2011 Second International Conference on Networking and Computing.

[15]  John R. Koza,et al.  Genetic programming - on the programming of computers by means of natural selection , 1993, Complex adaptive systems.

[16]  Mark Harman,et al.  Grow and Graft a Better CUDA pknotsRG for RNA Pseudoknot Free Energy Calculation , 2015, GECCO.

[17]  Mark Harman,et al.  Search Based Software Engineering: Techniques, Taxonomy, Tutorial , 2010, LASER Summer School.

[18]  Joao Marques-Silva Practical applications of Boolean Satisfiability , 2008, 2008 9th International Workshop on Discrete Event Systems.

[19]  Jason Lawrence,et al.  Genetic programming for shader simplification , 2011, ACM Trans. Graph..

[20]  Mark Harman,et al.  Applying Genetic Improvement to MiniSAT , 2013, SSBSE.

[21]  Charles Consel,et al.  Partial evaluation for software engineering , 1998, CSUR.

[22]  Yuanyuan Zhang,et al.  Search based software engineering for software product line engineering: a survey and directions for future work , 2014, SPLC.

[23]  Jeff Yu Lei,et al.  IPOG/IPOG‐D: efficient test generation for multi‐way combinatorial testing , 2008, Softw. Test. Verification Reliab..

[24]  Mikko Koivisto,et al.  Finding Efficient Circuits for Ensemble Computation , 2012, SAT.

[25]  Mohamed Wiem Mkaouer,et al.  High dimensional search-based software engineering: finding tradeoffs among 15 objectives for automating software refactoring using NSGA-III , 2014, GECCO.

[26]  Mark Harman,et al.  Grow and Serve: Growing Django Citation Services Using SBSE , 2015, SSBSE.

[27]  Anders Haraldsson,et al.  A partial evaluator, and its use for compiling iterative statements in LISP , 1978, POPL.

[28]  Mark Harman,et al.  Ieee Transactions on Evolutionary Computation 1 , 2022 .

[29]  Peter Sestoft,et al.  Partial evaluation and automatic program generation , 1993, Prentice Hall international series in computer science.

[30]  Günther Ruhe,et al.  Search Based Software Engineering , 2013, Lecture Notes in Computer Science.

[31]  Lori L. Pollock,et al.  SEEDS: a software engineer's energy-optimization decision support framework , 2014, ICSE.

[32]  Myra B. Cohen,et al.  Evaluating improvements to a meta-heuristic search for constrained interaction testing , 2011, Empirical Software Engineering.

[33]  David S. Johnson,et al.  Computers and Intractability: A Guide to the Theory of NP-Completeness , 1978 .

[34]  Inês Lynce,et al.  Conflict-Driven Clause Learning SAT Solvers , 2009, Handbook of Satisfiability.

[35]  Hareton K. N. Leung,et al.  A survey of combinatorial testing , 2011, CSUR.

[36]  Armando Tacchella,et al.  Theory and Applications of Satisfiability Testing , 2003, Lecture Notes in Computer Science.

[37]  Massimiliano Di Penta SBSE Meets Software Maintenance: Achievements and Open Problems , 2012, SSBSE.

[38]  Katsuro Inoue,et al.  Multi-Criteria Code Refactoring Using Search-Based Software Engineering , 2016, ACM Trans. Softw. Eng. Methodol..

[39]  Jürgen Giesl,et al.  SAT Solving for Termination Proofs with Recursive Path Orders and Dependency Pairs , 2012, Journal of Automated Reasoning.

[40]  John A. Clark,et al.  Searching for resource-efficient programs: low-power pseudorandom number generators , 2008, GECCO '08.

[41]  Michael L. Fredman,et al.  The AETG System: An Approach to Testing Based on Combinatiorial Design , 1997, IEEE Trans. Software Eng..

[42]  Zhendong Su,et al.  A study of the uniqueness of source code , 2010, FSE '10.

[43]  Katsumi Inoue,et al.  Generating Combinatorial Test Cases by Efficient SAT Encodings Suitable for CDCL SAT Solvers , 2010, LPAR.

[44]  Yuanyuan Zhang,et al.  Achievements, Open Problems and Challenges for Search Based Software Testing , 2015, 2015 IEEE 8th International Conference on Software Testing, Verification and Validation (ICST).

[45]  Myra B. Cohen,et al.  Efficiency and early fault detection with lower and higher strength combinatorial interaction testing , 2013, ESEC/FSE 2013.

[46]  William B. Langdon,et al.  Genetically Improved Software , 2015, Handbook of Genetic Programming Applications.

[47]  Katsuro Inoue,et al.  Search-based software library recommendation using multi-objective optimization , 2017, Inf. Softw. Technol..

[48]  Westley Weimer,et al.  Post-compiler software optimization for reducing energy , 2014, ASPLOS.

[49]  Phil McMinn,et al.  Search‐based software test data generation: a survey , 2004, Softw. Test. Verification Reliab..

[50]  Mark Harman,et al.  Babel Pidgin: SBSE Can Grow and Graft Entirely New Functionality into a Real World System , 2014, SSBSE.

[51]  Mark Harman,et al.  Why Source Code Analysis and Manipulation Will Always be Important , 2010, 2010 10th IEEE Working Conference on Source Code Analysis and Manipulation.

[52]  Sebastian Fischmeister,et al.  Impact of Community Structure on SAT Solver Performance , 2014, SAT.

[53]  Mark Harman,et al.  Search-Based Software Project Management , 2014, Software Project Management in a Changing World.

[54]  Dines Bjørner,et al.  Partial Evaluation and Mixed Computation , 1987 .

[55]  Claire Le Goues,et al.  GenProg: A Generic Method for Automatic Software Repair , 2012, IEEE Transactions on Software Engineering.

[56]  David A. Schmidt,et al.  The Essence of Computation , 2002 .

[57]  Mark Harman,et al.  The Oracle Problem in Software Testing: A Survey , 2015, IEEE Transactions on Software Engineering.

[58]  Alexander L. Wolf,et al.  Multiplicity computing: a vision of software engineering for next-generation computing platform applications , 2010, FoSER '10.

[59]  Claire Le Goues,et al.  A systematic study of automated program repair: Fixing 55 out of 105 bugs for $8 each , 2012, 2012 34th International Conference on Software Engineering (ICSE).

[60]  Neil D. Jones,et al.  Compiler generation by partial evaluation , 1989 .

[61]  Daniel Kroening,et al.  A Survey of Automated Techniques for Formal Software Verification , 2008, IEEE Transactions on Computer-Aided Design of Integrated Circuits and Systems.

[62]  Scott Draves Partial evaluation for media processing , 1998, CSUR.

[63]  Yuanyuan Zhang,et al.  Search Based Requirements Optimisation: Existing Work and Challenges , 2008, REFSQ.

[64]  Sergio Segura,et al.  Automated analysis of feature models 20 years later: A literature review , 2010, Inf. Syst..

[65]  Carsten Fuhs SAT-based Termination Analysis for Java Bytecode with AProVE ? , 2011 .

[66]  Mark Harman,et al.  Genetic programming for Reverse Engineering , 2013, 2013 20th Working Conference on Reverse Engineering (WCRE).

[67]  Riccardo Poli,et al.  A Field Guide to Genetic Programming , 2008 .

[68]  John A. Clark,et al.  The GISMOE challenge: constructing the pareto program surface using genetic programming to find better programs (keynote paper) , 2012, 2012 Proceedings of the 27th IEEE/ACM International Conference on Automated Software Engineering.

[69]  Mark Harman,et al.  Improving 3D medical image registration CUDA software with genetic programming , 2014, GECCO.

[70]  Outi Räihä,et al.  A survey on search-based software design , 2010, Comput. Sci. Rev..

[71]  Yoshihiko Futamura,et al.  Partial Evaluation of Computation Process--An Approach to a Compiler-Compiler , 1999, High. Order Symb. Comput..

[72]  Jesper Jørgensen,et al.  Compiler Generation by Partial Evaluation , 1992 .

[73]  Chang Liu,et al.  Term rewriting and all that , 2000, SOEN.

[74]  Andreas Zeller,et al.  Yesterday, my program worked. Today, it does not. Why? , 1999, ESEC/FSE-7.

[75]  Mark Harman,et al.  Evolving a CUDA kernel from an nVidia template , 2010, IEEE Congress on Evolutionary Computation.

[76]  Toshio Nakatani,et al.  Refactoring Java programs using concurrent libraries , 2011, PADTAD '11.

[77]  David Lo,et al.  Automated library recommendation , 2013, 2013 20th Working Conference on Reverse Engineering (WCRE).

[78]  Sharad Malik,et al.  Boolean Satisfiability Solvers and Their Applications in Model Checking , 2015, Proceedings of the IEEE.

[79]  Justyna Petke,et al.  Reducing Energy Consumption Using Genetic Improvement , 2015, GECCO.

[80]  Mark Harman,et al.  Genetically Improved CUDA C++ Software , 2014, EuroGP.

[81]  Jerffeson Teixeira de Souza,et al.  Ten Years of Search Based Software Engineering: A Bibliometric Analysis , 2011, SSBSE.

[82]  Ding Li,et al.  Making web applications more energy efficient for OLED smartphones , 2014, ICSE.

[83]  Mark Harman,et al.  Automated software transplantation , 2015, ISSTA.

[84]  John A. Clark,et al.  Evolutionary Improvement of Programs , 2011, IEEE Transactions on Evolutionary Computation.

[85]  Mark Harman,et al.  Software Engineering Meets Evolutionary Computation , 2011, Computer.

[86]  Mark Harman,et al.  A formal relationship between program slicing and partial evaluation , 2006, Formal Aspects of Computing.

[87]  Moshe Sipper,et al.  Flight of the FINCH Through the Java Wilderness , 2011, IEEE Transactions on Evolutionary Computation.

[88]  Claire Le Goues,et al.  Current challenges in automatic software repair , 2013, Software Quality Journal.

[89]  Jacques Klein,et al.  Bypassing the Combinatorial Explosion: Using Similarity to Generate and Prioritize T-wise Test Suites for Large Software Product Lines , 2012, ArXiv.

[90]  Armin Biere,et al.  Optimization of Combinatorial Testing by Incremental SAT Solving , 2015, 2015 IEEE 8th International Conference on Software Testing, Verification and Validation (ICST).

[91]  Mark Harman,et al.  Using Genetic Improvement and Code Transplants to Specialise a C++ Program to a Problem Class , 2014, EuroGP.

[92]  Theo Tryfonas,et al.  Frontiers in Artificial Intelligence and Applications , 2009 .

[93]  Yuanyuan Zhang,et al.  Search-based software engineering: Trends, techniques and applications , 2012, CSUR.

[94]  Yuriy Brun,et al.  The plastic surgery hypothesis , 2014, SIGSOFT FSE.

[95]  Carlos Ansótegui,et al.  The Community Structure of SAT Formulas , 2012, SAT.