retagged by
1,983 views
6 votes
6 votes
Consider a system using segmented paging architecture where both logical address space and physical address space is 64 MB. The logical address space is divided into 8 equal size segments, the segment is divided into equal size pages which are power of 2. The memory is byte addressable and page table entry size is 2 bytes. What must be the size of the page of segment in bytes so that the page table of segment exactly fits in one page frame?
retagged by

1 Answer

Best answer
5 votes
5 votes

Segmented Paging Architecture - The segments are divided into pages and each segment will have its own page table. Let us assume we have 4 segments for process 1 namely CodeSeg, DataSeg, StackSeg, HeapSeg. CodeSeg is divided into pages and each entry in pagetable of CodeSeg will point to one of the page of CodeSegment. Now,   Each entry in the Segment table will point to the corresponding page table of that segment. For ex, One entry will point to Code Segment Page Table, other will point to Stack Segment Page table etc.

Address is divided into 3 parts -  | SegNo | PageNoOfRequiredSegment | PageOffsetwithinSegment |

Now, LAS = 64MB and byte addressable. Thus we need 26 bits. and No of Seg = 8

Thus, MSB 3 bits will be used for SegNo. Let the page size be 2x bytes. Thus LSB is x bits.

Address Structure so far :    | 3 bits |  -  | x bits |

Total is 26 bits. Thus no of entries in page table is 226-(3+x) = 223-x 

 Page table must fit in one page. and PTE = 2 B

  223-x * 2 B  = 2B

24-x = x 

24= 2x 

 x = 12

Thus page size 4 KB or 4096 B. 

selected by

Related questions

1 votes
1 votes
0 answers
2
Tuhin Dutta asked Nov 8, 2017
711 views
https://gateoverflow.in/3600/gate2006-it-56Why is only 1 Page Table considered for 4 Segment Table entries in the selected best answer?
5 votes
5 votes
2 answers
4
vaishali jhalani asked Jan 19, 2017
1,729 views