Demo of Scalable Pluggable Types Michael Ernst MIT Dagstuhl Seminar “Scalable Program Analysis” April 17, 2008.

Slides:



Advertisements
Similar presentations
Author: Carlos Pacheco, Shuvendu K. Lahiri, Michael D. Ernst, Thomas Ball MIT CSAIL.
Advertisements

Copyright © 2002 W. A. Tucker1 Chapter 1 Lecture Notes Bill Tucker Austin Community College COSC 1315.
Preventing bugs with pluggable type checking Michael D. Ernst University of Washington Object x)
GUI Threading Explained and Verified Michael Ernst U. of Washington, Seattle, USA IMDEA Software Institute, Madrid, Spain joint work with Colin Gordon,
Automated creation of verification models for C-programs Yury Yusupov Saint-Petersburg State Polytechnic University The Second Spring Young Researchers.
MATLAB Presented By: Nathalie Tacconi Presented By: Nathalie Tacconi Originally Prepared By: Sheridan Saint-Michel Originally Prepared By: Sheridan Saint-Michel.
Static code check – Klocwork
Detecting and preventing bugs with pluggable type-checking Michael D. Ernst University of Washington Joint work with Mahmood Ali, Werner Dietl, …
CS2200 Software Development Lecture 2: Java Program Development Lecturer: Adrian O’Riordan Course Webpage:
An overview of JML tools and applications Lilian Burdy Gemplus Yoonsik Cheon, Gary Leavens Iowa Univ. David Cok Kodak Michael Ernst MIT Rustan Leino Microsoft.
Turning Eclipse Against Itself: Finding Errors in Eclipse Sources Benjamin Livshits Stanford University.
Introduction to a Programming Environment
Chapter 3.2 C++, Java, and Scripting Languages hacked by jeffery.
UNIT4 BUSINESS ANALYTICS. page WHAT IS THE PRODUCT? 2 A business intelligence tool kit, specializing in Coporate Performance Management An application.
Java Swing Joon Ho Cho. What is Java Swing? Part of the Java Foundation Classes (JFC) Provides a rich set of GUI components Used to create a Java program.
Usable code verification: balancing costs and benefits Two nuggets: User-defined verifiers Crowd-sourced verification Michael D. Ernst University of Washington.
Getting Started With Java Downloading and installing software Running your first program Dr. DwyerFall 2012.
Introduction to High-Level Language Programming
Polyglot An Extensible Compiler Framework for Java Nathaniel Nystrom Michael R. Clarkson Andrew C. Myers Cornell University.
© Janice Regan, CMPT 128, Jan CMPT 128 Introduction to Computing Science for Engineering Students Creating a program.
Towards Scalable Modular Checking of User-defined Properties Thomas Ball, MSR Brian Hackett, Mozilla Shuvendu Lahiri, MSR Shaz Qadeer, MSR Julien Vanegue,
Integrated Development Environments (IDEs) CS 21a: Introduction to Computing I First Semester,
Software Engineering Prof. Dr. Bertrand Meyer March 2007 – June 2007 Chair of Software Engineering Static program checking and verification Slides: Based.
Programming. What is a Program ? Sets of instructions that get the computer to do something Instructions are translated, eventually, to machine language.
Michael Ernst, page 1 Collaborative Learning for Security and Repair in Application Communities Performers: MIT and Determina Michael Ernst MIT Computer.
CSCE 548 Code Review. CSCE Farkas2 Reading This lecture: – McGraw: Chapter 4 – Recommended: Best Practices for Peer Code Review,
1 Module Objective & Outline Module Objective: After completing this Module, you will be able to, appreciate java as a programming language, write java.
Object x) { List lst; … } Detecting and preventing null pointer errors with pluggable type-checking CSE 331 University of Washington.
Program documentation using the Javadoc tool 1 Program documentation Using the Javadoc tool.
IDEs Department of Information Systems and Computer Science Ateneo de Manila University.
Preventing bugs with pluggable type checking Michael Ernst and Mahmood Ali University of Washington and MIT OOPSLA 2009 tutorial Object.
Testing and Debugging Session 9 LBSC 790 / INFM 718B Building the Human-Computer Interface.
User-defined type checkers for error detection and prevention in Java Michael D. Ernst MIT Computer Science & AI Lab
1 CS210 Intermediate Computing with Data Structures (Java) Saaid Baraty S-3-90.
15/06/2006 The Future of Visual DCT EPICS Collaboration 2006 Argonne National Laboratory
© 2002 IBM Corporation Confidential | Date | Other Information, if necessary June, 2011 Made available under the Eclipse Public License v Mobile.
Unit Testing with JUnit and Clover Based on material from: Daniel Amyot JUnit Web site.
Eclipse 24-Apr-17.
Application of Design Heuristics in the Designing and Implementation of Object Oriented Informational Systems.
22-July-2002cse142-13B-Development © 2002 University of Washington1 Development Tools CSE 142, Summer 2002 Computer Programming 1
How analysis can hinder source code manipulaton And what to do about it Michael Ernst University of Washington.
May08-21 Model-Based Software Development Kevin Korslund Daniel De Graaf Cory Kleinheksel Benjamin Miller Client – Rockwell Collins Faculty Advisor – Dr.
JSR 308: Type Annotations Making Java annotations more general and more useful Spec leads: Michael Ernst & Alex Buckley Implementation lead: Werner Dietl.
What’s New in Windows Forms 2.0 Stephen Turner Software Design Engineer
Java Annotations for Types and Expressions Mathias Ricken October 24, 2008 COMP 617 Seminar.
STL CSSE 250 Susan Reeder. What is the STL? Standard Template Library Standard C++ Library is an extensible framework which contains components for Language.
Detecting and preventing bugs with pluggable type-checking Michael D. Ernst University of Washington Joint work with Werner Dietl, and many others
Integrated Development Environments (IDEs) CS 21a: Introduction to Computing I Department of Information Systems and Computer Science Ateneo de Manila.
Combining Static and Dynamic Reasoning for Bug Detection Yannis Smaragdakis and Christoph Csallner Elnatan Reisner – April 17, 2008.
Preventing bugs with pluggable type checking Michael Ernst University of Washington Joint work with Mahmood Ali and Matthew Papi Object.
Random Test Generation of Unit Tests: Randoop Experience
Preventing bugs with pluggable type-checking Michael Ernst MIT
Michael Ernst, page 1 Application Communities: Next steps MIT & Determina October 2006.
Eclipse 27-Apr-17.
CS 440 Database Management Systems Stored procedures & OR mapping 1.
Debugging using By: Samuel Ashby. What is debugging?  A bug is an error in either a program or the hardware itself.  Debugging is first locating and.
ECLIPSE RICH CLIENT PLATFORM Part 1 Introduction.
Netbeanstcl (A netbeans plugin for Tcl) A GSoC (Google Summer of Code) Project by Michal Poczwardowski.
Jeremy Nimmer, page 1 Automatic Generation of Program Specifications Jeremy Nimmer MIT Lab for Computer Science Joint work with.
Continuous Testing in Eclipse
The need for Programming Languages
Javarifier: inference of reference immutability
Testing and Debugging.
Accessible Formal Methods A Study of the Java Modeling Language
CBCD: Cloned Buggy Code Detector
runtime verification Brief Overview Grigore Rosu
The JSF Tools Project – WTP (internal) release review
Semantic Type Qualifiers
Review of Previous Lesson
Presentation transcript:

