Shortest seek time first (SSTF)  Selects the request with the minimum seek time from the current head position  SSTF scheduling is a form of SJF scheduling; may cause starvation of some requests  Illustration shows total head movement of 236 cylinders Operating System Concepts with Java – 8th Edition 12.11 Silberschatz, Galvin and Gagne ©2009
View full slide show




SSTF  Shortest Seek Time First selects the request with the minimum seek time from the current head position  SSTF scheduling is a form of SJF scheduling; may cause starvation of some requests  Illustration shows total head movement of 236 cylinders Operating System Concepts Essentials – 8 th Edition 11.19 Silberschatz, Galvin and Gagne ©2011
View full slide show




SSTF  Shortest Seek Time First selects the request with the minimum seek time from the current head position  SSTF scheduling is a form of SJF scheduling; may cause starvation of some requests  Illustration shows total head movement of 236 cylinders Operating System Concepts Essentials – 2nd Edition 9.21 Silberschatz, Galvin and Gagne ©2013
View full slide show




The New Stack – Process Is the Next Platform Client Punch Card or Terminal Custom (10’s of users) Application Data Management Applicatio n OS and Databas e Mainframe 4 Request Form Request Form Request Form Request Form Request Form Request Form Request Form Request Form Request Form Request Form Request Form Request Form Request Form Request Form Request Form Request Form Request Form Request Form Request Form Request Form Request Form Request Form Request Form Request Form Any Device (Millions of users) PC or Internet (1000’s of users) Composites Applicatio n Applicatio n Applicatio n OS OS OS DB OS Client Server OS OSApplicatio ns OS OS DB OS DB OS DB OS OS SOA Magal and Word ! Essentials of Business Processes and Information Systems | © 2009 Composites OS OSApplicatio ns OS OS DB OS DB OS DB OS OS
View full slide show




Shortest Job First (SJF) • PIAS aims to implement SJF Practically • Improves FCT • SJF per switch SJF for network High Short flows Low Long flows • Optimal for a single switch (PIAS [NSDI ‘15]) • NOT optimal for the whole network (pFabric [Sigcomm ‘13]) SJF SJF SJF SJF SJF SJF Optimal Global vs. local Not optimal PIAS (SJF per switch) is locally but not globally optimal 5
View full slide show




Shortest Seek Time First (SSTF) Service the request closest to the current head position • • • SSTF scheduling is similar to SJF scheduling Starvation of some requests is possible This Illustration shows total head movement of 236 cylinders.
View full slide show




C:\UMBC\331\java> java.ext.dirs=C:\JDK1.2\JRE\lib\ext java.io.tmpdir=C:\WINDOWS\TEMP\ os.name=Windows 95 java.vendor=Sun Microsystems Inc. java.awt.printerjob=sun.awt.windows.WPrinterJob java.library.path=C:\JDK1.2\BIN;.;C:\WINDOWS\SYSTEM;C:\... java.vm.specification.vendor=Sun Microsystems Inc. sun.io.unicode.encoding=UnicodeLittle file.encoding=Cp1252 java.specification.vendor=Sun Microsystems Inc. user.language=en user.name=nicholas java.vendor.url.bug=http://java.sun.com/cgi-bin/bugreport... java.vm.name=Classic VM java.class.version=46.0 java.vm.specification.name=Java Virtual Machine Specification sun.boot.library.path=C:\JDK1.2\JRE\bin os.version=4.10 java.vm.version=1.2 java.vm.info=build JDK-1.2-V, native threads, symcjit java.compiler=symcjit path.separator=; file.separator=\ user.dir=C:\UMBC\331\java sun.boot.class.path=C:\JDK1.2\JRE\lib\rt.jar;C:\JDK1.2\JR... user.name=nicholas user.home=C:\WINDOWS C:\UMBC\331\java>java envSnoop -- listing properties -java.specification.name=Java Platform API Specification awt.toolkit=sun.awt.windows.WToolkit java.version=1.2 java.awt.graphicsenv=sun.awt.Win32GraphicsEnvironment user.timezone=America/New_York java.specification.version=1.2 java.vm.vendor=Sun Microsystems Inc. user.home=C:\WINDOWS java.vm.specification.version=1.0 os.arch=x86 java.awt.fonts= java.vendor.url=http://java.sun.com/ user.region=US file.encoding.pkg=sun.io java.home=C:\JDK1.2\JRE java.class.path=C:\Program Files\PhotoDeluxe 2.0\Adob... line.separator=
View full slide show




