page 1 2p13 week 6. page 2 table 7.1 memory management terms frame a fixed-length block of main...
TRANSCRIPT
![Page 1: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/1.jpg)
Page 1
2P13
Week 6
![Page 2: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/2.jpg)
Page 2
Table 7.1 Memory Management Terms
FrameA fixed-length block of main memory.
Page
A fixed-length block of data that resides in secondary memory (such as disk). A page of data may temporarily be copied into a frame of main memory.
Segment
A variable-length block of data that resides in secondary memory. An entire segment may temporarily be copied into an available region of main memory (segmentation) or the segment may be divided into pages which can be individually copied into main memory (combined segmentation and paging).
![Page 3: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/3.jpg)
Page 3
![Page 4: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/4.jpg)
Page 4
Table 7.2 Memory Management Techniques
Technique Description Strengths Weaknesses
Fixed Partitioning
Main memory is divided into a number of static partitions at system generation time. A process may be loaded into a partition of equal or greater size.
Simple to implement; little operating system overhead.
Inefficient use of memory due to internal fragmentation; maximum number of active processes is fixed.
Dynamic Partitioning
Partitions are created dynamically, so that each process is loaded into a partition of exactly the same size as that process.
No internal fragmentation; more efficient use of main memory.
Inefficient use of processor due to the need for compaction to counter external fragmentation.
Simple Paging
Main memory is divided into a number of equal-size frames. Each process is divided into a number of equal-size pages of the same length as frames. A process is loaded by loading all of its pages into available, not necessarily contiguous, frames.
No external fragmentation.
A small amount of internal fragmentation.
Simple Segmentation
Each process is divided into a number of segments. A process is loaded by loading all of its segments into dynamic partitions that need not be contiguous.
No internal fragmentation; improved memory utilization and reduced overhead compared to dynamic partitioning.
External fragmentation.
Virtual Memory Paging
As with simple paging, except that it is not necessary to load all of the pages of a process. Nonresident pages that are needed are brought in later automatically.
No external fragmentation; higher degree of multiprogramming; large virtual address space.
Overhead of complex memory management.
Virtual Memory Segmentation
As with simple segmentation, except that it is not necessary to load all of the segments of a process. Nonresident segments that are needed are brought in later automatically.
No internal fragmentation, higher degree of multiprogramming; large virtual address space; protection and sharing support.
Overhead of complex memory management.
![Page 5: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/5.jpg)
Page 5
![Page 6: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/6.jpg)
Page 6
![Page 7: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/7.jpg)
Page 7
![Page 8: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/8.jpg)
Page 8
![Page 9: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/9.jpg)
Page 9
![Page 10: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/10.jpg)
Page 10
Get_Hole
Void get_hole(int i){if (i==(U+1)) <failure>;if (<i_list empty> {
get_hole(i+1);<split hole into buddies><put buddies on list>
}<take first hole on i_list>
}
![Page 11: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/11.jpg)
Page 11
List i
List i+1
![Page 12: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/12.jpg)
Page 12
![Page 13: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/13.jpg)
Page 13
![Page 14: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/14.jpg)
Page 14
![Page 15: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/15.jpg)
Page 15
![Page 16: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/16.jpg)
Page 16
![Page 17: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/17.jpg)
Page 17
![Page 18: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/18.jpg)
Page 18
MS Dos Segment organization
![Page 19: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/19.jpg)
Page 19
Buffer overflow
void * memcpy ( void * destination, const void * source, size_t num ); • Note: if destination is a buffer, and num is
too big then an overflow can occure.• Compilers can check and warn against
such an operation.
![Page 20: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/20.jpg)
Page 20
![Page 21: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/21.jpg)
Page 21
![Page 22: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/22.jpg)
Page 22
![Page 23: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/23.jpg)
Page 23
![Page 24: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/24.jpg)
Page 24
![Page 25: Page 1 2P13 Week 6. Page 2 Table 7.1 Memory Management Terms Frame A fixed-length block of main memory. Page A fixed-length block of data that resides](https://reader035.vdocument.in/reader035/viewer/2022070415/56649ee05503460f94bf105c/html5/thumbnails/25.jpg)
Page 25
The End