05.02.2013 Views

ARM Architecture Reference Manual ARMv7-A and ARMv7-R edition

ARM Architecture Reference Manual ARMv7-A and ARMv7-R edition

ARM Architecture Reference Manual ARMv7-A and ARMv7-R edition

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Application Level Memory Model<br />

To ensure access rules are maintained, an instruction that causes multiple accesses to Device or<br />

Strongly-ordered memory must not cross a 4KB address boundary, otherwise the effect is<br />

UNPREDICTABLE. For this reason, it is important that an access to a volatile memory device is not<br />

made using a single instruction that crosses a 4KB address boundary.<br />

<strong>ARM</strong> expects this restriction to impose constraints on the placing of volatile memory devices in the<br />

memory map of a system, rather than expecting a compiler to be aware of the alignment of memory<br />

accesses.<br />

For instructions that generate accesses to Device or Strongly-ordered memory, implementations must<br />

not change the sequence of accesses specified by the pseudocode of the instruction. This includes not<br />

changing:<br />

— how many accesses there are<br />

— the time order of the accesses<br />

— the data sizes <strong>and</strong> other properties of each access.<br />

In addition, processor implementations expect any attached memory system to be able to identify the<br />

memory type of an accesses, <strong>and</strong> to obey similar restrictions with regard to the number, time order,<br />

data sizes <strong>and</strong> other properties of the accesses.<br />

Exceptions to this rule are:<br />

— An implementation of a processor can break this rule, provided that the information it supplies<br />

to the memory system enables the original number, time order, <strong>and</strong> other details of the accesses<br />

to be reconstructed. In addition, the implementation must place a requirement on attached<br />

memory systems to do this reconstruction when the accesses are to Device or Strongly-ordered<br />

memory.<br />

For example, an implementation with a 64-bit bus might pair the word loads generated by an<br />

LDM into 64-bit accesses. This is because the instruction semantics ensure that the 64-bit access<br />

is always a word load from the lower address followed by a word load from the higher address.<br />

However the implementation must permit the memory systems to unpack the two word loads<br />

when the access is to Device or Strongly-ordered memory.<br />

— Any implementation technique that produces results that cannot be observed to be different<br />

from those described above is legitimate.<br />

— An Advanced SIMD element or structure load instruction can access bytes in Device or<br />

Strongly-ordered memory that are not explicitly accessed by the instruction, provided the<br />

bytes accessed are within a 16-byte window, aligned to 16-bytes, that contains at least one byte<br />

that is explicitly accessed by the instruction.<br />

Any multi-access instruction that loads or stores the PC must access only Normal memory. If the<br />

instruction accesses Device or Strongly-ordered memory the result is UNPREDICTABLE. There is one<br />

exception to this restriction. In the VMSA architecture, when the MMU is disabled any multi-access<br />

instruction that loads or stores the PC functions correctly, see Enabling <strong>and</strong> disabling the MMU on<br />

page B3-5.<br />

Any instruction fetch must access only Normal memory. If it accesses Device or Strongly-ordered<br />

memory, the result is UNPREDICTABLE. For example, instruction fetches must not be performed to an<br />

area of memory that contains read-sensitive devices, because there is no ordering requirement<br />

between instruction fetches <strong>and</strong> explicit accesses.<br />

A3-36 Copyright © 1996-1998, 2000, 2004-2008 <strong>ARM</strong> Limited. All rights reserved. <strong>ARM</strong> DDI 0406B

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

Saved successfully!

Ooh no, something went wrong!