Efficiently importing/export GMP floats
marc.glisse at inria.fr
Mon Jan 17 15:43:39 CET 2011
On Mon, 17 Jan 2011, Joerg Arndt wrote:
> * foxmuldrster at yahoo.com <foxmuldrster at yahoo.com> [Jan 17. 2011 15:11]:
>> I do not see where network byte order is in any way desirable, as it
>> necessarily mandates manipulation on any machine with an alternate
>> native endian format.
> Are you kidding?
I am not sure why you are reacting so strongly against this suggestion.
> Note the "overhead" is usually a single machine instruction (bswap).
Having to use bswap also prohibits some of the usual optimizations of
> Making the overhead come back, conditionally...
Only when necessary. That seems like a nice property.
>> Requiring conversions both in and out on some architectures seems
>> wholly undesirable.
> Undesirable as in _networking_ ?
Networking would not be the only use. And even for networking, as long as
the encoding includes the endianness information...
>> It should only be required whenever it happens
>> to be different.
> You do not know in general if it's required.
Do you pull the seat down when you exit the bathroom?
More information about the gmp-discuss