7.3. LDC/STC

The LDC and STC instructions are used respectively to transfer data to and from external coprocessor registers and memory. In the case of the ARM946E-S processor, the memory can be either cache, Tightly-Coupled Memory (TCM) or AHB depending on the address range of the access and the protection unit settings.

Figure 7.6 shows the cycle timing for these operations.

Figure 7.6. LDC/STC cycle timing

In this example, four words of data are transferred. The number of words transferred is determined by how the coprocessor drives the CHSDE[1:0] and CHSEX[1:0] buses.

As with all other instructions, the ARM9E-S core performs the main decode off the rising edge of the clock during the Decode stage. From this, the core commits to executing the instruction and so performs an instruction fetch. The coprocessor instruction pipeline keeps in step with the ARM9E-S core by monitoring nCPMREQ. This is a registered version of the ARM9E-S core instruction memory request signal InMREQ.

At the rising edge of CLK, if CPCLKEN is HIGH, and nCPMREQ is LOW, an instruction fetch is taking place, and CPINSTR[31:0] contains the fetched instruction on the next rising edge of the clock, when CPCLKEN is HIGH.

This means that:

In all other cases, the ARM9E-S pipeline is stalled, and the coprocessor pipeline must not advance.

During the Execute stage, the condition codes are compared with the flags to determine whether the instruction really executes or not. The output CPPASS is asserted, HIGH, if the instruction in the Execute stage of the coprocessor pipeline:

If a coprocessor instruction busy-waits, CPPASS is asserted on every cycle until the coprocessor instruction is executed. If an interrupt occurs during busy-waiting, CPPASS is driven LOW, and the coprocessor stops execution of the coprocessor instruction.

Another output, CPLATECANCEL, cancels a coprocessor instruction when the instruction preceding it caused a Data Abort. This is valid on the rising edge of CLK on the cycle that follows the first Execute cycle of any coprocessor instruction. This is the only cycle in which CPLATECANCEL can be asserted.

On the rising edge of the clock, the ARM9E-S processor examines the coprocessor handshake signals CHSDE[1:0] or CHSEX[1:0]:

Copyright © 2001-2003, 2007 ARM Limited. All rights reserved.ARM DDI 0201D