skip to main content
10.1145/2162049.2162052acmconferencesArticle/Chapter ViewAbstractPublication PagesmodularityConference Proceedingsconference-collections
research-article

Intraprocedural dataflow analysis for software product lines

Published:25 March 2012Publication History

ABSTRACT

Software product lines (SPLs) are commonly developed using annotative approaches such as conditional compilation that come with an inherent risk of constructing erroneous products. For this reason, it is essential to be able to analyze SPLs. However, as dataflow analysis techniques are not able to deal with SPLs, developers must generate and analyze all valid methods individually, which is expensive for non-trivial SPLs. In this paper, we demonstrate how to take any standard intraprocedural dataflow analysis and automatically turn it into a feature-sensitive dataflow analysis in three different ways. All are capable of analyzing all valid methods of an SPL without having to generate all of them explicitly. We have implemented all analyses as extensions of SOOT's intraprocedural dataflow analysis framework and experimentally evaluated their performance and memory characteristics on four qualitatively different SPLs. The results indicate that the feature-sensitive analyses are on average 5.6 times faster than the brute force approach on our SPLs, and that they have different time and space tradeoffs.

References

  1. B. Adams, W. De Meuter, H. Tromp, and A. E. Hassan. Can we refactor conditional compilation into aspects? In Proceedings of the 8th ACM international conference on Aspect-oriented software development (AOSD'09), pages 243--254, Charlottesville, Virginia, USA, 2009. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. G. Ammons and J. R. Larus. Improving data-flow analysis with path profiles. In Programming Language Design and Implementation (PLDI'98), pages 72--84, Montreal, Canada, 1998. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. S. Apel, C. Kastner, A. Grösslinger, and C. Lengauer. Type safety for feature-oriented product lines. Automated Software Engineering, 17: 251--300, September 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. S. Apel, H. Speidel, P. Wendler, A. von Rhein, and D. Beyer. Detection of feature interactions using feature-aware verification. In Proceedings of the 26th IEEE/ACM International Conference on Automated Software Engineering (ASE'11), Lawrence, USA, November 2011. IEEE Computer Society. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. T. Ball and S. K. Rajamani. Bebop: a path-sensitive interprocedural dataflow engine. In PASTE'01, pages 97--103, Snowbird, Utah, USA. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. A. Classen, P. Heymans, P.-Y. Schobbens, A. Legay, and J.-F. Raskin. Model checking lots of systems: efficient verification of temporal properties in software product lines. In Proceedings of the 32nd ACM/IEEE International Conference on Software Engineering (ICSE '10), pages 335--344, Cape Town, South Africa, 2010. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. P. Clements and L. Northrop. Software Product Lines: Practices and Patterns. Addison-Wesley, 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. M. D. Ernst, G. J. Badros, and D. Notkin. An empirical analysis of c preprocessor use. IEEE Transactions on Software Engineering, 28: 1146--1170, December 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. E. Figueiredo, N. Cacho, C. Sant'Anna, M. Monteiro, U. Kulesza, A. Garcia, S. Soares, F. Ferrari, S. Khan, F. C. Filho, and F. Dantas. Evolving software product lines with aspects: an empirical study on design stability. In Proceedings of the 30th International Conference on Software Engineering (ICSE'08), pages 261--270, Leipzig, Germany, 2008. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. M. Fowler. Refactoring: Improving the Design of Existing Code. Addison-Wesley, 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. C. Hwan, P. Kim, D. Batory, and S. Khurshid. Reducing combinatorics in testing product lines. In Proceedings of the 10th International Conference on Aspect-oriented Software Development (AOSD'11), pages 57--68, Porto de Galinhas, Brazil, 2011. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. N. D. Jones, C. K. Gomard, and P. Sestoft. Partial evaluation and automatic program generation. Prentice-Hall, Inc., Upper Saddle River, NJ, USA, 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. K. C. Kang, S. G. Cohen, J. A. Hess, W. E. Novak, and A. S. Peterson. Feature-Oriented Domain Analysis (FODA) feasibility study. Technical report, Carnegie-Mellon University Software Engineering Institute, November 1990.Google ScholarGoogle ScholarCross RefCross Ref
  14. ner(2010)}kastnerthesisC. Kastner. Virtual Separation of Concerns: Toward Preprocessors 2.0. PhD thesis, University of Magdeburg, Germany, May 2010.Google ScholarGoogle Scholar
  15. C. Kastner and S. Apel. Type-checking software product lines - a formal approach. In Proceedings of the 23rd IEEE/ACM International Conference on Automated Software Engineering (ASE'08), pages 258--267, L'Aquila, Italy, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. C. Kastner, S. Apel, and M. Kuhlemann. Granularity in software product lines. In Proceedings of the 30th International Conference on Software Engineering (ICSE'08), pages 311--320, Leipzig, Germany, 2008. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. C. Kastner, P. G. Giarrusso, T. Rendel, S. Erdweg, K. Ostermann, and T. Berger. Variability-aware parsing in the presence of lexical macros and conditional compilation. In Proceedings of the ACM International Conference on Object-Oriented Programming Systems Languages and Applications (OOPSLA'11), pages 805--824, Portland, OR, USA, 2011. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. G. A. Kildall. A unified approach to global program optimization. In Proceedings of the 1st annual ACM symposium on Principles of programming languages (POPL'73), pages 194--206, Boston, Massachusetts, 1973. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. C. H. P. Kim, E. Bodden, D. Batory, and S. Khurshid. Reducing configurations to monitor in a software product line. In ph1st International Conference on Runtime Verification (RV), volume 6418 of LNCS, Malta, November 2010. Springer. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. M. Krone and G. Snelting. On the inference of configuration structures from source code. In Proceedings of the 16th International Conference on Software Engineering (ICSE'04), pages 49--57, Los Alamitos, CA, USA, 1994. IEEE Computer. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. J. Liebig, S. Apel, C. Lengauer, C. Kastner, and M. Schulze. An analysis of the variability in forty preprocessor-based software product lines. In Proceedings of the 32nd ACM/IEEE International Conference on Software Engineering (ICSE'10), pages 105--114, Cape Town, South Africa, 2010. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. S. Moon, M. W. Hall, and B. R. Murphy. Predicated array data-flow analysis for run-time parallelization. In Proceedings of the 12th International Conference on Supercomputing (ICS'98), pages 204--211, Melbourne, Australia, 1998. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. F. Nielson, H. R. Nielson, and C. Hankin. Principles of Program Analysis. Springer-Verlag, Secaucus, USA, 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. K. Pohl, G. Böckle, and F. van der Linden. Software Product Line Engineering: Foundations, Principles and Techniques. Springer, 2005. Google ScholarGoogle ScholarCross RefCross Ref
  25. H. Post and C. Sinz. Configuration lifting: Verification meets software configuration. In phProceedings of the 23rd IEEE/ACM International Conference on Automated Software Engineering (ASE'08), pages 347--350, L'Aquila, Italy, 2008. IEEE Computer Society. Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. M. Ribeiro, H. Pacheco, L. Teixeira, and P. Borba. Emergent feature modularization. In Onward! 2010, affiliated with the 1st ACM SIGPLAN International Conference on Systems, Programming, Languages and Applications: Software for Humanity (SPLASH'10), pages 11--18, Reno, NV, USA, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  27. H. Spencer and G. Collyer. #ifdef considered harmful, or portability experience with C news. In Proceedings of the Usenix Summer 1992 Technical Conference, pages 185--198, Berkeley, CA, USA, June 1992. Usenix Association.Google ScholarGoogle Scholar
  28. R. Vallée-Rai, P. Co, E. Gagnon, L. Hendren, P. Lam, and V. Sundaresan. Soot - a java bytecode optimization framework. In Proceedings of the 1999 conference of the Centre for Advanced Studies on Collaborative research (CASCON'99), pages 13--. IBM Press, 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  29. M. N. Wegman and F. K. Zadeck. Constant propagation with conditional branches. ACM Transactions on Programming Languages and Systems, 13: 181--210, April 1991. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Intraprocedural dataflow analysis for software product lines

                Recommendations

                Reviews

                Simon John Thompson

                Computer systems of any size are unlikely to be simple programs. Extracted from some sort of source code control, they will be configured and targeted for deployment using preprocessors, configuration, and make tools. These aspects are often neglected—for example, does your favorite refactoring tool ensure that tests and makefiles are refactored in step with the code__?__ One approach to taming this complexity is to use software product lines (SPLs), which the authors of this paper describe by means of sets of features (or configurations) that (de)activate certain program artifacts. They ask the following question: Given an SPL description, how does one analyze that description, for example, in a dataflow analysis__?__ The naive approach is to analyze all the instances of the SPL, but in this paper, the authors show that a more thoughtful approach pays performance dividends, at least in the case of a number of intraprocedural analyses. The first step of the new approach is to build an analysis that is feature sensitive so that each analysis can be performed for the features enabled by the configuration of the particular instance of the SPL, rather than making the analysis on the compiled version of the configuration. The second innovation is to perform an analysis of all the configurations simultaneously, by means of a product lattice. This has the distinct advantage of performing the fixed-point calculation once and for all, rather than repeating it for each configuration. The final innovation is to share computations in the simultaneous calculation of the analysis. The paper gives a theoretical analysis of the speedups and presents data gathered in a number of real-world case studies. The simultaneous analysis performs particularly well in the case where the SPL is feature rich, producing a substantial speedup. Sharing computations can reduce the memory footprint of the analysis as well. It will be interesting to see how the results of this well-written paper scale to larger systems and to interprocedural analyses in particular. Online Computing Reviews Service

                Access critical reviews of Computing literature here

                Become a reviewer for Computing Reviews.

                Comments

                Login options

                Check if you have access through your login credentials or your institution to get full access on this article.

                Sign in
                • Published in

                  cover image ACM Conferences
                  AOSD '12: Proceedings of the 11th annual international conference on Aspect-oriented Software Development
                  March 2012
                  286 pages
                  ISBN:9781450310925
                  DOI:10.1145/2162049

                  Copyright © 2012 ACM

                  Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

                  Publisher

                  Association for Computing Machinery

                  New York, NY, United States

                  Publication History

                  • Published: 25 March 2012

                  Permissions

                  Request permissions about this article.

                  Request Permissions

                  Check for updates

                  Qualifiers

                  • research-article

                  Acceptance Rates

                  AOSD '12 Paper Acceptance Rate20of79submissions,25%Overall Acceptance Rate41of139submissions,29%

                PDF Format

                View or Download as a PDF file.

                PDF

                eReader

                View online with eReader.

                eReader