Demo of Scalable Pluggable Types Michael Ernst MIT Dagstuhl Seminar “Scalable Program Analysis” April 17, 2008

Brief summary Pluggable type-checking for Java Detect and prevent more bugs than Java types Programming language support for syntax Framework for writing type checkers 5 checkers written using the framework Case studies enabled by the infrastructure Insights about the type systems

Questions Which problem does your tool solve? What kind of analysis is the tool using? What are the strengths/weaknesses of the tool (e.g. which language features are (not) supported?) Usability: What and (qualitatively) how many user annotations does the tool need, if any, for (a) primary functionality, and (b) filtering false alarms? How does your tool interface with other tools? Under what conditions is it available (free download, commercial product)? If you were to write your tool from scratch again, what would you do differently?

Which problem does your tool address? Java types prevent many errors Java types don’t prevent enough errors Programmers wish to check: –Null dereferences, equality errors, mutability Tool writers wish to write new checkers Type system designers wish to experimentally evaluate their ideas Only for checkers that can be expressed as a type system

What analysis does the tool use? Type-checking In any type system that is an extension (refinement) of the Java type system

Tool strengths/weaknesses Only for checkers that can be expressed as a type system Handles all of Java, scales to >200KLOC No built-in analysis of reflection, native methods, unanalyzed code –Can add annotations Run-time checking is possible –Published algorithms for doing so in Javari, non-null –Not supported by the toolset

Usability: How many user annotations does the tool need? User annotations are required: type checking, not type inference –If run without annotations: Null reference checker: many false positives Mutability checker: reports no problems For legacy code: –Null reference checking: 1 per 75 lines –Equality checking: 1 per 2000 lines –Mutation checking: 1 per 50 lines User effort is spent on understanding/fixing code, not on writing annotations Fewer in new (better-designed) code Inference tools exist for Javari, NonNull, Nullable –Inserts annotations into source or.class files

How does your tool interface with other tools? Integrated with Java toolchain –Plug-in to javac compiler: supply an additional command-line argument, output in same format Annotations are preserved in classfiles New checkers written in Java –Declarative: meta-annotations –Procedural: use Sun Tree API IDE integration: –Can run as an external builder –NetBeans support is experimental –Eclipse and IntelliJ support are underway Integrated with JastAdd, other tools underway

Availability of the tool Free download (in source and binary) User manual, examples, mailing list

What would you do differently if you started over? It took a lot longer than I expected –Especially extending the Java language Our approach was a pragmatic one, steered by existing problems: This worked very well! –Didn’t propose a framework before writing several checkers –Didn’t propose a syntax for expressing type systems before writing several –Focused on expressiveness of checkers before conciseness –Focused on both soundness and practicality –First fixed the bugs that users cared about Tools are better today (and javac license is better) –Could avoid some dead ends and clean-room reimplementation