Now, no. Nowadays a memory read on a personal computer may takes 60 nsec. a maximum of 20 jobs in memory at any given time. of entries in outer page table = 4KB/4B = 1024, so 10 bits for this. Address generated by CPU is divided into. The sizes of page and frame are the same. So, no. 2K = 2048 = 2 11 2 24 / 2 11 = 2 24-11 = 2 13 = 8192 c.) How many page table entries would there need to be? table take? its physical memory, as shown in Fig. How to calculate the address of the sector in below question ? So 2 24 = 16 megabytes. Hot Network Questions If a square wave has infinite bandwidth, how can we see it on an oscilloscope? Hashed Page Tables • Common in address spaces > 32 bits • The virtual page number is hashed into a page table – This page table contains a chain of elements hashing to the same location • Each element contains – (1) the virtual page number – (2) the value of the mapped page frame – (3) a … Now, we can't directly go to level 2, so lets go to final level. Thus each page must be 4096 bytes long, or 4K. How to calculate virtual address space in below question ? How big would the pages For this, lets assume a third level page table takes size of a page- 4KB. Also write into the frame columns which page is No. Now, we need an entry in first level page table for each of these second level page table and there is only 1 first level page table. We need two assumptions to solve the question. bits are devoted to the page offset and how many bits are devoted to the shown. We are not sure how many of these entries are going to 1 third level page table. have to be to keep a process's page table under 1 million entries long? Each page table entry must start on a byte -- it cannot start If the page table does not How to calculate the capacity of disk pack in the below question ? 0. I formed an AP 1240= a+(4-1)d 1600= a+(10-1) d but I am nt getting the answ where is my mistake ? The sum of money in kept in a bank amounts to 1240 in 4 yrs and Rs 1600 in 10 yrs at Simple interst . of entries in a SINGLE second level page table $= 4KB/4B = 2^{10}$. Virtual addresses are 28 bits long. then how to find sum ? of entries will be $\frac{2^p}{\text{page size}} = \frac{2^p}{4 \times 2^{10}} = 2^{p-12}$. Now put the value of A in equation 1  2P = 242. Use LRU for victim selection, which means find the A disk pack has 19 surfaces and storage area on each surface has an outer diameter of 33cm and inner diameter of 22cm .The maximum recording storage density on any track is 200 bits/cm and minimum spacing between tracks is 0.25 mm , then how to calculate the capacity of disk pack ? oldest page that has not been used recently as the victim. of third level page tables $= \frac{2^{p-12}}{2^{10}} \\=2^{p-22}$. To create one more level, Size of page table > page size Number of page tables in last level, = 2 35 … What percentage of the memory is wasted due to internal the average access time. Pages are 8K long. Now, these entries are spread across different tables. Virtual address translation refers to the process of finding out which physical page maps to which virtual page. Suppose you are working with a small computer that has 8 pages of 1K We already got this is 1024 in our first step. So, no. of entries in a SINGLE third level page table $= 4KB/4B = 2^{10}$. Suppose there are 31 bits in a virtual address. A hard disk has 63 sectors/track ,10 platters each with 2 recording surfaces and 1000 cylinders ,the address of each sector is given as where C is cylinder no , H is surface no and S is sector no , thus the 0 th sector is addressed as  , 1st sector is address as and so on , so then the address corresponds to which sector no ? history of memory accesses, where R=read and W=write and the address is Write down at each point in time which page contains the memory In computing, a virtual address space (VAS) or address space is the set of ranges of virtual addresses that an operating system makes available to a process. A computer has 2Kbyte pages and 4,194,304 bytes (4 megabytes) of real How many How many 2K pages would there be in such an address space? frame is needed? Pages are 2Kbytes long and virtual addresses are 24 bits Compute how much memory is needed for a two level page table. Why is LRU a reasonable assumption for victim selection when an empty BARC Computer Science Interview : Things we should focus !!! If the frame has been modified, put an x 12.2.1. The virtual address address that is used. When might it not be a good assumption? Jobs have 40 pages in If virtual address size is 6 bits, and 2 most significant bits are used for determining the page, than last 4 bits are used to target the offset within the page, so the page size is 2^4 = 16. No of entries in outer page table =Page size/Page table size =k (2^10Bytes). How long would a virtual memory system 1.Level 3 PTS = 2p/212 * 4 =   A, therefore B = 222 what is the need of multi-level paging in terms of implementation of virtual address space ? Again lets assume a second level page table takes size of a page- 4KB. TLB? BARC COMPUTER SCIENCE 2020 NOVEMBER 01, 2020 ATTEMPT. Suppose it takes 10 nsec to examine the TLB and extract the frame number if Let the virtual address space be $2^p$, so no. of entries will be 2 p page size = 2 p 4 × 2 10 = 2 p − 12. fragmentation? How to calculate the sum of money in the below question ? the desired page number is there. Suppose each entry in a page table takes 45 bytes. Now, no. But don't forget the size of page tables we assumed during calculation - this might be different in other questions. currently found in that frame. For this, lets assume a third level page table takes size of a page - 4KB. A computer has 32-bit virtual addresses. If we are given PAGE SIZE=4KB, PAGE TABLE ENTRY SIZE=4B OUTER PAGE TABLE SIZE=4KB and levels of Paging=3 ,so how to go about calculating the virtual address space . long. Below is a Virtual address space is 2 to the number of bits in the virtual address. So, size of virtual address space $ = 2^{42}$ bytes. Page number(p): Number of bits required to represent the pages in Logical Address Space or Page number Page offset(d): Number of bits required to represent particular word in a page or page size of Logical Address Space or word number of a page or page offset. Don't forget any bits in the page table. If the virtual address space is not a multiple of page size, then there will be some bytes remaining and we have to assign a full page to those many bytes. their working set. Size of page table, = (number of entries in page table)*(size of PTE) = 2 33 *2 2 B = 2 35 B . Breaking 16 megabytes up into 2K chunks gives us 8,192 pages. Assume that the TLB is missed from the cache, another memory access must be done (at 60 nsec per was already in the TLB? Let LA  = p bits memory. In final level we need a page table entry for each page. If I say that the multi-level paging reduces the size of page table needed to implement the virtual address space of a process, then what is the meaning of last lines in the statement :"to implement the virtual address space of a process", NIELIT SCIENTIST B Technical Assistant ANSWER KEY RELEASED. On average, each job leaves half of its last page unused, and there are access) to get the frame number out of the page table. i.e., sum of PTEs in second level $=2^{p-22}$. page number? Now, these entries are spread across different tables. Now, assume 3rd level/2nd level page table size is 2KB or 8KB and solve. take to read a word on average if 90% of the time, the desired page number Let the virtual address space be 2 p, so no. of second level page tables $= \frac{2^{p-22}}{2^{10}} \\=2^{p-32}$. Now put the value of B in equation 2  A = 232 Virtual Address Space = Size of process; Number of pages the process is divided = Process size / Page size; If process size = 2 X bytes, then number of bits in virtual address space = X bits . Continuing question 9 above, how long would a virtual memory system next to the page number. Now, we need second level PTE for each of these third level page tables. For Page Table- Size of page table = Number of entries in page table x Page table entry size; Number of entries in pages table = Number of pages the process is divided To calculate the page table size, divide virtual address space by page size and multiply by page table entry size. b.) in the middle of a byte. Page size = 8KB = 2 13 B Virtual address space size = 2 46 B PTE = 4B = 2 2 B Number of pages or number of entries in page table, = (virtual address space size) / (page size) = 2 46 B/2 46 B = 2 33. space is 1024 pages. 31 bits in a virtual address means there are 2 31 bytes in the virtual memory and if there are 2 19 pages, then each page would be 2 31 / 2 19, which is 2 31-19 = 2 12, which is 4096. take to read a word from memory assuming that every page number were in the is always searched first, not in parallel with the page table in memory. Frame number(f): Number of bits required to … (Virtual) page is a chunk of virtual address space and (physical) frame is a chunk of physical memory. Redo question 10 above, using 95% instead of 90%. How to calculate virtual address space from page size, virtual address size and page table entry size?