Methods of Stochastic Performance Analysis

Slides:



Advertisements
Similar presentations
UNIT-II Queuing Theory
Advertisements

Lecture 5 This lecture is about: Introduction to Queuing Theory Queuing Theory Notation Bertsekas/Gallager: Section 3.3 Kleinrock (Book I) Basics of Markov.
Introduction to Queuing Theory
Hadi Goudarzi and Massoud Pedram
Copyright © 2005 Department of Computer Science CPSC 641 Winter PERFORMANCE EVALUATION Often in Computer Science you need to: – demonstrate that.
Queueing Model 박희경.
Queuing Analysis Based on noted from Appendix A of Stallings Operating System text 6/10/20151.
ECS 152A Acknowledgement: slides from S. Kalyanaraman & B.Sikdar
RAIDs Performance Prediction based on Fuzzy Queue Theory Carlos Campos Bracho ECE 510 Project Prof. Dr. Duncan Elliot.
OS Fall ’ 02 Performance Evaluation Operating Systems Fall 2002.
1 Performance Evaluation of Computer Networks Objectives  Introduction to Queuing Theory  Little’s Theorem  Standard Notation of Queuing Systems  Poisson.
Data Communication and Networks Lecture 13 Performance December 9, 2004 Joseph Conron Computer Science Department New York University
1 Queueing Theory H Plan: –Introduce basics of Queueing Theory –Define notation and terminology used –Discuss properties of queuing models –Show examples.
1 PERFORMANCE EVALUATION H Often in Computer Science you need to: – demonstrate that a new concept, technique, or algorithm is feasible –demonstrate that.
CS533 Modeling and Performance Evaluation of Network and Computer Systems Queuing Theory (Chapter 30-31)
CSE 550 Computer Network Design Dr. Mohammed H. Sqalli COE, KFUPM Spring 2012 (Term 112)
Queueing Theory.
7/3/2015© 2007 Raymond P. Jefferis III1 Queuing Systems.
Introduction to Queuing Theory. 2 Queuing theory definitions  (Kleinrock) “We study the phenomena of standing, waiting, and serving, and we call this.

Introduction to Queuing Theory
Queueing Theory Queueing theory definitions (Bose) “the basic phenomenon of queueing arises whenever a shared facility needs to be accessed for.
Copyright warning. COMP5348 Lecture 6: Predicting Performance Adapted with permission from presentations by Alan Fekete.
Introduction to Discrete Event Simulation Customer population Service system Served customers Waiting line Priority rule Service facilities Figure C.1.
AN INTRODUCTION TO THE OPERATIONAL ANALYSIS OF QUEUING NETWORK MODELS Peter J. Denning, Jeffrey P. Buzen, The Operational Analysis of Queueing Network.
Network Analysis A brief introduction on queues, delays, and tokens Lin Gu, Computer Networking: A Top Down Approach 6 th edition. Jim Kurose.
Introduction to Queuing Theory
Copyright ©: Nahrstedt, Angrave, Abdelzaher, Caccamo1 Queueing Systems.
1 Performance Evaluation of Computer Systems and Networks Introduction, Outlines, Class Policy Instructor: A. Ghasemi Many thanks to Dr. Behzad Akbari.
 Birth Death Processes  M/M/1 Queue  M/M/m Queue  M/M/m/B Queue with Finite Buffers  Results for other Queueing systems 2.
