Håkan Sundell, Chalmers University of Technology 1 Evaluating the performance of wait-free snapshots in real-time systems Björn Allvin.

Slides:



Advertisements
Similar presentations
TWO STEP EQUATIONS 1. SOLVE FOR X 2. DO THE ADDITION STEP FIRST
Advertisements

Chapter 13: I/O Systems I/O Hardware Application I/O Interface
1 Concurrency: Deadlock and Starvation Chapter 6.
Advanced Piloting Cruise Plot.
Chapter 1 The Study of Body Function Image PowerPoint
Processes and Operating Systems
Author: Julia Richards and R. Scott Hawley
1 Copyright © 2013 Elsevier Inc. All rights reserved. Appendix 01.
Business Transaction Management Software for Application Coordination 1 Business Processes and Coordination.
and 6.855J Spanning Tree Algorithms. 2 The Greedy Algorithm in Action
1 Episode III in our multiprocessing miniseries. Relaxed memory models. What I really wanted here was an elephant with sunglasses relaxing On a beach,
© 2010 Pearson Addison-Wesley. All rights reserved. Addison Wesley is an imprint of Chapter 11: Structure and Union Types Problem Solving & Program Design.
Jeopardy Q 1 Q 6 Q 11 Q 16 Q 21 Q 2 Q 7 Q 12 Q 17 Q 22 Q 3 Q 8 Q 13
Jeopardy Q 1 Q 6 Q 11 Q 16 Q 21 Q 2 Q 7 Q 12 Q 17 Q 22 Q 3 Q 8 Q 13
Title Subtitle.
My Alphabet Book abcdefghijklm nopqrstuvwxyz.
DIVIDING INTEGERS 1. IF THE SIGNS ARE THE SAME THE ANSWER IS POSITIVE 2. IF THE SIGNS ARE DIFFERENT THE ANSWER IS NEGATIVE.
FACTORING ax2 + bx + c Think “unfoil” Work down, Show all steps.
Addition Facts
Year 6 mental test 10 second questions
1 Interprocess Communication 1. Ways of passing information 2. Guarded critical activities (e.g. updating shared data) 3. Proper sequencing in case of.
ZMQS ZMQS
Solve Multi-step Equations
Richmond House, Liverpool (1) 26 th January 2004.
REVIEW: Arthropod ID. 1. Name the subphylum. 2. Name the subphylum. 3. Name the order.
DOROTHY Design Of customeR dRiven shOes and multi-siTe factorY Product and Production Configuration Method (PPCM) ICE 2009 IMS Workshops Dorothy Parallel.
Outline Introduction Assumptions and notations
Fast and Lock-Free Concurrent Priority Queues for Multi-Thread Systems Håkan Sundell Philippas Tsigas.
ABC Technology Project
1 Undirected Breadth First Search F A BCG DE H 2 F A BCG DE H Queue: A get Undiscovered Fringe Finished Active 0 distance from A visit(A)
VOORBLAD.
15. Oktober Oktober Oktober 2012.
Making Time-stepped Applications Tick in the Cloud Tao Zou, Guozhang Wang, Marcos Vaz Salles*, David Bindel, Alan Demers, Johannes Gehrke, Walker White.
1 Breadth First Search s s Undiscovered Discovered Finished Queue: s Top of queue 2 1 Shortest path from s.
Factor P 16 8(8-5ab) 4(d² + 4) 3rs(2r – s) 15cd(1 + 2cd) 8(4a² + 3b²)
Squares and Square Root WALK. Solve each problem REVIEW:
Basel-ICU-Journal Challenge18/20/ Basel-ICU-Journal Challenge8/20/2014.
1..
© 2012 National Heart Foundation of Australia. Slide 2.
1 Processes and Threads Chapter Processes 2.2 Threads 2.3 Interprocess communication 2.4 Classical IPC problems 2.5 Scheduling.
LO: Count up to 100 objects by grouping them and counting in 5s 10s and 2s. Mrs Criddle: Westfield Middle School.
Understanding Generalist Practice, 5e, Kirst-Ashman/Hull
Executional Architecture
Chapter 5 Test Review Sections 5-1 through 5-4.
GG Consulting, LLC I-SUITE. Source: TEA SHARS Frequently asked questions 2.
Addition 1’s to 20.
25 seconds left…...
Equal or Not. Equal or Not
U1A L1 Examples FACTORING REVIEW EXAMPLES.
H to shape fully developed personality to shape fully developed personality for successful application in life for successful.
Januar MDMDFSSMDMDFSSS
Week 1.
We will resume in: 25 Minutes.
©Brooks/Cole, 2001 Chapter 12 Derived Types-- Enumerated, Structure and Union.
Intracellular Compartments and Transport
PSSA Preparation.
Essential Cell Biology
1 Chapter 13 Nuclear Magnetic Resonance Spectroscopy.
Immunobiology: The Immune System in Health & Disease Sixth Edition
CpSc 3220 Designing a Database
Håkan Sundell, Chalmers University of Technology 1 Space Efficient Wait-free Buffer Sharing in Multiprocessor Real-time Systems Based.
Simple Wait-Free Snapshots for Real-Time Systems with Sporadic Tasks Håkan Sundell Philippas Tsigas.
Håkan Sundell, Chalmers University of Technology 1 Using Timing Information on Wait-Free Algorithms in Real-Time Systems (2 papers)
Håkan Sundell, Chalmers University of Technology 1 Applications of Non-Blocking Data Structures to Real-Time Systems Seminar for the.
Håkan Sundell, Chalmers University of Technology 1 Simple and Fast Wait-Free Snapshots for Real-Time Systems Håkan Sundell Philippas.
Presentation transcript:

