Cache miss
A cache miss occurs when a cache lookup does not find a usable requested item in that cache.
100 Go Mistakes and How to Avoid Them
A cache miss occurs when requested data is not present in the relevant cache and must be obtained from a lower-level memory source.
- How it is used
- Uses cache misses to explain how memory access patterns affect Go performance.
- How deep it goes
- Traces compulsory and conflict misses through cache lines and sets, while deferring detailed CPU caching strategies.
- Examples
- Traces a 16-element slice sum and compares matrix sums with 512 and 513 columns.
- What you can do after
- Evaluate access patterns for compulsory and conflict misses and consider layout or stride changes in performance-intensive code.
Read how 100 Go Mistakes and How to Avoid Them explains cache miss →
Latency
A cache miss occurs when requested data or instructions are absent from the current cache level and must be fetched from slower storage.
- How it is used
- Explains variable access latency and evaluates whether caching avoids enough slow lookups to justify its overhead.
- How deep it goes
- Defines misses and traces read-through retrieval, with replacement and integration trade-offs but no implementation procedure.
- Examples
- Uses CPU memory fetches, a customer lookup with no results, and a read-through database lookup to illustrate misses.
- What you can do after
- Evaluate cache effectiveness using the hit-to-miss ratio and understand miss-handling trade-offs.
The Coder Cafe
A cache miss occurs when a requested memory location is not present in the relevant CPU cache.
- How it is used
- Explains why linked-list iteration can underperform arrays despite theoretical advantages for some operations.
- How deep it goes
- Connects cache misses to cache lines, spatial locality, prefetching, and iteration patterns without detailing cache hardware.
- Examples
- Uses a benchmark where a contiguous linked list iterated 230% slower than an array.
- What you can do after
- Evaluate/understand how memory layout and access patterns affect iteration performance when choosing arrays or linked lists.
High Performance Unity Game Development
A memory access in which the requested data is not found in a processor cache and must be retrieved from another memory level.
- How it is used
- Explains why enemy movement can stall while data is retrieved and motivates arranging data to improve cache-hit likelihood.
- How deep it goes
- Defines a miss and traces retrieval through cache levels to main memory, while noting that exact behavior depends on the processor.
- Examples
- Uses enemy position, direction, and velocity retrieval, plus contrasting C# arrays of structs and classes.
- What you can do after
- Evaluate data layouts by placing values processed together nearby to improve cache-hit likelihood.
Read how High Performance Unity Game Development explains cache miss →
What to know first
- meanThe mean is a measure of central location equal to the arithmetic average of numerical observations, or the probability-weighted average of a random variable’s possible values.
- arrayAn array is an ordered collection of elements organized in one or more dimensions and accessible by position or index.
- cachingCaching is the temporary storage of data or computed results for reuse, reducing the work or delay of retrieving or computing them again.
- integerAn integer is a whole-number mathematical value, including negative numbers, zero, and positive numbers, with no fractional part.
Related concepts
- cachingcontrasts with · Caching is the temporary storage of data or computed results for reuse, reducing the work or delay of retrieving or computing them again.
- compulsory missincludes · A compulsory miss is a cache miss caused by the first access to a memory block that has not yet been loaded into the cache.
- backing storeuses · A backing store is the authoritative storage layer from which a cache obtains values that it does not contain or whose cached copies have expired.
- heapproduced by · A heap is a runtime memory region from which dynamically allocated data is obtained and whose allocation and lifetime are managed separately from function call frames.
Questions about cache miss
What is cache miss?
A cache miss occurs when a cache lookup does not find a usable requested item in that cache.
Which Manning books explain cache miss?
100 Go Mistakes and How to Avoid Them, Latency, The Coder Cafe and High Performance Unity Game Development.
What should I know before learning cache miss?
Manning books that teach cache miss usually introduce mean, array, caching and integer first.
What is the difference between cache miss and caching?
A cache miss occurs when a cache lookup does not find a usable requested item in that cache. Caching is the temporary storage of data or computed results for reuse, reducing the work or delay of retrieving or computing them again.
What kinds of cache miss are there?
Kinds of cache miss include compulsory miss.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.



