reverse engineering feature models
play

Reverse Engineering Feature Models. . . S. She, R. Lotufo, T. - PowerPoint PPT Presentation

Reverse Engineering Feature Models. . . S. She, R. Lotufo, T. Berger, A. Wasowski, K. Czarnecki Generative Software Development Lab University of Waterloo . . International Conference on Software Engineering, Honolulu, Hawaii, USA.


  1. Reverse Engineering Feature Models. . . S. She, R. Lotufo, T. Berger, A. Wasowski, K. Czarnecki Generative Software Development Lab University of Waterloo . . International Conference on Software Engineering, Honolulu, Hawaii, USA.

  2. Outline. 1 . . . . Conclusions 5 Evaluation 4 Procedures 3 Feature Models 2 Introduction Steven She. Reverse Engineering Feature Models. 2 / 29

  3. Timeline. . . . . . parts of the FreeBSD FMs. Rev. engineering Linux, eCos, and . Linux and eCos feature models. . Evolution of Linux feature models. . Initial study on the Linux FM. . Sample spaces and FMs. . Propositional logic and FMs. . SPLC ’07 . SPLC ’08 . VaMoS ’10 . SPLC ’10 . ASE ’10 . ICSE ’11 . Steven She. Reverse Engineering Feature Models. 3 / 29

  4. Motivation. software product lines (SPLs), e.g. Linux and eCos. understand for users and developers. project artifacts. . . . . • Feature models are great for representing variability in • Some SPLs don’t have feature models, e.g. FreeBSD. • Without a feature model, dependencies are hard to • Solution: Reverse engineer a feature model from existing • We present procedures to address this task. Steven She. Reverse Engineering Feature Models. 4 / 29

  5. Outline. 1 . . . . Conclusions 5 Evaluation 4 Procedures 3 Feature Models 2 Introduction Steven She. Reverse Engineering Feature Models. 5 / 29

  6. A Propositional Feature Model… is a Tree + Cross-Tree Constraints. . . . . acpi_system pm acpi performance cpu_freq cpu_hotplug powersave powersave ∧ acpi → cpu_hotplug Steven She. Reverse Engineering Feature Models. 6 / 29

  7. Configuration Semantics. A feature model describes a set of legal configurations. Legal configurations can be represented by a formula. . . . . ] ≡ φ [ [ FM ] Steven She. Reverse Engineering Feature Models. 7 / 29

  8. Formula. . cpu_hotplug cpu_freq performance acpi pm acpi_system powersave . . . powersave ∧ acpi → cpu_hotplug φ = child-parent impl. ∧ mandatory impl. ∧ implies edges ∧ excludes edges ∧ feature groups ∧ cross-tree constraints Steven She. Reverse Engineering Feature Models. 8 / 29

  9. Propositional Logic to Feature Models. that describe its legal configurations. FM = tree + cross-tree constraints. . . . . Given φ , there are many possible feature models Steven She. Reverse Engineering Feature Models. 9 / 29

  10. Ontological semantics. dst is an experimental feature. . . . . assistance. Linux different ontological semantics. dst staging net Linux dst staging net • Two FMs with the same configuration semantics, but • We need a human to decide the placement of a feature. • But, names and descriptions can be used to provide Steven She. Reverse Engineering Feature Models. 10 / 29

  11. Ontological semantics. dst is an experimental feature. . . . . assistance. Linux different ontological semantics. dst staging net Linux dst staging net • Two FMs with the same configuration semantics, but • We need a human to decide the placement of a feature. • But, names and descriptions can be used to provide Steven She. Reverse Engineering Feature Models. 10 / 29

  12. Outline. 1 . . . . Conclusions 5 Evaluation 4 Procedures 3 Feature Models 2 Introduction Steven She. Reverse Engineering Feature Models. 11 / 29

  13. Overview. . Reverse-Engineering Procedures. building hierarchy. Key challenge. edges are automatically detected. . . . • Building the feature hierarchy. • Task—Select a parent for each feature. • Interactive—procedures provides assistance to the user for • Robust—we consider and evaluate on incomplete input. • Mandatory features, feature groups, implies and excludes Steven She. Reverse Engineering Feature Models. 12 / 29

  14. Overview. . Reverse-Engineering Procedures. building hierarchy. Key challenge. edges are automatically detected. . . . • Building the feature hierarchy. • Task—Select a parent for each feature. • Interactive—procedures provides assistance to the user for • Robust—we consider and evaluate on incomplete input. • Mandatory features, feature groups, implies and excludes Steven She. Reverse Engineering Feature Models. 12 / 29

  15. Required Input. . . . Feature Names . Descriptions . . Dependencies . . D φ F Steven She. Reverse Engineering Feature Models. 13 / 29

  16. Names and Descriptions. pm Power management, CPU and ACPI options acpi Adv. Configuration and Power Interface support acpi_system Enable your system to shut down using ACPI cpu_freq CPU frequency scaling cpu_hotplug Allows turning CPU on and off powersave This CPU governor uses the lowest frequency performance This CPU governor uses the highest frequency . . . . Steven She. Reverse Engineering Feature Models. 14 / 29

  17. Dependencies. . . . . ( acpi → acpi_system ∧ pm ) ∧ ( acpi_system → acpi ) ∧ ( cpu_freq → pm ) ∧ ( cpu_freq → powersave ∨ performance ) ∧ ( cpu_hotplug → powersave ) ∧ ( cpu_hotplug → ¬ performance ) ∧ ( cpu_hotplug → acpi ∧ cpu_freq ) ∧ ( powersave → ¬ performance ) ∧ ( powersave → cpu_freq ) ( performance → cpu_freq ) ∧ ( powersave ∧ acpi → cpu_hotplug ) ∧ Steven She. Reverse Engineering Feature Models. 15 / 29

  18. Parent Candidates. acpi_system 4. 5. cpu_freq powersave performance acpi ... 2. feature implies sorted by similarity. similarity. . . . . Ranked Implied Features 3. . 5. . 2. Ranked All-Features 3. 1 4. powersave Selected: cpu_hotplug acpi acpi_system cpu_freq pm CPU frequency scaling. 1 • Ranked Implied Features (RIFs) : set of features the selected • Ranked All-Features (RAFs) : all features sorted by their Steven She. Reverse Engineering Feature Models. 16 / 29

  19. Implication Graph. . cpu_freq powersave performance acpi acpi_system cpu_hotplug pm . . . • An edge v → w : implication from v to w exists in φ . • Direct implications are the thick edges. • Calculated using a SAT solver. Steven She. Reverse Engineering Feature Models. 17 / 29

  20. Similarity Heuristic. how many words they share. document frequency (IDF) between the two features. . . . . • Similarity function δ compares two features and measures • Removes stop words, then calculates the sum of the inverse • RIFs ( f ): Using the implication graph, prioritize direct implications then all remaining implications, sorted by δ . • RAFs ( f ): All features, sorted by δ . Steven She. Reverse Engineering Feature Models. 18 / 29

  21. Groups and Cross-Tree Constraints. groups, and the remaining edges in the implication and mutex graphs. . . . . • Construct a Mutex Graph to detect exclusions. • Detect mutex and xor -groups. • Implies and excludes edges are found using the hierarchy, Steven She. Reverse Engineering Feature Models. 19 / 29

  22. Outline. 1 . . . . Conclusions 5 Evaluation 4 Procedures 3 Feature Models 2 Introduction Steven She. Reverse Engineering Feature Models. 20 / 29

  23. Linux and eCos Feature Models. . . . . . . • Kconfig and CDL languages. • Reference models to evaluate our procedures. Steven She. Reverse Engineering Feature Models. 21 / 29

  24. FreeBSD Reference Model. . . FreeBSD kernel. . . . . • Dependencies and descriptions extracted from various artifacts in • Manually created ontology of 192 features. • Reference FM of 90 features extracted from ontology. • Thorsten’s area of expertise. Steven She. Reverse Engineering Feature Models. 22 / 29

  25. Characterization of Input Data. . . . 200 50 150 40 ecos 30 100 20 50 10 0 0 600 800 500 freebsd 600 400 Number of Features 300 400 200 200 100 0 0 10 freebsd−ref 80 8 60 6 40 4 20 2 0 0 2000 700 600 1500 500 linux 400 1000 300 200 500 100 0 0 0 50 100 150 0 20 40 60 80 100 Number of Words Number of Implications Steven She. Reverse Engineering Feature Models. 23 / 29

  26. Measuring Effectiveness. . RAFs Is the reference parent in the Top 5 results? How many features do we have to examine to have a 75% chance of finding the reference parent? RIFs randomly removing implications and words. . . . • Applied measures to complete and incomplete data sets. • Generated sets of incomplete data for Linux and eCos by Steven She. Reverse Engineering Feature Models. 24 / 29

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend