SlideShare a Scribd company logo
1 of 26
Automatic Non-functional Testing of
Code Generators Families
Mohamed
BOUSSAA
Olivier
BARAIS
Gerson
SUNYE
Benoit
BAUDRY
2016 IEEE International Conference on Software Quality, Reliability & Security (QRS 2016)
August 1-3, 2016 - Vienna, Austria
INRIA Rennes, France
15th International Conference on Generative Programming: Concepts & Experiences (GPCE 2016)
Amsterdam, Netherlands, October 31 – November 1, 2016
1
a1. Context
a2. Motivation
a3. Automatic Non-functional Testing of Code Generators Families
a4. Performance Evaluation
a5. Conclusion
Outline
2
Context
3
Software Platform
Diversity
Software Design Automatic Code Generation
Software
Designer
DSL
Model
GPL
Specs
GUI
Code Generator
creators/maintainers
Code generators
Generated code
All tests are successfully passed but…
How about the non-functional properties (quality) of generated code ?
Code generators are used everywhere
They automatically transform high-level system specifications (Models, DSLs,
GUIs, etc.) into general-purpose languages (JAVA, C++, C#, etc.)
Target diverse and heterogeneous software platorms
Context
4
• Testing issues:
- Defective code generators may generate poor-quality code
- Testing the non-functional properties is time-consuming
- Require examining different non-functional requirements
- Code generators are complex and difficult to understand (involve complex
and hetergenous technologies)
Motivation
5
 Non-functional testing of code generators: The traditional way
• Analyze the non-functional properties of generated code using platform-
specific tools, profilers, etc.
Lack of tools for automatic non-functional testing of code generators
Footprint C
Footprint A
DSL
(Model)
SUT
SUT
SUT
Design
Generate
Generate
Generate
Code
Generator A
Code
Generator B
Code
Generator C
Execute
Execute
Execute
C++
Platform C
Platform B
Platform A
JAVA
C#
Profiler A
Profiler B
Profiler C
Bugs
Finding
Report
Report
Report
Footprint B
Code Generation Non-functional TestingCode ExecutionSoftware Design
Automatic Non-functional Testing of
Code Generators Families
https://testingcodegenerators.wordpress.com
6
Contributions
7
 We propose:
• A runtime monitoring infrastructure, based on system containers (Docker) as
execution platforms, that allow code-generator developers to evaluate the
non-functional properties of generated code
• A black-box testing approach to automatically check the potential inefficient
code generators
Microservice-based infrastructure
8
 Execute and monitor of the generated code using system containers
 Different configurations, instances, images, machines, etc
 Resource isolation and management
 Less performance overhead
 Provide a fine-grained understanding and analysis of compilers behavior
 Automatic extraction of non-functional properties relative to resource usage
Approach Overview
9
Footprint C
Footprint A
DSL
(Model)
SUT
SUT
SUT
Design
Generate
Generate
Generate
Code
Generator A
Code
Generator B
Code
Generator C
Execute
Execute
Execute
C++
Platform C
Platform B
Platform A
JAVA
C#
Profiler A
Profiler B
Profiler C
Bugs
Finding
Report
Report
Report
Footprint B
Code Generation Non-functional TestingCode ExecutionSoftware Design
Container C
Container B
Container A
DSL
(Model)
SUT
SUT
SUT
Design
Generate
Generate
Generate
Code
Generator A
Code
Generator B
Code
Generator C
Code Generation Runtime monitoring engineCode ExecutionSoftware Design
Container A’
C#
Container B’
Container C’
Monitoring
Container
Back-end
Data Base
Container
Front-end
Visualization
Container
JAVA
C++
Footprint C’
Footprint A’
REST
Calls
Footprint B’Request
Bugs Finding
Approach Overview
000
000
Compile and execute the
generated code within
a new container instance
Gather at runtime non-
functional properties of running
programs under test
Save information relative
to resource consumptions
within a times series database
Analysis of the performance
and non-functional properties
of programs under test
1
2
3
4
Code
Execution
Runtime
Monitoring
Time series
Database
Performance
Analysis
10
Testing Infrastructure
Component
Under Test
Back-end
Database
Component
Cgroup file systems
Running…
Monitoring records
Front-end:
Visualization
Component
Time-series database
HTTP Requests
11
8086:
Monitoring
Component
…
Code
Generation +
Compilation
Software
Tester
Testing Method
12
Definition (Code generator family):
We define a code generator family as a set of code generators that takes as input
the same language/model and generate code for different target platforms
(example: Haxe, ThingML, etc)
Differential Testing:
Compare equivalent implementations of the same program written in different
languages
Standard deviation (std_dev):
Quantify the amount of variation among the execution traces in terms of memory
usage and execution time
Testing Method
13
Test suites with Std_dev > threshold value are interpreted as code generator
inconsistencies
…
Memory usage Memory usage Memory usage
Compare
Std_dev > kStd_dev < k
BugNo Bug
Evaluation
https://testingcodegenerators.wordpress.com/experimental-results/
14
Experimental Setup
Haxe Libraries + Test suites
For monitoring:
Google cAdvisor
For storage:
InfluxDB
Execution time (S)
Programs
under test:
Haxe Libraries
Code Generators
under Test:
Haxe Compilers
Non-functional metrics
Memory usage (MBytes)
15
5 targets: C#, C++, JAVA, JS, PHP
Validation
16
• The comparison results of
running each test suite across
five target languages: the
metric used is the standard
deviation between execution
times
• Standard deviations are mostly
close to 0 - 8 interval.
• 8 data points where the
std_dev was extreamly high
Validation
17
 Test suites with the highest variation in terms of execution time (k=60)
We can identify a singular behavior of the PHP code regarding the exectution
time
Validation
18
• The comparison results of
running each test suite across
five target languages: the
metric used is the standard
deviation between memory
consumptions
• Standard deviations are mostly
close to 0 - 150 interval.
• 6 data points where the
std_dev was extreamly high
Validation
19
 Test suites with the highest variation in terms of memory usage (k=400)
We can identify a singular behavior of the PHP code regarding the memory
usage
Validation
20
For Color_TS4 in PHP:
• We observe the intensive use of « arrays »
• We replace « arrays » by « SplFixedArray »
=> Speedup x5
=> Memory usage reduction x2
Conclusion
21
Conclusion
22
 Approach for testing and
monitoring the code generators
families using a container-based
infrastructure
 Automatically extract information
about the resource usage
 The evaluation results show that
we can find real issues in existing
code generators (i.e., PHP)
Summary
 Detect more code generator
issues (e.g., CPU consumption)
 Evaluate our approach:
• On other code generator families
• Compare to other state-of-the-art
approaches
Future directions
22
https://testingcodegenerators.wordpress.com 23
Questions?
Tool Support
24
Visualization
25
26
Code Generators Testing: ThingML

More Related Content

What's hot

Integrated Language Definition Testing: Enabling Test-Driven Language Develop...
Integrated Language Definition Testing: Enabling Test-Driven Language Develop...Integrated Language Definition Testing: Enabling Test-Driven Language Develop...
Integrated Language Definition Testing: Enabling Test-Driven Language Develop...lennartkats
 
The Spoofax Language Workbench (SPLASH 2010)
The Spoofax Language Workbench (SPLASH 2010)The Spoofax Language Workbench (SPLASH 2010)
The Spoofax Language Workbench (SPLASH 2010)lennartkats
 
Java Source Code Analysis using SonarQube
Java Source Code Analysis using SonarQubeJava Source Code Analysis using SonarQube
Java Source Code Analysis using SonarQubeAngelin R
 
torque - Automation Testing Tool for C-C++ on Linux
torque -  Automation Testing Tool for C-C++ on Linuxtorque -  Automation Testing Tool for C-C++ on Linux
torque - Automation Testing Tool for C-C++ on LinuxJITENDRA LENKA
 
Megha_Smriti_resume
Megha_Smriti_resumeMegha_Smriti_resume
Megha_Smriti_resumemegha smriti
 
An Overview of LLVM Link Time Optimization
An Overview of LLVM Link Time Optimization An Overview of LLVM Link Time Optimization
An Overview of LLVM Link Time Optimization Vivek Pandya
 
A Sneak Peek At Visual Studio 2010 And .Net Framework 4.0
A Sneak Peek At Visual Studio 2010 And .Net Framework 4.0A Sneak Peek At Visual Studio 2010 And .Net Framework 4.0
A Sneak Peek At Visual Studio 2010 And .Net Framework 4.0Antonio Chagoury
 
.net CLR
.net CLR.net CLR
.net CLRDevTalk
 
How to debug machine learning call stacks
How to debug machine learning call stacksHow to debug machine learning call stacks
How to debug machine learning call stacksRogue Wave Software
 

What's hot (20)

Integrated Language Definition Testing: Enabling Test-Driven Language Develop...
Integrated Language Definition Testing: Enabling Test-Driven Language Develop...Integrated Language Definition Testing: Enabling Test-Driven Language Develop...
Integrated Language Definition Testing: Enabling Test-Driven Language Develop...
 
The Spoofax Language Workbench (SPLASH 2010)
The Spoofax Language Workbench (SPLASH 2010)The Spoofax Language Workbench (SPLASH 2010)
The Spoofax Language Workbench (SPLASH 2010)
 
C-Sharp 6.0 ver2
C-Sharp 6.0 ver2C-Sharp 6.0 ver2
C-Sharp 6.0 ver2
 
C# language
C# languageC# language
C# language
 
Java Source Code Analysis using SonarQube
Java Source Code Analysis using SonarQubeJava Source Code Analysis using SonarQube
Java Source Code Analysis using SonarQube
 
ctchou-resume
ctchou-resumectchou-resume
ctchou-resume
 
Resume LinkedIn
Resume LinkedInResume LinkedIn
Resume LinkedIn
 
ctchou-resume
ctchou-resumectchou-resume
ctchou-resume
 
Python for Swift
Python for SwiftPython for Swift
Python for Swift
 
torque - Automation Testing Tool for C-C++ on Linux
torque -  Automation Testing Tool for C-C++ on Linuxtorque -  Automation Testing Tool for C-C++ on Linux
torque - Automation Testing Tool for C-C++ on Linux
 
Benefits of Extensions
Benefits of ExtensionsBenefits of Extensions
Benefits of Extensions
 
ctchou-resume
ctchou-resumectchou-resume
ctchou-resume
 
Megha_Smriti_resume
Megha_Smriti_resumeMegha_Smriti_resume
Megha_Smriti_resume
 
An Overview of LLVM Link Time Optimization
An Overview of LLVM Link Time Optimization An Overview of LLVM Link Time Optimization
An Overview of LLVM Link Time Optimization
 
Electron
ElectronElectron
Electron
 
A Sneak Peek At Visual Studio 2010 And .Net Framework 4.0
A Sneak Peek At Visual Studio 2010 And .Net Framework 4.0A Sneak Peek At Visual Studio 2010 And .Net Framework 4.0
A Sneak Peek At Visual Studio 2010 And .Net Framework 4.0
 
.net CLR
.net CLR.net CLR
.net CLR
 
How to debug machine learning call stacks
How to debug machine learning call stacksHow to debug machine learning call stacks
How to debug machine learning call stacks
 
Intro dotnet
Intro dotnetIntro dotnet
Intro dotnet
 
balaraju
balarajubalaraju
balaraju
 

Viewers also liked

QRS16: NOTICE: A Framework for Non-functional Testing of Compilers
QRS16: NOTICE: A Framework for Non-functional Testing of CompilersQRS16: NOTICE: A Framework for Non-functional Testing of Compilers
QRS16: NOTICE: A Framework for Non-functional Testing of CompilersMohamed BOUSSAA
 
Antlr Conference Drools & Hibernate
Antlr Conference   Drools & HibernateAntlr Conference   Drools & Hibernate
Antlr Conference Drools & HibernateAlexandre Porcelli
 
Installation testing
Installation testingInstallation testing
Installation testingRobin0590
 
Non-functional testing
Non-functional testingNon-functional testing
Non-functional testingVishwanath KC
 
Miller using scn egg counts and hg type testing
Miller using scn egg counts and hg type testingMiller using scn egg counts and hg type testing
Miller using scn egg counts and hg type testingnacaa
 
Functional testing
Functional testingFunctional testing
Functional testing99tests
 
Glimpse and Benefits of Testing
Glimpse and Benefits of TestingGlimpse and Benefits of Testing
Glimpse and Benefits of TestingSourabh Kasliwal
 
What are the advantages of non functional testing
What are the advantages of non functional testingWhat are the advantages of non functional testing
What are the advantages of non functional testingMaveric Systems
 
Non functional testing
Non functional testingNon functional testing
Non functional testingVaibhav Dash
 
Non Functional Testing_Sampath kumar Mohan
Non Functional Testing_Sampath kumar MohanNon Functional Testing_Sampath kumar Mohan
Non Functional Testing_Sampath kumar MohanSampath kumar Mohan
 

Viewers also liked (18)

QRS16: NOTICE: A Framework for Non-functional Testing of Compilers
QRS16: NOTICE: A Framework for Non-functional Testing of CompilersQRS16: NOTICE: A Framework for Non-functional Testing of Compilers
QRS16: NOTICE: A Framework for Non-functional Testing of Compilers
 
Antlr Conference Drools & Hibernate
Antlr Conference   Drools & HibernateAntlr Conference   Drools & Hibernate
Antlr Conference Drools & Hibernate
 
Installation testing
Installation testingInstallation testing
Installation testing
 
Non-functional testing
Non-functional testingNon-functional testing
Non-functional testing
 
Miller using scn egg counts and hg type testing
Miller using scn egg counts and hg type testingMiller using scn egg counts and hg type testing
Miller using scn egg counts and hg type testing
 
Re Type Testing
Re Type TestingRe Type Testing
Re Type Testing
 
Functional UI Testing
Functional UI TestingFunctional UI Testing
Functional UI Testing
 
Skillwise - 11 cat.ppt
Skillwise - 11 cat.pptSkillwise - 11 cat.ppt
Skillwise - 11 cat.ppt
 
Functional testing
Functional testingFunctional testing
Functional testing
 
Type Cross browsers testing
Type Cross browsers testingType Cross browsers testing
Type Cross browsers testing
 
Glimpse and Benefits of Testing
Glimpse and Benefits of TestingGlimpse and Benefits of Testing
Glimpse and Benefits of Testing
 
What are the advantages of non functional testing
What are the advantages of non functional testingWhat are the advantages of non functional testing
What are the advantages of non functional testing
 
Type Testing
Type TestingType Testing
Type Testing
 
Non functional testing
Non functional testingNon functional testing
Non functional testing
 
Testing type
Testing typeTesting type
Testing type
 
Non Functional Testing_Sampath kumar Mohan
Non Functional Testing_Sampath kumar MohanNon Functional Testing_Sampath kumar Mohan
Non Functional Testing_Sampath kumar Mohan
 
Compatibility Testing
Compatibility TestingCompatibility Testing
Compatibility Testing
 
Installation testing
Installation testingInstallation testing
Installation testing
 

Similar to GPCE16: Automatic Non-functional Testing of Code Generators Families

Presentation Verification & Validation
Presentation Verification & ValidationPresentation Verification & Validation
Presentation Verification & ValidationElmar Selbach
 
Rhapsody Software
Rhapsody SoftwareRhapsody Software
Rhapsody SoftwareBill Duncan
 
AdaCore Paris Tech Day 2016: Jose Ruiz - QGen Tech Update
AdaCore Paris Tech Day 2016: Jose Ruiz - QGen Tech UpdateAdaCore Paris Tech Day 2016: Jose Ruiz - QGen Tech Update
AdaCore Paris Tech Day 2016: Jose Ruiz - QGen Tech Updatejamieayre
 
Code Review with Sonar
Code Review with SonarCode Review with Sonar
Code Review with SonarMax Kleiner
 
Modernizing Testing as Apps Re-Architect
Modernizing Testing as Apps Re-ArchitectModernizing Testing as Apps Re-Architect
Modernizing Testing as Apps Re-ArchitectDevOps.com
 
oyedele_resume_updated
oyedele_resume_updatedoyedele_resume_updated
oyedele_resume_updatedAkin Oyedele
 
Recommendations for Building Machine Learning Software
Recommendations for Building Machine Learning SoftwareRecommendations for Building Machine Learning Software
Recommendations for Building Machine Learning SoftwareJustin Basilico
 
Enabling Visual Analytics with Unity - Exploring Regression Test Results in A...
Enabling Visual Analytics with Unity - Exploring Regression Test Results in A...Enabling Visual Analytics with Unity - Exploring Regression Test Results in A...
Enabling Visual Analytics with Unity - Exploring Regression Test Results in A...Markus Borg
 
.NET Fundamentals and Business Application Development
.NET Fundamentals and Business Application Development.NET Fundamentals and Business Application Development
.NET Fundamentals and Business Application Development명신 김
 
Continuous Inspection of Code Quality: SonarQube
Continuous Inspection of Code Quality: SonarQubeContinuous Inspection of Code Quality: SonarQube
Continuous Inspection of Code Quality: SonarQubeEmre Dündar
 
Justin Basilico, Research/ Engineering Manager at Netflix at MLconf SF - 11/1...
Justin Basilico, Research/ Engineering Manager at Netflix at MLconf SF - 11/1...Justin Basilico, Research/ Engineering Manager at Netflix at MLconf SF - 11/1...
Justin Basilico, Research/ Engineering Manager at Netflix at MLconf SF - 11/1...MLconf
 
Ukfs Snr Dev Arch Forum Pres3 Re
Ukfs Snr Dev Arch Forum Pres3 ReUkfs Snr Dev Arch Forum Pres3 Re
Ukfs Snr Dev Arch Forum Pres3 ReAllyWick
 
SRV312 DevOps on AWS: Building Systems to Deliver Faster
SRV312 DevOps on AWS: Building Systems to Deliver FasterSRV312 DevOps on AWS: Building Systems to Deliver Faster
SRV312 DevOps on AWS: Building Systems to Deliver FasterAmazon Web Services
 
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...Amazon Web Services
 
Machine programming
Machine programmingMachine programming
Machine programmingDESMOND YUEN
 

Similar to GPCE16: Automatic Non-functional Testing of Code Generators Families (20)

Presentation Verification & Validation
Presentation Verification & ValidationPresentation Verification & Validation
Presentation Verification & Validation
 
Rhapsody Software
Rhapsody SoftwareRhapsody Software
Rhapsody Software
 
AdaCore Paris Tech Day 2016: Jose Ruiz - QGen Tech Update
AdaCore Paris Tech Day 2016: Jose Ruiz - QGen Tech UpdateAdaCore Paris Tech Day 2016: Jose Ruiz - QGen Tech Update
AdaCore Paris Tech Day 2016: Jose Ruiz - QGen Tech Update
 
Rashmi_Resume
Rashmi_ResumeRashmi_Resume
Rashmi_Resume
 
Code Review with Sonar
Code Review with SonarCode Review with Sonar
Code Review with Sonar
 
Modernizing Testing as Apps Re-Architect
Modernizing Testing as Apps Re-ArchitectModernizing Testing as Apps Re-Architect
Modernizing Testing as Apps Re-Architect
 
Resume
ResumeResume
Resume
 
oyedele_resume_updated
oyedele_resume_updatedoyedele_resume_updated
oyedele_resume_updated
 
Recommendations for Building Machine Learning Software
Recommendations for Building Machine Learning SoftwareRecommendations for Building Machine Learning Software
Recommendations for Building Machine Learning Software
 
Enabling Visual Analytics with Unity - Exploring Regression Test Results in A...
Enabling Visual Analytics with Unity - Exploring Regression Test Results in A...Enabling Visual Analytics with Unity - Exploring Regression Test Results in A...
Enabling Visual Analytics with Unity - Exploring Regression Test Results in A...
 
.NET Fundamentals and Business Application Development
.NET Fundamentals and Business Application Development.NET Fundamentals and Business Application Development
.NET Fundamentals and Business Application Development
 
Continuous Inspection of Code Quality: SonarQube
Continuous Inspection of Code Quality: SonarQubeContinuous Inspection of Code Quality: SonarQube
Continuous Inspection of Code Quality: SonarQube
 
Justin Basilico, Research/ Engineering Manager at Netflix at MLconf SF - 11/1...
Justin Basilico, Research/ Engineering Manager at Netflix at MLconf SF - 11/1...Justin Basilico, Research/ Engineering Manager at Netflix at MLconf SF - 11/1...
Justin Basilico, Research/ Engineering Manager at Netflix at MLconf SF - 11/1...
 
Ukfs Snr Dev Arch Forum Pres3 Re
Ukfs Snr Dev Arch Forum Pres3 ReUkfs Snr Dev Arch Forum Pres3 Re
Ukfs Snr Dev Arch Forum Pres3 Re
 
Resume_Shanthi
Resume_ShanthiResume_Shanthi
Resume_Shanthi
 
SRV312 DevOps on AWS: Building Systems to Deliver Faster
SRV312 DevOps on AWS: Building Systems to Deliver FasterSRV312 DevOps on AWS: Building Systems to Deliver Faster
SRV312 DevOps on AWS: Building Systems to Deliver Faster
 
Effective DevSecOps
Effective DevSecOpsEffective DevSecOps
Effective DevSecOps
 
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
ENT201 A Tale of Two Pizzas: Accelerating Software Delivery with AWS Develope...
 
Machine programming
Machine programmingMachine programming
Machine programming
 
seibold_resume
seibold_resumeseibold_resume
seibold_resume
 

Recently uploaded

AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.arsicmarija21
 
Meghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media ComponentMeghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media ComponentInMediaRes1
 
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxEPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxRaymartEstabillo3
 
Gas measurement O2,Co2,& ph) 04/2024.pptx
Gas measurement O2,Co2,& ph) 04/2024.pptxGas measurement O2,Co2,& ph) 04/2024.pptx
Gas measurement O2,Co2,& ph) 04/2024.pptxDr.Ibrahim Hassaan
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Celine George
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxNirmalaLoungPoorunde1
 
