Define hit ratio.
Define hit ratio.
Hit ratio is the fraction of memory accesses that find the needed data in the cache.
$$\text{Hit ratio } H = \frac{\text{number of hits}}{\text{total number of accesses}}$$
For example, if the CPU makes 1000 accesses and 950 are found in the cache, then $H = 950/1000 = 0.95$. The miss ratio is $1 - H = 0.05$. A higher hit ratio gives a lower average access time, because fewer accesses go to the slow main memory.
Short on time? The 1, 5 and 10 mark versions of this answer, flashcards and practice sets come with a program pass.
Up nextWhat do you mean by page fault?