A Discipline of Multiprogramming: Programming Theory for Distributed Applications by Jayadev Misra Chapter 1, Mikhail Nesterenko.

Slides:



Advertisements
Similar presentations
Operating Systems Part III: Process Management (Process Synchronization)
Advertisements

1 Chapter 5 Concurrency: Mutual Exclusion and Synchronization Principals of Concurrency Mutual Exclusion: Hardware Support Semaphores Readers/Writers Problem.
1 1 Regression Verification for Multi-Threaded Programs Sagar Chaki, SEI-Pittsburgh Arie Gurfinkel, SEI-Pittsburgh Ofer Strichman, Technion-Haifa Originally.
Concurrency Important and difficult (Ada slides copied from Ed Schonberg)
Concurrent Programming Problems OS Spring Concurrency pros and cons Concurrency is good for users –One of the reasons for multiprogramming Working.
1 Chapter 1 Why Parallel Computing? An Introduction to Parallel Programming Peter Pacheco.
Concurrency 101 Shared state. Part 1: General Concepts 2.
Parallel Algorithms Lecture Notes. Motivation Programs face two perennial problems:: –Time: Run faster in solving a problem Example: speed up time needed.
Concurrency Control in Transactional Drago Concurrency Control in Transactional Drago M. Patiño-Martínez, R. Jiménez-Peris Technical University of Madrid.
PZ13B Programming Language design and Implementation -4th Edition Copyright©Prentice Hall, PZ13B - Client server computing Programming Language.
Chapter 11: Distributed Processing Parallel programming Principles of parallel programming languages Concurrent execution –Programming constructs –Guarded.
©Brooks/Cole, 2003 Chapter 7 Operating Systems Dr. Barnawi.
1 Ivan Lanese Computer Science Department University of Bologna Italy Concurrent and located synchronizations in π-calculus.
© 2006 Pearson Addison-Wesley. All rights reserved2-1 Chapter 2 Principles of Programming & Software Engineering.
BACS 485—Database Management Concurrency Control Overview of Database Concurrency Control.
Quick Review of Apr 24 material Sorting (Sections 13.4) Sort-merge Algorithm for external sorting Join Operation implementations (sect. 13.5) –Size estimation.
Advances in Language Design
What is Concurrent Programming? Maram Bani Younes.
Lecture 4: Parallel Programming Models. Parallel Programming Models Parallel Programming Models: Data parallelism / Task parallelism Explicit parallelism.
This module was created with support form NSF under grant # DUE Module developed by Martin Burtscher Module B1 and B2: Parallelization.
Parallel Programming Models Jihad El-Sana These slides are based on the book: Introduction to Parallel Computing, Blaise Barney, Lawrence Livermore National.
Threads, Thread management & Resource Management.
Chapter 3 An Object-Oriented View of Action Systems.
Architecture styles Pipes and filters Object-oriented design Implicit invocation Layering Repositories.
12/1/98 COP 4020 Programming Languages Parallel Programming in Ada and Java Gregory A. Riccardi Department of Computer Science Florida State University.
Concurrency: Mutual Exclusion and Synchronization Chapter 5.
Definitions & Scenarios. Acknowledgements  This tutorial is based in part on Concurrency: State Models & Java Programming by Jeff Magee and Jeff Kramer.
CS4231 Parallel and Distributed Algorithms AY 2006/2007 Semester 2 Lecture 3 (26/01/2006) Instructor: Haifeng YU.
Multiprocessor and Real-Time Scheduling Chapter 10.
Chapter 101 Multiprocessor and Real- Time Scheduling Chapter 10.
111 © 2002, Cisco Systems, Inc. All rights reserved.
1 Multiprocessor and Real-Time Scheduling Chapter 10 Real-Time scheduling will be covered in SYSC3303.
ARTIFICIAL INTELLIGENCE [INTELLIGENT AGENTS PARADIGM] Professor Janis Grundspenkis Riga Technical University Faculty of Computer Science and Information.
Java Threads. What is a Thread? A thread can be loosely defined as a separate stream of execution that takes place simultaneously with and independently.
Major objective of this course is: Design and analysis of modern algorithms Different variants Accuracy Efficiency Comparing efficiencies Motivation thinking.
1 Concurrency Architecture Types Tasks Synchronization –Semaphores –Monitors –Message Passing Concurrency in Ada Java Threads.
CMPT 354, Simon Fraser University, Fall 2008, Martin Ester 136 Database Systems I SQL Modifications and Transactions.
WG5: Applications & Performance Evaluation Pascal Felber
Chapter 10 Software Engineering. Understand the software life cycle. Describe the development process models. Understand the concept of modularity in.
ICS 313: Programming Language Theory Chapter 13: Concurrency.
1. 2 Pipelining vs. Parallel processing  In both cases, multiple “things” processed by multiple “functional units” Pipelining: each thing is broken into.
DOUBLE INSTANCE LOCKING A concurrency pattern with Lock-Free read operations Pedro Ramalhete Andreia Correia November 2013.
© 2006 Pearson Addison-Wesley. All rights reserved2-1 Chapter 2 Principles of Programming & Software Engineering.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Lecture 11: Synchronization (Chapter 6, cont)
© 2006 Pearson Addison-Wesley. All rights reserved 2-1 Chapter 2 Principles of Programming & Software Engineering.
13-1 Chapter 13 Concurrency Topics Introduction Introduction to Subprogram-Level Concurrency Semaphores Monitors Message Passing Java Threads C# Threads.
Fall 2008Programming Development Techniques 1 Topic 20 Concurrency Section 3.4.
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.
Concurrent Object-Oriented Programming Languages Chris Tomlinson Mark Scheevel.
Parallel Computing Presented by Justin Reschke
Distributed Mutual Exclusion Synchronization in Distributed Systems Synchronization in distributed systems are often more difficult compared to synchronization.
1 Distributed Vertex Coloring. 2 Vertex Coloring: each vertex is assigned a color.
Agenda  Quick Review  Finish Introduction  Java Threads.
1/50 University of Turkish Aeronautical Association Computer Engineering Department Ceng 541 Introduction to Parallel Computing Dr. Tansel Dökeroğlu
Homework-6 Questions : 2,10,15,22.
740: Computer Architecture Memory Consistency Prof. Onur Mutlu Carnegie Mellon University.
Adding Concurrency to a Programming Language Peter A. Buhr and Glen Ditchfield USENIX C++ Technical Conference, Portland, Oregon, U. S. A., August 1992.
“Language Mechanism for Synchronization”
Advanced Topics in Concurrency and Reactive Programming: Asynchronous Programming Majeed Kassis.
The University of Adelaide, School of Computer Science
Symmetric Multiprocessing (SMP)
Objective of This Course
What is Concurrent Programming?
Multiprocessor and Real-Time Scheduling
Threaded Programming in Python
What is Concurrent Programming?
CS703 - Advanced Operating Systems
CS561 Computer Architecture Hye Yeon Kim
Operating System Overview
Concurrency: Threads, Address Spaces, and Processes
Presentation transcript:

