Consider a demand paging memory management system with 32-bit logical address, 20 -bit physical address, and page size of 2048 bytes. Assuming that the memory is byte addressable, what is the maximum number of entries in the page table?
Suppose in a multiprogramming environment, the following C program segment is executed. A process goes into I/O queue whenever an I/O related operation is performed. Assume that there will always be a context switch whenever a process requests for an I/O, and also whenever the process returns from an I/O. The number of times the process will enter the ready queue during its lifetime (not counting the time the process enters the ready queue when it is run initially) is _________ . (Answer in integer)
int main( )
{
int x = 0,i=0;
scanf("%d", &x);
for(i=0; i<20;i++)
{
x=x+20;
printf("%d\n", x);
}
return 0;
}
A computer has two processors, $M_1$ and $M_2$. Four processes $P_1, P_2, P_3, P_4$ with CPU bursts of $20,16,25$, and 10 milliseconds, respectively, arrive at the same time and these are the only processes in the system. The scheduler uses non-preemptive priority scheduling, with priorities decided as follows:
$\bullet$ $M_1$ uses priority of execution for the processes as, $P_1>P_3>P_2>P_4$, i.e., $P_1$ and $P_4$ have highest and lowest priorities, respectively.
$\bullet$ $M_2$ uses priority of execution for the processes as, $P_2>P_3>P_4>P_1$, i.e., $P_2$ and $P_1$ have highest and lowest priorities, respectively.
A process $P_i$ is scheduled to a processor $M_k$, if the processor is free and no other process $P_j$ is waiting with higher priority. At any given point of time, a process can be allocated to any one of the free processors without violating the execution priority rules. Ignore the context switch time. What will be the average waiting time of the processes in milliseconds?
In optimal page replacement algorithm, information about all future page references is available to the operating system (OS). A modification of the optimal page replacement algorithm is as follows:
The OS correctly predicts only up to next 4 page references (including the current page) at the time of allocating a frame to a page.
A process accesses the pages in the following order of page numbers:
$$1,3,2,4,2,3,1,2,4,3,1,4$$
If the system has three memory frames that are initially empty, the number of page faults that will occur during execution of the process is __________ (Answer in integer)