SlideShare a Scribd company logo
Astrid Younang & Lunjin Lu & Nabil Almashfi
March 3,2017
Outline
1. Motivation
2. Related Work
3. Conventionality Analysis
4. Conclusion and Future Work
Motivation
 JavaScript objects have dynamic set of fields
(properties)
 Arrays are just like regular objects with the property
(field) length that is automatically updated;
 Arrays can have fields whose names are not indices;
 Are they used like regular objects?
 Are they used in a conventional way like in Java ?
Motivation
 A conventional array is an array that does not have
any properties other than indices and length.
 Conventionality analysis
• provides valuable information for program
comprehension
• provides valuable information for performance
optimization
• Feature to add to JavaScript development tool
var A = [ ] ; / New empty array /
var i ;
function populate_array (x,y,A) {
for (i=x ; i<=y ; i++) {
A[i]= 2*i +10;
}
return A;
}
A = populate_array (0, 3, A) ;
A = populate_array (6, 10, A) ;
A.prop1 = “foo” ;
i= -3.5; A[i] = true;
[0, 3]  [10,16], [6,10] [22,30], // A has indexes 0—3, 6—10
// A is not dense
“prop1”  “foo”,
SNum true // A is not conventional
“length”  11
Information tracked by
conventional analysis
 String information: what strings a variable can take as
value?
 Number information: what numbers a variable can
take as a value?
 Type information: is a number definitely integer or
possibly a floating point number?
Related Work
 Existing abstract string domains
 Constant propagation domain for strings
(TAJS, SAFE, JSAI)
 Character inclusion, prefix domain, suffix
domain, bricks and string graphs
 Automata-based string domains
Related Work
Existing abstract string domains
 do not track range of indexes (which are
strings) precisely
 do not supports conventionality analysis
Abstract string domain

Abstract string domain- Operations
n – a non-index numeric string
r – a non-numeric string
Abstract numeric domain
 Range -- Interval domain
intv(3,5) – all numbers between 3 and 5
norm(3,5) – all numbers between 3 and d plus NaN
Type -- <int, any>
Evaluation
 Studied 98 benchmark programs
 70 out of them had less than 2 arrays
(were omitted)
Evaluation
Evaluation
Only conventional arrays were found on
GitHub
o Programmers most likely use arrays in a
conventional way and flagging possible
non-conventional arrays provides useful
information during program
development.
Evaluation
 Arrays are used in a conventional way
in 95% of the benchmark programs.
Storage of single/mixed types
o 377 arrays analyzed
o 11.93% - string values
o 33% - integer values
Conclusion & Future work
 Conventionality analysis can be
integrated in static analyzers
 Future work will investigate the use the
use of array information for
performance optimization

More Related Content

PPT
Modern Compiler Design
PPT
Templates
PPTX
Lecture 1 Introduction C++
PDF
TMPA-2017: Modeling of PLC-programs by High-level Coloured Petri Nets
PDF
Gnu octave
PDF
Sperasoft‬ talks j point 2015
PPT
PPTX
Templates in c++
Modern Compiler Design
Templates
Lecture 1 Introduction C++
TMPA-2017: Modeling of PLC-programs by High-level Coloured Petri Nets
Gnu octave
Sperasoft‬ talks j point 2015
Templates in c++

What's hot (9)

PDF
Hidden Truths in Dead Software Paths
PPT
12. Stack
PPT
PDF
Safety Beyond Types
PDF
PPTX
Transfer learning, active learning using tensorflow object detection api
PPTX
PPTX
Advanced Functional Programming in Scala
PDF
Generics past, present and future
Hidden Truths in Dead Software Paths
12. Stack
Safety Beyond Types
Transfer learning, active learning using tensorflow object detection api
Advanced Functional Programming in Scala
Generics past, present and future
Ad

Viewers also liked (20)

