Log in Sign up
Back to Discover
💻

Endianness

technology Maturity 11-13 war conflict
This article covers sensitive topics: war_conflict. Parents can manage visibility in Parental Controls.

Computers store data in small groups.

32bit-Endianess.svg
32bit-Endianess.svg
These groups have an order. One way starts at the big end. Another way starts at the small end. This helps the computer read things. Does your computer use a big end or a small end?

43 words

Computers store data in small groups.

32bit-Endianess.svg
32bit-Endianess.svg
These groups have an order. One way starts with the big part. This is called big-endian. The other way starts with the small part. This is called little-endian.
Gullivers travels.jpg
Gullivers travels.jpg
These names come from a funny story about eggs. Some people like the big end of an egg. Others like the small end. Computers use these two ways to read information. Both ways are used in the world today.

75 words

Computers store data in groups of bits. Most computers use groups called bytes. A single byte is eight bits long.

32bit-Endianess.svg
32bit-Endianess.svg

Sometimes, a computer needs to store a large piece of data. This data might take up four bytes. There are two main ways to order these bytes in memory. This way of ordering is called endianness.

In a big-endian system, the most important byte comes first. This is like how we write numbers in English. We write the biggest part of the number on the left. In a little-endian system, the least important byte comes first. This can look backwards when you read it.

Gullivers travels.jpg
Gullivers travels.jpg
The names come from a book called Gulliver's Travels. In the story, people argue about how to break an egg. Some break the big end, and some break the little end.

Different machines use different ways. Most modern processors use little-endian. However, big-endian is used for many internet rules. This is often called network order. Some machines can even switch between both ways.

169 words

Computers store information in groups of bits. Most computers use groups called bytes, which are eight bits long. Sometimes, a computer must store a much larger group of data. This larger group might contain four bytes, which is called a 32-bit word. To keep things organized, the computer must decide the order of these bytes in its memory. This way of ordering bytes is known as endianness.

32bit-Endianess.svg
32bit-Endianess.svg

There are two main ways to handle this task. In a big-endian system, the computer stores the most significant byte at the smallest memory address. This means the most important part of the data comes first. This is very similar to how we write numbers in English. We write the largest part of a number on the left side. In a little-endian system, the computer does the opposite. It stores the least significant byte at the smallest address.

32bit-Endianess.svg
32bit-Endianess.svg

The funny names for these systems come from a famous book. The book is called Gulliver's Travels by Jonathan Swift, written in 1726.

Gullivers travels.jpg
Gullivers travels.jpg
In a story in the book, people have a huge argument. They fight about how to break the shell of a boiled egg. Some people insist on breaking the big end of the egg. These people are called Big-Endians. The people who break the little end are called Little-Endians. Danny Cohen used these terms for computers in a note from 1980.

Different types of technology use different orders. Big-endian is the main order used for internet rules. This is often called network order. Many computer processors use little-endian instead. This includes the x86 processors and most ARM implementations. Some special computers are called bi-endian. These machines can switch between both ways of storing data. Other systems might use a middle-endian or mixed-endian order.

32bit-Endianess.svg
32bit-Endianess.svg

Understanding endianness helps us see how machines talk to each other. If a little-endian computer sends data to a big-endian computer, the bytes might look backwards. For example, a name like "JOHN" might look like "NH OJ" on a little-endian machine. Engineers use a process called byte swapping to fix this. This rearranges the bytes so the information is correct. It is like turning a word around so it makes sense again.

32bit-Endianess.svg
32bit-Endianess.svg

368 words

Endianness is a fundamental concept in computer science regarding data organization. It describes the specific order in which bytes are transmitted or stored in memory. When a computer handles a large group of data, called a word, it must decide how to arrange the individual bytes. This arrangement is based on byte significance, which refers to the mathematical weight of each byte within the larger value.

32bit-Endianess.svg
32bit-Endianess.svg

To understand the mechanism, one must look at how computer memory is structured. Memory consists of a sequence of storage cells called bytes, which are eight bits long. Each byte is assigned a unique memory address used for access. When a data field contains multiple bytes, the computer must order them. In a big-endian system, the most significant byte is stored at the smallest memory address. This is the byte that carries the highest numerical value. Conversely, a little-endian system stores the least significant byte at the smallest address.

32bit-Endianess.svg
32bit-Endianess.svg

There are several distinct types of endianness used in digital engineering. The two primary types are big-endian (BE) and little-endian (LE). Big-endian is similar to how humans write numbers in English, placing the most important digits on the left. Little-endian reverses this logic in memory. Some specialized architectures are described as bi-endian. These machines have the ability to switch their endianness during data fetches or stores. Other, more complex arrangements are called middle-endian or mixed-endian.

32bit-Endianess.svg
32bit-Endianess.svg

The terms used to describe these systems have a literary origin. In 1980, Danny Cohen introduced the terms in an Internet Experiment Note. He borrowed the names from Jonathan Swift’s 1726 satirical novel, Gulliver’s Travels.

Gullivers travels.jpg
Gullivers travels.jpg
In the book, residents of the land of Lilliput engage in a fierce debate. They argue over whether a boiled egg should be broken at the big end or the little end. The scholars who prefer the big end are called Big-Endians, while those who prefer the little end are Little-Endians.

Different technologies rely on different endianness for specific tasks. Big-endian is the dominant standard for networking protocols. In the Internet protocol suite, this is specifically referred to as network order. This ensures that the most significant byte is transmitted first across the network. On the other hand, little-endian is the dominant ordering for many processor architectures. This includes the x86 family used in many computers and most ARM implementations.

32bit-Endianess.svg
32bit-Endianess.svg

Endianness can cause interesting challenges when data moves between different systems. If a little-endian machine reads a text string like "JOHN" stored as an integer, it might appear as "NH OJ". This happens because the bytes are interpreted in a different sequence. To fix this, engineers use a process called byte-swapping. Byte-swapping rearranges the bytes to convert one endianness to another. Many modern compilers and CPU instruction sets, such as those in x86 or ARMv6, provide native support for this task.

32bit-Endianess.svg
32bit-Endianess.svg

Understanding these orders is important for hardware efficiency and mathematical operations. For example, addition, subtraction, and multiplication often start at the least significant digit. Because of this, little-endian machines can find the implementation of these operations marginally simpler. However, comparison and division operations typically start at the most significant digit. This makes big-endian machines slightly more efficient for those specific tasks.

32bit-Endianess.svg
32bit-Endianess.svg

534 words
🖼️ Images & Media (2)
File:32bit-Endianess.svg
32bit-Endianess.svg
File:Gullivers_travels.jpg
Gullivers_travels.jpg
Up Next
💻
Units of information
Technology
More to explore

What is Nepedia?

A free, ad-free encyclopedia for children. Every article is written at five reading levels, so the same page works for a five-year-old and a fifteen-year-old — use the level switcher above to see this one change. No account needed to read.