Advanced Software Tools Research Seminar Fall 07 Arik Nemtsov.

Slides:



Advertisements
Similar presentations
Distributed Systems Major Design Issues Presented by: Christopher Hector CS8320 – Advanced Operating Systems Spring 2007 – Section 2.6 Presentation Dr.
Advertisements

Thomas Arts Industrial Use of a Functional Language Thomas Arts Ericsson Computer Science Laboratory Stockholm, Sweden
Dr. Kalpakis CMSC 621, Advanced Operating Systems. Fall 2003 URL: Distributed System Architectures.
WHAT IS AN OPERATING SYSTEM? An interface between users and hardware - an environment "architecture ” Allows convenient usage; hides the tedious stuff.
Distributed System Structures Network Operating Systems –provide an environment where users can access remote resources through remote login or file transfer.
MACHINE-INDEPENDENT VIRTUAL MEMORY MANAGEMENT FOR PAGED UNIPROCESSOR AND MULTIPROCESSOR ARCHITECTURES R. Rashid, A. Tevanian, M. Young, D. Golub, R. Baron,
Chorus and other Microkernels Presented by: Jonathan Tanner and Brian Doyle Articles By: Jon Udell Peter D. Varhol Dick Pountain.
Operating System Structure
490dp Synchronous vs. Asynchronous Invocation Robert Grimm.
Software Engineering and Middleware: a Roadmap by Wolfgang Emmerich Ebru Dincel Sahitya Gupta.
1: Operating Systems Overview
3.5 Interprocess Communication Many operating systems provide mechanisms for interprocess communication (IPC) –Processes must communicate with one another.
Scripting Languages For Virtual Worlds. Outline Necessary Features Classes, Prototypes, and Mixins Static vs. Dynamic Typing Concurrency Versioning Distribution.
3.5 Interprocess Communication
Chapter 13 Embedded Systems
16: Distributed Systems1 DISTRIBUTED SYSTEM STRUCTURES NETWORK OPERATING SYSTEMS The users are aware of the physical structure of the network. Each site.
1 Chapter 13 Embedded Systems Embedded Systems Characteristics of Embedded Operating Systems.
JAVA v.s. C++ Programming Language Comparison By LI LU SAMMY CHU By LI LU SAMMY CHU.
Wind River VxWorks Presentation
Lecture 4: Parallel Programming Models. Parallel Programming Models Parallel Programming Models: Data parallelism / Task parallelism Explicit parallelism.
9/14/2015B.Ramamurthy1 Operating Systems : Overview Bina Ramamurthy CSE421/521.
1 COMPSCI 110 Operating Systems Who - Introductions How - Policies and Administrative Details Why - Objectives and Expectations What - Our Topic: Operating.
LOGO OPERATING SYSTEM Dalia AL-Dabbagh
Operating System Review September 10, 2012Introduction to Computer Security ©2004 Matt Bishop Slide #1-1.
B.Ramamurthy9/19/20151 Operating Systems u Bina Ramamurthy CS421.
Distributed Systems. Interprocess Communication (IPC) Processes are either independent or cooperating – Threads provide a gray area – Cooperating processes.
Evaluating Erlang: Are High-level Languages suitable for Robust Telecoms Software? Jan Nystrom SafeCom'05 – Henry Nystrom, Phil Trinder, David King.
Motorola Internal Use Only Evaluating Erlang for Robust Telecoms Software David King 2004 S 3 Symposium – Henry Nystrom, Phil Trinder, David King.
Lecture 3 Process Concepts. What is a Process? A process is the dynamic execution context of an executing program. Several processes may run concurrently,
Advanced Computer Networks Topic 2: Characterization of Distributed Systems.
CE Operating Systems Lecture 3 Overview of OS functions and structure.
OSes: 3. OS Structs 1 Operating Systems v Objectives –summarise OSes from several perspectives Certificate Program in Software Development CSE-TC and CSIM,
CS 326: Functional Programming 1. 2 Erlang – A survey of the language & applications Paper by: Joe Armstrong, Computer Science Laboratory, Ericsson Telecom.
Distributed System Concepts and Architectures Services
The Performance of μ-Kernel-Based Systems H. Haertig, M. Hohmuth, J. Liedtke, S. Schoenberg, J. Wolter Presenter: Sunita Marathe.
Full and Para Virtualization
Operating Systems Unit 2: – Process Context switch Interrupt Interprocess communication – Thread Thread models Operating Systems.
1 Chapter 2: Operating-System Structures Services Interface provided to users & programmers –System calls (programmer access) –User level access to system.
Object Interaction: RMI and RPC 1. Overview 2 Distributed applications programming - distributed objects model - RMI, invocation semantics - RPC Products.
Towards a High Performance Extensible Grid Architecture Klaus Krauter Muthucumaru Maheswaran {krauter,
Presented by: Daniel Taylor
Operating Systems : Overview
Credits: 3 CIE: 50 Marks SEE:100 Marks Lab: Embedded and IOT Lab
Other Important Synchronization Primitives
The Client/Server Database Environment
Operating Systems : Overview
Operating Systems : Overview
Transactional Memory Semaphores, monitors, and conditional critical regions all suffer from limitations based on lock semantics Naïve synchronization may.
Operating Systems Bina Ramamurthy CSE421 11/27/2018 B.Ramamurthy.
Operating Systems : Overview
Threading And Parallel Programming Constructs
Operating Systems : Overview
Operating Systems : Overview
Operating Systems : Overview
Operating Systems : Overview
Operating Systems Lecture 1.
Operating Systems : Overview
Operating Systems : Overview
Operating Systems : Overview
Operating Systems : Overview
Industrial Use of a Functional Language
Mark McKelvin EE249 Embedded System Design December 03, 2002
Operating Systems : Overview
Operating Systems : Overview
Operating Systems : Overview
Operating Systems : Overview
Outline Operating System Organization Operating System Examples
Operating System Overview
Lecture Topics: 11/1 Hand back midterms
Presentation transcript:

Advanced Software Tools Research Seminar Fall 07 Arik Nemtsov

 Design Goals & History  Basic Syntax  Main strengths ◦ Concurrency Oriented Programming ◦ Distributed Programming ◦ Soft Real-time Environment ◦ Continuous Operation  Misc ◦ Criticism ◦ Real World Development using Erlang ◦ Bit Syntax ◦ Usage Examples

 Support of concurrency  Soft real-time environment  Continuous operation – no downtime  Support of distributed computing  Easy integration with binary modules

 1982 – Experiments with programming of telecom using > 20 different languages. Conclusion: The language must be a very high level symbolic language in order to achieve productivity gains ! (Leaves us with: Lisp, Prolog, Parlog...)  1985 – 86 - Experiments with Lisp, Prolog, Parlog etc. Conclusion: The language must contain primitives for concurrency and error recovery, and the execution model must not have back-tracking (Rules out Lisp and Prolog.)  Prototype construction of PABX functionality by external users. Erlang escapes from the lab!  ACS/Dunder Phase 2. Reconstruction of 1/10 of the complete MD-110 system. Results: 10 times greater gains in efficiency at construction compared with construction in PLEX!

 Fast implementation of Erlang is released to users. Erlang is represented at Telecom'91. More functionality such as ASN1 - Compiler, graphical interface etc.  A lot of new users. Erlang is ported to VxWorks, PC, Macintosh etc. Three applications using Erlang are presented at ISS'92. The two first product projects using Erlang are started.  Distribution is added to Erlang, which makes it possible to run a homgeneous Erlang system on a heterogeneous hardware.  1996 – 1997 – construction of BEAM – Erlang to C compiler. Replaces old compiler.

 Specific problem at hand: large soft real-time control systems ◦ Millions of lines of code ◦ Robust – 3min/year downtime  Prototype language used for massively concurrent projects  Language features removed/added by developer demand

 Declarative syntax  Single assignment property  Data Types: ◦ Primitive:  Numbers – 1, 2#101011, 16#1FFA3, $B, 0.23  Atoms – mememe, start_with_lower_case, ‘quoted’ ◦ Complex:  Lists – [123, xyz, ’aaa’]  Tuples – {123, xyz, ‘aaa’}  String implemented as a list of integers “abc” [97,98,99]  Variables start with an Uppercase letter

 C#, Java – shared state concurrency ◦ Any thread can modify any state at any time ◦ All synchronization is explicit, manual ◦ No compile-time verification of correctness properties:  Deadlock-free  Race-free  Software generally scales poorly to thread count (= multi-processors)

 At present: ◦ Xbox 360 – 3 cores ◦ Intel Core 2 – up to 4 cores ◦ Sun T2000 – 8 cores, 32 hardware threads  In a couple of years: ◦ 20+ cores ◦ 80+ hardware threads  Multi-core support is a must at this point

 Lightweight Processes ◦ provide a convenient partitioning into concurrent sub-components  Efficiency in scaling to a multi-processor environment ◦ Functional programming style avoids mutable state ◦ Message passing avoids shared state  Fault isolation ◦ no sharing of data that can be corrupted (affecting many processes)

 Support of processes ◦ a sort of self contained VMs ◦ Processes are strongly isolated  Each process has a unique identifier ◦ The name of a process cannot be forged  Message passing is the only way processes interact ◦ The is no shared state ◦ If one knows the name of a process it can send a message to the process  Message passing is unreliable ◦ Messages are delivered asynchronously ◦ Messages are atomic – they are either delivered, or not  A process can detect failure in another process ◦ We should also be able to find the reason for failure

 Support of lightweight processes ◦ All executed code resides inside processes ◦ No use of OS processes/threads ◦ Built-in scheduler ◦ Processes share no resources  Process naming scheme ◦ register(Name, Pid)  Non local Error handling ◦ Error-kernel: not all processes must be correct ◦ Leads to fault-tolerance  Uses Actor Model

 Message Passing ◦ One must know the name/Pid of process to send it a message  Why not shared memory? ◦ Critical Regions  Programs crash in a critical region (lacking transaction semantics)  Programs spend too much time in a critical region  Locking more than you need ◦ No support of distribution – multi CPU/multi physical computers ◦ Can introduce deadlocks ◦ Creates process inter-dependency -> error prone -> unreliable

 Erlang allows linking of processes  Exit signals propagate through linked processes  Policy choice: ◦ Trap exit signal – no process termination ◦ No trapping – termination  Allows design of layered applications: ◦ No error handling code at lower levels ◦ Encourages application modularity

 Parent traps child exit  Re-spawns the child if K > 0

 Transparent extension across many nodes ◦ Process spawning ◦ Message passing (IPC) – not so easy  Code marshalling issues handled by environment ◦ Essentially enables code “hot-swapping” – run time replacement of executable modules  Leads to a fault tolerant programming paradigm  Additional security considerations

 Little need of OS services (Makes porting easier)  Real-time garbage collector  Lightweight processes  Efficient message passing  Internal cooperative process scheduler

 Dynamic module upgrade mechanism ◦ Old and Current code can run in parallel  Advanced error detection primitives ◦ Process exit signal trapping ◦ Exception handling mechanism

 Process Management ◦ Scheduler, I/O, …  Memory Management ◦ Garbage Collector  Process Isolation & Security ◦ Process Registration, Naming issues  Networking ◦ Distributed Computing  Device Drivers ◦ Ports

 Primitive security model ◦ How to restrict access to a node? ◦ Limit the abilities of a process  Message Passing only IPC ◦ Copying of buffers back and forth  How to program “Photoshop”? ◦ Game-state simulation  1000’s of objects updated 30 times per second. Each update touches up to 5-10 other objects. (Tim Sweeny)  How to program “Quake”?

 OTP core library ◦ OTP “drives” the application and you supply the “business logic” via callbacks ◦ Many useful generalization of behavior (e.g. gen_server) ◦ Battle-tested in Ericsson (scalability, reliability)  Good software development tools ◦ Fast Native compiler ◦ Helper tools – debugger, procman, table viewer, … ◦ Again tested by ericsson  Ecplise IDE Plugin! (December 2007)

 Bit Syntax  Real World projects: ◦ Ejabberd – jabber server ◦ Yaws – web server ◦ ErlyWeb – web application framework (a la “Rails”) ◦ Erricsson AXD301 – 1.7 MLOC  Erlang for.NET

 Apache dies at ~4000 requests  Yaws endures very high loads Throughput (kb/sec) vs. load (requests)