Electronics America Network Cables User Manual

CHAPTER 3 SYSTEM CONTROLLER
228
Preliminary User’s Manual S15543EJ1V0UM
However, when making half-word accesses into a data array consisting of word data, access to the more-
significant half word requires the address corresponding to the less significant half word (and vice versa). Such code
is not endian-independent. A super-group access (for example, accessing two half words simultaneously as a word
from a half-word data array) causes the same problem. Such problems also arise when a half-word access is made
into a 32-bit register, whereas a word access into a 32-bit register creates no problem.
Figure 3-3. Word Data Array Example
Word
Data Array
Big-Endian
Data extraction using sequential halfword access
W1
W0
LSHWMSHW
Little-Endian
MSHW LSHW
A B C D
E F G H
I J K L
M N O P
A B C D
E F G H
I J K L
M N O P
Order Retained
Data extraction using sequential halfword access
A B C D E F G H
I J K L M N O P
Order Lost
A B C D E F G H
I J K L M N O P W1
W0 A B C D E F G H
I J K L M N O P
A B C D E F G H
I J K L M N O P