Byte order

The IEEE standards specify the four-byte float and eight-byte double data formats in order to facilitate data portability across diverse systems. But the standards don't specify the order in which the bytes are stored in a system, and platforms differ between storing the byte with the most significant bits of the number at the lowest address (big endian architectures) and storing the byte with the least significant bits at the lowest address (little endian architectures). Traditionally, this has proved troublesome when porting data between different systems, but the CommonPoint system eliminates this problem by reconciling byte ordering in the stream I/O operators <<= and >>=. See "Byte order of data" on page 210 for the effect of byte order on the data types.

NOTE If you use stream operators for the input and output of float and double values, the byte order of the underlying system won't affect your data across different systems. (The data is streamed in big endian format.)


[Contents] [Previous] [Next]
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.

Generated with WebMaker