Types of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxTypes of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxEyham Joco
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxpboyjonauth
 
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfLike-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfMr Bounab Samir
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon AUnboundStockton
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
Presiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsPresiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsanshu789521
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxiammrhaywood
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxthorishapillay1
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...JhezDiaz1
 
DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersSabitha Banu
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 

Recently uploaded (20)

AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.AmericanHighSchoolsprezentacijaoskolama.
AmericanHighSchoolsprezentacijaoskolama.
 
Meghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media ComponentMeghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media Component
 
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
 
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxEPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
 
Gas measurement O2,Co2,& ph) 04/2024.pptx
Gas measurement O2,Co2,& ph) 04/2024.pptxGas measurement O2,Co2,& ph) 04/2024.pptx
Gas measurement O2,Co2,& ph) 04/2024.pptx
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptx
 
Types of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxTypes of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptx
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptx
 
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfLike-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon A
 
9953330565 Low Rate Call Girls In Rohini Delhi NCR
9953330565 Low Rate Call Girls In Rohini  Delhi NCR9953330565 Low Rate Call Girls In Rohini  Delhi NCR
9953330565 Low Rate Call Girls In Rohini Delhi NCR
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
 
Presiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsPresiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha elections
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptx
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
 
DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginners
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 

GPCE16: Automatic Non-functional Testing of Code Generators Families

  • 1. Automatic Non-functional Testing of Code Generators Families Mohamed BOUSSAA Olivier BARAIS Gerson SUNYE Benoit BAUDRY 2016 IEEE International Conference on Software Quality, Reliability & Security (QRS 2016) August 1-3, 2016 - Vienna, Austria INRIA Rennes, France 15th International Conference on Generative Programming: Concepts & Experiences (GPCE 2016) Amsterdam, Netherlands, October 31 – November 1, 2016 1
  • 2. a1. Context a2. Motivation a3. Automatic Non-functional Testing of Code Generators Families a4. Performance Evaluation a5. Conclusion Outline 2
  • 3. Context 3 Software Platform Diversity Software Design Automatic Code Generation Software Designer DSL Model GPL Specs GUI Code Generator creators/maintainers Code generators Generated code All tests are successfully passed but… How about the non-functional properties (quality) of generated code ? Code generators are used everywhere They automatically transform high-level system specifications (Models, DSLs, GUIs, etc.) into general-purpose languages (JAVA, C++, C#, etc.) Target diverse and heterogeneous software platorms
  • 4. Context 4 • Testing issues: - Defective code generators may generate poor-quality code - Testing the non-functional properties is time-consuming - Require examining different non-functional requirements - Code generators are complex and difficult to understand (involve complex and hetergenous technologies)
  • 5. Motivation 5  Non-functional testing of code generators: The traditional way • Analyze the non-functional properties of generated code using platform- specific tools, profilers, etc. Lack of tools for automatic non-functional testing of code generators Footprint C Footprint A DSL (Model) SUT SUT SUT Design Generate Generate Generate Code Generator A Code Generator B Code Generator C Execute Execute Execute C++ Platform C Platform B Platform A JAVA C# Profiler A Profiler B Profiler C Bugs Finding Report Report Report Footprint B Code Generation Non-functional TestingCode ExecutionSoftware Design
  • 6. Automatic Non-functional Testing of Code Generators Families https://testingcodegenerators.wordpress.com 6
  • 7. Contributions 7  We propose: • A runtime monitoring infrastructure, based on system containers (Docker) as execution platforms, that allow code-generator developers to evaluate the non-functional properties of generated code • A black-box testing approach to automatically check the potential inefficient code generators
  • 8. Microservice-based infrastructure 8  Execute and monitor of the generated code using system containers  Different configurations, instances, images, machines, etc  Resource isolation and management  Less performance overhead  Provide a fine-grained understanding and analysis of compilers behavior  Automatic extraction of non-functional properties relative to resource usage
  • 9. Approach Overview 9 Footprint C Footprint A DSL (Model) SUT SUT SUT Design Generate Generate Generate Code Generator A Code Generator B Code Generator C Execute Execute Execute C++ Platform C Platform B Platform A JAVA C# Profiler A Profiler B Profiler C Bugs Finding Report Report Report Footprint B Code Generation Non-functional TestingCode ExecutionSoftware Design Container C Container B Container A DSL (Model) SUT SUT SUT Design Generate Generate Generate Code Generator A Code Generator B Code Generator C Code Generation Runtime monitoring engineCode ExecutionSoftware Design Container A’ C# Container B’ Container C’ Monitoring Container Back-end Data Base Container Front-end Visualization Container JAVA C++ Footprint C’ Footprint A’ REST Calls Footprint B’Request Bugs Finding
  • 10. Approach Overview 000 000 Compile and execute the generated code within a new container instance Gather at runtime non- functional properties of running programs under test Save information relative to resource consumptions within a times series database Analysis of the performance and non-functional properties of programs under test 1 2 3 4 Code Execution Runtime Monitoring Time series Database Performance Analysis 10
  • 11. Testing Infrastructure Component Under Test Back-end Database Component Cgroup file systems Running… Monitoring records Front-end: Visualization Component Time-series database HTTP Requests 11 8086: Monitoring Component … Code Generation + Compilation Software Tester
  • 12. Testing Method 12 Definition (Code generator family): We define a code generator family as a set of code generators that takes as input the same language/model and generate code for different target platforms (example: Haxe, ThingML, etc) Differential Testing: Compare equivalent implementations of the same program written in different languages Standard deviation (std_dev): Quantify the amount of variation among the execution traces in terms of memory usage and execution time
  • 13. Testing Method 13 Test suites with Std_dev > threshold value are interpreted as code generator inconsistencies … Memory usage Memory usage Memory usage Compare Std_dev > kStd_dev < k BugNo Bug
  • 15. Experimental Setup Haxe Libraries + Test suites For monitoring: Google cAdvisor For storage: InfluxDB Execution time (S) Programs under test: Haxe Libraries Code Generators under Test: Haxe Compilers Non-functional metrics Memory usage (MBytes) 15 5 targets: C#, C++, JAVA, JS, PHP
  • 16. Validation 16 • The comparison results of running each test suite across five target languages: the metric used is the standard deviation between execution times • Standard deviations are mostly close to 0 - 8 interval. • 8 data points where the std_dev was extreamly high
  • 17. Validation 17  Test suites with the highest variation in terms of execution time (k=60) We can identify a singular behavior of the PHP code regarding the exectution time
  • 18. Validation 18 • The comparison results of running each test suite across five target languages: the metric used is the standard deviation between memory consumptions • Standard deviations are mostly close to 0 - 150 interval. • 6 data points where the std_dev was extreamly high
  • 19. Validation 19  Test suites with the highest variation in terms of memory usage (k=400) We can identify a singular behavior of the PHP code regarding the memory usage
  • 20. Validation 20 For Color_TS4 in PHP: • We observe the intensive use of « arrays » • We replace « arrays » by « SplFixedArray » => Speedup x5 => Memory usage reduction x2
  • 22. Conclusion 22  Approach for testing and monitoring the code generators families using a container-based infrastructure  Automatically extract information about the resource usage  The evaluation results show that we can find real issues in existing code generators (i.e., PHP) Summary  Detect more code generator issues (e.g., CPU consumption)  Evaluate our approach: • On other code generator families • Compare to other state-of-the-art approaches Future directions 22