CPU 字长(cpu word size)是什么意思?

In computing, word size refers to the maximum number of bits that a CPU can process at a time. A word is a fixed-sized piece of data which is dictated by the processor hardware architecture; fixed in a sense that it is the maximum size that the processor is always using, yet variable in the sense that word sizes vary amongst processor architectures, most notably because of generation and the state of technology.

在计算中,字长是指 CPU 一次可以处理的最大位数

Word size has varied in size and even in meaning throughout the history of the computer. Originally, “word” meant 16 bits, as that was the maximum possible value at the time. But as processor hardware technology progressed and computers were able to handle larger and larger amounts of data, word simply became the maximum possible number of bits that the processor in question can process. So word size could be as low as 4 bits or as high as 64 bits, depending on what a particular processor can handle.

在计算机的整个历史中, Word size的大小甚至含义都各不相同。 最初,“字”表示 16 位,因为这是当时的最大可能值。 但是随着处理器硬件技术的进步和计算机能够处理越来越多的数据,Word size就变成了所讨论的处理器可以处理的最大可能位数。 因此,字长可以低至 4 位,也可以高至 64 位,具体取决于特定处理器的处理能力。

Word size用于许多概念,都与处理有关。 它用于以下任何一项:

Addresses — The address must be able to represent the full range possible, so it uses a full word or a multiple of it.
Fixed-point numbers — Integers are available in different sizes, but usually it takes the size of the full word supported by the processor.
Floating-point numbers — Holders for floating-point numbers typically use the full word size length or multiples of it.
Registers — The size of the register depends on the kind of register and what its purpose is, but a general-purpose register usually uses the maximum word size capability of the processor.
Instructions — Instruction sets for processors are often coded in full word size.

总结

  • 字长是指 CPU 一次可以处理的最大位数

ps

  • 为什么超过字长的一次处理不了?

参考

计算机中的字长是什么意思?

上一篇:PyTorch - torch.ones_like、torch.zeros_like、 torch.full_like


下一篇:Cmder Full with Git