1 / 12

Memory Address Space and Page Table Management in Operating Systems

This text explains the management of memory address space and page tables in operating systems, including frame table, backing store, frame update, disk validity, and process execution.

jerir
Download Presentation

Memory Address Space and Page Table Management in Operating Systems

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Memory Address Space Frame Table Address Space Free Ref PID Backing Store Frame Update Disk Valid Clock Algorithm Example Process 1 PT 0 1 2 3 4 Frame Update Disk Valid Process 2 PT

  2. Memory Frame Table 1 1 1 1 1 Free Ref PID Backing Store Start State 0 1 2 3 4

  3. Memory Address Space Frame Table 1 1 1 1 1 Free Ref PID Backing Store Create Process 1 / Load into VM Process 1 PT ^ ^ ^ ^ 0 0 0 0 0 1 2 3 4 A B C D Frame Update Disk Valid

  4. Memory Address Space Backing Store Load 1st Two Pages of P1 into Memory Process 1 PT 1 3 0 0 ^ ^ ^ ^ 1 1 0 0 A B 0 1 2 3 4 A B C D Frame Table 1 0 1 0 1 1 1 Frame Update Disk Valid Ref PID Free

  5. Memory Address Space Backing Store P1 Begins Executing using Pages 0&1 Process 1 PT 1 3 0 0 ^ ^ ^ ^ 1 1 0 0 A B 0 1 2 3 4 A B C D Frame Table 1 0 1 0 1 1 1 1 1 Frame Update Disk Valid Ref PID Free

  6. Memory Address Space Address Space Backing Store Frame Update Disk Valid Create Process 2 / Load into VM Process 1 PT 1 3 0 0 ^ ^ ^ ^ 1 1 0 0 A B 0 1 2 3 4 A B C D Frame Table 1 0 1 0 1 1 1 1 1 Frame Update Disk Valid Process 2 PT Ref PID Free D E F ^ ^ ^ 0 0 0

  7. Memory Address Space Address Space Backing Store Frame Update Disk Valid Load 1st Two Pages of P2 into Memory Process 1 PT 1 3 0 0 ^ ^ ^ ^ 1 1 0 0 E A D B 0 1 2 3 4 A B C D Frame Table 0 0 0 0 1 0 1 0 1 2 1 2 1 Frame Update Disk Valid Process 2 PT Ref PID Free D E F 0 0 ^ ^ ^ 2 0 1 1 0

  8. Memory Address Space Address Space Backing Store Frame Update Disk Valid P2 Begins Executing using Pages 0&1 – Update Page 1 Process 1 PT 1 3 0 0 ^ ^ ^ ^ 1 1 0 0 E A D B 0 1 2 3 4 A B C D Frame Table 0 0 0 0 1 1 1 1 1 2 1 2 1 Frame Update Disk Valid Process 2 PT Ref PID Free D E F 0 1 ^ ^ ^ 2 0 1 1 0

  9. Memory Address Space Address Space Backing Store Frame Update Disk Valid P2 Page Fault for Page 2 – P1 Executes During Paging I/O Process 1 PT 1 3 0 0 ^ ^ ^ ^ 1 1 0 0 E A D B F 0 1 2 3 4 A B C D Frame Table 0 0 0 0 0 1 1 1 1 0 2 1 2 1 2 Frame Update Disk Valid Process 2 PT Ref PID Free D E F 0 1 0 ^ ^ ^ 2 0 4 1 1 1

  10. Memory Address Space Address Space Backing Store Frame Update Disk Valid I/O Completion Interrupt – P2 Begins Execution - Updates Page 2 Process 1 PT 1 3 0 0 ^ ^ ^ ^ 1 1 0 0 E A D B F 0 1 2 3 4 A B C D Frame Table 0 0 0 0 0 1 1 1 1 1 2 1 2 1 2 Frame Update Disk Valid Process 2 PT Ref PID Free D E F 0 1 1 ^ ^ ^ 2 0 4 1 1 1

  11. PT Memory 1 3 0 0 ^ ^ ^ ^ 1 1 0 0 Address Space A B C D Frame Table 0 0 0 0 0 0 1 1 1 1 2 1 2 1 2 Frame Update Disk Valid Process 2 Address Space PT Ref PID Free D E F 0 1 2 ^ ^ ^ 2 0 4 1 1 1 Backing Store 0 0 0 1 1 0 0 1 1 1 0 0 0 0 1 0 0 0 0 0 Frame Update Disk Valid Timer Interrupt – P1 Begins Execution – Page Fault for Page 2 – No Free Frames – Initiate Clock Algorithm for Page Replacement Process 1 E A D B F 0 1 2 3 4

  12. Memory Address Space Address Space Backing Store Frame Update Disk Valid Replace Frame 0 – Must swap out to disk as updated Process 1 PT 1 3 0 0 0 0 ^ ^ ^ ^ 1 1 1 0 C A D B F 0 1 2 3 4 A B C D Frame Table 0 0 0 0 0 0 0 0 0 0 1 1 2 1 2 Frame Update Disk Valid Process 2 PT Ref PID Free D E F 0 1 2 ^ ^ ^ 2 0 4 1 0 1

More Related