TLB, page-table and physical-cache outcomes
Virtual Memory & Paging

Answer & solution
Official answer: B, C
Givens and goal
A cache is physically addressed. An MMU has a TLB, and eviction of a page invalidates that page’s cache blocks. Which sequences cannot occur for a reference: A TLB miss/page-table hit/cache hit; B TLB hit/page-table miss/cache hit; C TLB miss/page-table miss/cache hit; D TLB miss/page-table miss/cache miss?
Approach
Distinguish a missing cached translation from a nonresident page, and apply the cache invalidation condition.
Step-by-step solution
1. Interpret a page-table miss here as a nonresident page (a page fault), not as a cache miss while fetching the page-table entry. The cache is physically addressed, so the ordinary sequence first resolves virtual-to-physical translation and then accesses the referenced cache block.
2. A TLB miss can occur even when the page is resident: the translation may simply not be cached in the TLB. After a successful page-table lookup the data block may still be present in the cache. Therefore A is possible.
3. In a correctly maintained translation system, a TLB hit supplies a valid resident-page translation, and a page-table walk is not needed for that reference. It cannot simultaneously be the page-table-fault sequence described in B. Thus B is impossible.
4. If the referenced page is absent from memory, the stated invalidation rule prevents its data blocks from remaining valid in the cache. Therefore the page-fault-plus-cache-hit sequence C is impossible. A TLB miss, page fault and absence of the data block from cache, as in D, is possible.
Interpretation note: These are hit/miss conditions for the original reference before fault recovery. Fault servicing can populate memory or cache and then retry the instruction; hits on that later retry are not the same event sequence. Correct TLB invalidation is implicit in a functioning virtual-memory system.
Possible-state examples help separate the two misses. A resident page whose translation has been displaced from the small TLB, but whose recently used data still sits in cache, gives A. A never-loaded virtual page gives a TLB miss and page fault; since it has no valid physical cached block, its initial data access is also a cache miss, matching D. “Page-table miss” is not being used to mean that the page-table entry itself missed in a processor cache.



![Question 47, GATE 2025: A demand-paging system has three initially empty frames and reference string [1,2,3,4,5,4,1,6,4,5,1,3,2]. In frame order, the resident triples after each reference are:
1:(1,−,−); 2:(1,2,−); 3:(1,2,3); 4:(1,4,3); 5:(1,4,5); 6:(1,4,5); 7:(1,4,5); 8:(6,4,5); 9:(6,4,5); 10:(6,4,5); 11:(6,1,5); 12:(6,1,3); 13:(2,1,3).
Which policies could produce this trace? A. LRU; B. LFU; C. MFU; D. optimal/farthest-next-use. Frequency-counter lifetime and tie-breaking are not stated.](../../../assets/questions/CS-2025-S2-Q47-1.webp)




![Question 57, GATE 2023: Row-major C array int D[128][128] is accessed by for i=0..127, for j=0..127, D[j][i]*=10. A page holds 512 array elements and 30 frames are available under LRU demand paging. Count faults in the intended page-aligned, initially nonresident array model; disclose these implicit assumptions.](../../../assets/questions/CS-2023-Q57-1.webp)




































































![Question 7(i), GATE 1996: A demand-paged system has 16-bit virtual addresses, 256-byte pages, 1 KiB physical memory, and LRU order [17,1,63] from least to most recent. Process hexadecimal addresses 00FF,010D,10FF,11B0 in order. Only three initial residents are listed, so assume the fourth frame is free. Give the new list after each access.](../../../assets/questions/CS-1996-Q60-1.webp)
![Question 7(i), GATE 1996: A demand-paged system has 16-bit virtual addresses, 256-byte pages, 1 KiB physical memory, and LRU order [17,1,63] from least to most recent. Process hexadecimal addresses 00FF,010D,10FF,11B0 in order. Only three initial residents are listed, so assume the fourth frame is free. Give the new list after each access.](../../../assets/questions/CS-1996-Q60-2.webp)
![Question 7(ii), GATE 1996: A demand-paged system has 16-bit virtual addresses, 256-byte pages, 1 KiB physical memory, and LRU order [17,1,63] from least to most recent. Process hexadecimal addresses 00FF,010D,10FF,11B0 in order. Only three initial residents are listed, so assume the fourth frame is free. Identify the accesses causing page faults.](../../../assets/questions/CS-1996-Q61-1.webp)
![Question 7(ii), GATE 1996: A demand-paged system has 16-bit virtual addresses, 256-byte pages, 1 KiB physical memory, and LRU order [17,1,63] from least to most recent. Process hexadecimal addresses 00FF,010D,10FF,11B0 in order. Only three initial residents are listed, so assume the fourth frame is free. Identify the accesses causing page faults.](../../../assets/questions/CS-1996-Q61-2.webp)
![Question 7(iii), GATE 1996: A demand-paged system has 16-bit virtual addresses, 256-byte pages, 1 KiB physical memory, and LRU order [17,1,63] from least to most recent. Process hexadecimal addresses 00FF,010D,10FF,11B0 in order. Only three initial residents are listed, so assume the fourth frame is free. Identify page replacements, if any.](../../../assets/questions/CS-1996-Q62-1.webp)
![Question 7(iii), GATE 1996: A demand-paged system has 16-bit virtual addresses, 256-byte pages, 1 KiB physical memory, and LRU order [17,1,63] from least to most recent. Process hexadecimal addresses 00FF,010D,10FF,11B0 in order. Only three initial residents are listed, so assume the fourth frame is free. Identify page replacements, if any.](../../../assets/questions/CS-1996-Q62-2.webp)







![Question 21(a), GATE 1993: Four initially empty page frames receive [1, 2, 3, 4, 1, 3, 5, 2, 1, 5, 4, 3, 2, 3]. Identify each page fault under LRU.](../../../assets/questions/CS-1993-Q58-1.webp)
![Question 21(a), GATE 1993: Four initially empty page frames receive [1, 2, 3, 4, 1, 3, 5, 2, 1, 5, 4, 3, 2, 3]. Identify each page fault under LRU.](../../../assets/questions/CS-1993-Q58-2.webp)
![Question 21(a), GATE 1993: Four initially empty page frames receive [1, 2, 3, 4, 1, 3, 5, 2, 1, 5, 4, 3, 2, 3]. Identify each page fault under LRU.](../../../assets/questions/CS-1993-Q58-3.webp)
![Question 21(b), GATE 1993: Four initially empty page frames receive [1, 2, 3, 4, 1, 3, 5, 2, 1, 5, 4, 3, 2, 3]. Identify each page fault under FIFO.](../../../assets/questions/CS-1993-Q59-1.webp)
![Question 21(b), GATE 1993: Four initially empty page frames receive [1, 2, 3, 4, 1, 3, 5, 2, 1, 5, 4, 3, 2, 3]. Identify each page fault under FIFO.](../../../assets/questions/CS-1993-Q59-2.webp)
![Question 21(b), GATE 1993: Four initially empty page frames receive [1, 2, 3, 4, 1, 3, 5, 2, 1, 5, 4, 3, 2, 3]. Identify each page fault under FIFO.](../../../assets/questions/CS-1993-Q59-3.webp)


