coldRef:
coldRef is a measure of the number of memory accesses that are cold misses in the cache.
Classifying coldRef:
coldRef can be classified into low, medium or high as follows:
Bucket | Condition |
---|---|
Low | Any region of code that has more than one memory reference and isn't streaming through memory. |
Medium | A region of code contains a mix of array initialization and memory references. |
High | A region of coda that has a single memory access and streams through memory. This would mostly be seen in array initialization loops. |
Example:
Consider the following code:
for (i=0; i<1000; i++) array[i] = 0;In this application, each memory access is to a new location and there is no reuse. Therefore, coldRef can be estimated to be high.