Automatic Derivation, Integration, and Verification of Synchronization Aspects in Object-Oriented Design Methods Automatic Derivation, Integration, and.

Slides:



Advertisements
Similar presentations
Bernd Bruegge & Allen Dutoit Object-Oriented Software Engineering: Conquering Complex and Changing Systems 1 Software Engineering September 12, 2001 Capturing.
Advertisements

Object-Oriented Software Development CS 3331 Fall 2009.
OBJECT ORIENTED PROGRAMMING M Taimoor Khan
Background information Formal verification methods based on theorem proving techniques and model­checking –to prove the absence of errors (in the formal.
Software Model Checking for Embedded Systems PIs: Matthew Dwyer 1, John Hatcliff 1, and George Avrunin 2 Post-docs: Steven Seigel 2, Radu Iosif 1 Students:
Assurance through Enhanced Design Methodology Orlando, FL 5 December 2012 Nirav Davé SRI International This effort is sponsored by the Defense Advanced.
Formal Methods in Software Engineering Credit Hours: 3+0 By: Qaisar Javaid Assistant Professor Formal Methods in Software Engineering1.
Programming Distributed Systems Lab Institute of Computer Science University of Augsburg Universitätsstraße 14, D Augsburg Tel.: (+49) 821/ ,
Object-Oriented Analysis and Design
Rational Unified Process
ECE Synthesis & Verification1 ECE 667 Spring 2011 Synthesis and Verification of Digital Systems Verification Introduction.
PDDL: A Language with a Purpose? Lee McCluskey Department of Computing and Mathematical Sciences, The University of Huddersfield.
1 Building with Assurance CSSE 490 Computer Security Mark Ardis, Rose-Hulman Institute May 10, 2004.
SE 464: Industrial Information systems Systems Engineering Department Industrial Information System LAB 02: Introduction to SAP.
Supplement 02CASE Tools1 Supplement 02 - Case Tools And Franchise Colleges By MANSHA NAWAZ.
End-to-End Design of Embedded Real-Time Systems Kang G. Shin Real-Time Computing Laboratory EECS Department The University of Michigan Ann Arbor, MI
Department of Computer Science & Engineering College of Engineering Dr. Betty H.C. Cheng, Laura A. Campbell, Sascha Konrad The demand for distributed real-time.
5/24/011 Advanced Tool Integration for Embedded Systems Assurance Insup Lee Department of Computer and Information Science University of Pennsylvania.
Software Engineering Tools and Methods Presented by: Mohammad Enamur Rashid( ) Mohammad Rashim Uddin( ) Masud Ur Rahman( )
CSC230 Software Design (Engineering)
Architecture, Implementation, and Testing Architecture and Implementation Prescriptive architecture vs. descriptive architecture Prescriptive architecture:
1.Database plan 2.Information systems plan 3.Technology plan 4.Business strategy plan 5.Enterprise analysis Which of the following serves as a road map.
Transitioning From Software Requirements Models to Design Models
Katanosh Morovat.   This concept is a formal approach for identifying the rules that encapsulate the structure, constraint, and control of the operation.
1 Yolanda Gil Information Sciences InstituteJanuary 10, 2010 Requirements for caBIG Infrastructure to Support Semantic Workflows Yolanda.
Research & Development Roadmap 1. Outline A New Communication Framework Giving Bro Control over the Network Security Monitoring for Industrial Control.
Chapter 2 The process Process, Methods, and Tools
Copyright 2002 Prentice-Hall, Inc. Chapter 1 The Systems Development Environment 1.1 Modern Systems Analysis and Design.
CORBA Component Model (CCM)-based Design, Analysis, and Infrastructure for DRE Systems Matt DwyerJohn HatcliffMasaaki.
1 Chapter 2 The Process. 2 Process  What is it?  Who does it?  Why is it important?  What are the steps?  What is the work product?  How to ensure.
An Introduction to Software Architecture
Automatic Derivation, Integration, and Verification of Synchronization Aspects in Object-Oriented Design Methods Automatic Derivation, Integration, and.
Overview of Formal Methods. Topics Introduction and terminology FM and Software Engineering Applications of FM Propositional and Predicate Logic Program.
Chapter 11 Analysis Concepts and Principles
Tufts University School Of Engineering Tufts Wireless Laboratory TWL Direction Almir Davis 09/28/20091.
Model-Driven Analysis Frameworks for Embedded Systems George Edwards USC Center for Systems and Software Engineering
© 2012 xtUML.org Bill Chown – Mentor Graphics Model Driven Engineering.
1 Introduction to Software Engineering Lecture 1.
Component Composition for Embedded Systems Using Semantic Aspect-Oriented Programming Martin Rinard Laboratory for Computer Science Massachusetts Institute.
Department of Computing and Information Sciences Kansas State University Design Methodology for State based Embedded Systems Case Study: Maze Navigator.
C. André, J. Boucaron, A. Coadou, J. DeAntoni,
CS Data Structures I Chapter 2 Principles of Programming & Software Engineering.
CIS 842: Specification and Verification of Reactive Systems Lecture 1: Course Overview Copyright 2001, Matt Dwyer, John Hatcliff, and Radu Iosif. The.
FDT Foil no 1 On Methodology from Domain to System Descriptions by Rolv Bræk NTNU Workshop on Philosophy and Applicablitiy of Formal Languages Geneve 15.
Tool-support for Invariant-based Specification, Synthesis, and Verification of Synchronization in Concurrent Java Programs M.S. Defense William Deng Department.
Automatic Derivation, Integration, and Verification of Synchronization Aspects in Object-Oriented Design Methods Principal Investigators Matt Dwyer John.
J. Scott Hawker p. 1Some material © Rational Corp. Rational Unified Process Overview See and use the RUP Browser on lab machines.
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.
© 2006 Pearson Addison-Wesley. All rights reserved2-1 Chapter 2 Principles of Programming & Software Engineering.
CASE (Computer-Aided Software Engineering) Tools Software that is used to support software process activities. Provides software process support by:- –
© 2006 Pearson Addison-Wesley. All rights reserved 2-1 Chapter 2 Principles of Programming & Software Engineering.
Software Engineering and Object-Oriented Design Topics: Solutions Modules Key Programming Issues Development Methods Object-Oriented Principles.
Formal Specification: a Roadmap Axel van Lamsweerde published on ICSE (International Conference on Software Engineering) Jing Ai 10/28/2003.
Automatic Derivation, Integration, and Verification of Synchronization Aspects in Object-Oriented Design Methods Automatic Derivation, Integration, and.
Design-Directed Programming Martin Rinard Daniel Jackson MIT Laboratory for Computer Science.
Formal Verification. Background Information Formal verification methods based on theorem proving techniques and model­checking –To prove the absence of.
Software Systems Verification and Validation Laboratory Assignment 4 Model checking Assignment date: Lab 4 Delivery date: Lab 4, 5.
From Use Cases to Implementation 1. Structural and Behavioral Aspects of Collaborations  Two aspects of Collaborations Structural – specifies the static.
A Vision for Integration of Embedded System Properties Via a Model-Component-Aspect System Architecture Christopher D. Gill Department.
Introduction to Software Engineering 1. Software Engineering Failures – Complexity – Change 2. What is Software Engineering? – Using engineering approaches.
Automatic Derivation, Integration, and Verification of Synchronization Aspects in Object-Oriented Design Methods Automatic Derivation, Integration, and.
From Use Cases to Implementation 1. Mapping Requirements Directly to Design and Code  For many, if not most, of our requirements it is relatively easy.
Sung-Dong Kim, Dept. of Computer Engineering, Hansung University Java - Introduction.
Review of last class Software Engineering Modeling Problem Solving
Software Project Configuration Management
Arab Open University 2nd Semester, M301 Unit 5
Model-Driven Analysis Frameworks for Embedded Systems
Automatic Derivation, Integration and Verification
Automatic Derivation, Integration, and Verification of Synchronization Aspects in Object-Oriented Design Methods DARPA Order K203/AFRL Contract F C-3044.
From Use Cases to Implementation
Presentation transcript:

Automatic Derivation, Integration, and Verification of Synchronization Aspects in Object-Oriented Design Methods Automatic Derivation, Integration, and Verification of Synchronization Aspects in Object-Oriented Design Methods DARPA Order K203/AFRL Contract F C-3044 Principal Investigators Matt Dwyer John Hatcliff Masaaki Mizuno Mitch Neilsen Gurdip Singh Department of Computing and Information Sciences Kansas State University

Problem Description Embedded systems are growing in complexity and developers are looking towards OO technologies to manage that complexity Design methods for OO do not treat synchronization effectively Embedded systems software is multi-threaded for performance reasons –System correctness relies on correct synchronization of multiple activities Synchronization design/implementation is low-level and platform specific –Error prone and not reusable

Project Objectives III. Automatic verification of critical safety and liveness properties of woven embedded code … domain-specific model-checking engines … built on previous DARPA work – Bandera environment II. Automatic derivation and weaving of synchronization code … multiple language and synchronization targets (Java, C++, monitors, event service,etc.) … weaving & optimization via abstract interpretation and program specialization techniques I. Provide high-level, modular specification of global synchronization aspects … integrated with UML/RUP … formal specification via global invariants … language of composable invariant patterns … powerful, yet easy to use IV. Evaluation using BoldStroke OEP

Contribution to PCES Goals Invariant patterns enable reuse of synchronization “solutions” across multiple systems and languages Evaluate reduction in effort in context of BoldStroke OEP on controlled system development (class projects) Synthesis of “correct” synchronization implementations potentially eliminates a class of subtle coding errors –Evaluate potential for reducing errors and validation effort The overarching goal of the PCES program is novel technology and supporting engineering approaches that can greatly reduce effort to program embedded systems, while increasing confidence in the embedded software product.

Contribution to Relevant Military Application Apply our approach to BoldStoke OEP event service Event Service Application synchronization specification - Enhance event service to include synchronization support - Extract synchronization regions from existing Boldstroke applications and re-engineer them using our approach DoD Target System Studies - CAN based event service implementation - Seaborne (ST 2000) and Airborne (BQM- 74, MQM-107)

Project Tasks/Schedule Integration Verification Code generation Aspect code synthesis Synch Aspect language Key Tasks Non-synch Aspects Initial Optimized Full-scale Evaluation 5/01 5/02 10/01 10/01 + 5/02 10/01 + 5/03 5/02 + 5/03 5/01 (Java,C) 10/01 (CAN) 10/01 (ES)5/02 (ES) 11/02 (ES)+ 11/02 (CAN)+ 5/02 (CAN) 11/02 (Java)+5/02 (Java/C)

A Typical Synchronization Problem Flow policies in Boldstroke: control-push, data pull Sensor Logical Sensor Logical Actuator set event get event get

A Typical Synchronization Problem Flow policies in Boldstroke: control-push, data pull Sensor Logical Sensor Logical Actuator set event get event get Multiple sensors and actuators: Get single data value Get multiple values from single component Get multiple values via multiple calls to single component Get multiple values via multiple calls to multiple components Synchronization issues per Boeing OEP contacts

Gyroscope/Rudder System Logical gyroscope Buffer Logical rudder Logical gyroscope updates buffer Logical rudder reads position values from buffer and uses them to actuate the physical rudder

Gyroscope/Rudder System Logical gyroscope Buffer Logical rudder Logical gyroscope updates buffer Logical rudder reads position values from buffer and uses them to actuate the physical rudder : while (true) { : get new value from physical gyroscope : place value in buffer } while (true) { : get value from buffer : actuate physical rudder : }

Technical Progress Actors: Use Cases Classes: Use-Case Realizations Component Code Step 1: Synchronization specifications –via invariants and regions –Identify common idioms/patterns Global Invariant Specs Rational Unified Process (RUP)

Gyroscope/Rudder System Logical gyroscope Buffer Logical rudder while (true) { : get new value from physical gyroscope : place value in buffer } while (true) { : get value from buffer : actuate physical rudder : } wait until buffer is empty wait until buffer is full In G ++ Out G ++ Implicit Counters In R ++ Out R ++ Implicit Counters Assume each region has associated implicit in and out counters that are incremented as regions are entered and exited Step 1 Identify intended critical regions State a global invariant constraining occupancy of the regions

Invariants Invariants control entry and exit from regions by imposing constraints on counter values Exclusion(R A, R B ):(Out A – In A = 0) \/ (Out B – In B = 0) Pattern based approach: - template formula encoding a commonly occurring synchronization problem User never writes formulas but instead build invariants using a collection of global invariant patterns Invariant pattern repository on the project web-page

Gyroscope/Rudder Synchronization Logical Gyroscope Buffer ProduceConsume Produce Logical Rudder RGRG R Gyroscope Value Empty Buffer Slot Resource(R G,R R,0) Resource(R R,R G,1) Exclusion(R G,R R ) Resource(R G,R R,0) + Resource(R R,R G,1) + Exclusion(R G,R R ) Invariant:

Technical Progress Actors: Use Cases Classes: Use-Case Realizations Component Code Step 1: Synchronization specifications –via invariants –Identify common idioms/patterns Global Invariant Specs Coarse-Grain Solution Step 2: Automatic generation of coarse-grain generation solution – optimization using SVC Rational Unified Process (RUP)

Coarse-grain Solution Gyroscope Rudder Buffer C> …wait until B then execute C atomically …execute C atomically Step 2 From the invariant, guards for region enter/exit are generated automatically <await (In G == Out R ) && (In R == Out R ) -> In G ++> <await (In R < Out G ) && (In G == Out G ) -> In R ++> Semantics captured by high-level & language-independent intermediate representation Resource(R G,R R,0) + Resource(R R,R G,1) + Exclusion(R G,R R ) Invariant:

Complete Program Technical Progress Actors: Use Cases Classes: Use-Case Realizations Component Code Complete Program Fine-Grain Synchronization Code Step 3: Synch-code generation –C/C++ and Java - prototype released 9/01 -CAN: active monitor, replication -Tao event service (in progress) Complete Program Rational Unified Process (RUP) Step 1: Synchronization specifications –via invariants –Identify common idioms/patterns Global Invariant Specs Coarse-Grain Solution Step 2: Automatic generation of coarse-grain generation solution – optimization using SVC

Fine-grain Solution Gyroscope Rudder Buffer Call Gyro_Enter(); Call Gyro_Exit(); Call Rudder_Enter(); Call Rudder_Exit(); …monitors, rendezvous, semaphores, etc… Step 3 await and atomic statements are automatically translated to chosen synchronization mechanism Monitor Proc Gyro_Enter() … …; Proc Gyro_Exit() … …; Proc Rudder_Enter() … …; Proc Rudder_Exit() … …; Monitor

Fine-grain Solution using Tao Event Service Gyroscope Rudder Buffer Call Gyro_Enter(); Call Gyro_Exit(); Call Rudder_Enter(); Call Rudder_Exit(); Step 3 await and atomic statements are automatically translated to primitives in an enhanced version of the Tao Event Service Fine-grain Solution Implementation Tao Event Service Our enhancements for history and conditional events We believe that this will allow confident use of more sophisticated synchronization policies within the BoldStroke environment.

Event Service - Anonymous one-way communication between producers and consumers Supplier Proxies Subscription & Filtering Event Correlation Dispatching module Consumer Proxies Supplier Consumer - A consumer can subscribe to conjunction or disjunction of events - An event is pushed to all consumers that subscribe to it

Event service with synchronization - Enhance event service to include synchronization support Supplier Proxies Subscription & Filtering Event Correlation Dispatching module Consumer Proxies Supplier Consumer Synchronization

Translation for event-service In G ++> /* insert gyroscope value into buffer */ Logical gyroscope region: In R ++> /* read gyroscope value from buffer */ Logical rudder region: Supplier Proxies Subscription & Filtering Event Correlation Dispatching module Consumer Proxies Synchronization

Translation for event-service In G ++> /* insert gyroscope value into buffer */ Logical gyroscope region: In R ++> /* read gyroscope value from buffer */ Logical rudder region: Supplier Proxies Subscription & Filtering Event Correlation Dispatching module Consumer Proxies Publish Synchronization

Translation for event-service await (In G +1 <= Out R +1) && (In R == Out R ) /* insert gyroscope value into buffer */ Logical gyroscope region: <await (In G < Out R ) && (In G == Out G ) /* read gyroscope value from buffer */ Logical rudder region: Supplier Proxies Subscription & Filtering Event Correlation Dispatching module Consumer Proxies  In G ++  In R ++ > Counts the number of notifications Synchronization Publish Subscribe < > Control the number of notifications

Synchronization in Event Service Supplier Proxies Subscription & Filtering Event Correlation Dispatching module Consumer Proxies Supplier Consumer Synchronization - Exactly k semantics: an event is pushed to exactly k consumers - At most k semantics: an event is pushed to at most k consumers - At least k semantics: an event is pushed to at least k consumers Controlling the number of notifications: 1

Synchronization in Event Service Supplier Proxies Subscription & Filtering Event Correlation Dispatching module Consumer Proxies Supplier Consumer Synchronization - published(e): number of events of type e published so far - notified(e): number of notifications for event e pushed so far - Condition event: a predicate on published and notification counters - Event channel publishes condition events

Translation to event based solution In G ++> /* insert gyroscope value into buffer */ Logical gyroscope region: In R ++> /* read gyroscope value from buffer */ Logical rudder region: Condition events Simple events

Tao Real-time Event Service PushConsumer ProxyPushSupplier SupplierAdmin ProxyPushConsumer PushSupplier ProxyPushSupplier Dispatching

Modified Real-time Event Service PushConsumer ProxyPushSupplier SupplierAdmin ProxyPushConsumer PushSupplier ProxyPushSupplier Dispatching SynchAdmin synchronization event evaluate condition events publish condition events

Event service issues Event service issues Incorporate subscription changes Federated event channels Real-time scheduling with synchronization

Next Milestones ( months) Public distribution of prototype synchronization specification, code generation, and weaving tools Modify Tao Real-time event service to include synchronization support Re-engineer Boldstroke applications to use event-service based synchronization CAN-based event service Extend global invariant approach to address real-time synchronization properties (e.g., priority inversion) Provide evidence of correctness of synchronization policies implemented via event channel Integrate Bandera to check safety/liveness properties

Collaborations Stanford (SVC) Berkeley (Bane, Banshee) MIT (analyses to optimize weaved code) Grammatech, Inc. (slicing/verification techniques) Collins, aJile systems (JEM boards) Honeywell (challenge problems from avionics) Boeing (BoldStroke OEP) Kvaser, AB (CAN Kingdom = CDA 101/11) Seaborne Targets Engineering Lab (CDA 101) National Marine Electronics Association (NMEA)

Technology Transition/Transfer Boeing BoldStroke applications CDA 101 based Target Systems –Seaborne Targets: ST 2000 –Airborne Targets: BQM-74 MQM-107 Commercial Applications –NMEA 2000, CanKingdom - standards for real- time networking –Precision farming, industrial automation

Program Issues Repository of embedded systems applications illustrating the problems to be addressed Program meetings provide little time for technical interchange –i.e., identifying future collaborators Involvement of more industrial participants to provide challenge problems –i.e., need more than code and documentation

Funding Profile and Financial Expenditures to Date We are burning our Salary/IDC at 100% –Due to a clerical error certain charges made against the project have not hit the project account –It may appear that we are underspending, but back-charges will hit within the next month. We are burning our travel money at ~80% –Travel money from the 1 st funding period was shifted to the second period. This means that 100% burn of the second period’s travel money will appear as if we are underburning. –Note that due to this shift we had to pay for travel to the PCES kickoff meeting from non-PCES sources.