Data Organization
1. 进制转换。
按照正常的书写顺序写一个数字(无论多少进制),其中最左边的列称为“最高有效符号”,最右边的列称为“最低有效符号”。
(The right-most column is called
the least significant symbol, and the left-most column is called
the most significant symbol.)
二进制、十进制与十六进制转换表,学过数电一定对这个很熟悉~
2. Data sizes
在存储
多字节数据时,有“大端法”和“小端法”两种模式,区别在于把放置“最高有效符号”和“最低有效符号”的顺序。
(Computers differ in how they organize multiple-byte values. Some of them use
big-endian ordering and put the most significant byte of the number in the first storage byte, and others use
little-endian ordering and put the least significant byte of the number in the first storage byte.)
二者的区别可从这张图上很直观的看出来
3. 字符编码
为了存储非数值类型的数据(字符),我们以各种标准来编码字符,比如ASCII和Unicode
(...to stores letters and sentences. The most common technique is to encode the characters
using ASCII or Unicode.)
ASCII码由于只占一个字节,因此不受大小端模式的影响。
(The endian ordering of a system does not play a role in how the characters are stored because these are separate 1-byte values.)
4. 数据结构
数据结构描述了数据的布局(或者我理解为一种协议),程序根据这些约定好的布局,访问特定数据域得到目标值。
(Computers know the layout of the data because of data structures.
A data structure describes how data are laid out. It works like a template or map.
The data structure is broken up into
fields, and each field has a size and name, although this information is not saved with the
data.)
5. 标志位
有时需要的信息是二值的,一个位即可存储,然而计算机的最小存储单位是字节,这时可把若干位组合成一个字节,每一位称作一个标志位。
(这时各种强大的位运算可以大显身手了~)
(A more efficient
method is to pack several of these binary conditions into one value. Each bit in the value
corresponds to a feature or option.)
Booting Process
下图虚线描述了计算机通电后控制权的转交过程,即BIOS->MBR->VBR->OS中的引导代码