0% found this document useful (0 votes)
223 views

Exercise 3 - Questions

Exercise 3 - QuestionsExercise 3 - QuestionsExercise 3 - QuestionsExercise 3 - QuestionsExercise 3 - QuestionsExercise 3 - QuestionsExercise 3 - Questions

Uploaded by

Da Ny
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
223 views

Exercise 3 - Questions

Exercise 3 - QuestionsExercise 3 - QuestionsExercise 3 - QuestionsExercise 3 - QuestionsExercise 3 - QuestionsExercise 3 - QuestionsExercise 3 - Questions

Uploaded by

Da Ny
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

Universitt Duisburg-Essen

Prof. Dr.-Ing. Axel Hunger


Dipl.-Ing. Angela Hirlehei

SS 12

Operating Systems and Computer Networks

Exercise 3 : Memory Management

The following figure indicates a part of memory, available for allocation. The memory is divided into segments of fixed sizes.

10 KB

4 KB

20 KB

18 KB

7 KB

9 KB

12 KB

15KB

Three processes A, B, and C with the respective sizes of 12 KB, 10 KB and 9 KB are to be allocated successively.

Question 3.1: Describe the results of the allocation when the following allocation methods are used: a. first fit b. best fit c. worst fit d. next fit Which algorithm makes use of the memory space the best?

Universitt Duisburg-Essen

Prof. Dr.-Ing. Axel Hunger


Dipl.-Ing. Angela Hirlehei

SS 12

Operating Systems and Computer Networks

Question 3.2: Describe the memory allocations of the following memory requests and memory releases if buddy system allocation mechanism is applied. The initial memory segment available for allocation is 1024 KB. a. memory requests: i. Program A 240 KB

ii. Program B 120 KB iii. Program C 60 KB iv. Program D 130 KB b. memory releases: i. Program A

ii. Program C iii. Program D

Universitt Duisburg-Essen

Prof. Dr.-Ing. Axel Hunger


Dipl.-Ing. Angela Hirlehei

SS 12

Operating Systems and Computer Networks

A computer with 16 bit address has virtual address space of 64 KB and physical memory of 32 KB. The size of a page is 4 KB. The following figure depicts the page table belonging to the computer.

Figure 1 Page Table

Question 3.3: How many virtual pages and page frames are generated? Question 3.4: The instruction MOV REG, 20482 is being executed by a program in the computer. Using the page table previously provided, determine the resulting instruction. Question 3.5: Determine the size of a page table for a computer with 32 bit address, a page size of 4 KB and each entry in the page table requires 4 bytes.

Universitt Duisburg-Essen

Prof. Dr.-Ing. Axel Hunger


Dipl.-Ing. Angela Hirlehei

SS 12

Operating Systems and Computer Networks

A computer has four frames. The following are time for loading, time of last access, the R and M bits for each page. The times are in clock ticks.

Page
0 1 2 3

Loaded
126 230 140 110

Last access
280 265 270 285

R
1 0 0 1

M
0 1 0 1

Question 3.6: a. Which page will NRU replace? b. Which page will FIFO replace? c. Which page will LRU replace? d. Which page will Second Chance replace?

You might also like