Runtime Assertion Checking Support for JML on Eclipse Platform Amritam Sarcar Department of Computer Science University of Texas at El Paso, 500 W. University.

Slides:



Advertisements
Similar presentations
Agenda Definitions Evolution of Programming Languages and Personal Computers The C Language.
Advertisements

Prescriptive Process models
Towards Self-Testing in Autonomic Computing Systems Tariq M. King, Djuradj Babich, Jonatan Alava, and Peter J. Clarke Software Testing Research Group Florida.
Kellan Hilscher. Definition Different perspectives on the components, behavioral specifications, and interactions that make up a software system Importance.
The System and Software Development Process Instructor: Dr. Hany H. Ammar Dept. of Computer Science and Electrical Engineering, WVU.
System Analysis and Design
© Chinese University, CSE Dept. Software Engineering / Software Engineering Topic 1: Software Engineering: A Preview Your Name: ____________________.
Software Process Models
Prof Fateman CS 164 Lecture 371 Review: Programming Languages and Compilers CS AM MWF 10 Evans.
H Apr-01 Clark Thomborson Software Security CompSci 725 Handout 28: Report Writing #2 (Sample Titles & Abstracts) Clark Thomborson University of.
Case Tools Trisha Cummings. Our Definition of CASE  CASE is the use of computer-based support in the software development process.  A CASE tool is a.
Educating Programmers: A Customer Perspective Alexander Stepanov A9.com Workshop on Quality Software: A Festschrift for Bjarne Stroustrup Texas A&M University,
Dept. of Computer Science A Runtime Assertion Checker for the Java Modeling Language (JML) Yoonsik Cheon and Gary T. Leavens SERP 2002, June 24-27, 2002.
Web services for Improving the development of automatic generalisation solutions Nicolas Regnauld Research & Innovarion Ordnance Survey 07 th March 2006,
Introduction to System Analysis and Design
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.
1 A Web-Based Integral Evaluator: A Demonstration of the Successful Integration of WebEQ, Maple, and Java Wanda M. Kunkle Department of Mathematics & Computer.
1 Semantic Processing. 2 Contents Introduction Introduction A Simple Compiler A Simple Compiler Scanning – Theory and Practice Scanning – Theory and Practice.
Fundamentals of Information Systems, Second Edition
Software Quality: Testing and Verification II. 2 1.A failure is an unacceptable behaviour exhibited by a system — The frequency of failures measures software.
JML TOOLS REVIEW & EVALUATION Chris Grosshans Mark Lewis-Prazen.
1 CMSC 132: Object-Oriented Programming II Software Development III Department of Computer Science University of Maryland, College Park.
Software Development Unit 6.
Concordia University Department of Computer Science and Software Engineering Click to edit Master title style ADVANCED PROGRAMING PRACTICES API documentation.
Introduction to High-Level Language Programming
CS 355 – Programming Languages
Implementation Yaodong Bi. Introduction to Implementation Purposes of Implementation – Plan the system integrations required in each iteration – Distribute.
A Safety-Critical Java Technology Compatibility Kit Hans Søndergaard Stephan Korsholm VIA University College, Horsens, Denmark & Anders P. Ravn Aalborg.
Software Engineering Prof. Dr. Bertrand Meyer March 2007 – June 2007 Chair of Software Engineering Static program checking and verification Slides: Based.
Architecture-Based Runtime Software Evolution Peyman Oreizy, Nenad Medvidovic & Richard N. Taylor.
Teaching material for a course in Software Project Management & Software Engineering – part II.
UDoCument: Electronic Scrapbook for the Information Era Soufiane Berouel, Undergraduate Student Supervised by Prof. Lily Liang Department of Computer Science.
Plug-in System for the Xylia Extensible XML Editor Student: Jonathan Milley Supervisor: Dr. T. S. Norvell.
Component Basics CS6961 – Lecture 6 Nathan Dykman.
Composing Adaptive Software Authors Philip K. McKinley, Seyed Masoud Sadjadi, Eric P. Kasten, Betty H.C. Cheng Presented by Ana Rodriguez June 21, 2006.
Proof Carrying Code Zhiwei Lin. Outline Proof-Carrying Code The Design and Implementation of a Certifying Compiler A Proof – Carrying Code Architecture.
1.8History of Java Java –Based on C and C++ –Originally developed in early 1991 for intelligent consumer electronic devices Market did not develop, project.
Compiler course 1. Introduction. Outline Scope of the course Disciplines involved in it Abstract view for a compiler Front-end and back-end tasks Modules.
1 Total Correctness of Recursive Functions Using JML4 FSPV George Karabotsos, Patrice Chalin, Perry R. James, Leveda Giannas Dependable Software Research.
Copyright © 2007 Addison-Wesley. All rights reserved.1-1 Reasons for Studying Concepts of Programming Languages Increased ability to express ideas Improved.
The Systems Development Life Cycle
P.R. James © P.Chalin et al.1 An Integrated Verification Environment for JML: Architecture and Early Results Patrice Chalin, Perry R. James, and George.
1 The Modular Structure of Complex Systems Presented by: SeyedMasoud Sadjadi and Wei Zhu David L. Parnas, Paul C. Clement, and David M. Weiss ICSE 1984.
The System and Software Development Process Instructor: Dr. Hany H. Ammar Dept. of Computer Science and Electrical Engineering, WVU.
CS Data Structures I Chapter 2 Principles of Programming & Software Engineering.
Introduction to Software Development (Software Engineering - I)
1 CSCD 326 Data Structures I Software Design. 2 The Software Life Cycle 1. Specification 2. Design 3. Risk Analysis 4. Verification 5. Coding 6. Testing.
1 Compiler Construction (CS-636) Muhammad Bilal Bashir UIIT, Rawalpindi.
Toulouse, September 2003 Page 1 JOURNEE ALTARICA Airbus ESACS  ISAAC.
© 2006 Pearson Addison-Wesley. All rights reserved 2-1 Chapter 2 Principles of Programming & Software Engineering.
Demo of Scalable Pluggable Types Michael Ernst MIT Dagstuhl Seminar “Scalable Program Analysis” April 17, 2008.
 Programming - the process of creating computer programs.
