Lecture10-intro-to-processes-part2

Lecture10-intro-to-processes-part2 - CS 3214 Computer...

Info iconThis preview shows pages 1–8. Sign up to view the full content.

View Full Document Right Arrow Icon
CS 3214 Computer Systems Godmar Back Lecture 10
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Announcements Exercise 4 due Sep 30 Brand new! Reverse-engineering and observation exercise Project 3 due Oct 14 CS 3214 Fall 2011
Background image of page 2
Threads and Processes Part 1 CS 3214 Fall 2011
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Processes Def: An instance of a program in execution OS provides each process with key abstractions Logical control flow 1 flow – single-threaded process Multiple flows – multi-threaded process Private address space Abstracted resources: e.g., stdout/stdin file descriptors These abstractions create the illusion that CS 3214 Fall 2011
Background image of page 4
CS 3214 Fall 2011 A Context Switch Scenario Process 1 Process 2 Kernel user mode kernel mode Timer interrupt: P1 is preempted, context switch to P2 System call: (trap): P2 starts I/O operation, blocks context switch to process 1 I/O device interrupt: P2’s I/O complete switch back to P2 Timer interrupt: P2 still has time left, no context switch
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
CS 3214 Fall 2011 Reasoning about Processes: Process States Only 1 process (per CPU) can be in RUNNING state RUNNING READY BLOCKED Process must wait for event Event arrived Scheduler picks process Process preempted
Background image of page 6
Process States RUNNING: Process is on CPU, its instructions are executed READY: Process could make progress if a CPU were available BLOCKED: Process cannot make progress even if a CPU
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 8
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 12/31/2011 for the course CS 3214 taught by Professor Staff during the Fall '11 term at Virginia Tech.

Page1 / 17

Lecture10-intro-to-processes-part2 - CS 3214 Computer...

This preview shows document pages 1 - 8. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online