0% found this document useful (0 votes)
16 views3 pages

Essay Questions Chapter 9

The document discusses key concepts in computer memory management, including the necessity of loading programs into main memory for execution, the types of requests seen by the memory unit, and the differences between logical and physical addresses. It also covers memory protection, fragmentation types, and the paging technique used to manage memory efficiently. Additionally, it provides calculations for internal fragmentation based on given parameters.

Uploaded by

kimoelhady99
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
16 views3 pages

Essay Questions Chapter 9

The document discusses key concepts in computer memory management, including the necessity of loading programs into main memory for execution, the types of requests seen by the memory unit, and the differences between logical and physical addresses. It also covers memory protection, fragmentation types, and the paging technique used to manage memory efficiently. Additionally, it provides calculations for internal fragmentation based on given parameters.

Uploaded by

kimoelhady99
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Essay questions:

CHAPTER 9

(slide 4)

1. Explain why a program must be loaded into main memory to be executed?


because the CPU can only directly access main memory and registers. and the
Programs are stored on disk, which is not directly accessible by the CPU
and the main memory is faster than the disk
Therefore, the program must be brought into memory to be run
2. What types of requests does the memory unit see, and what data is exchanged
between the CPU and memory?
The memory unit sees a stream of:
• addresses + read requests
• address + data and write requests
3. Compare the access times of CPU registers and main memory
Register access is done in one CPU clock (or less), while main memory can take
many cycles, causing a stall. Therefore, CPU registers have much faster access
times compared to main memory.

(slide 5,6)

4. Explain why memory protection is essential for the correct operation of a computer
system?
because it ensures that a process can only access addresses within its own
address space
(slide 10)

5. Explain the difference between logical (virtual) addresses and physical addresses?
• Logical addresses (also referred to as virtual addresses) are generated by
the CPU, The logical address space is the set of all logical addresses
generated by a program
• physical addresses are the addresses seen by the memory unit, the
physical address space is the set of all physical addresses generated by a
program
• In compile-time and load-time (address-binding schemes) the logical and
physical addresses are the same, but they differ in execution-time.

(slide 11,12)

6. What is the primary purpose of the Memory Management Unit (MMU)?

The primary purpose of the Memory Management Unit (MMU) is to map virtual
(logical) addresses to physical addresses at run time

(slide 20)

7. What are the Dynamic storage allocations?


• First-fit: Allocate the first hole that is big enough
• Best-fit: Allocate the smallest hole that is big enough
• Worst-fit: Allocate the largest hole

(slide 21)

8. Differentiate between internal and external fragmentation?


• external fragmentation: There are free spaces in the memory but in a non-
contiguous block which makes it impossible to allocate a large request even
if the total free space is enough.
• internal fragmentation: allocated memory may be slightly larger than
requested; leaving unused space within partitions.

(slide 22)

9. What is the solution for external fragmentation?

Compaction reduces external fragmentation by combining all free memory


together in one large block.

(slide 23)

10. What is the definition of paging?


Paging is a memory management technique that allows a process's physical
address space to be non-contiguous
11. What is the objective of paging?
• allows a process's physical address space to be non-contiguous
• avoid external fragmentation
• avoid varying sized memory
12. What is the technique of paging?
o Dividing physical memory into fixed-size blocks called frames.
o Dividing logical memory into blocks of the same size called pages.
o Allocating physical memory to a process whenever frames are available.
o Maintaining a page table to translate logical addresses to physical addresses.
o backing store is also paged

(slide 28)

13. calculate internal fragmentation


page size= 2048 bytes
process size= 72766 bytes
no. pf pages= 72766/2048=35.5 ~ 36 pages
total memory allocated= 36/2048= 73728
internal fragmentation= 73728-72766= 962 bytes

You might also like