Mon 20 - Fri 24 October 2014 Portland, Oregon, United States
Mon 20 Oct 2014 10:30 - 11:15 at Salon C - Session 2

The C preprocessor is widely used to handle variability and solve portability issues in program families. In this context, developers normally use tools like GCC and Clang. However, these tools are not variability-aware, i.e., they preprocess the code and consider each family member individually. As a result, even well-known and widely used families, such as Linux and Apache, contain bad smells and bugs related to variability. To minimize this problem, we propose an approach to safely evolve C program families. We develop a strategy to detect bugs related to variability and define refactorings to remove bad smells in preprocessor directives. Our supporting tool, Colligens, implements our strategy to detect bugs and applies our refactorings automatically. By using our approach in 40 open-source C program families, we detect 121 bugs related to variability, and developers accepted 78% of the patches we submit. Also, we remove 477 bad smells in 12 C program families without clone code as in previous studies.

Mon 20 Oct

10:30 - 12:00: Doctoral Symposium - Session 2 at Salon C
splash2014-ds141379380000010:30 - 11:15
Flavio MedeirosFederal University of Campina Grande
splash2014-ds141379650000011:15 - 12:00