Table 56: Endian Example; Table 57: Storage Of Big-Endian Data; Table 58: Storage Of Little-Endian Data - Broadcom BCM5722 Programmer's Manual

Host programmer interface specification for the netxtreme and netlink family of highly integrated media access controllers
Table of Contents

Advertisement

Programmer's Guide
10/15/07
E
C
NDIAN
ONTROL
B
ACKGROUND
There are two basic formats for storing data in memory—little-endian and big-endian. The endianess of a system is
determined by how multibyte quantities are stored in memory. A big-endian architecture stores the most significant byte at
the lowest address offset while little-endian architecture stores the least significant byte at the lowest address offset.
For example, the 32-bit hex value 0x12345678 would be stored in memory as shown in the following table.
Address
00
Big Endian
12
Little Endian
78
Another way of viewing how this data would be stored is shown in the following tables.
Storage Byte
00
Data Contents
12
Storage Byte
03
Data Contents
12
Examples of big-endian platforms include SGI Irix, IBM RS6000, and SUN.
Examples of little-endian platforms include Intel x86 and DEC Alpha.
PCI assumes a little-endian memory model. PCI configuration registers are organized so that the least significant portion of
the data is assigned to the lower address.
Document
5722-PG101-R
(B
W
YTE AND
ORD

Table 56: Endian Example

01
34
56

Table 57: Storage of Big-Endian Data

01
34

Table 58: Storage of Little-Endian Data

02
34
Bro adco m Co rp or atio n
S
)
WAPPING
02
56
34
02
56
01
56
Endian Control (Byte and Word Swapping)
BCM5722
03
78
12
03
78
00
78
Page 142

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the BCM5722 and is the answer not in the manual?

Questions and answers

This manual is also suitable for:

Bcm5722kfb1g

Table of Contents