为什么Big Endian以小字节结尾?
Why does Big Endian end with the little byte?
通常说内存(或内存段)的"end"地址最高。例如:程序计数器通常递增(而不是递减)并且代码从"start"执行到"end",因此程序末尾的指令位于最高地址(而不是最低地址) ).
BigEndian 约定指定 最大 字节(即最高有效字节)位于最低地址(即内存的开始)。不应该反过来吗?这是大结束ian,不是大开始ian.
同样,LittleEndian 指定最小字节位于内存的开头而不是末尾。
为什么是倒着的?
根据杰出的 Wikipedia:
In 1726, Jonathan Swift described in his satirical novel Gulliver’s
Travels tensions in Lilliput and Blefuscu: whereas royal edict in
Lilliput requires cracking open one's soft-boiled egg at the small
end, inhabitants of the rival kingdom of Blefuscu crack theirs at the
big end, giving them the moniker Big-endians. The terms little-endian
and endianness have a similar intent.
因此,如果我们在这种情况下查看它,则 x 端是从 x 端开始的。因此,big-endian 是从 "big" 结尾开始的人,可以这么说,反之亦然。
它使用 "end" 表示 "adjacent to an extremity",就像:
- 你点蜡烛的两端,而不是开始和结束。
- 一条面包有两个端片,但没有端片。
- 您可以坐在 table 的两端,但不能坐在起点和终点。
像1234567这样的数字有两端,你可以先存大端(一百万)或小端(七)。
通常说内存(或内存段)的"end"地址最高。例如:程序计数器通常递增(而不是递减)并且代码从"start"执行到"end",因此程序末尾的指令位于最高地址(而不是最低地址) ).
BigEndian 约定指定 最大 字节(即最高有效字节)位于最低地址(即内存的开始)。不应该反过来吗?这是大结束ian,不是大开始ian.
同样,LittleEndian 指定最小字节位于内存的开头而不是末尾。
为什么是倒着的?
根据杰出的 Wikipedia:
In 1726, Jonathan Swift described in his satirical novel Gulliver’s Travels tensions in Lilliput and Blefuscu: whereas royal edict in Lilliput requires cracking open one's soft-boiled egg at the small end, inhabitants of the rival kingdom of Blefuscu crack theirs at the big end, giving them the moniker Big-endians. The terms little-endian and endianness have a similar intent.
因此,如果我们在这种情况下查看它,则 x 端是从 x 端开始的。因此,big-endian 是从 "big" 结尾开始的人,可以这么说,反之亦然。
它使用 "end" 表示 "adjacent to an extremity",就像:
- 你点蜡烛的两端,而不是开始和结束。
- 一条面包有两个端片,但没有端片。
- 您可以坐在 table 的两端,但不能坐在起点和终点。
像1234567这样的数字有两端,你可以先存大端(一百万)或小端(七)。