2.5
Memory formats
ARM DDI 0337B
The processor views memory as a linear collection of bytes numbered in ascending
order from 0. For example:
•
bytes 0-3 hold the first stored word
•
bytes 4-7 hold the second stored word.
The processor can access data words in memory in little-endian format or big-endian
format. It always accesses code in little-endian format.
Note
Little-endian is the default memory format for ARM processors.
In little-endian format, the byte with the lowest address in a word is the least-significant
byte of the word. The byte with the highest address in a word is the most significant.
The byte at address 0 of the memory system connects to data lines 7-0.
In big-endian format, the byte with the lowest address in a word is the most significant
byte of the word. The byte with the highest address in a word is the least significant. The
byte at address 0 of the memory system connects to data lines 31-24.
Figure 2-5 on page 2-12 shows the difference between little-endian and big-endian
memory formats.
The processor contains a configuration pin, BIGEND, that enables you to select either
the little-endian or BE-8 big-endian format. This configuration pin is sampled on reset.
Endianness cannot be changed when out of reset.
Note
•
Accesses to System Control Space (SCS) are always performed as little endian.
•
Attempts to change endianness while not in reset are ignored.
•
PPB space is little-endian only irrespective of the setting of BIGEND.
Copyright © 2005, 2006 ARM Limited. All rights reserved.
Programmer's Model
2-11