PDF
TMPA-2017: Compositional Process Model Synthesis based on Interface Patterns
PDF
TMPA-2017: Distributed Analysis of the BMC Kind: Making It Fit the Tornado Su...
PDF
TMPA-2017: Conference Opening
PDF
TMPA-2017: Vellvm - Verifying the LLVM
PDF
TMPA-2017: Unity Application Testing Automation with Appium and Image Recogni...
PDF
TMPA-2017: Live testing distributed system fault tolerance with fault injecti...
PDF
TMPA-2017: 5W+1H Static Analysis Report Quality Measure
PDF
TMPA-2017: Generating Cost Aware Covering Arrays For Free
PDF
TMPA-2017: Defect Report Classification in Accordance with Areas of Testing
PDF
TMPA-2017: Technology and Tools for Developing Industrial Software Test Suite...
PDF
TMPA-2017: Using Functional Directives to Analyze Code Complexity and Communi...
PDF
TMPA-2017: Regression Testing with Semiautomatic Test Selection for Auditing ...
PDF
TMPA-2017: Functional Parser of Markdown Language Based on Monad Combining an...
PDF
TMPA-2017: Stemming Architectural Decay in Software Systems
PDF
TMPA-2017: The Quest for Average Response Time
PDF
TMPA-2017: Evolutionary Algorithms in Test Generation for digital systems
PDF
TMPA-2017: A Survey of High-Performance Computing for Software Verification
PDF
TMPA-2017: Layered Layouts for Software Systems Visualization
PDF
TMPA-2017: Predicate Abstraction Based Configurable Method for Data Race Dete...
PDF
TMPA-2017: Dl-Check: Dynamic Potential Deadlock Detection Tool for Java Programs
TMPA-2017: Compositional Process Model Synthesis based on Interface Patterns
TMPA-2017: Distributed Analysis of the BMC Kind: Making It Fit the Tornado Su...
TMPA-2017: Conference Opening
TMPA-2017: Vellvm - Verifying the LLVM
TMPA-2017: Unity Application Testing Automation with Appium and Image Recogni...
TMPA-2017: Live testing distributed system fault tolerance with fault injecti...
TMPA-2017: 5W+1H Static Analysis Report Quality Measure
TMPA-2017: Generating Cost Aware Covering Arrays For Free
TMPA-2017: Defect Report Classification in Accordance with Areas of Testing
TMPA-2017: Technology and Tools for Developing Industrial Software Test Suite...
TMPA-2017: Using Functional Directives to Analyze Code Complexity and Communi...
TMPA-2017: Regression Testing with Semiautomatic Test Selection for Auditing ...
TMPA-2017: Functional Parser of Markdown Language Based on Monad Combining an...
TMPA-2017: Stemming Architectural Decay in Software Systems
TMPA-2017: The Quest for Average Response Time
TMPA-2017: Evolutionary Algorithms in Test Generation for digital systems
TMPA-2017: A Survey of High-Performance Computing for Software Verification
TMPA-2017: Layered Layouts for Software Systems Visualization
TMPA-2017: Predicate Abstraction Based Configurable Method for Data Race Dete...
TMPA-2017: Dl-Check: Dynamic Potential Deadlock Detection Tool for Java Programs
Ad

Similar to TMPA-2017: Static Checking of Array Objects in JavaScript (20)

PDF
Numpy.pdf
PPTX
Data Science Using Scikit-Learn
PPTX
Data structures in c#
DOCX
array model.docx
PDF
Generic Programming
PPTX
Introduction-to-Arrays-in-Java . Exploring array
PPTX
ppt on arrays in c programming language.pptx
PDF
A Brief Overview of (Static) Program Query Languages
PPTX
NumPy.pptx
PPTX
2 Arrays & Strings.pptx
PPTX
unit 2.pptx
PDF
Java R20 - UNIT-3.pdf Java R20 - UNIT-3.pdf
DOCX
Array andfunction
PDF
Standardizing on a single N-dimensional array API for Python
PDF
Standardizing arrays -- Microsoft Presentation
PDF
Lecture 8_٠٨٣٣٣٦taiz unvercity object oreinted programming.pdf
PPTX
22CS307-ADAVANCE JAVA PROGRAMMING UNIT 5
PPTX
Java 103
DOCX
Data structure and algorithm.
PPTX
Introduction to numpy.pptx
Numpy.pdf
Data Science Using Scikit-Learn
Data structures in c#
array model.docx
Generic Programming
Introduction-to-Arrays-in-Java . Exploring array
ppt on arrays in c programming language.pptx
A Brief Overview of (Static) Program Query Languages
NumPy.pptx
2 Arrays & Strings.pptx
unit 2.pptx
Java R20 - UNIT-3.pdf Java R20 - UNIT-3.pdf
Array andfunction
Standardizing on a single N-dimensional array API for Python
Standardizing arrays -- Microsoft Presentation
Lecture 8_٠٨٣٣٣٦taiz unvercity object oreinted programming.pdf
22CS307-ADAVANCE JAVA PROGRAMMING UNIT 5
Java 103
Data structure and algorithm.
Introduction to numpy.pptx

