On May 9, 10:04, Dominic Sweetman wrote:
>Scientific manner, chaps! LE and BE are two different *arbitrary*
>choices about how you represent bigger-than-byte integers in a
>byte-organised memory. Neither one is right or wrong; I find LE
>easier because I began my computing career on DEC and got into
>low-level code on Intel CPUs. Tor finds BE natural, I suspect,
>because he started off on Motorola?
Well, microprosessors weren't much used when I started, and I don't know
even today what an Alpha LSI used for byte endianity.. however, when I
began to do things where I had to know about such things I was working with
VAX and another mini with Motorola endianity, at roughly the same time.
>Arguably DEC and IBM (whose bit numbers increase the same way as their
>byte addresses) are righter than Motorola (whose bit numbers go down
>as byte addresses go up). It would be nice if everyone did the same,
>of course - one less thing to go wrong.
IMHO it doesn't matter much which way the bits are counted, however I
prefer that the sequence is linear also when crossing byte boundaries
(e.g. bit 7 sits beside bit 8 is more important than which comes 'first').
One reason is that I worked with satellite data where we had to write code
to extract say 47 bits from a particular window inside a set of 111 bits.
For me it was always easier to code that on big endian computers. There are
others though who argue that LE is easier, although I never really got it :-)
This is no big deal though, and I've been using my Linux/Intel PC since 1992
without suffering too much :-)
>> I would really like to switch my Olivetti M700-10 over to big endian
>> at some stage, if that's at all technically possible.
>Don't even think about it!
The real reason I'm interested in BE for Linux/MIPS is as I said that Sun
and SGI use it. So are you saying that it can't be done for Jazz boxes?
That's bad news :-(
>PS: the "change endianness in user mode" feature was a late addition
> to the R3000 chip, by disgruntled MIPS engineers who wanted to be
> able to run DECstation binaries on MIPS Unix boxes. The system
> software to make the hardware feature usable was never included in
> any MIPS OS, and I think has never been used by anyone.
Interesting! I didn't know it could be done in user mode for MIPS, I thought
it had to be done no later than during boot (I seem to remember a pin on the
chip for this?). I know PPC can be switched at any time, one task can run BE
and the other LE -- at the same time even. At least that's what I've been