Simplifying the Analysis of Software Design Variants with a Colorful Alloy

Formal modeling and automatic analysis are essential to achieve a trustworthy software design prior to its implementation. Alloy and its Analyzer are a popular language and tool for this task. Frequently, rather than a single software artifact, the goal is to develop a full software product line (SPL) with many variants supporting different features. Ideally, software design languages and tools should provide support for analyzing all such variants (e.g., by helping pinpoint combinations of features that could break a property), but that is not currently the case. Even when developing a single artifact, support for multi-variant analysis is desirable to explore design alternatives. Several techniques have been proposed to simplify the implementation of SPLs. One such technique is to use background colors to identify the fragments of code associated with each feature. In this paper we propose to use that same technique for formal design, showing how to add support for features and background colors to Alloy and its Analyzer, thus easing the analysis of software design variants. Some illustrative examples and evaluation results are presented, showing the benefits and efficiency of the implemented technique.

[1]  Daniel Jackson,et al.  Software Abstractions - Logic, Language, and Analysis , 2006 .

[2]  Mark Ryan,et al.  Feature integration using a feature construct , 2001, Sci. Comput. Program..

[3]  Sven Apel,et al.  Language-Independent and Automated Software Composition: The FeatureHouse Experience , 2013, IEEE Transactions on Software Engineering.

[4]  Pierre-Yves Schobbens,et al.  Model checking lots of systems: efficient verification of temporal properties in software product lines , 2010, 2010 ACM/IEEE 32nd International Conference on Software Engineering.

[5]  Fausto Giunchiglia,et al.  NUSMV: a new symbolic model checker , 2000, International Journal on Software Tools for Technology Transfer.

[6]  Pierre-Yves Schobbens,et al.  Model checking software product lines with SNIP , 2012, International Journal on Software Tools for Technology Transfer.

[7]  Sven Apel,et al.  Detecting Dependences and Interactions in Feature-Oriented Design , 2010, 2010 IEEE 21st International Symposium on Software Reliability Engineering.

[8]  Gerard J. Holzmann,et al.  The Model Checker SPIN , 1997, IEEE Trans. Software Eng..

[9]  Sven Apel,et al.  An Overview of Feature-Oriented Software Development , 2009, J. Object Technol..

[10]  Ana C. R. Paiva,et al.  Sharing and Learning Alloy on the Web , 2019, ArXiv.

[11]  Stefania Gnesi,et al.  Formal Modeling for Product Families Engineering , 2008, 2008 12th International Software Product Line Conference.

[12]  Christian Wende,et al.  FeatureMapper: mapping features to models , 2008, ICSE Companion '08.

[13]  Elena Planas,et al.  Analysis of Feature Models Using Alloy: A Survey , 2016, FMSPLE.

[14]  Sven Apel,et al.  Granularity in software product lines , 2008, 2008 ACM/IEEE 30th International Conference on Software Engineering.

[15]  Gunter Saake,et al.  Type checking annotation-based product lines , 2012, TSEM.

[16]  Thomas Leich,et al.  Do background colors improve program comprehension in the #ifdef hell? , 2012, Empirical Software Engineering.

[17]  Krzysztof Czarnecki,et al.  Verifying feature-based model templates against well-formedness OCL constraints , 2006, GPCE '06.

[18]  Reiner Hähnle,et al.  Formal Methods in Software Product Line Engineering , 2011, Computer.

[19]  Krzysztof Czarnecki,et al.  Feature Diagrams and Logics: There and Back Again , 2007 .

[20]  Michal Antkiewicz,et al.  Mapping features to models: a template approach based on superimposed variants , 2005, GPCE'05.