Results 1 -
6 of
6
A Type Checking Annotation-Based Product Lines
"... Software-product-line engineering is an efficient means to generate a family of program variants for a domain from a single code base. However, because of the potentially high number of possible program variants, it is difficult to test them all and ensure properties like type safety for the entire ..."
Abstract
-
Cited by 13 (12 self)
- Add to MetaCart
Software-product-line engineering is an efficient means to generate a family of program variants for a domain from a single code base. However, because of the potentially high number of possible program variants, it is difficult to test them all and ensure properties like type safety for the entire product line. We present a product-line–aware type system that can type check an entire software product line without generating each variant in isolation. Specifically, we extend the Featherweight Java calculus with feature annotations for product-line development and prove formally that all program variants generated from a well-typed product line are well-typed. Furthermore, we present a solution to the problem of typing mutually exclusive features. We discuss how results from our formalization helped implementing our own product-line tool CIDE for full Java and report of experience with detecting type errors in four existing software-product-line implementations.
Partial preprocessing C code for variability analysis
- In Proc. 5th ACM Workshop on Variability Modeling of Software-Intensive Systems
, 2011
"... The C preprocessor is commonly used to implement variability. Given a feature selection, code fragments can be excluded from compilation with #ifdef and similar directives. However, the token-based nature of the C preprocessor makes variability implementation difficult and error-prone. Additionally, ..."
Abstract
-
Cited by 2 (1 self)
- Add to MetaCart
The C preprocessor is commonly used to implement variability. Given a feature selection, code fragments can be excluded from compilation with #ifdef and similar directives. However, the token-based nature of the C preprocessor makes variability implementation difficult and error-prone. Additionally, variability mechanisms are intertwined with macro definitions, macro expansion, and file inclusion. To determine whether a code fragment is compiled, the entire file must be preprocessed. We present a partial preprocessor that preprocesses file inclusion and macro expansion, but retains variability information for further analysis. We describe the mechanisms of the partial preprocessor, provide a full implementation, and present some initial experimental results. The partial preprocessor is part of a larger endeavor in the TypeChef project to check variability implementations (syntactic correctness, type correctness) in C projects such as the Linux kernel. 1.
A Study of Cloning in the Linux SCSI Drivers
"... Abstract—To date, most research on software code cloning has concentrated on detection and analysis techniques and their evaluation, and most empirical studies of cloning have investigated cloning within single system versions. In this paper, we present the results of a longitudinal study of cloning ..."
Abstract
-
Cited by 1 (1 self)
- Add to MetaCart
Abstract—To date, most research on software code cloning has concentrated on detection and analysis techniques and their evaluation, and most empirical studies of cloning have investigated cloning within single system versions. In this paper, we present the results of a longitudinal study of cloning among the SCSI drivers for the Linux operating system that spans 16 years of evolution. We have chosen the SCSI driver subsystem as a test subject as it is known that cloning has been embraced by these developers as a design practice: when a new SCSI card comes out that is similar to an old one, but different enough to warrant its own implementation, a new driver may be cloned from an existing one. We discuss the results of our qualitative and quantitative analyses, including how the layered architecture of the SCSI subsystem seems to have affected the use of cloning as a design tool, the likelihood of consistent and inconsistent change over time, and the predictive power of using cloning between two independent driver implementations to model the similarity between two target devices. I.
An Algorithm for Quantifying the Program Variability Induced by Conditional Compilation
, 2010
"... The C Preprocessor (CPP) provides the programmer with powerful means to implement variability. Therefore the tool CPP is an important standard asset in the development toolchain for classical system software written in C. Yet, nobody has seriously quantified the effects of implementing variability w ..."
Abstract
- Add to MetaCart
The C Preprocessor (CPP) provides the programmer with powerful means to implement variability. Therefore the tool CPP is an important standard asset in the development toolchain for classical system software written in C. Yet, nobody has seriously quantified the effects of implementing variability with conditional compilation. In this report we describe conditional compilation in a semi-formal way. On this basis, we present an algorithm that is able to calculate the resulting variability. With this, we believe that further analysis on variability caused by preprocessor based configuration can be supported. This is useful to detect bugs caused by inconsistencies between variability models in the actual implementation and to support exploration of actually implemented variability in source artifacts.
uni-marburg.de
"... Software product lines have gained momentum as an approach to generate many variants of a program, each tailored to a specific use case, from a common code base. However, the implementation of product lines raises new challenges, as potentially millions of program variants are developed in parallel. ..."
Abstract
- Add to MetaCart
Software product lines have gained momentum as an approach to generate many variants of a program, each tailored to a specific use case, from a common code base. However, the implementation of product lines raises new challenges, as potentially millions of program variants are developed in parallel. In prior work, we and others have developed product-line–aware type systems to detect type errors in a product line, without generating all variants. With TypeChef, we build a similar type checker for product lines written in C that implements variability with #ifdef directives of the C preprocessor. However, a product-line–aware type system for C is more difficult than expected due to several peculiarities of the preprocessor, including lexical macros and unrestricted use of #ifdef directives. In this paper, we describe the problems faced and our progress to solve them with TypeChef. Although TypeChef is still under development and cannot yet process arbitrary C code, we demonstrate its capabilities so far with a case study: By type checking the open-source web server Boa with potentially 2 110 variants, we found type errors in several variants.