More from Iosif Itkin (20)

PDF
Foundations of Software Testing Lecture 4
PPTX
QA Financial Forum London 2021 - Automation in Software Testing. Humans and C...
PDF
Exactpro FinTech Webinar - Global Exchanges Test Oracles
PDF
Exactpro FinTech Webinar - Global Exchanges FIX Protocol
PDF
Operational Resilience in Financial Market Infrastructures
PDF
20 Simple Questions from Exactpro for Your Enjoyment This Holiday Season
PDF
Testing the Intelligence of your AI
PDF
EXTENT 2019: Exactpro Quality Assurance for Financial Market Infrastructures
PDF
ClearTH Test Automation Framework: Case Study in IRS & CDS Swaps Lifecycle Mo...
PPTX
EXTENT Talks 2019 Tbilisi: Failover and Recovery Test Automation - Ivan Shamrai
PDF
EXTENT Talks QA Community Tbilisi 20 April 2019 - Conference Open
PDF
User-Assisted Log Analysis for Quality Control of Distributed Fintech Applica...
PPTX
QAFF Chicago 2019 - Complex Post-Trade Systems, Requirements Traceability and...
PDF
QA Community Saratov: Past, Present, Future (2019-02-08)
PDF
Machine Learning and RoboCop Testing
PDF
Behaviour Driven Development: Oltre i limiti del possibile
PDF
2018 - Exactpro Year in Review
PPTX
Exactpro Discussion about Joy and Strategy
PPTX
FIX EMEA Conference 2018 - Post Trade Software Testing Challenges
PDF
BDD. The Outer Limits. Iosif Itkin at Youcon (in Russian)
Foundations of Software Testing Lecture 4
QA Financial Forum London 2021 - Automation in Software Testing. Humans and C...
Exactpro FinTech Webinar - Global Exchanges Test Oracles
Exactpro FinTech Webinar - Global Exchanges FIX Protocol
Operational Resilience in Financial Market Infrastructures
20 Simple Questions from Exactpro for Your Enjoyment This Holiday Season
Testing the Intelligence of your AI
EXTENT 2019: Exactpro Quality Assurance for Financial Market Infrastructures
ClearTH Test Automation Framework: Case Study in IRS & CDS Swaps Lifecycle Mo...
EXTENT Talks 2019 Tbilisi: Failover and Recovery Test Automation - Ivan Shamrai
EXTENT Talks QA Community Tbilisi 20 April 2019 - Conference Open
User-Assisted Log Analysis for Quality Control of Distributed Fintech Applica...
QAFF Chicago 2019 - Complex Post-Trade Systems, Requirements Traceability and...
QA Community Saratov: Past, Present, Future (2019-02-08)
Machine Learning and RoboCop Testing
Behaviour Driven Development: Oltre i limiti del possibile
2018 - Exactpro Year in Review
Exactpro Discussion about Joy and Strategy
FIX EMEA Conference 2018 - Post Trade Software Testing Challenges
BDD. The Outer Limits. Iosif Itkin at Youcon (in Russian)

Recently uploaded (20)

PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PPTX
OMC Textile Division Presentation 2021.pptx
PPTX
SOPHOS-XG Firewall Administrator PPT.pptx
PPTX
TechTalks-8-2019-Service-Management-ITIL-Refresh-ITIL-4-Framework-Supports-Ou...
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PPTX
Programs and apps: productivity, graphics, security and other tools
PPTX
Machine Learning_overview_presentation.pptx
PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
PDF
MIND Revenue Release Quarter 2 2025 Press Release
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PDF
Machine learning based COVID-19 study performance prediction
PDF
Assigned Numbers - 2025 - Bluetooth® Document
PDF
August Patch Tuesday
PDF
Accuracy of neural networks in brain wave diagnosis of schizophrenia
PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PDF
Approach and Philosophy of On baking technology
PDF
NewMind AI Weekly Chronicles - August'25-Week II
PPTX
Group 1 Presentation -Planning and Decision Making .pptx
Advanced methodologies resolving dimensionality complications for autism neur...
OMC Textile Division Presentation 2021.pptx
SOPHOS-XG Firewall Administrator PPT.pptx
TechTalks-8-2019-Service-Management-ITIL-Refresh-ITIL-4-Framework-Supports-Ou...
Diabetes mellitus diagnosis method based random forest with bat algorithm
Programs and apps: productivity, graphics, security and other tools
Machine Learning_overview_presentation.pptx
Unlocking AI with Model Context Protocol (MCP)
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
MIND Revenue Release Quarter 2 2025 Press Release
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Machine learning based COVID-19 study performance prediction
Assigned Numbers - 2025 - Bluetooth® Document
August Patch Tuesday
Accuracy of neural networks in brain wave diagnosis of schizophrenia
Building Integrated photovoltaic BIPV_UPV.pdf
Approach and Philosophy of On baking technology
NewMind AI Weekly Chronicles - August'25-Week II
Group 1 Presentation -Planning and Decision Making .pptx

TMPA-2017: Static Checking of Array Objects in JavaScript

  • 1. Astrid Younang & Lunjin Lu & Nabil Almashfi March 3,2017
  • 2. Outline 1. Motivation 2. Related Work 3. Conventionality Analysis 4. Conclusion and Future Work
  • 3. Motivation  JavaScript objects have dynamic set of fields (properties)  Arrays are just like regular objects with the property (field) length that is automatically updated;  Arrays can have fields whose names are not indices;  Are they used like regular objects?  Are they used in a conventional way like in Java ?
  • 4. Motivation  A conventional array is an array that does not have any properties other than indices and length.  Conventionality analysis • provides valuable information for program comprehension • provides valuable information for performance optimization • Feature to add to JavaScript development tool
  • 5. var A = [ ] ; / New empty array / var i ; function populate_array (x,y,A) { for (i=x ; i<=y ; i++) { A[i]= 2*i +10; } return A; } A = populate_array (0, 3, A) ; A = populate_array (6, 10, A) ; A.prop1 = “foo” ; i= -3.5; A[i] = true; [0, 3]  [10,16], [6,10] [22,30], // A has indexes 0—3, 6—10 // A is not dense “prop1”  “foo”, SNum true // A is not conventional “length”  11
  • 6. Information tracked by conventional analysis  String information: what strings a variable can take as value?  Number information: what numbers a variable can take as a value?  Type information: is a number definitely integer or possibly a floating point number?
  • 7. Related Work  Existing abstract string domains  Constant propagation domain for strings (TAJS, SAFE, JSAI)  Character inclusion, prefix domain, suffix domain, bricks and string graphs  Automata-based string domains
  • 8. Related Work Existing abstract string domains  do not track range of indexes (which are strings) precisely  do not supports conventionality analysis
  • 10. Abstract string domain- Operations n – a non-index numeric string r – a non-numeric string
  • 11. Abstract numeric domain  Range -- Interval domain intv(3,5) – all numbers between 3 and 5 norm(3,5) – all numbers between 3 and d plus NaN Type -- <int, any>
  • 12. Evaluation  Studied 98 benchmark programs  70 out of them had less than 2 arrays (were omitted)
  • 14. Evaluation Only conventional arrays were found on GitHub o Programmers most likely use arrays in a conventional way and flagging possible non-conventional arrays provides useful information during program development.
  • 15. Evaluation  Arrays are used in a conventional way in 95% of the benchmark programs. Storage of single/mixed types o 377 arrays analyzed o 11.93% - string values o 33% - integer values
  • 16. Conclusion & Future work  Conventionality analysis can be integrated in static analyzers  Future work will investigate the use the use of array information for performance optimization