
3-22
MPC603e & EC603e RISC Microprocessors User's Manual
MOTOROLA
More specifically, the 603e internally detects the scenario where a load request is
outstanding and the processor has pipelined a write operation on top of the load. Normally,
when the data bus is granted to the 603e, the resulting data bus tenure is used for the load
operation. The enveloped high-priority cache block push feature defines a bus signal, the
data bus write only qualifier (DBWO), which, when asserted with a qualified data bus grant,
indicates that the resulting data tenure should be used for the store operation instead. This
signal is described in Section 8.10, “Using Data Bus Write Only.” Note that the enveloped
copyback operation is an internally pipelined bus operation.
3.7 Cache Control Instructions
Software must use the appropriate cache management instructions to ensure that caches are
kept consistent when data is modified by the processor. When a processor alters a memory
location that may be contained in an instruction cache, software must ensure that updates
to memory are visible to the instruction fetching mechanism. Although the instructions to
enforce coherency vary among implementations and hence operating systems should
provide a system service for this function, the following sequence is typical:
1.
dcbst
(update memory)
2.
sync
(wait for update)
3.
icbi
(invalidate copy in cache)
4.
isync
(invalidate copy in own instruction buffer)
These operations are necessary because the processor does not maintain instruction
memory coherent with data memory. Software is responsible for enforcing coherency of
instruction caches and data memory. Since instruction fetching may bypass the data cache,
changes made to items in the data cache may not be reflected in memory until after the
instruction fetch completes.
The PowerPC architecture defines instructions for controlling both the instruction and data
caches when they exist. The 603e interprets the cache control instructions (
icbi
,
dcbi
,
dcbt
,
dcbz
,
dcbst
) as if they pertain only to the 603e’s caches. They are not intended for use in
managing other caches in the system.
The
dcbz
instruction causes an address-only broadcast on the bus if the contents of the
block are from a page marked global through the WIMG bits. This broadcast is performed
for coherency reasons; the
dcbz
instruction is the only cache control instruction that can
allocate and take new ownership of a line. Note that if the HID0[ABE] bit is set on a PID7v-
603e processor, the execution of the
dcbf
,
dcbi
, and
dcbst
instructions will also cause an
address-only broadcast. The
dcbz
instruction is also the only cache operation that is
snooped by the 603e. The cache instructions are intended primarily for the management of
the on-chip cache, and do not perform address-only broadcasts for the maintenance of other
caches in the system. The ability of the PID7v-603e to optionally perform address-only
broadcasts when executing the
dcbi
,
dcbf
, and the
dcbst
instructions allows the coherency
management of an external copyback L2 cache.