Subject  : Operating System <br />Group Members :<br />Muhammad Shakeeb  ( IS/17122-Aut -FO7 M )<br />Syed Zeeshan Nasir  ...
           Handling Memory<br />
• Process A&apos;s virtual address space<br />• Physical memory<br />• Process B&apos;s virtual address space<br />
                 Memory Management<br /><ul><li>The initial memory management schemes were constrained in size by the rela...
 UNIX was developed  on the PDP machines
Pre 3BSD system use swapping exclusively to handle memory contention among processes
  If there is too much contention, processes are swapped out until enough memory is available
Allocation of both main memory and swap space is done first-fit</li></li></ul><li>                                 Paging<...
 Demand paging – When a process needs a page and the page is not there, a page fault tot he kernel occurs, a frame of main...
  A page daemon process uses a modified second-chance page-replacement algorithm to keep enough free frames to support the...
  If the scheduler decides that the paging system is overloaded, processes will be swapped out whole until the overload is...
Disk block descriptors
Upcoming SlideShare
Loading in …5
×

Unix

3,447 views

Published on

OS Unix Case Study

Published in: Technology, Spiritual
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
3,447
On SlideShare
0
From Embeds
0
Number of Embeds
5
Actions
Shares
0
Downloads
105
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Unix

  1. 1. Subject : Operating System <br />Group Members :<br />Muhammad Shakeeb ( IS/17122-Aut -FO7 M )<br />Syed Zeeshan Nasir ( IS/17133-Aut –F 07 M )<br />Faisal Muhammad ( IS/17122-Aut –F07 M)<br />Class : BsCS 4th -B<br />
  2. 2. Handling Memory<br />
  3. 3. • Process A&apos;s virtual address space<br />• Physical memory<br />• Process B&apos;s virtual address space<br />
  4. 4. Memory Management<br /><ul><li>The initial memory management schemes were constrained in size by the relatively small memory resources of
  5. 5. UNIX was developed on the PDP machines
  6. 6. Pre 3BSD system use swapping exclusively to handle memory contention among processes
  7. 7. If there is too much contention, processes are swapped out until enough memory is available
  8. 8. Allocation of both main memory and swap space is done first-fit</li></li></ul><li> Paging<br /><ul><li> Berkeley UNIX systems depend primarily on paging for memory-contention management, and depend only secondarily on swapping
  9. 9. Demand paging – When a process needs a page and the page is not there, a page fault tot he kernel occurs, a frame of main memory is allocated, and the proper disk page is read into the frame
  10. 10. A page daemon process uses a modified second-chance page-replacement algorithm to keep enough free frames to support the executing processes
  11. 11. If the scheduler decides that the paging system is overloaded, processes will be swapped out whole until the overload is relieved</li></li></ul><li> Paging<br /><ul><li>Page table entry
  12. 12. Disk block descriptors
  13. 13. Page frame data table
  14. 14. Swap use table</li></li></ul><li>Page Table Entry and Disk Block Descriptor<br />Page Table<br />Region<br />Disk Block Descriptor<br />Page Table Entry<br />Page Table Entry<br />Disk Block Descriptor<br />
  15. 15. Contains the physical address of page and the following bits:<br />Valid: whether the page content legal<br />Reference: whether the page is referenced recently<br />Modify:whether the page content is modified<br />copy on write: kernel must create a new copy when a process modifies its content (required for fork)<br />Age: Age of the page<br />Protection: Read/ write permission<br />Page Table Entry<br />
  16. 16. Disk Block Descriptor<br />Swap Device number as there may be several swap devices<br />Block number that contains page<br />
  17. 17. Page Frame Data Table Entry<br /> Swap use Table entry<br />
  18. 18. 11<br />
  19. 19. Replacement policy <br />

×