您的位置:首页 > 其它

Big-Endian and Little-Endian

2015-09-04 23:56 453 查看
Wikipedia has a very clear graph and tells me that "big-endian" and "little-endian" comes from Gulliver’s Travels

1. Big-Endian, Little-Endian is not only for bit level, but most likely people talk about it on byte level. The network (big-endian) and host (any) conversion is quite popular on Internet. 

2. Some terms

a) Most-Significant-Byte (MSB): High byte

b) Lest-Significant-Byte (LSB): Low byte

c) Bit Endianness or Bit-level Endianness: very rare used

3. Little Endian is more popular: Windows, Linux on x86/64, BSD/FreeBSD on X86/64, iOS on ARM, MAC OS on x86/64

4. POSIX has defined some functions to do the network/host converting: ntohl(), ntohs(), htonl(), htons() in arpa/inet.h

 

--<>---- The END ------<>--
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: