edited by
9,684 views
35 35 votes
Free disk space can be used to keep track of using a free list or a bit map. Disk addresses require $d$ bits. For a disk with $B$ blocks, $F$ of which are free, state the condition under which the free list uses less space than the bit map.

4 Answers

Best answer
70 70 votes

Bit map maintains one bit for each block, If it is free then bit will be "$0$" if occupied then bit will be "$1$".
For space purpose, it doesn't matter what bit we are using, only matters that how many blocks are there.
For $B$ blocks, Bit map takes space of "$B$" bits.

Free list is a list that maintains addresses of free blocks only. If we have $3$ free blocks then it maintains $3$ addresses in a list, if $4$ free blocks then $4$ address in a list and like that.


Given that we have $F$ free blocks, therefore $F$ addresses in a list, and each address size is d bits therefore Free list takes space of "$Fd$".

condition under which the free list uses less space than the bit map: $Fd<B$

edited by
11 11 votes
Solution for Part a :-

Assume that size of each block is S bits.

Then no of bits required for free list is = Fd, No of blocks required = Fd/S

No of bits required for Bit map = B (No of blocks ) , No of block required is =  B /S

Condition under which free list uses less space than the bit map.

Fd / S < B / S
0 0 votes

Freelist is used to store list of those addresses which are free

0 0 votes

A bit map uses exactly 1 bit for every single block on the disk, regardless of whether that block is currently free or occupied.

Since the disk contains a total of $B$ blocks, the total storage space required by the bit map method is always fixed at $B$ bits.

A free list works by explicitly storing the unique binary address of only the blocks that are currently free.

Since each disk address requires $d$ bits and there are a total of $F$ free blocks to keep track of, the total storage space used by the free list is $F \times d$ bits.

The question asks for the specific condition where the free list method consumes less storage space than the bit map method.

We can write this requirement directly as a mathematical inequality:

$$F \times d < B$$

Rearranging the terms to isolate the number of free blocks gives the final required condition:

$$F < \frac{B}{d}$$

Position:
Show:

Related questions

16 16 votes
6 6 answers
5.6k
5.6k views
Arjun asked Mar 6, 2016
5,637 views
Consider a disk with $c$ cylinders, $t$ tracks per cylinder, $s$ sectors per track and a sector length $s_l$. A logical file $d_l$ with fixed record length $r_l$ is stor...
4 4 votes
1 1 answer
4.5k
4.5k views
Kathleen asked Sep 26, 2014
4,511 views
Calculate the total time required to read 35 sectors on a 2-sided floppy disk. Assume that each track has 8 sectors and the track-to-track step time is 8 milliseconds. Th...
36 36 votes
3 answers 3 answers
11.3k
11.3k views
Kathleen asked Sep 25, 2014
11,318 views
Formatting for a floppy disk refers toarranging the data on the disk in contiguous fashionwriting the directoryerasing the system datawriting identification information o...
52 52 votes
5 answers 5 answers
19.1k
19.1k views
Kathleen asked Sep 26, 2014
19,053 views
Four jobs are waiting to be run. Their expected run times are $6, 3, 5$ and $x.$ In what order should they be run to minimize the average response time?Write a concurrent...