|Non-Confidential||PDF version||ARM 100241_0001_00_en|
|Home > Functional Description > Cache Behavior and Cache Protection > About read allocate mode|
The processor supports read allocate mode, also called write streaming mode, both for the L1 and the L2 cache.
Read allocate mode is a performance and power-saving optimization for writing a large block of data.
The L1 data cache supports only a Write-Back policy. It normally allocates a
cache line on either a read miss or a write miss, although you can alter this by
changing the inner cache allocation hints in the page tables. However, there are
some situations where allocating on writes is not wanted, such as executing the C
memset() function to set a large
block of memory to a known value. Writing large blocks of data like this can pollute
the cache with unnecessary data. It can also waste power and reduce performance if a
linefill must be performed only to discard the linefill data because the entire line
was subsequently written by the
Therefore, the core includes logic to detect when the processor has written a full
cache line before the linefill completed. If this situation is detected on a
threshold number of consecutive linefills, the core switches to read allocate
When the L1 data cache is in read allocate mode:
More than the specified number of linefills might be observed on the master interface, before the core detects that three full cache lines have been written and switches to read allocate mode.
The core continues in read allocate mode until it detects either a cacheable write burst to L2 that is not a full cache line, or there is a load to the same line as is currently being written to L2.
To configure the L1 read allocate mode threshold, use CPUACTLR.L1RADIS.
The L2 cache enters read allocate mode after a threshold number of consecutive cache line sized writes to L2 are detected.
When the L2 cache is in read allocate mode:
L2 read allocate mode continues until there is a cacheable write burst that is not a full cache line, or there is a load to the same line as is currently being written to L3.
To configure the L2 read allocate mode threshold, use CPUACTLR.RADIS.