字和字节

转载自:https://blog.csdn.net/Fabulous1111/article/details/79525384

论据:

先看一段摘抄自《Computer system: a programmer's perspective》的说明:

Buses are typically designed to transfer fixed-sized chunks of bytes known aswords. The
number of bytes in a word (the word size) is a fundamental system parameter that
varies across systems. Most machines today have word sizes of either 4 bytes (32
bits)or8bytes(64bits).


翻译过来就是说:总线一般被设计来传输固定大小的一块数据,这块数据被称为字(word),一个字包含的字节数(即字的大小)是各种计算机系统里面的基本参数,而且这个参数在不同的系统里通常是不同的。大多数的现代计算机系统里面,一个字要么是4个字节(32位),要么是8个字节(64位).

结论:

       一个字等于多少个字节,与系统硬件(总线、cpu命令字位数等)有关,不应该毫无前提地说一个字等于多少位。

正确的说法:

①:1字节(byte) = 8位(bit)

②:在16位的系统中(比如8086微机) 1字 (word)= 2字节(byte)= 16(bit)

       在32位的系统中(比如win32) 1字(word)= 4字节(byte)=32(bit)

       在64位的系统中(比如win64)1字(word)= 8字节(byte)=64(bit)


原文地址:https://www.cnblogs.com/wei1/p/9582091.html