MACRO IMPACT ANALYSIS USING MACRO SLICING

László Vidács, Árpád Beszédes, Rudolf Ferenc

Abstract

The expressiveness of the C/C++ preprocessing facility enables the development of highly configurable source code. However, the usage of language constructs like macros also bears the potential of resulting in highly incomprehensible and unmaintainable code, which is due to the flexibility and the “cryptic” nature of the pre-processor language. This could be overcome if suitable analysis tools were available for preprocessor-related issues, however, this is not the case (for instance, none of the modern Integrated Development Environments provides features to efficiently analyze and browse macro usage). A conspicuous problem in software maintenance is the correct (safe and efficient) management of change. In particular, due to the aforementioned reasons, determining efficiently the impact of a change in a specific macro definition is not yet possible. In this paper, we describe a method for the impact analysis of macro definitions, which significantly differs from the previous approaches. We reveal and analyze the dependencies among macro-related program points using the so-called macro slices.

References

  1. Agrawal, H. and Horgan, J. R. (1990). Dynamic program slicing. In Proceedings of the ACM PLDI 1990, pages 246-256, New York, NY, USA. ACM Press.
  2. Badros, G. J. and Notkin, D. (2000). A Framework for Preprocessor-Aware C Source Code Analyses. Softw. Pract. Exper., 30(8):907-924.
  3. Beszédes, Í ., Gergely, T., and Gyimóthy, T. (2006). Graphless dynamic dependence-based dynamic slicing algorithms. In Proceedings of SCAM 2006), pages 21-30.
  4. Ebert, J., Kullbach, B., Riediger, V., and Winter, A. (2002). GUPRO - Generic Understanding of Programs. In Electronic Notes in Theoretical Computer Science, volume 72. Elsevier.
  5. FrontEndART Homepage (2007). http://www.frontendart.com.
  6. Garrido, A. (2005). Program refactoring in the presence of preprocessor directives. Ph.D. thesis, UIUC.
  7. Horwitz, S., Reps, T., and Binkley, D. (1990). Interprocedural slicing using dependence graphs. ACM Transactions on Programming Languages and Systems, 12(1):26-61.
  8. Kullbach, B. and Riediger, V. (2001). Folding: An approach to enable program understanding of preprocessed languages. In Proceedings of WCRE 2001, pages 3-12, Los Alamitos. IEEE Computer Society.
  9. Livadas, P. E. and Small, D. T. (1994). Understanding code containing preprocessor constructs. In Proceedings of IWPC 1994, pages 89-97. IEEE Computer Society.
  10. Mennie, C. A. and Clarke, C. L. A. (2004). Giving meaning to macros. In Proceedings of IWPC 2004, page 79, Washington, DC, USA. IEEE Computer Society.
  11. Rajlich, V. (1997). A model for change propagation based on graph rewriting. In Proceedings of ICSM 1997), pages 84-91.
  12. Spencer, H. and Collyer, G. (1992). #ifdef considered harmful, or portability experience with C News. In Technical Conference, pages 185-197.
  13. Spinellis, D. (2003). Global analysis and transformations in preprocessed languages. IEEE Transactions on Software Engineering, 29(11):1019-1030.
  14. Tip, F. (1995). A survey of program slicing techniques. Journal of Programming Languages, 3(3):121-189.
  15. Understand for C++ Homepage (2007). http://www.scitools.com.
  16. Weiser, M. (1984). Program slicing. IEEE Transactions on Software Engineering, SE-10(4):352-357.
  17. Xu, B., Qian, J., Zhang, X., Wu, Z., and Chen, L. (2005). A brief survey of program slicing. ACM SIGSOFT Softw. Eng. Notes, 30(2):1-36.
Download


Paper Citation


in Harvard Style

Vidács L., Beszédes Á. and Ferenc R. (2007). MACRO IMPACT ANALYSIS USING MACRO SLICING . In Proceedings of the Second International Conference on Software and Data Technologies - Volume 2: ICSOFT, ISBN 978-989-8111-06-7, pages 230-235. DOI: 10.5220/0001341902300235


in Bibtex Style

@conference{icsoft07,
author={László Vidács and Árpád Beszédes and Rudolf Ferenc},
title={MACRO IMPACT ANALYSIS USING MACRO SLICING},
booktitle={Proceedings of the Second International Conference on Software and Data Technologies - Volume 2: ICSOFT,},
year={2007},
pages={230-235},
publisher={SciTePress},
organization={INSTICC},
doi={10.5220/0001341902300235},
isbn={978-989-8111-06-7},
}


in EndNote Style

TY - CONF
JO - Proceedings of the Second International Conference on Software and Data Technologies - Volume 2: ICSOFT,
TI - MACRO IMPACT ANALYSIS USING MACRO SLICING
SN - 978-989-8111-06-7
AU - Vidács L.
AU - Beszédes Á.
AU - Ferenc R.
PY - 2007
SP - 230
EP - 235
DO - 10.5220/0001341902300235