Types of Locality of reference

  1. Spatial Locality of reference
    Spatial locality means instruction or data near to the current memory location that is being fetched, may be needed soon in the near future.
  2. Temporal Locality of reference
    Temporal locality means current data or instruction that is being fetched may be needed soon. So we should store that data or instruction in the cache memory to avoid searching again in main memory for the same data.
Posted on by