
5-4
Coprocessor Interface
Rev. A
Copyright 2000 by LSI Logic Corporation. All rights reserved.
5.4 Pipeline Following Signals
Every coprocessor in the system must contain a pipeline follower to track
the instructions executing in the ARM7TDMI-S pipeline. The
coprocessors connect to CLK and CLKEN, and to the ARM7TDMI-S
input data bus, RDATA[31:0], over which instructions are fetched.
It is essential that the two pipelines remain in step at all times. When
designing a pipeline follower for a coprocessor, the following rules must
be observed:
At reset (nRESET LOW), the pipeline must either be marked as
invalid, or filled with instructions that will not decode valid instructions
for that coprocessor.
The coprocessor state must only change when CLKEN is HIGH
(except for reset).
An instruction must be loaded into the pipeline on the rising edge of
CLK, and only when CPnOPC, CPnMREQ, and CPTBIT were all
LOW in the previous bus cycle. These conditions indicate that this
cycle is an ARM7TDMI-S state opcode fetch, so the new opcode
must be sampled into the pipeline.
Advance the pipeline on the rising edge of CLK when CPnOPC,
CPnMREQ, and CPTBIT are all LOW in the current bus cycle. These
conditions indicate that the current instruction is about to complete
execution, because the first action of any instruction performing an
instruction fetch is to refill the pipeline.
Any instructions that are flushed from the ARM7TDMI-S pipeline will
never signal on CPnI that they have entered the execute stage, and so
they are automatically flushed from the coprocessor pipeline by the
prefetches required to refill the pipeline.
There are no coprocessor instructions in the Thumb instruction set. So
coprocessors must monitor the state of the CPTBIT signal to ensure that
they do not try to decode pairs of Thumb instructions as ARM7TDMI-S
instructions.