Docsity

Implementing Processes, Thread and Resources - Lecture Notes for Exam | CS 3204, Study notes of Operating Systems

Partial preview of the text

Download Implementing Processes, Thread and Resources - Lecture Notes for Exam | CS 3204 and more Study notes Operating Systems in PDF only on Docsity!

 ^  



      ^    ^ 

  ^  ^ 

^  ^  

 ^    

!^   

^  ^  

OS AddressSpace (  ^  

)* ControlUnit OS interface

CPU^ P^ Addressi^ ALUSpace^ …^ Machine Executable Memory

PCPUi^ P Executablei^ Memory

PCPU PCPUk^ j … P Executable PExecutablek^ j MemoryMemory^ P^ Addressk^ Space^ PAddressj^ Space

,^   -

  ApplicationProgram CreateThread()^ fork()CreateProcess()CloseHandle()wait()exec()WaitForSingleObject() File Mgr^ File Mgr Device Mgr^ Device Mgr Process Mgr^ Process Mgr Memory Mgr^ Memory Mgr UNIX^ Windows Hardware

4

  

^ ^ 5^   #

!^  $ 

^    

^    

6   

OS interface

Thrd^ in PThrd^ in Pj^ i^ k^ i^ … P^ CPUi^ …^ …^ …

89

)^ AddressAddressSpaceBinding Process

ExecutableMemory^ Files^ Other objects

88

^  *

^  

 ^   *   <& ^ 

^ ^ !

 2  3^ 

8"

)*

 Application Program User ModeInstructions User ModeInstructions

Abstract Machine Instructions Trap^ fork()Instructionopen()^ create()^ OS Supervisor ModeInstructions

8(

  Executable Memory^1 Initialization^ ProcessManager^ InterruptHandler^2 P^1 P^2 P^ n

3 4 5 (^78) Interrupt 9 6

8

^ ^  

^ %

84

87

:^ !=

; )  

^ ^ !



:^ !=

!E

^ ) !^

^  ^   *

 ^ ^ !^ ^ !^ ^  ^ ^ !^ ^ !^  ^ ^ ^     !* ^ ^ ≠^ ≠^ ^2 '3^ ^ ^ ^ F ^ ^ &^ 

^  G