Consider the following segmented paging memory system. There are 4 segments for the given process and a total of 5 page tables in the entire system. Each page table has a total of 8 entries. The physical memory requires 12 bits to address it; there are a total of 128 frames.
(i) How many bytes are contained within the physical memory?
(ii) How large is the virtual address?
(iii) What is the physical address that corresponds to virtual address 0x312?
(iv) What is the physical address that corresponds to virtual address 0x1E9?
Solution
(i) Number of bytes in physical memory is equal to 2 ^(7 + 7) = 16K bytes. This is
because 12 bits are required to address physical memory location out of which 3 bits
are to refer frame no. within page table + 2 bits to locate page from segment and
remaining 7 bits for offset with frame.
(ii) The size of virtual memory is 2 ^ 20 ( 20 = 2 for segment index, + 3 for page table index + 3 for frame index in page table + 7 for frame number and 5 for offset within frame).
(iii) 312 (Hex) = 001100010010 = 00(segment) in table number 3 (refer to the data in question at entry 0 in segment table then find page 3, in page 3 find 110 (6th entry) which is 78; that is 120 th frame then the offset with the frame is given by the last 7 bits 0010010.
(iv) 312 (Hex) = 001100010010 = 00(segment) in table number 3 (refer to the data in question at entry 0 in segment table then find page 3, in page 3 find 110 (6th entry) which is 78; that is 120 th frame then the offset with the frame is given by the last 7 bits 0010010.
(ii) The size of virtual memory is 2 ^ 20 ( 20 = 2 for segment index, + 3 for page table index + 3 for frame index in page table + 7 for frame number and 5 for offset within frame).
(iii) 312 (Hex) = 001100010010 = 00(segment) in table number 3 (refer to the data in question at entry 0 in segment table then find page 3, in page 3 find 110 (6th entry) which is 78; that is 120 th frame then the offset with the frame is given by the last 7 bits 0010010.
(iv) 312 (Hex) = 001100010010 = 00(segment) in table number 3 (refer to the data in question at entry 0 in segment table then find page 3, in page 3 find 110 (6th entry) which is 78; that is 120 th frame then the offset with the frame is given by the last 7 bits 0010010.
0 comments:
Feel free to contact the admin for any suggestions and help.