The overlay tree for a program is as shown below: What will be the size of the…
1998
The overlay tree for a program is as shown below:

What will be the size of the partition (in physical memory) required to load (and run) this program?
Answer: B. 14 KB — To solve this problem, we need to understand how memory overlays work. In an overlay system, parts of a program that do not need to be in memory at the same…
- A.
12 KB
- B.
14 KB
- C.
10 KB
- D.
8 KB
Attempted by 19 students.
Show answer & explanation
Correct answer: B
To solve this problem, we need to understand how memory overlays work.
In an overlay system, parts of a program that do not need to be in memory at the same time can share the same physical memory space. A branch/path from the Root down to a leaf node represents a set of routines that must reside in memory simultaneously to execute that specific path.
1. Step-by-Step Analysis (Solution)
To find the minimum size of the partition required to run the entire program, we need to find the maximum memory required by any single execution path from the Root to a leaf node.
Let's list out all possible execution paths from the diagram and calculate the total memory required for each path:
Path 1: Root ⟶ A ⟶ D
Size = Root + A + D = 2 KB + 4 KB + 6 KB = 12 KB
Path 2: Root ⟶ A ⟶ E
Size = Root + A + E = 2 KB + 4 KB + 8 KB = 14 KB
Path 3: Root ⟶ B ⟶ F
Size = Root + B + F = 2 KB + 6 KB + 2 KB = 10 KB
Path 4: Root ⟶ C ⟶ G
Size = Root + C + G = 2 KB + 8 KB + 4 KB = 14 KB
The partition in physical memory must be large enough to accommodate the most demanding path so that the program doesn't crash during its peak memory execution.
Maximum Path Size = (12, 14, 10, 14) = 14 KB