02.02.2013 Views

ARM Processor Instruction Set

ARM Processor Instruction Set

ARM Processor Instruction Set

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>ARM</strong> <strong>Processor</strong> <strong>Instruction</strong> <strong>Set</strong><br />

5.13 Coprocessor Data Transfers (LDC, STC)<br />

5-38<br />

31<br />

28<br />

27<br />

Use of the LDC or STC instruction on the <strong>ARM</strong> processor (except for the defined FPA<br />

instructions) will cause an undefined instruction trap to be taken, which may be used<br />

to emulate the coprocessor instruction.<br />

The instruction is only executed if the condition is true. The various conditions are<br />

defined at the beginning of this chapter. The instruction encoding is shown in Figure<br />

5-24: Coprocessor data transfer instructions.<br />

This class of instruction is used to load (LDC) or store (STC) a subset of a<br />

coprocessors’s registers directly to memory. The processor is responsible for<br />

supplying the memory address, and the coprocessor supplies or accepts the data and<br />

controls the number of words transferred.<br />

25<br />

24<br />

23<br />

22<br />

21<br />

20<br />

19<br />

Cond 110 P U N W L Rn CRd CP# Offset<br />

16<br />

Figure 5-24: Coprocessor data transfer instructions<br />

5.13.1 The coprocessor fields<br />

The CP# field is used to identify the coprocessor which is required to supply or accept<br />

the data, and a coprocessor will only respond if its number matches the contents of<br />

this field.<br />

The CRd field and the N bit contain information for the coprocessor which may be<br />

interpreted in different ways by different coprocessors, but by convention CRd is<br />

the register to be transferred (or the first register where more than one is to be<br />

transferred), and the N bit is used to choose one of two transfer length options.<br />

15<br />

<strong>ARM</strong>7500FE Data Sheet<br />

<strong>ARM</strong> DDI 0077B<br />

Named Partner Open Confidential Access - Preliminary - Preliminary Draft<br />

12<br />

11<br />

8<br />

7<br />

Unsigned 8 bit immediate offset<br />

Coprocessor number<br />

Coprocessor source/destination register<br />

Base register<br />

Load/Store bit<br />

0 = Store to memory<br />

1 = Load from memory<br />

Write-back bit<br />

0 = no write-back<br />

1 = write address into base<br />

Transfer length<br />

Up/Down bit<br />

0 = down; subtract offset from base<br />

1 = up; add offset to base<br />

Pre/Post indexing bit<br />

0 = post; add offset after transfer<br />

1 = pre; add offset before transfer<br />

Condition field<br />

0

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!