Little endian also allows you to truncate integers more easily.
Little endian also allows you to truncate integers more easily.
In the days of 8-bit microprocessors, the endianness became visible in software from 16-bit numbers up.
Now it might be visible only for numbers above 64-bit on many CPUs, but there is always a number size above which you must take endianness into account, even for the simplest operations, like comparing and adding.
In theory, you could choose the layout of a large number to have mixed endianness, e.g. to have a large number as a little-endian sequence of 64-bit chunks, where the 64-bit chunks are big-endian, because the CPU used is BE.
However that might make the algorithms even more complex than when you use a consistent endianness.
The endianness of a CPU is not visible in software only when the addressing unit of the memory is the same as the data register size of the CPU.
All modern CPUs have register sizes of either 32-bit or 64-bit, while the memory is addressed in bytes, so the endianness will continue to matter in the foreseeable future.
Some operations start at the least significant end, some start at the most significant end, and it's equally easy to loop over the words in either direction, so i don't buy this.
> Little endian also allows you to truncate integers more easily.
What do you mean by truncate an integer? If you mean go from 32 bit to 16 bit, that's still trivial with big-endian, you just shift.
Surely you would agree that moves are easier than shifts?
Moves can be handled by the renamer and be effectively free (even for memory operands, on CISC, with the advent of memory renamers; but this is even more important for RISC, where what would otherwise have been a load followed by a shift can just be a load), whereas shifts cannot and must take up some fraction of a cycle.
It's the same kind of thing as computers and calculators switching from decimal hardware to binary hardware 100 years ago.
Not quite. ENIAC, for example, did calculations in decimal, and it was finished in 1945. There may be more recent examples.
If you include binary-coded decimal, that still includes machines made in 1970 or later, like the IBM 1401.