Discussion/Midterm Question

1 / 6

# Discussion/Midterm Question - PowerPoint PPT Presentation

Discussion/Midterm Question. Assume a system with a two level page table. The virtual memory address space is 32 bits and the physical memory address space is 16 bits. . Factors in determining size of page. Page table fits on one page Equal sized L1 and L2 page tables

I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.

## PowerPoint Slideshow about ' Discussion/Midterm Question' - hidi

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.

- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript

### Discussion/Midterm Question

Assume a system with a two level page table. The virtual memory address space is 32 bits and the physical memory address space is 16 bits.

Factors in determining size of page
• Page table fits on one page
• Equal sized L1 and L2 page tables
• Size of a page table entry
• size of physical memory (16 bit address space)
• bookkeeping bits
Fitting a page table on one page

(size of page) (size of page table)

• Size of page
• # of PTE
• Size of PTE

(size of page table) =

(# of PTEs) * (size of PTE)

• (2offset)
• (2(32-offset)/2)

(16 bits - offset + bookkeeping ≈ 1-4 bytes)

2offset ≥ 2(32-offset)/2 (assuming 1 byte PTE)

offset ≥ 10.667

Fitting a page table on one page

(size of page) (size of page table)

• Size of page
• # of PTE
• Size of PTE

(size of page table) =

(# of PTEs) * (size of PTE)

• (2offset)
• (2(32-offset)/2)

(16 bits - offset + bookkeeping ≈ 1-4 bytes)

2offset ≥ 2(32-offset)/2*22 (assuming 4 byte PTE)

offset ≥ 12

12 bit offset works under either assumption

Solutions
• Offset = 12
• 4KB pages
• VPN1 = VPN2 = 10
• 210 entries per page table