Assignment1Second Semester
Session 1445 AH
Student Name
:
Student ID
:
Student Signature
:
Department
Course Code
Total Marks
: Department of Computer Science
: COCS 361
Course Name
Deadline
Time
: Operating Systems
Number of Exam Pages
: 4
: Wednesday, May 05, 2024
: 11:00 – 12:00
20
Marks
S.O 1
□
□
□
/10 Marks
Signature:
S.O 2
/10 Marks
Examiner: Prof Dr Ali Ahmed
Total Marks
(In Figure)
Total Marks
(In Words)
/20 Marks
1. Consider a user program of logical address of size 6 pages and page size is 4 bytes.
The physical address contains 300 frames. The user program consists of 22 instructions
a,b, c, . . . u, v . Each instruction takes 1 byte. Assume at that time the free frames are 7,
26, 52, 20, 55, 6, 18, 21, 70, and 90. Find the following?
a) Draw the logical and physical maps and page tables?
b) Allocate each page in the corresponding frame?
c) Find the physical addresses for the instructions m, d,v, r?
d) Calculate the fragmentation ifexist
[SO1: 10.0 Marks]
2
2. Consider apaging system with the page table stored in memory
a) If amemory reference takes 50 nanoseconds, how long does a paged memory
reference take?
b) If we add TLBs, and if 75 percent of all page-table references are found in the
TLBs, what is the effective memory reference time? (Assume that finding a
page-table entry in the TLBs takes 2 nanoseconds, if the entry is present.)
[SO2: 4.0 Marks]
3
3. Consider the following page reference string:
1, 2, 3, 4, 2, 1, 5, 6, 2, 1, 2, 3, 7, 6, 3, 2, 1, 2, 3, 6
How many page faults would occur for the following replacement algorithms, assuming
one, three , five and seven frames? Remember that all frames are initially empty, so your
first unique pages will cost one fault each.
a) LRU Replacement
b) FIFO Replacement
c) Optimal Replacement
[SO2: 6.0 Marks]
4
Delivering a high-quality product at a reasonable price is not enough anymore.
That’s why we have developed 5 beneficial guarantees that will make your experience with our service enjoyable, easy, and safe.
You have to be 100% sure of the quality of your product to give a money-back guarantee. This describes us perfectly. Make sure that this guarantee is totally transparent.
Read moreEach paper is composed from scratch, according to your instructions. It is then checked by our plagiarism-detection software. There is no gap where plagiarism could squeeze in.
Read moreThanks to our free revisions, there is no way for you to be unsatisfied. We will work on your paper until you are completely happy with the result.
Read moreYour email is safe, as we store it according to international data protection rules. Your bank details are secure, as we use only reliable payment systems.
Read moreBy sending us your money, you buy the service we provide. Check out our terms and conditions if you prefer business talks to be laid out in official language.
Read more