Building Unreliable Systems out of Reliable Components: The Real Time Story Edward A. Lee Professor, Chair of EE, and Associate Chair of EECS CHESS: Center.

Slides:



Advertisements
Similar presentations
Topic 2: Balance between formal and informal methods, engineering and artistry, evolution and rebuild Edward A. Lee Professor UC Berkeley Center for Hybrid.
Advertisements

Concurrent Computational Systems Edward A. Lee Professor, UC Berkeley Ptolemy Project CHESS: Center for Hybrid and Embedded Software Systems University.
DATAFLOW PROCESS NETWORKS Edward A. Lee Thomas M. Parks.
Discrete Event Models: Getting the Semantics Right Edward A. Lee Robert S. Pepper Distinguished Professor Chair of EECS UC Berkeley With thanks to Xioajun.
ACM SIGPLAN 2001 Workshop on Languages, Compilers, and Tools for Embedded Systems (LCTES'2001) Jun 22-23, 2001, Snowbird, Utah, USA Embedded Software from.
PTIDES: Programming Temporally Integrated Distributed Embedded Systems Yang Zhao, EECS, UC Berkeley Edward A. Lee, EECS, UC Berkeley Jie Liu, Microsoft.
Process-Based Software Components for Networked Embedded Systems Edward A. Lee, PI UC Berkeley Core Technical Team (Mobies, SEC, and GSRC): Christopher.
7th Biennial Ptolemy Miniconference Berkeley, CA February 13, 2007 Causality Interfaces for Actor Networks Ye Zhou and Edward A. Lee University of California,
SRC ETAB Summer Study Colorado Springs, June 25-26, 2001 Model-Based Approaches to Embedded Software Design Edward A. Lee UC Berkeley & GSRC.
Overview of Ptolemy II Edward A. Lee Professor UC Berkeley October 9, 2003.
Chess Review May 8, 2003 Berkeley, CA Classes and Inheritance in Actor- Oriented Models Stephen Neuendorffer Edward Lee UC Berkeley.
Advanced Tool Architectures Supporting Interface-Based Design
NSF Foundations of Hybrid and Embedded Software Systems UC Berkeley: Chess Vanderbilt University: ISIS University of Memphis: MSI A New System Science.
Mobies Phase 1 UC Berkeley 1 Agenda 8:00-8:30 Continental breakfast 8:30-9:00 Overview of Mobies Phase 1 effort (Edward A. Lee) 9:00-9:40 Introduction.
Type System, March 12, Data Types and Behavioral Types Yuhong Xiong Edward A. Lee Department of Electrical Engineering and Computer Sciences University.
7th Biennial Ptolemy Miniconference Berkeley, CA February 13, 2007 Leveraging Synchronous Language Principles for Hybrid System Models Haiyang Zheng and.
Department of Electrical Engineering and Computer Sciences University of California at Berkeley Behavioral Types for Actor-Oriented Design Edward A. Lee.
Behavioral Types as Interface Definitions for Concurrent Components Center for Hybrid and Embedded Software Systems Edward A. Lee Professor UC Berkeley.
6th Biennial Ptolemy Miniconference Berkeley, CA May 12, 2005 Future Directions Edward A. Lee.
Building Unreliable Systems out of Reliable Components: The Real Time Story Edward A. Lee Professor, Chair of EE, and Associate Chair of EECS CHESS: Center.
Understandable and Scalable Concurrency Christopher Brooks Programmer/Analyst, University of California, Berkeley Edward A. Lee Robert S. Pepper Distinguished.
February 11, 2010 Center for Hybrid and Embedded Software Systems Ptolemy II - Heterogeneous Concurrent Modeling and Design.
Causality Interface  Declares the dependency that output events have on input events.  D is an ordered set associated with the min ( ) and plus ( ) operators.
Chess Review October 4, 2006 Alexandria, VA Edited and presented by Advanced Tool Architectures Edward A. Lee UC Berkeley.
Is Truly Real-Time Computing Becoming Unachievable? Edward A. Lee Robert S. Pepper Distinguished Professor and Chair of EECS, UC Berkeley Keynote Talk.
Chess Review November 21, 2005 Berkeley, CA Edited and presented by Advanced Tool Architectures Edward A. Lee UC Berkeley.
Heterogeneous Modeling and Design in Ptolemy II Johan Eker UC Berkeley with material courtesy of Edward Lee and the Ptolemy group ECE Seminar Series, Carnegie.
6th Biennial Ptolemy Miniconference Berkeley, CA May 12, 2005 Ptolemy Project Status and Overview Edward A. Lee Ptolemy Project Director, UC Berkeley.
Mobies Phase 1 UC Berkeley 1 Process-Based Software Components Mobies Phase 1, UC Berkeley Edward A. Lee and Tom Henzinger PI Meeting, Boca Raton January.
Review of “Embedded Software” by E.A. Lee Katherine Barrow Vladimir Jakobac.
Actor-Oriented Design: A focus on domain-specific languages for embedded systems Edward A. Lee Professor, UC Berkeley Director, Center for Hybrid and Embedded.
The Case for Precision Timed (PRET) Machines Edward A. Lee Professor, Chair of EECS UC Berkeley With thanks to Stephen Edwards, Columbia University. National.
An Extensible Type System for Component-Based Design
Defining Domains Edward A. Lee Professor, UC Berkeley Ptolemy Ptutorial, Feb. 12, 2007.
Mixing Models of Computation Jie Liu Palo Alto Research Center (PARC) 3333 Coyote Hill Rd., Palo Alto, CA joint work with Prof. Edward.
Models of Computation for Embedded System Design Alvise Bonivento.
Discrete Event Models: Getting the Semantics Right Edward A. Lee Robert S. Pepper Distinguished Professor Chair of EECS UC Berkeley With special thanks.
Chess Review November 21, 2005 Berkeley, CA Edited and presented by Causality Interfaces and Compositional Causality Analysis Rachel Zhou UC Berkeley.
7th Biennial Ptolemy Miniconference Berkeley, CA February 13, 2007 Cyber-Physical Systems: A Vision of the Future Edward A. Lee Robert S. Pepper Distinguished.
A Denotational Semantics For Dataflow with Firing Edward A. Lee Jike Chong Wei Zheng Paper Discussion for.
Understandable Concurrency Edward A. Lee Professor, Chair of EE, and Associate Chair of EECS Director, CHESS: Center for Hybrid and Embedded Software Systems.
NSF Foundations of Hybrid and Embedded Software Systems UC Berkeley: Chess Vanderbilt University: ISIS University of Memphis: MSI A New System Science.
Ptolemy Miniconference May 9, 2003 Berkeley, CA Ptolemy Project Plans for the Future Edward A. Lee Professor Ptolemy Project Director.
SEC PI Meeting Annapolis, May 8-9, 2001 Component-Based Design of Embedded Control Systems Edward A. Lee & Jie Liu UC Berkeley with thanks to the entire.
Department of Electrical Engineering and Computer Sciences University of California at Berkeley System-Level Types for Component-Based Design Edward A.
Department of Electrical Engineering and Computer Sciences University of California at Berkeley Concurrent Component Patterns, Models of Computation, and.
Chess Review May 11, 2005 Berkeley, CA Discrete-Event Systems: Generalizing Metric Spaces and Fixed-Point Semantics Adam Cataldo Edward Lee Xiaojun Liu.
MoBIES Working group meeting, September 2001, Dearborn Ptolemy II The automotive challenge problems version 4.1 Johan Eker Edward Lee with thanks.
7th Biennial Ptolemy Miniconference Berkeley, CA February 13, 2007 PTIDES: A Programming Model for Time- Synchronized Distributed Real-time Systems Yang.
State of the Art Lecture IEEE Instrumentation and Measurement Technology Conference Budapest, Hungary, May 21-23, 2001 Computing for Embedded Systems Edward.
Designing Predictable and Robust Systems Tom Henzinger UC Berkeley and EPFL.
Embedded Software: Leveraging Concurrent Models of Computation Edward A. Lee Professor, UC Berkeley Center for Hybrid and Embedded Software Systems (CHESS)
Embedded Software Challenges for the Next 10 Years Chess: Center for Hybrid and Embedded Software Systems Infineon Embedded Software Days Munich, Sept.
Panel: What Comes After C++ in System-Level Specification Edward Lee UC Berkeley Forum on Design Languages Workshop on System Specification & Design Languages.
Model-Driven Development From Object-Oriented Design to Actor-Oriented Design Chess: Center for Hybrid and Embedded Software Systems Edward A. Lee Professor.
System-Level Types for Component-Based Design Paper by: Edward A. Lee and Yuhong Xiong Presentation by: Dan Patterson.
Department of Electrical Engineering and Computer Sciences University of California at Berkeley The Ptolemy II Framework for Visual Languages Xiaojun Liu.
Embedded Software: Building the Foundations Edward A. Lee Professor, Chair of EE, and Associate Chair of EECS CHESS: Center for Hybrid and Embedded Software.
Course Outline DayContents Day 1 Introduction Motivation, definitions, properties of embedded systems, outline of the current course How to specify embedded.
Composing Models of Computation in Kepler/Ptolemy II
Design Languages in 2010 Chess: Center for Hybrid and Embedded Software Systems Edward A. Lee Professor UC Berkeley Panel Position Statement Forum on Design.
Actor Networks Edward A. Lee Robert S. Pepper Distinguished Professor Chair of EECS UC Berkeley Invited Talk Workshop Foundations and Applications of Component-based.
Ptolemy Project Vision Edward A. Lee Robert S. Pepper Distinguished Professor Eighth Biennial Ptolemy Miniconference April 16, 2009 Berkeley, CA, USA.
Ptolemy II - Heterogeneous Concurrent Modeling and Design in Java
Ptolemy II - Heterogeneous Concurrent Modeling and Design in Java
Retargetable Model-Based Code Generation in Ptolemy II
Ptolemy II - Heterogeneous Concurrent Modeling and Design in Java
Embedded Systems: A Focus on Time
Ptolemy II - Heterogeneous Concurrent Modeling and Design in Java
Concurrent Models of Computation
Presentation transcript:

Building Unreliable Systems out of Reliable Components: The Real Time Story Edward A. Lee Professor, Chair of EE, and Associate Chair of EECS CHESS: Center for Hybrid and Embedded Software Systems UC Berkeley Shannon Lecture IEEE-Computer Society, Silicon Valley Chapter Stanford University, November 17, 2005.

Lee, Berkeley 2 Electronics Technology Delivers Timeliness … and the overlaying abstractions discard it.

Lee, Berkeley 3 Computation in the 20 th Century f : {0,1}   {0,1} 

Lee, Berkeley 4 Computation in the 20 th Century initial state final state sequence f : State  State Time is irrelevant All actions are ordered Nontermination is a defect Concurrency is an illusion Alan Turing

Lee, Berkeley 5 Exploiting the 20 th Century Abstraction Programming languages Debuggers Virtual memory Caches Dynamic dispatch Speculative execution Power management (voltage scaling) Memory management (garbage collection) Just-in-time (JIT) compilation Multitasking (threads and processes) Networking (TCP) Theory (complexity)

Lee, Berkeley 6 What about timeliness? Moore’s law has saved us!

Lee, Berkeley 7 In Core Software Abstractions: Real-Time is Not Time is not in the semantics of programs. Have to step outside the semantics to specify timing. Timing is a consequence of implementation not a property of design. Measured on the bench For a particular realization Resulting systems are brittle. Small changes have big consequences Ports to new platforms require redesign

Lee, Berkeley 8 The Myth of WCET Worst-Case Execution Time True WCET can be thousands of times bigger than actual execution time. In many implementations, true WCET is not a useful number. Dubious WCET is what is actually used. Correctness of even safety-critical systems depends on WCET being correct.

Lee, Berkeley 9 What is Done in Practice Real-time systems are boxes, not software services. Critical real-time systems use idiosyncratic, non-mainstream processors (like DSPs). Designs are bench tested, then encased.

Lee, Berkeley 10 APOT The question: What would have to change to achieve absolutely, positively on time (APOT)? The answer: nearly everything.

Lee, Berkeley 11 What to do? Put time into programming languages Promising start: Simulink, Giotto, Discrete-event models Rethink the OS/programming language split Promising start: TinyOS/nesC Rethink the hardware/software split Promising start: FPGAs with programmable cores Memory hierarchy with predictability Promising start: Scratchpad memories vs. caches Memory management with predictability Promising start: Bounded pause time garbage collection Predictable, controllable deep pipelines Promising start: Pipeline interleaving + stream-oriented languages Predictable, controllable, understandable concurrency Promising start: Synchronous languages, SCADE Networks with timing Promising start: Time triggered architectures, time synchronization Computational dynamical systems theory Promising start: Hybrid systems, schedulability analysis

Lee, Berkeley 12 Recall: Computation in the 20 th Century f : {0,1}   {0,1} 

Lee, Berkeley 13 Computation in the 21 st Century f : [T  {0,1}  ] P  [T  {0,1}  ] P …where T is a set representing time, precedence ordering, causality, synchronization, etc.

Lee, Berkeley 14 A Consequence: Component Abstractions Need to Change Actor oriented: actor name data (state) ports Input data parameters Output data What flows through an object is streams of data class name data methods call return What flows through an object is sequential control Object-oriented: Stuff happens to objects Actors make things happen

Lee, Berkeley 15 The First (?) Actor-Oriented Platform The On-Line Graphical Specification of Computer Procedures W. R. Sutherland, Ph.D. Thesis, MIT, 1966 MIT Lincoln Labs TX-2 Computer Bert Sutherland with a light pen Partially constructed actor-oriented model with a class definition (top) and instance (below). Bert Sutherland used the first acknowledged object- oriented framework (Sketchpad, created by his brother, Ivan Sutherland) to create the first actor-oriented programming framework.

Lee, Berkeley 16 Your Speaker in 1966

Lee, Berkeley 17 Modern Examples of Actor-Oriented Platforms Simulink (The MathWorks) LabVIEW (National Instruments) Modelica (Linkoping) OPNET (Opnet Technologies) Giotto and xGiotto (UC Berkeley) Polis & Metropolis (UC Berkeley) Gabriel, Ptolemy, and Ptolemy II (UC Berkeley) OCP, open control platform (Boeing) GME, actor-oriented meta-modeling (Vanderbilt) SPW, signal processing worksystem (Cadence) System studio (Synopsys) ROOM, real-time object-oriented modeling (Rational) Easy5 (Boeing) Port-based objects (U of Maryland) I/O automata (MIT) VHDL, Verilog, SystemC (Various) …

Lee, Berkeley 18 Ptolemy II: Our Laboratory for Actor-Oriented Models of Computation Director from an extensible library defines component interaction semantics or “model of computation.” Extensile, behaviorally- polymorphic component library. Visual editor supporting an abstract syntax Type system for transported data Concurrency management supporting dynamic model structure.

Lee, Berkeley 19 Models of Computation Implemented in Ptolemy II CI – Push/pull component interaction Click – Push/pull with method invocation CSP – concurrent threads with rendezvous CT – continuous-time modeling DE – discrete-event systems DDE – distributed discrete events DDF – Dynamic dataflow DPN – distributed process networks DT – discrete time (cycle driven) FSM – finite state machines Giotto – synchronous periodic GR – 2-D and 3-D graphics PN – process networks SDF – synchronous dataflow SR – synchronous/reactive TM – timed multitasking Most of these are actor oriented.

Lee, Berkeley 20 A New Foundation for Computation f : [T  {0,1}  ] P  [T  {0,1}  ] P …where T is a set representing time, precedence ordering, causality, synchronization, etc.

Lee, Berkeley 21 A Start on a 21 st Century Theory of Computation: The Tagged Signal Model [Lee & Sangiovanni-Vincentelli, 1998] A set of values V and a set of tags T An event is e  T  V A signal s is a set of events. I.e. s  T  V A functional signal is a (partial) function s: T  V The set of all signals S = 2 T  V Related models: Interaction Categories [Abramsky, 1995] Interaction Semantics [Talcott, 1996] Abstract Behavioral Types [Arbab, 2005]

Lee, Berkeley 22 Actors, Ports, and Behaviors An actor has a set of ports P A behavior is a function  : P A  S An actor is a set of behaviors A  [P A  S ] = S P A P A = { p 1, p 2, p 3, p 4 }

Lee, Berkeley 23 Actor Composition Composition is simple intersection (of sets of functions) P 1 = { p 1, p 2 } P 2 = { p 3, p 4 } P = P 1  P 2

Lee, Berkeley 24 Connectors Connectors are trivial actors. P 1 = { p 1, p 2 }P 2 = { p 3, p 4 } P c = { p 2, p 3 } c A

Lee, Berkeley 25 Tagged Signal Model Gives a Fixed-Point Semantics to Arbitrary Composition

Lee, Berkeley 26 Tagged Signal Model can be used on a Wide Variety of Concurrent and Timed Models of Computation CSP – concurrent threads with rendezvous CT – continuous-time modeling DE – discrete-event systems DDF – Dynamic dataflow DT – discrete time Giotto – synchronous periodic PN – process networks SDF – synchronous dataflow SR – synchronous/reactive

Lee, Berkeley 27 Application of this Theory of Computation: Discrete-Event Systems CI – Push/pull component interaction Click – Push/pull with method invocation CSP – concurrent threads with rendezvous CT – continuous-time modeling DE – discrete-event systems DDE – distributed discrete events DDF – Dynamic dataflow DPN – distributed process networks DT – discrete time (cycle driven) FSM – finite state machines Giotto – synchronous periodic GR – 2-D and 3-D graphics PN – process networks SDF – synchronous dataflow SR – synchronous/reactive TM – timed multitasking

Lee, Berkeley 28 Discrete Events (DE): A Timed Concurrent Model of Computation DE Director implements timed semantics using an event queue Event source Time line Reactive actors Signal

Lee, Berkeley 29 Semantics Clears Up Subtleties: Simultaneous Events By default, an actor produces events with the same time as the input event. But in this example, we expect (and need) for the BooleanSwitch to “see” the output of the Bernoulli in the same “firing” where it sees the event from the PoissonClock. Events with identical time stamps are also ordered, and reactions to such events follow data precedence order.

Lee, Berkeley 30 Semantics Clears Up Subtleties: Feedback Data precedence analysis has to take into account the non-strictness of this actor (that an output can be produced despite the lack of an input).

Lee, Berkeley 31 Semantics Clears Up Subtleties: Zeno Systems DE systems may have an infinite number of events in a finite amount of time. Carefully constructed semantics gives these systems meaning.

Lee, Berkeley 32 Example of Current Research Challenges Use distributed discrete-event systems as a timed model of computation for embedded software in unreliable, sporadically connected networks, such as wireless sensor networks. The most interesting possibilities are based on distributed consensus algorithms (as in Croquet, Reed, Lamport). Research challenges include: Defining the semantics Combining the semantics heterogeneously with others. E.g.: Signal processing for channel modeling TinyOS for node functionality Creating efficient runtime environments Building the design environment

Lee, Berkeley 33 Current Projects in the Ptolemy Group Abstract semantics (Cataldo, Liu, Matsikoudis, Zheng) Behavioral polymorphism Actor semantics (prefire, fire, postfire) Compositional directors Time semantics Causality interfaces Distributed computing (Feng, Zhao) Robust distributed consensus Data coherence (distributed caches) Time synchronization Real-time software (Bandyopadhyay, Cheong, Zhou) Time-based models vs. dataflow models Deterministic, understandable multitasking Memory hierarchy with scratchpad memory Code generation Hybrid systems (Cataldo, Zheng) Operational semantics Stochastic hybrid systems Aspect-oriented multi-view modeling Code generation

Lee, Berkeley 34 Conclusion The time is right to create the 21-st century theory of (embedded) computing.