Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Consider a system with 1MB of available memory and requests for 42KB, 396KB, 10K

ID: 3937993 • Letter: C

Question

Consider a system with 1MB of available memory and requests for 42KB, 396KB, 10KB, and 28KB. The system is using Buddy Allocation Algorithm. Show the amount of memory allocated for each request and the state of memory after each request. Assume there is no memory release. Why does internal fragmentation occur with buddy allocation? How much internal fragmentation exists in this scenario? Why does external fragmentation occur with buddy allocation? How much external fragmentation exists in this scenario?

Explanation / Answer

Consider system with 1MB of available memory and requests for 42KB, 396KB, 10KB, and 28KB. The system is using buddy allocation algorithm.

As we know that External fragmentation is left out or wasted memory which is noticeable to the system exterior of the requesting processes.

In buddy allocation External fragmentation usually occurs because most of the requests are not of same size thus, the memory request is not satisfied, still when there is sufficient total free memory in the system.

The external fragmentation exists in this scenario is:

16 + 128 + 256 = 400KB

total of fragmentation and the allocated memory should equal 1MB:

148KB + 400KB + 42KB + 396KB + 10KB +28KB

= 1024KB

= 1MB

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote