A cache memory includes a plurality of data memory blocks and a code memory block.
Each data memory block has a plurality of storage locations and has a particular
storage location identified by a same index value. The code memory block has a
plurality of code values with a particular code value being associated with the
same index value. The particular code value is operable to identify which ones
of the particular storage locations associated with the same index value are locked
to prevent alteration of contents therein. The particular code value is also operable
to identify which particular storage location has been most recently used and which
particular storage location has been least recently used of the particular storage
locations associated with the same index value.