Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Objectives Apply the use of a paging memory management mechanism. Recognize the

ID: 3586958 • Letter: O

Question

Objectives

Apply the use of a paging memory management mechanism.

Recognize the differences in memory addresses that are caused by different memory sizes.

Recognize the differences in memory addresses that are caused by different page frame sizes.

Practice the process of mapping a logical memory address to a physical memory address.

Practice the process used to calculate a physical memory address in the context of pure demand paging.

Useful Resources

How to convert binary to hexadecimal

http://www.wikihow.com/Convert-Binary-to-Hexadecimal (Links to an external site.)Links to an external site. (Links to an external site.)Links to an external site.

Base Conversions.pdf (Links to an external site.)Links to an external site. [URL: https://drive.google.com/open?id=0B2pK0GpUEQ4hS2dCU3NTOHRHSHc]


For the following questions, consider a paged memory system that has a physical main memory size of 64KB (216) and a page frame size of 8KB (213). Consider a process P whose logical address space is 64KB (216).

Important Note: If an answer requires an exponent, use the ^ character. For example: 216 would be entered as 2^16.



Q1

How many physical page frames are there in the above paged memory system? Your answer should be in exponential form.

How many bits are needed to represent a physical page frame number in the system?

Q2

How many logical pages are there for P? Your answer should be in exponential form.

How many bits are needed to represent a logical page number for P?

Q3

Assume that the state of the page table for some process P is as shown below. Note that both the page and page frame number shown in the page table are in hexadecimal so you will need to do some conversion.

Given the logical address 0x 969C, what will be the logical page number issued by a process P?

What is the corresponding physical frame number?

Note: Your responses should be given in hexadecimal format!




For the following questions, consider a paged memory system that has a physical main memory size of 1MB (220) and a page frame size (and hence page size) of 32KB (215). Consider a process P whose logical address space is 512KB (219).

Important Note: If an answer requires an exponent, use the ^ character. For example: 215 would be entered as 2^15.

Q4

How many physical page frames are there in the above paged memory system? Your answer should be in exponential form.

How many bits are needed to represent a physical page frame number in the system?

Q5

How many logical pages are there for P? Your answer should be in exponential form.

How many bits are needed to represent a logical page number for P?



Translate the following logical addresses issued by P into a physical addresses, assuming the state of the page table for P is as follows:

Note that both the page number and page frame number shown in the page table are in hexadecimal.

Q6

Given the logical address 0x 69656, what will be the logical page number issued by a process P?

What is the corresponding physical frame number?

What is the hexadecimal physical address?   

Note: Your responses should be given in hexadecimal format!




For the following questions, consider a system that has a physical main memory size of 32KB (215) and a page frame size (and hence page size) of 4KB (212). Assume that the system uses pure demand paging and that the system supports up to 16-bit logical/virtual addresses. Assume that a process P2 with a logical address space of 64KB (216) executes on this system. Assume that the current state of the page table for P2 in as shown below. The index of each entry in the page table is given for your convenience. Note that both the page and page frame number are in decimal. If a logical page is not currently in the physical main memory, no frame number is specified for that logical page.


Q7

How many page frames are there in the above pure demand paging memory system? Your answer should be in exponential form.

How many bits are needed to represent a physical page frame number in the system?

Q8

How many logical pages are there in the process P2? Your answer should be in exponential form.

How many bits are needed to represent a valid logical page number in the logical address space of process P2?

Q9

At any given time, what is the maximum number of entries in the page table of P2 that can have valid physical frame numbers?

Q10

Assume that P2 issues the logical address 0xA87A.

What is the logical page number contained in the given logical address, in hexadecimal?


Q11

What is the logical page number, in decimal, that corresponds with the hexadecimal logical address of the page being requested in the previous question?

Is this page being requested currently in the physical main memory? (yes or no)

Page Frame 0x 0 0x 1 0x 1 0x 6 0x 2 0x 3 0x 3 0x 5 0x 4 0x 2 0x 5 0x 4 0x 6 0x 7 0x 7 0x 0

Explanation / Answer

Answers as Follows :

1) 2^3

3

2) 2^3

3

3) 0x4

0x2

4) 2^8

8

5) 2^8

8

7) 2^3

3

8) 2^4

4

9) 8

10) 0xA

11) 10

No