MIT Fun queues for MIT The importance of queues When do queues appear? –Systems in which some serving entities provide some service in a shared.
Introduction to Operations Research
Lecture 10: Queueing Theory. Queueing Analysis Jobs serviced by the system resources Jobs wait in a queue to use a busy server queueserver.
NETE4631:Capacity Planning (2)- Lecture 10 Suronapee Phoomvuthisarn, Ph.D. /
Chapter 3 System Performance and Models. 2 Systems and Models The concept of modeling in the study of the dynamic behavior of simple system is be able.
Introduction to Queueing Theory
Queuing Theory Basic properties, Markovian models, Networks of queues, General service time distributions, Finite source models, Multiserver queues Chapter.
1 Queueing Theory Frank Y. S. Lin Information Management Dept. National Taiwan University
Queueing Theory What is a queue? Examples of queues: Grocery store checkout Fast food (McDonalds – vs- Wendy’s) Hospital Emergency rooms Machines waiting.
1 Queuing Models Dr. Mahmoud Alrefaei 2 Introduction Each one of us has spent a great deal of time waiting in lines. One example in the Cafeteria. Other.
TexPoint fonts used in EMF.
CS433 Modeling and Simulation Lecture 12 Queueing Theory Dr. Anis Koubâa 03 May 2008 Al-Imam Mohammad Ibn Saud University.
1 Chapters 8 Overview of Queuing Analysis. Chapter 8 Overview of Queuing Analysis 2 Projected vs. Actual Response Time.
yahoo.com SUT-System Level Performance Models yahoo.com SUT-System Level Performance Models8-1 chapter11 Single Queue Systems.
Modeling and Simulation Queuing theory
Queuing Theory and Traffic Analysis Based on Slides by Richard Martin.
Chapter 3 System Performance and Models Introduction A system is the part of the real world under study. Composed of a set of entities interacting.
M/M/1 Queues Customers arrive according to a Poisson process with rate. There is only one server. Service time is exponential with rate  j-1 jj+1...
CS352 - Introduction to Queuing Theory Rutgers University.
CSCI1600: Embedded and Real Time Software Lecture 19: Queuing Theory Steven Reiss, Fall 2015.
OPERATING SYSTEMS CS 3530 Summer 2014 Systems and Models Chapter 03.
Internet Applications: Performance Metrics and performance-related concepts E0397 – Lecture 2 10/8/2010.
Copyright ©: Nahrstedt, Angrave, Abdelzaher, Caccamo1 Queueing Systems.
Queuing Theory.  Queuing Theory deals with systems of the following type:  Typically we are interested in how much queuing occurs or in the delays at.
Queueing Fundamentals for Network Design Application ECE/CSC 777: Telecommunications Network Design Fall, 2013, Rudra Dutta.
Mohammad Khalily Islamic Azad University.  Usually buffer size is finite  Interarrival time and service times are independent  State of the system.
QUEUING THEORY 1.  - means the number of arrivals per second   - service rate of a device  T - mean service time for each arrival   = ( ) Utilization,
Queuing Theory Simulation & Modeling.
CPE 619 Introduction to Queuing Theory
OPERATING SYSTEMS CS 3502 Fall 2017
Al-Imam Mohammad Ibn Saud University
Lecture on Markov Chain
CSCI1600: Embedded and Real Time Software
Computer Systems Performance Evaluation
TexPoint fonts used in EMF.
Lecture 18 Syed Mansoor Sarwar
Computer Systems Performance Evaluation
Queueing Theory 2008.
Course Description Queuing Analysis This queuing course
VIRTUE MARYLEE MUGURACHANI QUEING THEORY BIRTH and DEATH.
Presentation transcript:

Methods of Stochastic Performance Analysis Perry Lea Hewlett Packard - Core Technology Laboratory

Why Am I Talking About This Currently I’m an ES working on future architectures and use these techniques with frequency to aid my design decisions Used these techniques to discover good designs Used these techniques to stop bad designs

Who Uses This Stuff System Architects / Engineers / Scientists Transportation systems Industrial and production analysis Behavorialists Communication systems and of course the general engineering community.

Typical Problems Addressed How fast will it print or copy? How do we distribute various tasks to various processors? What is the bus contention? Will we meet the real-time requirements?

What Is Performance Analysis (Jain Book Definition) Specifying performance requirements Comparing 2 or more systems Determining optimal/achievable parameters Finding bottlenecks Capacity planning Workload planning This talk is about: Stochastic Analysis Operational Analysis Discrete Event Simulation

The Stochastic Process Anything that is observed as a random process in time is a stochastic process. A stochastic process can be discrete (good for CS folks) or continuous (good for signals folks) If a future state of your system is not dependent on a previous state, the process can be called a Markov process. This is good because Markov processes are easy to model. Memoryless property If the arrival times of “data” to the different states are independent of each other – AND – the arrival times have the same distribution (hopefully exponentially distributed), then you can describe the process as a Poisson process. IID: Independent and identically distributed

Queue Rules  the interarrival rate, time between 2 successive arrivals (Random Variable)  the arrival rate s the service time  the mean service rate per server, or 1/E[s] n the number of jobs in the system r the response time (includes time waiting in queue and actual cpu time) w the waiting time

Some Math l = arrival rate (going in) m = service rate (going out) r = l / m is the traffic intensity or density The probability that there are n tasks waiting in the queue is:

Birth Death Process The Birth – Death Process Each state represents the queue depth 1 2 j-1 j j+1