Shortest-Job-First (SJF) Scheduling  Associate with each process the length of its next CPU burst. Use these lengths to schedule the process with the shortest time  SJF is optimal – gives minimum average waiting time for a given set of processes  The difficulty is knowing the length of the next CPU request Operating System Concepts with Java – 8th Edition 5.13 Silberschatz, Galvin and Gagne ©2009
View full slide show




Associating NFR to Multiple Use Case Elements Performance: system turn-around time less than 8 seconds. Current Practice: Title Submit Price Proposal Description Supplier submits price proposal against a RFP (request for proposal). Actors Supplier Basic Flow Repeating the NFR text in all applicable use cases 1.Supplier selects an RFP and requests system to submit a proposal against the RFP. 2.System prompts the Supplier for proposal information. 3.Supplier provides the following proposal information… 4.… Alternate Flows In step 3, Supplier may request to … Special Requirements Problems: • • Performance inherently associated with these 2 use cases Supplier may not see other suppliers’ identity and submitted proposals. Access on-line function Time consuming: same text in multiple places Error prone: • One change to NFR requires multiple synchronized changes • Thorough proof-read required to ensure correctness (no visual representation of NFRs) Title Submit Price Proposal Description Supplier submits price proposal against a RFP (request for proposal). Actors Supplier Basic Flow 1.Supplier selects an RFP and requests system to submit a proposal against the RFP. 2.System prompts the Supplier for proposal information. 3.Supplier provides the following proposal information… 4.… Alternate Flows In step 3, Supplier may request to … Special Requirements Supplier may not see other suppliers’ identity and submitted proposals. Title Submit Price Proposal Description Supplier submits price proposal against a RFP (request for proposal). Actors Supplier Basic Flow Approve price proposal Submit price proposal Alternate Flows In step 3, Supplier may request to … Special Requirements Supplier may not see other suppliers’ identity and submitted proposals. Service Item code name A Rule-based Solution: “An NFR associated with a use case element is propagated to other relevant use case elements in a more strict form” 1.Supplier selects an RFP and requests system to submit a proposal against the RFP. 2.System prompts the Supplier for proposal information. 3.Supplier provides the following proposal information… 4.… Menu Analogy: code and name inherited by these 2 classes Provision
View full slide show




Selecting a Disk-Scheduling Algorithm  SSTF is common and has a natural appeal  SCAN and C-SCAN perform better for systems that place a heavy load on the disk  Performance depends on the number and types of requests  Requests for disk service can be influenced by the file- allocation method  The disk-scheduling algorithm should be written as a separate module of the operating system, allowing it to be replaced with a different algorithm if necessary  Either SSTF or LOOK is a reasonable choice for the default algorithm Operating System Concepts with Java – 8th Edition 12.17 Silberschatz, Galvin and Gagne ©2009
View full slide show




Disk Scheduling  The operating system is responsible for using hardware efficiently — for the disk drives, this means having a fast access time and disk bandwidth  Access time has two major components  Seek time is the time for the disk to move the heads to the cylinder containing the desired sector  Rotational latency is the additional time waiting for the disk to rotate the desired sector to the disk head  Minimize seek time  Seek time  seek distance  Disk bandwidth is the total number of bytes transferred, divided by the total time between the first request for service and the completion of the last transfer Operating System Concepts with Java – 8th Edition 12.8 Silberschatz, Galvin and Gagne ©2009
View full slide show




Selecting a Disk-Scheduling Algorithm  SSTF is common and has a natural appeal  SCAN and C-SCAN perform better for systems that place a heavy load on the disk  Less starvation  Performance depends on the number and types of requests  Requests for disk service can be influenced by the file-allocation method  And metadata layout  The disk-scheduling algorithm should be written as a separate module of the operating system, allowing it to be replaced with a different algorithm if necessary  Either SSTF or LOOK is a reasonable choice for the default algorithm  What about rotational latency?   Difficult for OS to calculate How does disk-based queuing effect OS queue ordering efforts? Operating System Concepts Essentials – 8 th Edition 11.27 Silberschatz, Galvin and Gagne ©2011
View full slide show




