Nowadays software tends to come in many different, yet similar variants, often derived from a common code base via clone-and-own. Family-based-analysis strategies have recently shown very promising potential for improving efficiency in applying quality-assurance techniques to such variant-rich programs, as compared to variant-by-variant approaches. Unfortunately, these strategies require a single program representation superimposing all program variants in a syntactically well-formed, semantically sound, and variant-preserving manner, which is usually not available and manually hard to obtain in practice. In this article, we present a novel methodology, called S i MPOSE, for automatically generating superimpositions of existing program variants to facilitate family-based analyses of variant-rich software. To this end, we propose a novel N-way model-merging methodology to integrate the control-flow automaton (CFA) representations of N given variants of a C program into one unified CFA representation. CFA constitute a unified program abstraction used by many recent software-analysis tools for automated quality assurance. To cope with the inherent complexity of N-way model-merging, our approach (1) utilizes principles of similarity-propagation to reduce the number of potential N-way matches, and (2) enables us to decompose a set of N variants into arbitrary subsets and to incrementally derive an N-way superimposition from partial superimpositions. We apply our tool implementation of S i MPOSE to a selection of realistic C programs, frequently considered for experimental evaluation of program-analysis techniques. In particular, we investigate applicability and efficiency/effectiveness trade-offs of our approach by applying S i MPOSE in the context of family-based unit-test generation as well as model-checking as sample program-analysis techniques. Our experimental results reveal very impressive efficiency improvements by an average factor of up to 2.6 for test-generation and up to 2.4 for model-checking under stable effectiveness, as compared to variant-by-variant approaches, thus amortizing the additional effort required for merging. In addition, our results show that merging all N variants at once produces, in almost all cases, clearly more precise results than incremental step-wise 2-way merging. Finally, our comparison with major existing N-way merging techniques shows that S i MPOSE constitutes, in most cases, the best efficiency/effectiveness trade-off.
N-way model merging is a key technique for managing software variability, by integrating N concurrent model variants/versions into one. Most merging techniques are based on three operators: (1) compare, (2) match and (3) merge. As finding optimal solutions for (2) in terms of matching precision is NP-hard, many proposals for scalable yet sufficiently precise matching heuristics exist. However, most approaches are either generic which obstructs precision if applied to realistic modeling languages, or they require excessive computational upfront investment already in step (1) to ensure sufficient precision. We propose an alternative approach for automated construction of precise model merges by focusing on step (3): given an arbitrarily imprecise matching, we incrementally apply default modelrefactoring operators, as available for most mature modeling languages, to identify and unify further similarities among initially unmatched model elements. For those model-refactoring operators to produce correct results if applied to merged models, we utilize variability encoding as known from product-line engineering. Our tool implementation supports any EMFcompliant modeling language and is instantiated for UML class diagrams to demonstrate our methodology. Our evaluation results show that our technique (a) preserves the precision of near optimal matchings and (b) remarkably improves the precision of arbitrarily imprecise matchings while requiring acceptable computational effort.
scite is a Brooklyn-based organization that helps researchers better discover and understand research articles through Smart Citations–citations that display the context of the citation and describe whether the article provides supporting or contrasting evidence. scite is used by students and researchers from around the world and is funded in part by the National Science Foundation and the National Institute on Drug Abuse of the National Institutes of Health.
hi@scite.ai
10624 S. Eastern Ave., Ste. A-614
Henderson, NV 89052, USA
Copyright © 2024 scite LLC. All rights reserved.
Made with 💙 for researchers
Part of the Research Solutions Family.