What is Capacity miss?
A cache miss caused by the working set being larger than the cache. It occurs even in a fully associative cache and is reduced by a larger cache or by improving data reuse.
Japanese name: 容量ミス
A cache miss caused by the working set being larger than the cache. It occurs even in a fully associative cache and is reduced by a larger cache or by improving data reuse.
Japanese name: 容量ミス
The set of data a program uses repeatedly over a period is called its working set. If it does not fit in the cache, data still in use is evicted and misses when used next. A capacity miss is a miss that occurs even in the most flexible cache organization, where data can be placed anywhere. This distinguishes it from a conflict miss, which is caused by restrictions on placement.
Consider repeatedly scanning a 1 MB array with a 32 KB L1 cache. While the later part of the array is being read, the earlier part is evicted. A miss therefore occurs again at every new line, even on the second and later scans. A larger cache reduces misses, but a large cache takes longer to read. The cache is therefore built as a hierarchy: a small, fast L1, a larger L2 and a still larger L3. Much of the data that misses in L1 is found in L2 or L3.
In computations on large matrices, rather than sweeping over the whole at once, the work is divided into small blocks that fit in the cache and finished block by block. This technique is called cache blocking. Making the data itself smaller also helps. Separating frequently used fields and rarely used fields into different arrays lets more of the frequently used data fit in the same capacity. Combining operations on the same data into a single pass also reduces misses.
Answer: C. Compulsory, capacity and conflict misses
Cache misses are classified as compulsory (first access), capacity (evicted because the cache is too small) and conflict (competition for the same set). Remedies differ by cause: larger lines or prefetching for compulsory misses, a bigger cache for capacity misses, and higher associativity for conflict misses.
Answer: C. Conflict miss
Misses where two pieces of data fight over the same set and evict each other, even though the cache as a whole has room, are conflict misses. Raising associativity so a set can hold both, or offsetting one array so it maps to different sets, reduces them. Capacity misses arise because the working set exceeds the whole cache and persist even with full associativity. Compulsory misses happen on first access and do not describe repeated accesses.
If raising the associativity of the cache reduces the misses, they are conflict misses; if only more capacity reduces them, they are capacity misses. In practice they are classified with tools that simulate cache behavior.
Yes. Using a range larger than the number of TLB entries multiplied by the page size increases TLB misses. Using large pages widens the range each entry covers.
Capacity miss appears in 6 practice questions across 2 topics, including Memory Hierarchy, CPUs and architecture.
As an Amazon Associate I earn from qualifying purchases.
This page was drafted with AI and fact-checked by a separate AI review before publication. Our Editorial policy explains how we write and check content. If you spot an error, please tell us on our Contact page.