Detecting and understanding reasons for defects and inadvertent behavior in software is challenging due to their increasing complexity. In configurable software systems, the combinatorics that arises from the multitude of features a user might select from adds a further layer of complexity. We introduce the notion of feature causality, which is based on counterfactual reasoning and inspired by the seminal definition of actual causality by Halpern and Pearl. Feature causality operates at the level of system configurations and is capable of identifying features and their interactions that are the reason for emerging functional and non-functional properties. We present various methods to explicate these reasons, in particular well-established notions of responsibility and blame that we extend to the feature-oriented setting. Establishing a close connection of feature causality to prime implicants, we provide algorithms to effectively compute feature causes and causal explications. By means of an evaluation on a wide range of configurable software systems, including community benchmarks and real-world systems, we demonstrate the feasibility of our approach: We illustrate how our notion of causality facilitates to identify root causes, estimate the effects of features, and detect feature interactions.
翻译:由于软件系统日益复杂,检测和理解软件存在缺陷和意外行为的原因具有挑战性。在可配置的软件系统中,用户可能从更多复杂层面中选择的多种特性所产生的组合性因素增加了一层复杂因素。我们引入了特征因果关系概念,这一概念基于反事实推理,并受Halpern和Pearl对实际因果关系的开创性定义的启发。特性因果关系在系统配置层面运作,能够识别作为新兴功能性和非功能性特性原因的特征及其相互作用。我们提出了各种解释这些原因的方法,特别是我们扩展到以特征为导向的环境的既定责任和责备概念。建立特征因果关系与主要不易分子的密切联系,我们提供算法,以便有效地计算特征原因和因果关系。我们通过对一系列可配置的软件系统进行评估,包括社区基准和现实世界系统,来展示我们的方法的可行性:我们说明了我们的因果关系概念如何有助于查明根源,估计特征的影响,并检测特征互动。