Consider a memory of size 8KB 8192 bytes that allows dynamic

Consider a memory of size 8KB (8192 bytes) that allows dynamic, variable sized partitioning among processes and uses a linked list to keep track of free spaces (hereafter referred to as the free list) in the memory at any given time. Assume that there are 6 processes and assume that their memory size requirements (in bytes) are as given below:

P1: 500, P2: 600, P3: 1300, P4: 2000, P5: 100, P6: 200

Assume that the initial state of the free list is as shown below (BA is the base address and Sz is the size of each free space):

BA: 0; Sz: 1100 BA: 1200; Sz: 600 BA: 2000; Sz: 1800 BA: 6000; Sz 400

For these next questions assume the free list is in its initial state. Assume that the worst fit policy is used for partition placement. Identify the base address of the region to which each of the following processes will be allocated, assuming that they are allocated in the order specified and show the updated free liststate after each allocation.

Note: If a partition cannot be allocated due to the state of the free list, simply type in the words cannot be accommodated as your answer.

Question 1: If P6 is allocated, what is the BA? _______

Question 2:

The updated free list is:

BA: _________ ; Sz: __________ BA: __________ ; Sz: ___________ BA: __________ ; Sz: __________ BA: _________ ; Sz ___________

Expert Answer

Solution

BA: 0; Sz: 1100 BA: 1200; Sz: 600 BA: 2000; Sz: 1800 BA: 6000; Sz 400

Question 1: after allocating P1, P1 is allocated memory at 0 and free list BA = 500

Question 2:

P3 and P4 cannot be accomodated as the memory chunk is not available due to worst fit policy.

The updated free list is :

BA: 300; Sz: 800 BA: 1200; Sz: 600 BA: 3100; Sz: 700 BA: 6000; Sz 400

Address Memory Location
8192
6000-6400 Free
3100-3800 Free
2500-3100 P2
2000-2500 P1
1200-1800 Free
300-1100 Free
100- 300 P6
0-100 P5
Consider a memory of size 8KB (8192 bytes) that allows dynamic, variable sized partitioning among processes and uses a linked list to keep track of free spaces

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site