Cycle Timings and Interlock Behavior
ARM DDI 0301H
Copyright © 2004-2009 ARM Limited. All rights reserved.
16-5
ID012310
Non-Confidential, Unrestricted Access
The only useful sequences where two instructions write the same register without an instruction
reading its value in between are when the two instructions have opposite sets of condition codes.
The processor optimizes these sequences to prevent unnecessary interlocks. For example:
•
The following sequences take two cycles to execute:
—
ADDNE R1, R5, R6
LDREQ R1, [R8]
—
LDREQ R1, [R8]
ADDNE R1, R5, R6
•
The following sequence also takes two cycles to execute, because the STR instruction
does not store the value of R1 produced by the QDADDNE instruction:
QDADDNE R1, R5, R6
STREQ R1, [R8]
16.1.5
Definition of terms
Table 16-2 lists descriptions of cycle timing terms used in this chapter.
Table 16-2 Definition of cycle timing terms
Term
Description
Cycles
This is the minimum number of cycles required by an instruction.
Result latency
This is the number of cycles before the result of this instruction is available for a following
instruction requiring the result at the start of the ALU, MAC2, and DC1 stage. This is the normal
case. Exceptions to this mark the register as an Early Reg.
Note
The result latency is the number of cycles from the first cycle of an instruction.
Register Lock Latency
For STM and STRD instructions only. This is the number of cycles that a register is write locked
for by this instruction, preventing subsequent instructions that want to write the register from
starting. This lock is required to prevent a following instruction from writing to a register before
it has been read.
Early Reg
The specified registers are required at the start of the Sh, MAC1, and ADD stage. Add one cycle
to the result latency of the instruction producing this register for interlock calculations.
Late Reg
The specified registers are not required until the start of the ALU, MAC1, and DC1 stage for the
second execution. Subtract one cycle from the result latency of the instruction producing this
register for interlock calculations.
FlagsCycleDistance
The number of cycles between an instruction that sets the flags and the conditional instruction.