Queues Kendall Notation A/B/C/D/E Types of processes A = arrival process B = service process C = number of servers D = maximum number of jobs for which the queue has room. E = maximum number of jobs being simulated Types of processes M = (Memoryless) Poisson arrival process or exponentially distributed service time D = deterministic arrival process (each job has the same service time) Aha! Here’s the deterministic part of all this. G = general distribution arrival process E = Erlang distribution Hyperexponential

Typical Queues M/M/1 M/G/1 Others Jobs arrive according to a Poisson process Service time of each job is exponentially distributed. There is one server There is infinite waiting room and no limit to the number of jobs M/G/1 Service time is generally distributed (no restriction of the form the distribution may take) Others M/D/1 (D denotes each jobs take the same amount of time to be service) M/G/ (Infinite amount of servers available) G/M/1 G/G/m

M/M/1 Model Analysis Traffic Intensity (Utilization): r = l/m Condition of Stability: r < 1 Probability queue empty: p0 = 1 – r Probability queue = n: pn = (1-r)rn * Mean queue depth: E[n]=r/(1 - r) Mean waiting time: E[w]=r ((1/m) / (1-r)) Mean response time (E[n] = /E[r]) * E[r] = (1/m) / (1-r) Other models have similar equations (See Jain Book)

M/M/1 Example A printer processes 125 packets per second and takes 2 ms to process them. When will the printer overflow with 13 buffers? How many buffers are needed to keep packet loss below one in a million? Arrival rate l = 125 pps Service rate m = 1/.002 = 500 pps Utilization r = 0.25 or 25% Probability of n packets in gateway = (1-r)rn = 0.75(0.25)n Mean number of packets in gateway = r/1-r = 0.33 Probability of buffer overflow -> P(more than 13 packets) 13 = 0.2513 = 15 packets in 1 billion To limit the probability loss to 10-6 n <= 10-6 n > log(10-6) / log(0.25) = 9.96 buffers

Operational Laws (Denning and Buzen) (Simple formulas for finite observable time) If you observe a system for a finite amount of time, you can skip the distributions of service and interarrival times. You can use a set of simple (directly measurable) equations to predict performance Arrival Rate : # arrivals / time : Ai/T Throughput : # completions / time : Ci/T Busy Time : Bi Mean Service Time : total time served / # served : Bi / Ci Utilization Law : U = Bi/T (T is the observed time) Forced Flow Law : system throughput : X = C0/T Little’s Law : mean # in device = arrival rate * mean time Qi=i*Ri Bottleneck Identification : The device with the largest Di

Queuing Networks Open Network Closed Network Jackson product-form solution Closed Network Buzen convolution algorithms

Large Queuing Networks Large systems can be modeled as a collection of queues. Bounding algorithms Find upper and lower bounds only. Mean value analysis (MVA) Iterative method to find response times for each device in the system. This will sum to the system response time and overall queue lengths. Convolution algorithms Array convolutions Can answer more detailed questions than MVA, i.e. are 2 IO devices busy at the same time? For large networks, we use software simulators

Discrete Event Simulations Why use a simulator? Hard to build analytic models for: Virtual memory Resource sharing (CPU and IO) Mutual exclusion to resources Bulk packet arrivals (self similarity) Non-exponential service times Can run many variants and perturbations of a system Can build stochastic and deterministic models and intermix them. To automate the mathematical process Allows you to study the problem from many angles with ease compared to analytical models

Modeling Tips Understand the architecture in detail first Decide on how detailed your model should be The more detailed the more time, and possibly the more bugs you will introduce you don’t want to build the final product. Do you need to model the whole system, or just a part? Get the abstraction defined before you start!! Chose the right tool and language Verify and test the models State what the goal of the model is, know when to stop Don’t let mysterious results pass – understand them. Review the model design – like any other piece of code.

Good Simulation Tools http://www.idsia.ch/~andrea/simtools.html C++SIM Good site with links to many modeling tools C++SIM C Libraries Do it yourself standalone, no GUI, good for academics Opnet Modeler MIL3, mainly for network and data flow CSIM Lockheed Martin – good for computer and electronic systems Discrete and continuous models NT and Unix flavors SES Workbench A generic modeling tool GUI, object orientated, NT and Unix

Recommended Reading “The Art of Computer Systems Performance Analysis”, Raj Jain, Wiley & Sons 1991 “Performance Modeling for Computer Architects”, C. Krishna, IEEE Computer Society Press 1996 “Telecommunication Networks”, Mischa Shwartz, Addison Wesley 1987