Requirements on the Execution of Kahn Process Networks Marc Geilen and Twan Basten 11 April 2003 /e.

Slides:



Advertisements
Similar presentations
Bounded Model Checking of Concurrent Data Types on Relaxed Memory Models: A Case Study Sebastian Burckhardt Rajeev Alur Milo M. K. Martin Department of.
Advertisements

Mutual Exclusion – SW & HW By Oded Regev. Outline: Short review on the Bakery algorithm Short review on the Bakery algorithm Black & White Algorithm Black.
Use trace algebra to formalize the YAPI model EE290N Spring2002 Alessandro Pinto Mentors: Roberto Passerone Jerry Burch.
A Process Splitting Transformation for Kahn Process Networks Sjoerd Meijer.
Optimal PRAM algorithms: Efficiency of concurrent writing “Computer science is no more about computers than astronomy is about telescopes.” Edsger Dijkstra.
D u k e S y s t e m s Time, clocks, and consistency and the JMM Jeff Chase Duke University.
1 Concurrency Specification. 2 Outline 4 Issues in concurrent systems 4 Programming language support for concurrency 4 Concurrency analysis - A specification.
Development of Parallel Simulator for Wireless WCDMA Network Hong Zhang Communication lab of HUT.
DATAFLOW PROCESS NETWORKS Edward A. Lee Thomas M. Parks.
Synthesis of Embedded Software Using Free-Choice Petri Nets.
I MPLEMENTING S YNCHRONOUS M ODELS ON L OOSELY T IME T RIGGERED A RCHITECTURES Discussed by Alberto Puggelli.
SCORE - Stream Computations Organized for Reconfigurable Execution Eylon Caspi, Michael Chu, Randy Huang, Joseph Yeh, Yury Markovskiy Andre DeHon, John.
Deadlock Detection in Distributed Process Networks – Alex Olson Process Networks (PN)  Determinate dataflow model [Kahn, 1974].  Concurrent processes.
1 Concurrent and Distributed Systems Introduction 8 lectures on concurrency control in centralised systems - interaction of components in main memory -
Concurrency CS 510: Programming Languages David Walker.
I/O Hardware n Incredible variety of I/O devices n Common concepts: – Port – connection point to the computer – Bus (daisy chain or shared direct access)
Dataflow Process Networks Lee & Parks Synchronous Dataflow Lee & Messerschmitt Abhijit Davare Nathan Kitchen.
Design of Fault Tolerant Data Flow in Ptolemy II Mark McKelvin EE290 N, Fall 2004 Final Project.
Kahn’s Principle and the Semantics of Discrete Event Systems Xiaojun Liu EE290N Class Project December 10, 2004.
CPSC 4650 Operating Systems Chapter 6 Deadlock and Starvation
A Denotational Semantics For Dataflow with Firing Edward A. Lee Jike Chong Wei Zheng Paper Discussion for.
Heterochronous Dataflow in Ptolemy II Brian K. Vogel EE249 Project Presentation, Dec. 4, 1999.
Real-Time Kernels and Operating Systems. Operating System: Software that coordinates multiple tasks in processor, including peripheral interfacing Types.
Penn ESE535 Spring DeHon 1 ESE535: Electronic Design Automation Day 8: February 11, 2009 Dataflow.
A Platform-based Design Flow for Kahn Process Networks Abhijit Davare Qi Zhu December 10, 2004.
VLSI DSP 2008Y.T. Hwang3-1 Chapter 3 Algorithm Representation & Iteration Bound.
System-Level Types for Component-Based Design Paper by: Edward A. Lee and Yuhong Xiong Presentation by: Dan Patterson.
1 Correct and efficient implementations of synchronous models on asynchronous execution platforms Stavros Tripakis UC Berkeley and Verimag EC^2 Workshop,
Technische universiteit eindhoven Department of Electrical Engineering Electronic Systems Liveness and Boundedness of Synchronous Data Flow Graphs A.H.
Maria-Cristina Marinescu Martin Rinard Laboratory for Computer Science Massachusetts Institute of Technology A Synthesis Algorithm for Modular Design of.
Real-Time Software Design Yonsei University 2 nd Semester, 2014 Sanghyun Park.
S. M. Farhad PhD Student Supervisor: Dr. Bernhard Scholz
Voicu Groza, 2008 SITE, HARDWARE/SOFTWARE CODESIGN OF EMBEDDED SYSTEMS Hardware/Software Codesign of Embedded Systems Voicu Groza SITE Hall, Room.
1 Multiprocessor and Real-Time Scheduling Chapter 10 Real-Time scheduling will be covered in SYSC3303.
30 October Agenda for Today Introduction and purpose of the course Introduction and purpose of the course Organization of a computer system Organization.
May 16-18, Skeletons and Asynchronous RPC for Embedded Data- and Task Parallel Image Processing IAPR Conference on Machine Vision Applications Wouter.
OPERATING SYSTEM SUPPORT DISTRIBUTED SYSTEMS CHAPTER 6 Lawrence Heyman July 8, 2002.
SOFTWARE DESIGN. INTRODUCTION There are 3 distinct types of activities in design 1.External design 2.Architectural design 3.Detailed design Architectural.
Executing Parallel Programs with Potential Bottlenecks Efficiently Yoshihiro Oyama Kenjiro Taura Akinori Yonezawa {oyama, tau,
Department of Computer Science and Software Engineering
CSCI1600: Embedded and Real Time Software Lecture 11: Modeling IV: Concurrency Steven Reiss, Fall 2015.
C H A P T E R E L E V E N Concurrent Programming Programming Languages – Principles and Paradigms by Allen Tucker, Robert Noonan.
High Performance Embedded Computing © 2007 Elsevier Chapter 1, part 3: Embedded Computing High Performance Embedded Computing Wayne Wolf.
Deadlock Detection for Distributed Process Networks Alex Olson Embedded Software Spring 2004.
A Theory of Distributed Objects Toward a Foundation for Component Grid Platforms Ludovic HENRIO l A Theory of Distributed Objects l Components l Perspectives.
High Performance Embedded Computing © 2007 Elsevier Lecture 4: Models of Computation Embedded Computing Systems Mikko Lipasti, adapted from M. Schulte.
Agenda  Quick Review  Finish Introduction  Java Threads.
CS Spring 2009 CS 414 – Multimedia Systems Design Lecture 27 – Media Server (Part 2) Klara Nahrstedt Spring 2009.
Semaphores Chapter 6. Semaphores are a simple, but successful and widely used, construct.
Introduction to operating systems What is an operating system? An operating system is a program that, from a programmer’s perspective, adds a variety of.
PDES Introduction The Time Warp Mechanism
Chapter 13: I/O Systems.
Module 12: I/O Systems I/O hardware Application I/O Interface
Threads vs. Events SEDA – An Event Model 5204 – Operating Systems.
Processes and Threads Processes and their scheduling
Chapter 4: Multithreaded Programming
Capriccio – A Thread Model
COT 5611 Operating Systems Design Principles Spring 2012
Lecture 21: Introduction to Process Scheduling
Operating System Concepts
13: I/O Systems I/O hardwared Application I/O Interface
Concurrent Models of Computation
Semaphores Chapter 6.
Operating Systems Lecture 1.
Chapter 13: I/O Systems I/O Hardware Application I/O Interface
Lecture 21: Introduction to Process Scheduling
Deadlock Detection for Distributed Process Networks
COT 5611 Operating Systems Design Principles Spring 2014
Module 12: I/O Systems I/O hardwared Application I/O Interface
Prof. Onur Mutlu Carnegie Mellon University
Presentation transcript:

Requirements on the Execution of Kahn Process Networks Marc Geilen and Twan Basten 11 April 2003 /e

Overview 1.Introduction: Kahn Process Networks 2.Implementing KPNs 3.Execution of KPNs 4.An Improved Scheduling Algorithm 5.Conclusions

/e 1. Introduction: Kahn Process Networks

/e Kahn Process Networks Arcs carry (possibly infinite) streams of tokens (audio samples, video frames, etc.) Nodes compute (continuous) functions on streams

/e Kahn Process Networks Good for multimedia and signal processing applications E.g., JPEG/MPEG decoding, image/video processing Explicit parallelism and communication No synchronization between processes required Programming paradigm for modern multi-processor architectures MIT’s RAW, Philips’ SpaceCake

/e KPN Semantics Arcs connecting functions Set of equations Continuous functions: unique least solution Semantics of KPN: least fixed- point Yields new continuous function: Compositionality

/e 2. Implementing KPNs

/e Realizations of KPNs Functions: sequential (determinate) programs, e.g. C++ or Java Blocking read operations

/e Realizations of KPNs Functions: sequential (determinate) programs, e.g. C++ or Java Arcs: FIFO queues Store tokens that are written but not yet read Blocking read operations

/e Realizations of KPNs Determinacy Output is independent of scheduling order Compositionality Hierarchically, recursively, … The Kahn Principle Operational model with fair execution and unbounded channels realizes the formal semantics

/e Implementation Requirements When is an implementation of a KPN good?

/e Implementation Requirements Boundedness

/e Implementation Requirements Completeness: infinite execution vs. chain of strings

/e 3. Execution of KPNs

/e Implementations of KPNs FIFO bounds balance memory usage and context switching (Minimal) FIFO bounds are undecidable Run-time management Often follow [Thomas Parks ’95] scheduling approach YAPI, Jade/Pagis, Ptolemy II among others Bounded FIFOs combine aspects of data- and demand driven execution

/e Implementations of KPNs Blocking on full FIFO: artificial deadlocks Causal chains

/e Implementations of KPNs Execution thread per process POSIX threads, Java threads, … Artificial deadlock detection and resolution strategies Often: global deadlock detection Low priority thread

/e Implementations of KPNs Parks’ algorithm yields infinite computation, but possibly not complete Local deadlocks may remain undetected (fairness is violated) Deadlocks are cyclic causal chains

/e 4. An Improved Scheduling Algorithm

/e Improved Scheduling Algorithm Deadlocks cannot be avoided by scheduling Artificial deadlock occurs (only) if FIFO bounds are too small (At least) one of the full FIFOs on a deadlock cycle must be too small Increase size of the smallest full FIFO

/e Improved Scheduling Algorithm 1.Schedule enabled processes (in a fair way) 2.Until deadlock occurs (cyclic causal chain) 3.Resolve deadlock by increasing the smallest full FIFO

/e Correctness Operational (LTS) semantics of KPNs (see paper) Equivalent to KPN semantics by the Kahn Principle Operational semantics of realizations of KPNs bounded channels Show that both implement the same function

/e Correctness The new scheduling algorithm realizes the the formal semantics of Kahn Process Networks: Every bounded and effective KPN is executed in bounded memory by our scheduler and produces the complete output.

/e Correctness Prerequisites: Boundedness: there exists a fair execution with finite FIFO bounds Effectiveness: every token that is produced on some channels is eventually also consumed Both prerequisites are necessary

/e Local deadlock detection Deadlock detection becomes more involved Need not be done at every step of the execution May be possible to do this concurrently

/e Conclusions Studied implementation requirements for KPNs: boundedness and completeness Widely used implementation of KPNs does not schedule all KPNs correctly We have presented an improved scheduling algorithm that resolves the problem for a large class of KPNs And proved its correctness (in the paper)

/e Future Work An implementation of the improved scheduling algorithm is being made for YAPI Efficiency of scheduling. Optimal bounds, efficient deadlock detection Hierarchical or distributed implementations Distributed deadlock detection