Chapter 4 Automated Tools for Systems Development Modern Systems Analysis and Design Third Edition 4.1.
Jemerson Pedernal IT 2.1 FUNDAMENTALS OF DATABASE APPLICATIONS by PEDERNAL, JEMERSON G. [BS-Computer Science] Palawan State University Computer Network.
1 The Software Development Process ► Systems analysis ► Systems design ► Implementation ► Testing ► Documentation ► Evaluation ► Maintenance.
Project Proposal A JML compiler on Eclipse Platform Amritam Sarcar CS5381.
A Single Intermediate Language That Supports Multiple Implemtntation of Exceptions Delvin Defoe Washington University in Saint Louis Department of Computer.
Extended Static Checking for Java
Advanced Computer Systems
Bogor-Java Environment for Eclipse
Chapter 18 Maintaining Information Systems
Modern Systems Analysis and Design Third Edition
Presented by Munezero Immaculee Joselyne PhD in Software Engineering
Accessible Formal Methods A Study of the Java Modeling Language
Designing Software for Ease of Extension and Contraction
Object-Oriented and Classical Software Engineering Eighth Edition, WCB/McGraw-Hill, 2011 Stephen R. Schach.
Hoare-style program verification
(Computer fundamental Lab)
RAC Support for JML on Eclipse Platform
Modern Systems Analysis and Design Third Edition
Presentation transcript:

