
\subsection{\index{loadf}loadf, \index{storef}storef, \index{loadif}loadif,
\index{storeif}storeif}

\index{load and store without caching}

\begin{tabular}{l}
  {\bf loadf r3, r2, r1} \\
  {\bf loadfe r3, r2, r1} \\
  {\bf storef r3, r2, r1} \\
  {\bf storefe r3, r2, r1} \\
  {\bf loadif r3, r2, r1} \\
  {\bf loadife r3, r2, r1} \\
  {\bf storeif r3, r2, r1} \\
  {\bf storeife r3, r2, r1} \\
\end{tabular}

~~~~~~
These instructions only differ from the normal opcodes by one flag which does
not fit in the flag field (not enough room). This {\bf F} flag is a hint for 
the onchip memory system, it influences the caching strategy. {\bf F} means 
{\bf Flush}, the data that is currently being processed (read or written) is 
not needed anymore, the CPU doesn't need to keep a copy onchip. This flag is 
meant to reduce the cache line thrashing whenever possible and increase the 
effective memory bandwidth.

~~~~~~
More precisely, the semantic behind this flag is : the data is needed once''.
This is achieved inside the CPU by modifying the {\bf caching strategy} with
a cache line granularity. By default, when the {\bf F} flag is omitted, the 
strategy is~:\\
~~~~~~
- keep the current line in the memory buffer\\
~~~~~~
- when the line expires, flush it to the internal cache\\
~~~~~~
- when the line expires in cache, flush it to the external memory

When the F flag is used in a load operation, the whole cache line is
retrieved from external memory to the memory buffer. If possible, the
succeeding memory location (it can be the precedent or next memory locations,
depending on the sign of the pointer update) is retrieved. When the content 
of this second fetch begins to be used, this frees the first line, which is 
then used to fetch the third location. The two memory buffer lines continue 
this ping-pong as long as the stream goes on. The cache line is clearly 
flushed'' but is not written back in memory because it is not modified.\\
~~~~~~
With the store instruction, the operation doesn't necessarily need to begin
with a fetch from memory. The F flag says that the line is flushed directly
to the external memory instead of going to the internal cache memory.

~~~~~~
The behaviour when loading to r0 with the F flag set is undetermined. The
semantics don't go together, it would be prefetch something that will not be 
used after''... That's what i'd call waste time''. So stay tunned.

~
\begin{center}
{\bf Performance (FC0 only) :}
\end{center}


{\em Execution Unit :} Load/Store Unit\\
{\em Latency :} undetermined\\
{\em Throughput :} 1 operation per cycle per LSU (peak).\\

~
\pagebreak


