Subject: Re: as long as we're hitting FFS...
To: Alex Barclay <alex@vsys.com>
From: Bill Sommerfeld <sommerfeld@orchard.arlington.ma.us>
List: tech-kern
Date: 03/23/1999 19:46:20
> If you take a look at the CORBA 2.0 IP transport IIOP it takes the view
> of letting the receiver work out the endianness. This gives a gain in
> a network of same achitecture machines. You only convert when you
> have to. I think this is how filesystems should be.

Actually, I'm not at all convinced of this.  Have you actually
*looked* at the instruction sequences stubs have to go through to
decode stuff like this?  (My experience with this is with Apollo NCS
and DCE RPC which used this same technique.  It was a nightmare in
terms of stub size.)

The stubs contained a "fast path" which got executed when the data
reps matched exactly, and a "slow path" which executed when it
didn't. The total code size was probably 2x the size of
byteswap-all-the-time, and involved lots of conditional branches..
(because the drep included more than just integer byte order; charset
and floating point format also was involved).

				- Bill