Runtime Assertion Checking Support for JML on Eclipse Platform Amritam Sarcar Department of Computer Science University of Texas at El Paso, 500 W. University Avenue El Paso TX 79968, USA Abstract Java Modeling Language Problems with JML Tools The Common JML tools, a.k.a JML2 do not support robustness [1]. The JML tools were built on an open source Java compiler and suffered from extensibility The existing JML2 tools, more importantly RAC (the runtime assertion checker) from the performance point of view is really very slow. The compilation time Figure 1. Relative-slowness of Jmlc compared to Javac. Twenty-five programs that were test run for checking the compilation time were taken from the programs that were distributed as a part of the JML package, under the samples folder. The Java Modeling Language (JML) is used to document design for Java and has been used as a common language for many research projects. The inability to support Java 5 features is reducing user base, feedback and the impact on JML usage. The performance of JML2 tools is also not that impressive. The JMLRAC compiler on average is five times slower than the Javac compiler. In this paper, we present an architecture that would have better performance than JML2 and also try to alleviate the problem of extensibility of JML2 tools. The Java Modeling Language (JML) is a formal behavioral specification language for Java. It is used for detail design documentation of Java modules (classes and interfaces). JML has been used extensively by many researchers across various projects. JML has a large and varied spectrum of tool support. It extends from runtime assertion checking (RAC) to theorem proving. Amongst all these tools, RAC and ESC/Java are most widely used amongst developers. However, lately there has been a problem for tool support. The problem lies in their ability to keep up with new features being introduced by Java. In this paper, we propose to redevelop JML compiler (Jmlc) on top of a well maintained code base. We present the architecture that would support JML on an extensible architecture like Eclipse. We also present a new architecture for the JMLRAC compiler with potential performance gain than its predecessor. taken is huge compared to the compilation speed of Javac (see Fig.1). Three reasons can be cited immediately: 1. Jmlc does more work than Javac. 2. Jmlc being built on an open source compiler, results in decreasing its performance. This compiler is not as efficient as Javac. 3. The compilation process of Jmlc is double round. That is, every compilation unit undergoes two-time compilation. The third is the research question being addressed in this paper. Incremental Architecture Double-round Architecture The normal flow of any java source code starts from the scanner phase and ends in the code generation phase going through the different phases. For the case for JML- annotated Java source code, after the type checking phase, rather than going straight to the code generation phase it goes for second-round of compilation. Figure 2. The average percentage of each phase on running twenty-five test cases. These were taken from the programs that were distributed with JML package. They were timed on Eclipse platform The major bottleneck for this architecture is the double-round compilation. This is because it affects the runtime performance. It is a well-known fact that in a compilation phase, most time is spent in the scanning phase (see Fig. 2). In this architecture, scanning and parsing is done twice for the original code which slows down the performance. Figure 3. The incremental architecture designed on the Eclipse framework. Unlike in double-round compilation in this architecture only the RAC code is sent. In the second-round we merge using the RAC AST and the original AST to get the merged AST ready to go to byte-code generation phase. The architectural style that we call incremental architecture works on the same fashion as the double-round architecture. The code that is sent to the scanner phase for the second round of compilation is not the entire code but only runtime code. Generally speaking, this kind of architecture actually supports abstract syntax tree (AST) merging mechanism (see Fig.3). That is to say, the portion of code that is sent for second round of compilation, results into an AST. This new AST needs to be merged with the original AST. We must also note that the Eclipse framework does not provide us with any API that we can take help of for this increment approach. The unit of increment in Eclipse is a compilation unit. However, in our case the unit of increment is a sequence of Java statements. The idea behind this approach is incremental compilation. This model parses and type checks the original source code (before RAC Generation) in the first cycle of compilation, and uses this type checked AST to further mutate with the RAC version. The steps involved to implement this technique are (see Fig. 4) The main advantage of this architectural style is that the computation time would be greatly reduced. The lack of support from existing compiler framework or implementation may pose a serious problem. Current Status and Future Work We have outlined a strategy for extending the Eclipse framework to incorporate JML RAC compiler into it. This strategy is not without challenges, however. Choosing the right extension points with minimal changes in the existing source code are difficult. On successful completion of the prototype we would eventually go onto full-blown development with Concordia University and Kansas University. References [1] Lilian Burdy, Yoonsik Cheon, David R. Cok, Michael Ernst, Joe Kiniry, Gary T. Leavens, K. Rustan M. Leino, and Erik Poll. An Overview of JML Tools and Applications. International Journal on Software Tools for Technology Transfer, 7(3): , June [[2] Patrice Chalin, Perry R. James, and George Karabotsos. An Integrated Verification Environment for JML: Architecture and Early Results. Sixth International Workshop on Specification and Verification of Component-Based Systems (SAVCBS 2007), pages 47-53, September [3] Yoonsik Cheon. A Runtime Assertion Checker for the Java Modeling Language. Technical Report [The authors’ PhD dissertation], Department of Computer Science, Iowa State University, Ames, Iowa, April 2003). Figure 4. The status of the java source code and its intermediate format (AST) changes with every step. In step 1, in the first round the source code is changed to an AST, with the help of which RAC source code is generated and saved in a temporary folder. In step 3, this RAC code is retrieved and parsed and is merged with the original AST, which is done in step 4. In step 5 and 6 this merged AST is fully type checked and code generation is done. Supported in part by NSF under Grant No. CNS