A Discipline of Multiprogramming: Programming Theory for Distributed Applications by Jayadev Misra Chapter 1, Mikhail Nesterenko

Programming model claim: the major difficulty in programming a distributed application is not the number of computing entities but the inherent complexity of concurrent programming idea: to simplify (multi) programming separate sequential and concurrent aspects of programming model (Seuss): program execution is understood as single thread of control  program is reasoned about as sequential execution of actions (or methods)  implementation permits concurrent execution of multiple threads (actions)

Implications of Seuss possible to reason about sequential execution only (one action at a time) implementation can be concurrent need theory to formalize when concurrent execution is equivalent to serial efficiency becomes an issue (serial execution may degrade performance) no explicit need for concurrency control tools: synchronization, rendezvous, waiting, sharing, mutual exclusion, locking, etc.

Planning a meeting

Correctness and performance of plan sequential correctness: plan is correct when no other programs are executing  “easy” to prove, not the central issue of the book, use “traditional” sequential programming theories concurrent correctness  tradeoff between efficiency and ease of reasoning – the problem trivializes when each instance of plan gains exclusive access to shared data

Model again program – set of objects object – set of procedures (professor and room are objects): action or method action – a unit of uninterrupted execution, wait-free (action never stops or waits), terminating (always terminates) method – same as action only action is autonomous and method is called (object professor includes methods next and reserve) no need for locking, or other explicit consideration for concurrency

Efficient implementation: concurrency objective – implementation of efficient concurrent execution while preserving equivalence to serial execution independent actions – do not share objects, can be executed concurrently compatible actions (less strict) – concurrent execution of compatible action is equivalent to (some) serial execution  p.next and q.next are compatible (for all professors and rooms)  p.next and q.reserve are not task of programmer – specify compatible actions

Efficient implementation: termination what if resource is unavailable for a method to complete? (note, this never happens to actions, why?)  can’t wait  has to issue reject total method (transformational program) – always completes, never rejects  sorting an array of (non-shared) integers partial method(reactive?) – may issue reject rejection is transient condition (may change), acceptance is permanent if methods may reject, weaker compatibility is possible

Summary programming individual actions has been done before this book is the study in concurrent composition of actions and methods