Håkan Sundell, Chalmers University of Technology 1 Evaluating the performance of wait-free snapshots in real-time systems Björn Allvin Andreas Ermedahl Hans Hansson Marina Papatriantafilou Håkan Sundell Philippas Tsigas

Håkan Sundell, Chalmers University of Technology 2 Schedule What are we evaluating How did we do the evaluation Evaluation platform Analysis Experiments Conclusions Future work

Håkan Sundell, Chalmers University of Technology 3 Snapshot –A consistent momentous state of a set of several shared variables –One reader Reads the whole set of variables in one atomic step –Many writers Writes to only one variable each time What are we evaluating

Håkan Sundell, Chalmers University of Technology 4 What are we evaluating Synchronization methods –Lock Uses semaphores, spinning, disabling interrupts Negative –Blocking –Priority inversion –Risk of deadlock Positive –Execution time guarantees easy to do Take lock... do operation... Release lock

Håkan Sundell, Chalmers University of Technology 5 What are we evaluating Synchronization methods –Lock-free Retries until not interfered by other operations Usually uses some kind of shared flag variable Write flag... do operation... Check flag and maybe retry

Håkan Sundell, Chalmers University of Technology 6 What are we evaluating Synchronization methods –Lock-free Negative –No execution time guarantees, can continue forever - thus can cause starvation Positive –Avoids blocking and priority inversion –Avoids deadlock –Fast execution when low contention

Håkan Sundell, Chalmers University of Technology 7 What are we evaluating Synchronization methods –Wait-free Uses atomic synchronization primitives Uses shared memory Negative –Complex algorithms –Memory consuming Test&SetCompare&SwapCopyingHelpingAnnouncingSplitoperation???

Håkan Sundell, Chalmers University of Technology 8 What are we evaluating Synchronization methods –Wait-free Positive –Execution time guarantees –Fast execution –Avoids blocking and priority inversion –Avoids deadlock –Avoids starvation –Same implementation on both single- and multiprocessor systems

Håkan Sundell, Chalmers University of Technology 9 What are we evaluating Wait-free snapshot algorithm –Several register copies –Uses Test&Set for synchronization Used by writer Used by reader

Håkan Sundell, Chalmers University of Technology 10 How did we do the evaluation Analytically –Single-processor system –Measured schedulability

Håkan Sundell, Chalmers University of Technology 11 How did we do the evaluation Experimentally –Single-processor system Measured schedulability –Multi-processor system with CAN-bus Measured snapshot response time

Håkan Sundell, Chalmers University of Technology 12 Evaluation platform Hardware –CAN-bus, 1 Mhz –Nodes 1 processor, Motorola 68020, 20 MHz Single wait-state memory CAN-controller

Håkan Sundell, Chalmers University of Technology 13 Evaluation platform Software –RTOS –Device tasks (interrupts) –Updater tasks –Local snapshot tasks –System snapshot task

Håkan Sundell, Chalmers University of Technology 14 Evaluation platform Additional parameters –Snapshot algorithm timings from WCET analysis Cross-compiling Cycle counting –CAN-bus timing from estimation

Håkan Sundell, Chalmers University of Technology 15 Analysis Parameters –10 tasks –15 devices –Snapshot of 5 components

Håkan Sundell, Chalmers University of Technology 16 Analysis Response time formulas RiRiRiRi CiCiCiCi  CjCjCjCj RiRiRiRi TjTjTjTj = j  hp(i) +......

Håkan Sundell, Chalmers University of Technology 17 Analysis Generation of 100 random scenarios for each of 31 different CPU loads Each scenario schedulable without any synchronization method

Håkan Sundell, Chalmers University of Technology 18 Analysis Results

Håkan Sundell, Chalmers University of Technology 19 Experiments Simulation –RT-simulator in Erlang Fixed priority preemptive scheduler Execution time Semaphores Memory Messages

Håkan Sundell, Chalmers University of Technology 20 Experiments Single-node –Parameters 10 tasks 15 devices Snapshot of 5 components

Håkan Sundell, Chalmers University of Technology 21 Experiments Single-node –Simulator programming Using subset of scenarios used for the analysis Lock –Execution and semaphores Lock-free –Execution and shared memory Wait-free –Execution

Håkan Sundell, Chalmers University of Technology 22 Experiments Single-node –Results

Håkan Sundell, Chalmers University of Technology 23 Experiments Multi-node –CAN-simulation Sending –Execution Receiving –Execution of highest priority task –Execution

Håkan Sundell, Chalmers University of Technology 24 Experiments Multi-node –Parameters 10 nodes 10 tasks on each node 15 devices on each node Local snapshot of 24 components on each node 1 super snapshot task on last node

Håkan Sundell, Chalmers University of Technology 25 Experiments Multi-node –Simulator programming Using subset of scenarios used for the analysis Lock –Execution, semaphores and messages Lock-free –Execution, shared memory and messages Wait-free –Execution and messages

Håkan Sundell, Chalmers University of Technology 26 Experiments Multi-node –Results

Håkan Sundell, Chalmers University of Technology 27 Experiments Multi-node –Results

Håkan Sundell, Chalmers University of Technology 28 Conclusions Wait-free is always better than lock Lock-free mostly performs better than lock –Single-node Lock-free performs best in practice Wait-free performs very good –Multi-node Lock-free performs poor Wait-free performs best

Håkan Sundell, Chalmers University of Technology 29 Future work Investigations of other wait-free synchronization methods Implementations in RTOS kernels, by Enea and NRTG WARPing project -