recategorized by
16,047 views
56 votes
56 votes

The address sequence generated by tracing a particular program executing in a pure demand based paging system with $100$ records per page with $1$ free main memory frame is recorded as follows. What is the number of page faults?

$0100, 0200, 0430, 0499, 0510, 0530, 0560, 0120, 0220, 0240, 0260, 0320, 0370$

  1. $13$
  2. $8$
  3. $7$
  4. $10$
recategorized by

5 Answers

Best answer
62 votes
62 votes
  • $0100 - 1$ page fault. Records $0100-0199$ in memory
  • $0200 - 2$ page faults. Records $0200-0299$ in memory
  • $0430 - 3$ page faults. Records $0400-0499$ in memory
  • $0499 - 3$ page faults. Records $0400-0499$ in memory
  • $0510 - 4$ page faults. Records $0500-0599$ in memory
  • $0530 - 4$ page faults. Records $0500-0599$ in memory
  • $0560 - 4$ page faults. Records $0500-0599$ in memory
  • $0120 - 5$ page faults. Records $0100-0199$ in memory
  • $0220 - 6$ page faults. Records $0200-0299$ in memory
  • $0240 - 6$ page faults. Records $0200-0299$ in memory
  • $0260 - 6$ page faults. Records $0200-0299$ in memory
  • $0320 - 7$ page faults. Records $0300-0399$ in memory
  • $0370 - 7$ page faults. Records $0300-0399$ in memory

So, (C) - $7$ page faults.

edited by
11 votes
11 votes
page are fitted in frames ,so first we need to determine the pages but given request are just the record request in decimal.we can assume that first page to address from 0000 to 0099 and page 2 contains records from 0100 to 0199 and so on(it is given in question that each page contains 100 records) and so on.sso page reqquest string is 01,02,04,04,05,05,05,01,02,02,02,03,03 clearly 7 page fault.
6 votes
6 votes

Since no of record in each page is 100 try to normalize the given value.

normalized value for each record is given by floor( given value /100 ) 

so you will get 01,02,04,04,05,05,05,01,02,02,02,,03,03 

you can remove 0 from prefix if you love to remove .

now easily we can get 7 as total page fault.

0 votes
0 votes

one page contain =100 record mean(0-99) record,AND ALL THAT..

RECORD RANGE FRAME NUMBER
0-99         0
100-199         1
200-299         2
300-399         3
400-499         4
500-599         5

 

USING THE GIVEN TABLE WE WRITE STRING=1,2,4,4,5,5,5,1,2,2,2,3,3

        1 FRAME IS GIVEN    

        PAGE FAULTS STRING ARE=1,2,4,5,1,2,3

        TOTAL PAGE FAULTS=7

 

Answer:

Related questions

20 votes
20 votes
4 answers
1
Kathleen asked Oct 8, 2014
5,102 views
Which of the following page replacement algorithms suffers from Belady’s anamoly?Optimal replacementLRUFIFOBoth (A) and (C)
25 votes
25 votes
3 answers
3
Kathleen asked Oct 8, 2014
10,471 views
In a virtual memory system the address space specified by the address lines of the CPU must be _____ than the physical memory size and ____ than the secondary storage siz...
47 votes
47 votes
5 answers
4
Kathleen asked Oct 8, 2014
16,099 views
The sequence __________ is an optimal non-preemptive scheduling sequence for the following jobs which leaves the CPU idle for ________ unit(s) of time.$$\small \begin{arr...