Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
CS 220 / ARM / ARM1176JZ-S Technical Reference Mmanual.pdf
Источник:
Скачиваний:
44
Добавлен:
16.04.2015
Размер:
4.47 Mб
Скачать

Cycle Timings and Interlock Behavior

16.13 RFE and SRS instructions

This section describes the cycle timing for the RFE and SRS instructions.

These instructions return from an exception and save exception return state respectively. The RFE instruction always requires two memory cycles. It first loads the SPSR value from the stack, and then the return address. The SRS instruction takes one or two memory cycles depending on double-word alignment first address location.

In all cases the base register is an Early Reg, and requires an extra cycle of result latency to provide its value.

Table 16-20 lists the cycle timing behavior for RFE and SRS instructions.

Table 16-20 RFE and SRS instructions cycle timing behavior

Example Instruction

Cycle

Memory Cycles

s

 

 

 

 

 

Address double-word aligned

 

 

 

 

 

RFEIA <Rn>

9

2

 

 

 

SRSIA #<mode>

1

1

 

 

 

Address not double-word aligned

 

 

 

 

 

RFEIA <Rn>

9

2

 

 

 

SRSIA #<mode>

1

2

 

 

 

ARM DDI 0333H

Copyright © 2004-2009 ARM Limited. All rights reserved.

16-23

ID012410

Non-Confidential, Unrestricted Access

 

Cycle Timings and Interlock Behavior

16.14 Synchronization instructions

This section describes the cycle timing behavior for the SWP, SWPB, LDREX, and STREX instructions.

In all cases the base register, Rn, is an Early Reg, and requires an extra cycle of result latency to provide its value. Table 16-21 lists the synchronization instructions cycle timing behavior.

Table 16-21 Synchronization Instructions cycle timing behavior

Instruction

Cycle

Memory Cycles

Result Latency

s

 

 

 

 

 

 

 

SWP Rd, <Rm>, [Rn]

2

2

3

 

 

 

 

SWPB Rd, <Rm>, [Rn]

2

2

3

 

 

 

 

LDREX <Rd>, [Rn]

1

1

3

 

 

 

 

STREX, <Rd>, <Rm>, [Rn]

1

1

3

 

 

 

 

LDREX{B,H,D} <Rd>, [Rn]

1

1

3

 

 

 

 

STREX{B,H,D} <Rd>, <Rm>, [Rn]

1

1

3

 

 

 

 

CLREX

1

1

X

 

 

 

 

CLREX instructions have cycle timing behavior as for load instructions. Because they have no destination register, the result latency is not-applicable for such instructions.

ARM DDI 0333H

Copyright © 2004-2009 ARM Limited. All rights reserved.

16-24

ID012410

Non-Confidential, Unrestricted Access

 

Cycle Timings and Interlock Behavior

16.15 Coprocessor instructions

This section describes the cycle timing behavior for the CDP, LDC, STC, LDCL, STCL, MCR, MRC, MCRR, and MRRC instructions.

The precise timing of coprocessor instructions is tightly linked with the behavior of the relevant coprocessor. The numbers in Table 16-22 are best case numbers. For LDC/STC instructions, the coprocessor can determine how many words are required. Table 16-22 lists the coprocessor instructions cycle timing behavior.

Table 16-22 Coprocessor Instructions cycle timing behavior

Instruction

Cycle

Memory cycles

Result Latency

s

 

 

 

 

 

 

 

MCR

1

1

-

 

 

 

 

MCRR

1

1

-

 

 

 

 

MRC

1

1

3

 

 

 

 

MRRC

1

1

3/3

 

 

 

 

LDC/LDCL

1

As required

-

 

 

 

 

STC/STCL

1

As required

-

 

 

 

 

CDP

1

1

-

 

 

 

 

ARM DDI 0333H

Copyright © 2004-2009 ARM Limited. All rights reserved.

16-25

ID012410

Non-Confidential, Unrestricted Access

 

Cycle Timings and Interlock Behavior

16.16 SVC, SMC, BKPT, Undefined, and Prefetch Aborted instructions

This section describes the cycle timing behavior for SVC, SMC, Undefined Instruction, BKPT and Prefetch Abort.

In all cases, the exception is taken in the WBex stage of the pipeline. SVC, SMC, and most Undefined instructions that fail their condition codes take one cycle. A small number of undefined instructions that fail their condition codes take two cycles. Table 16-23 lists the SVC, SMC, BKPT, undefined, prefetch aborted instructions cycle timing behavior.

Table 16-23 SVC, BKPT, undefined, prefetch aborted instructions cycle timing behavior

Instruction

Cycle

s

 

 

 

SVC

8

 

 

SMC

8

 

 

BKPT

8

 

 

Prefetch Abort

8

 

 

Undefined Instruction

8

 

 

ARM DDI 0333H

Copyright © 2004-2009 ARM Limited. All rights reserved.

16-26

ID012410

Non-Confidential, Unrestricted Access

 

Соседние файлы в папке ARM