VarexJ: A Variability-Aware Java Interpreter Testing Configurable Systems Jens Meinicke, Chu-Pan Wong, Christian Kästner FOSD Meeting 2015 Feature Interaction Jens Meinicke VarexJ - Testing Configurable Systems 2 Feature Interaction Jens Meinicke VarexJ - Testing Configurable Systems 3 Testing Configurable Systems Brute Force Jens Meinicke VarexJ - Testing Configurable Systems C1 Result1 C2 Defect2 C3 Result3 Cn Resultn 4 Testing Configurable Systems Sampling Jens Meinicke VarexJ - Testing Configurable Systems C1 Result1 C2 Defect ? 2 C3 Result3 Cn Result ? n 5 Motivation Configuration Space Explosion 266 Features: More configurations than atoms in the visible universe Jens Meinicke VarexJ - Testing Configurable Systems 6 Testing Configurable Systems Result F1 & F2 & ¬F3 VaribilityAware Interpreter Result F1 & ¬F2 Defect F1 & F2 & F3 [CRE12, NCN14, M14] Jens Meinicke VarexJ - Testing Configurable Systems 7 VarexJ Variability-Aware execution for Java Based on the interpreter of Java Pathfinder Share as much redundant instructions as possible Share redundant data https://github.com/meinicke/VarexJ Jens Meinicke VarexJ - Testing Configurable Systems 8 content = Choice(SMILEY, “<p>…[:Temperature<img=“smiley.jpg”></p>”, Choice(WEATHER, “<p>…10°C>”, “<p>…[:Temperature:]>”)) True The Approach !SMILEY SMILEY !WEATHER WEATHER True SMILEY WEATHER Jens Meinicke VarexJ - Testing Configurable Systems 9 content = Choice(SMILEY, “<p>…[:Temperature<img=“smiley.jpg”></p>”, Choice(WEATHER, “<p>…10°C>”, “<p>…[:Temperature:]>”)) True The Approach !SMILEY SMILEY !WEATHER WEATHER True SMILEY WEATHER Jens Meinicke VarexJ - Testing Configurable Systems 10 Does it Scale? Jens Meinicke VarexJ - Testing Configurable Systems 11 Execution Time Jens Meinicke VarexJ - Testing Configurable Systems 12 Sharing of Instructions Jens Meinicke VarexJ - Testing Configurable Systems 13 seconds 132 checks & 5 additional options Jens Meinicke VarexJ - Testing Configurable Systems 14 seconds 132 checks & 5 additional options Jens Meinicke VarexJ - Testing Configurable Systems 15 T = 137 VarexJ - Testing Configurable Systems 16 seconds 132 checks & 5 additional options Jens Meinicke References Jens Meinicke. VarexJ: A Variability-Aware Interpreter for Java Applications. Master's thesis, University of Magdeburg, Germany, December 2014. Hung Viet Nguyen, Christian Kästner, and Tien N. Nguyen. Exploring Variability-Aware Execution for Testing Plugin-Based Web Applications. In Proceedings of the International Conference on Software Engineering (ICSE), pages 907–918. ACM, 2014. Christian Kästner, Alexander von Rhein, Sebastian Erdweg, Jonas Pusch, Sven Apel, Tillmann Rendel, and Klaus Ostermann. Toward Variability-Aware Testing. In Proceedings of the International SPLC Workshop Feature-Oriented Software Development (FOSD), pages 1–8. ACM, 2012b. Jens Meinicke VarexJ - Testing Configurable Systems 17 So far… Jens Meinicke VarexJ - Testing Configurable Systems 18 VarexJ: A Variability-Aware Java Interpreter Understanding Feature Interactions Jens Meinicke, Chu-Pan Wong, Christian Kästner FOSD Meeting 2015 Analyzing Variability Where do features interact? Why do features interact? Are they supposed to interact? Is the interaction accidental? Jens Meinicke VarexJ - Understanding Feature Interactions 20 Variability-Aware Execution True a=1 b = false ¬FOO FOO True FOO ¬FOO ¬FOO FOO ¬BAR BAR ¬BAR& ¬FOO BAR| FOO True Jens Meinicke a=1 b = Chc(FOO, true, false) a=2 b = Chc(FOO, true, false) a=2 b = Chc(FOO, true, false) a = Chc(FOO, 4, 2) b = Chc(FOO, true, false) a = Chc(FOO, Chc(BAR, 12, 4), Chc(BAR, 6, 2)) b = Chc(FOO, true, false) a = Chc(FOO, Chc(BAR,2, 4), Chc(BAR, 6, 2)) b = false a = Chc(FOO,Chc(BAR,60,20),Chc(BAR,30, 10)) b = false VarexJ - Understanding Feature Interactions 21 Variability in Executions True ¬FOO FOO True FOO ¬FOO ¬FOO FOO ¬BAR BAR ¬BAR& ¬FOO BAR| FOO True Jens Meinicke VarexJ - Understanding Feature Interactions 22 Variability in Data a=1 b = false a=1 b = Chc(FOO, true, false) a=2 b = Chc(FOO, true, false) a=2 b = Chc(FOO, true, false) a = Chc(FOO, 4, 2) b = Chc(FOO, true, false) a = Chc(FOO, Chc(BAR, 12, 4), Chc(BAR, 6, 2)) b = Chc(FOO, true, false) a = Chc(FOO, Chc(BAR,2, 4), Chc(BAR, 6, 2)) b = false a = Chc(FOO,Chc(BAR,60,20),Chc(BAR,30, 10)) b = false Jens Meinicke VarexJ - Understanding Feature Interactions 23 Some Views on Elevator Jens Meinicke interactions on data number of interacting features context specific code number of contexts VarexJ - Understanding Feature Interactions 24 Big Questions How do features interact in real world systems? What pattern cause (high) feature interactions? How do dangerous and unpredictable feature interactions appear? Jens Meinicke VarexJ - Understanding Feature Interactions 25 Summary Jens Meinicke VarexJ - Understanding Feature Interactions 26 Conditional Memory Variability-Aware Scheduling & Execution Jens Meinicke Variability-Aware Native Calls VarexJ - Testing Configurable Systems 27 27 http://www.javaservletsjspweb.in/2012/02/java-virtual-machine-jvm-architecture.html Example Programs Jens Meinicke VarexJ - Testing Configurable Systems 28 Time for Sampling Jens Meinicke VarexJ - Testing Configurable Systems 29 Interactions Jens Meinicke VarexJ - Testing Configurable Systems 30 Sharing of Instrucions Number of features in the context Jens Meinicke VarexJ - Testing Configurable Systems 31
© Copyright 2024