Question: Consider the following code to clear an array with 50 rows and 50 columns. begin{verbatim} for j := 0 to 49 do for i :=

Consider the following code to clear an array with 50 rows and 50 columns. \begin{verbatim} for j := 0 to 49 do for i := 49 downto 0 do a[i,j] := 0; \end{verbatim} Suppose you are given the following: The rows are stored in contiguous blocks of memory and the elements in a row are stored in contiguous words. Memory consists of frames that hold 250 array elements each. Only 8 frames of memory may be allocated to array storage. Initially, no part of the array is in memory. (a) Suppose that as page faults occur, the OS replaces pages on a FIFO basis. s on a FIFO basis. How many page faults does the above code cause? (b) Describe a page replacement strategy other than OPT that would minimize the number of page faults caused by the above code. How many page faults occur with your strategy in effect?

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!