Selecting a Disk-Scheduling Algorithm  SSTF is common and has a natural appeal  SCAN and C-SCAN perform better for systems that place a heavy load on the disk  Less starvation  Performance depends on the number and types of requests  Requests for disk service can be influenced by the file-allocation method  And metadata layout  The disk-scheduling algorithm should be written as a separate module of the operating system, allowing it to be replaced with a different algorithm if necessary  Either SSTF or LOOK is a reasonable choice for the default algorithm  What about rotational latency?   Difficult for OS to calculate How does disk-based queueing effect OS queue ordering efforts? Operating System Concepts Essentials – 2nd Edition 9.28 Silberschatz, Galvin and Gagne ©2013
View full slide show




Chapter 8 – Processor Scheduling Outline 8.1 8.2 8.3 8.4 8.5 8.6 8.7 8.7.1 8.7.2 8.7.3 8.7.4 8.7.5 8.7.6 8.7.7 8.8 8.9 8.10 Introduction Scheduling Levels Preemptive vs. Nonpreemptive Scheduling Priorities Scheduling Objectives Scheduling Criteria Scheduling Algorithms First-In-First-Out (FIFO) Scheduling Round-Robin (RR) Scheduling Shortest-Process-First (SPF) Scheduling Highest-Response-Ratio-Next (HRRN) Scheduling Shortest-Remaining-Time (SRT) Scheduling Multilevel Feedback Queues Fair Share Scheduling Deadline Scheduling Real-Time Scheduling Java Thread Scheduling  2004 Deitel & Associates, Inc. All rights reserved.
View full slide show




Shortest Path Trees Construction (We don’t need the Path Trees to get the Shortest Path Trees! That’s because a subpath of a shortest path is a shortest path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 0 0 1 3 S(k+1)Pi=SPSFk’i&(ORjSkPj Ej ) “The mask pTree of the shortest k+1 path starting at vertex i is the Shortest Paths So Far th c 9 a SPSF1i = S1Pi OR Mi , Mi has 1 only at i SPSF(k+1)i = SPSFki OR S(k+1)Pi 6 7 b a b 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 1 1 0 1 1 0 1 1 5 G6 4 2 SPSF2 3 8 3 1 1 1 1 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 0 0 0 0 3 1 1 1 1 0 0 0 0 0 0 1 1 1 1 0 0 1 1 1 1 0 0 0 0 What is the cost of creating the SPs? 3 1 2 c 0 0 0 1 0 1 1 1 1 0 1 1 0 0 1 0 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 0 0 0 0 0 0 0 0 0 1 1 1 0 S3P3=SPSF2’3&(ORjS2P3Ej ) SPSF3’3 3 SPSF4 3 S2P3=SPSF1’3&(ORjS1P3Ej ) SPSF2’3 3 SPSF3 3 1 S4P1=SPSF3’1&(ORjS3P1Ej ) SPSF4’1 SPSF41 S2P2=SPSF1’2&(ORjS1P2Ej ) S3P1=SPSF2’1&(ORjS2P1Ej ) SPSF3’1 8 1 1 0 0 S2P1=SPSF1’1&(ORjS1P1Ej ) 3 0 0 0 0 1 1 1 1 0 0 0 0 4 9 1 0 1 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 1 0 1 0 1 a b 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 1 1 0 1 1 0 1 1 S4P3=SPSF3’3&(ORjS3P3Ej ) SPSF4’3 vV, there are ~Avg{Diam(v)vV} steps, each costs Done with Vertex 1 complement of SPSF (cost =compl), 3 Shortest Paths. OR of ~Avg|Ek| pTrees (cost=OrAvg|Ek| 1 SPSF & above_OR_result (cost=AND), Vertices 4-c SPs done the same way 1 OR to update SPSF (cost=OR) 3 0 0 0 0 1 1 0 0 0 0 7 8 0 0 0 0 0 0 1 0 1 0 1 1 0 0 0 0 0 1 0 1 0 0 0 0 Cost= |V|*AvgDiam*(compl+OR*AD+AND+OR), 0 0 so O(|V|). I.e., linear in # of vertices, assuming AD=AvgDeg is small. This is a one-time, parallelizable construction over the vertices. For Friends, it is B*4*(3*pTOP+AD*pTOP)=4B*(3+AD)pTOP=B*pTOP*(12+4AD), where pTOP is the cost of a pTree Operation (comp, &, OR) and B=billion). Parallelized over an n node cluster, this 1-time Shortest Path Tree construction cost would be B*pTOP*(12+4AvgDeg) / n. The SnP’s capture only the shortest path lengths between all pairs of vertices. We could (have) capture actual shortest paths (all shortest paths?, all paths in PTs?), since we
View full slide show