You are on page 1of 1

Operating System (Chapter 8)

1. Explain the difference between internal and external fragmentation


a. Internal Fragmentation
i. Area in a segment/page that is not used by the job occupying that
segment/page
ii. This space is unavailable for use by the system until that job is finished and the
segment/page is released
b. External Fragmentation
i. Total memory space exists to satisfy a request, but it is not contiguous
ii. Storage is fragmented into a large number of small holes

2. Compare paging with segmentation with respect to the amount of memory required by the
address translation structures in order to convert virtual addresses to physical addresses
a. Paging requires more memory overhead to maintain the translation structures. Paging
requires one entry per page, and this entry provides the physical address in which the
page is located
b. Segmentation requires just two registers per segment:
i. One to maintain the base of the segment and
ii. The other to maintain the extend of the segment

3. Consider a logical address space of eight pages of 1024 words each mapped onto a physical
memory of 32 frames.
- How many bits are there in the physical address?
- How many bits are there in the logical address?
a. Physical (frame) :
i. 32 frames
ii. Frame size = page size; each frame 1024 words
iii. Total size = 32 * 1024 = 32768
iv. Number of bits needed to represent 32768 addresses is log 32768 / log 2 = 15
bits
b. Logical (page) :
i. 8 pages
ii. Each page 1024 words
iii. Total size = 8 * 1024 = 8192
iv. Number of bits needed of represent 8192 addresses is log 8192 / log 2 = 13 bits

4. Describe the mechanism by which one segment could belong to the address space of two
different processes
a. Segment tables are a collection of base-limit registers
b. Segments can be shared when entries in the segment table of two different jobs point
to the same physical location
c. The two segment table identical base pointers and the shared segment number must be
the same in the two processes

You might also like