9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 1 Threads CMSC 421 Spring 2012, Section 2 Dr. Richard Carback

Slides:



Advertisements
Similar presentations
Multithreading Overview Multithreading Models Threading Issues
Advertisements

OPERATING SYSTEMS Threads
Chapter 4: Threads. 4.2 Silberschatz, Galvin and Gagne ©2005 AE4B33OSS Chapter 4: Threads Overview Multithreading Models Threading Issues Pthreads Windows.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Chapter 4: Multithreaded Programming.
Threads. Objectives To introduce the notion of a thread — a fundamental unit of CPU utilization that forms the basis of multithreaded computer systems.
國立台灣大學 資訊工程學系 Chapter 4: Threads. 資工系網媒所 NEWS 實驗室 Objectives To introduce the notion of a thread — a fundamental unit of CPU utilization that forms the.
Threads.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Lecture 6: Threads Chapter 4.
Chapter 4: Threads. 4.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts – 7 th edition, Jan 23, 2005 Chapter 4: Threads Overview Multithreading.
Chapter 4: Threads. 4.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts – 7 th edition, Jan 23, 2005 Chapter 4: Threads Overview Multithreading.
Chapter 4: Threads. 4.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts – 7 th edition, Jan 23, 2005 Chapter 4: Threads Overview Multithreading.
Based on Silberschatz, Galvin and Gagne  2009 Threads Definition and motivation Multithreading Models Threading Issues Examples.
Chapter 4: Multithreaded Programming. 4.2 Silberschatz, Galvin and Gagne ©2005 Operating System Principles Objectives To introduce a notion of a thread.
Silberschatz, Galvin and Gagne ©2009Operating System Concepts – 8 th Edition Chapter 4: Threads.
Chapter 4: Threads READ 4.1 & 4.2 NOT RESPONSIBLE FOR 4.3 &
Chapter 4: Threads. 4.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Chapter 4: Threads Overview Multithreading Models Threading Issues.
Silberschatz, Galvin and Gagne  Operating System Concepts Chapter 5: Threads Overview Multithreading Models Threading Issues Pthreads Solaris.
Processes Part I Processes & Threads* *Referred to slides by Dr. Sanjeev Setia at George Mason University Chapter 3.
14.1 Silberschatz, Galvin and Gagne ©2009 Operating System Concepts with Java – 8 th Edition Chapter 4: Threads.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Chapter 4: Threads.
Operating System Principles Ku-Yaw Chang Assistant Professor, Department of Computer Science and Information Engineering Da-Yeh.
Silberschatz, Galvin and Gagne  Operating System Concepts Chapter 5: Threads Overview Multithreading Models Threading Issues Pthreads Solaris.
Chapter 4: Multithreaded Programming. 4.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Chapter 4: Multithreaded Programming Overview.
Copyright © 2006 by The McGraw-Hill Companies, Inc. All rights reserved. McGraw-Hill Technology Education Lecture 4 Operating Systems.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition Chapter 4: Threads CS 170 T Yang, Sept 2012.
Chapter 4: Threads. 4.2 Chapter 4: Threads Overview Multithreading Models Threading Issues Pthreads Windows XP Threads Linux Threads Java Threads.
14.1 Silberschatz, Galvin and Gagne ©2009 Operating System Concepts with Java – 8 th Edition Chapter 4: Threads.
Silberschatz, Galvin and Gagne ©2011Operating System Concepts Essentials – 8 th Edition Chapter 4: Threads.
Silberschatz, Galvin and Gagne ©2009Operating System Concepts – 8 th Edition Chapter 4: Threads.
Silberschatz, Galvin and Gagne  Operating System Concepts Chapter 5: Threads Multithreading Models Threading Issues Pthreads Solaris 2 Threads.
Chapter 4: Threads. 4.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts – 7 th edition, Jan 23, 2005 Chapter 4: Threads Overview Multithreading.
Chapter 4: Threads. 4.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Chapter 4: Threads Overview Multithreading Models Threading Issues.
Chapter 4: Threads. 2 Overview Multithreading Models Threading Issues Pthreads Windows XP Threads Linux Threads.
Overview Multithreading Models Threading Issues Pthreads Solaris 2 Threads Windows 2000 Threads Linux Threads Java Threads.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition Chapter 4: Threads Modified from the slides of the text book. TY, Sept 2010.
Chapter 4: Threads.
Silberschatz, Galvin and Gagne ©2013 Operating System Concepts – 9 th Edition Chapter 4: Threads.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Chapter 4: Threads.
Lecture 3 Threads Erick Pranata © Sekolah Tinggi Teknik Surabaya 1.
Saurav Karmakar. Chapter 4: Threads  Overview  Multithreading Models  Thread Libraries  Threading Issues  Operating System Examples  Windows XP.
Silberschatz, Galvin and Gagne ©2009Operating System Concepts – 8 th Edition Chapter 4: Threads (7 th Edition)
Silberschatz, Galvin and Gagne ©2009Operating System Concepts – 8 th Edition Chapter 4: Threads.
Silberschatz, Galvin and Gagne  Operating System Concepts Chapter 5: Threads Overview Multithreading Models Threading Issues Pthreads Solaris.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Chapter 4: Threads.
Lecture 5. Example for periority The average waiting time : = 41/5= 8.2.
14.1 Silberschatz, Galvin and Gagne ©2009 Operating System Concepts with Java – 8 th Edition Chapter 4: Multithreaded Programming.
OPERATING SYSTEM CONCEPT AND PRACTISE
Chapter 5: Threads Overview Multithreading Models Threading Issues
Chapter 5: Threads Overview Multithreading Models Threading Issues
Chapter 5: Threads Overview Multithreading Models Threading Issues
Chapter 5: Threads Overview Multithreading Models(多线程模型)
Chapter 4: Multithreaded Programming
Nadeem MajeedChoudhary.
Chapter 4: Threads.
ريسه ها Threads اسلايدهاي فصل چهارم کتاب سيلبرشاتز
Chapter 4: Threads.
Chapter 5: Threads Overview Multithreading Models Threading Issues
Chapter 4: Threads.
Chapter 4: Threads.
OPERATING SYSTEMS Threads
Modified by H. Schulzrinne 02/15/10 Chapter 4: Threads.
Chapter 4: Threads.
Chapter 4: Threads.
CHAPTER 4:THreads Bashair Al-harthi OPERATING SYSTEM
Chapter 4: Threads.
Chapter 5: Threads Overview Multithreading Models Threading Issues
Q:(a)Describe the action for a kernel to context switching for threads (b)why it is faster than processes?
Chapter 4: Threads.
Chapter 4: Threads.
Presentation transcript:

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 1 Threads CMSC 421 Spring 2012, Section 2 Dr. Richard Carback Slides based on Operating Systems Concepts, 8th Edition

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 2 Lecture Overview ● Overview ● Multithreading Models ● Thread Libraries ● Threading Issues ● Operating System Examples ● Windows XP Threads ● Linux Threads

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 3

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 4

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 5

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 6 User v. Kernel Threads ● Thread management done by user-level threads library ● Three primary thread libraries: ● POSIX Pthreads ● Win32 threads ● Java threads ● Supported by the Kernel ● Multiple pointers/more complex PCB. ● Examples ● Windows XP/2000 ● Solaris ● Linux ● Tru64 UNIX ● Mac OS X

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 7

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 8

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 9

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 10

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 11 Thread Libraries ● Thread library provides programmer with API for creating and managing threads ● Two primary ways of implementing ● Library entirely in user space ● Kernel-level library supported by the OS

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 12

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 13

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 14

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 15

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 16

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 17

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 18

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 19 Linux threads ● fork() and clone() system calls ● Doesn’t distinguish between process and thread ● Uses term task rather than thread ● clone() takes options to determine sharing on process create ● struct task_struct points to process data structures (shared or unique)

9/30/2016 Slides based on Operating Systems Concepts, 8th Edition 20 Questions?