计算机组成中一些值得注意的地方

1、Some would say that the CPU is what actually does the work, but while
largely true, it’s an oversimplification. Plenty of real work is done in the
memory system, and in what are called peripherals, such as video display
boards, USB and network ports, and so on. So, while the CPU does do a good
deal of the work, it also parcels out quite a bit to other components within the
computer, largely to enable itself to do a lot more quickly what it does best.
Like any good manager, the foreman delegates to other computer subsystems
whatever it can.

2、32位CPU虽然每次读取32bit的数据,但是在Memory中,每个byte都有其独立的地址。

3、If the CPU is the shop foreman, then the peripherals are the assembly-line
workers, and the data bus is the assembly line itself. (Unlike most assembly
lines, however, the foreman works the line much harder than the rest of his
crew!)

4、Acomputer program is nothingmore than a table of these machine instructions
stored in memory. There’s nothing special about the table, nor about where it
is positioned in memory. It could be almost anywhere, and the bytes in the
table are nothing more than binary numbers.

5、The soul of a CPU is pretty cleanly divided into
two parts: what the CPU does and how the CPU does it. We, as programmers,
see it from the outside: what the CPU does.

6、The real job of a CPU, and the real challege of assembly language, lies in locating the required instructions and data in memory.

The skill of assembly language consists of deep comprehension of memory addressing.

7、Real mode segmented model: one of the 3 memory model.

paragraph, paragraph boundary, segment, segment address.

In summary: segments may begin at any segment address. There are 65,536
segment addresses evenly distributed across real mode’s full megabyte of
memory, sixteen bytes apart. A segment address is more a permission than
a compulsion; for all the 64K possible segment addresses, only five or six
are ever actually used to begin segments at any one time. Think of segment
addresses as slots where segments may be placed.

8、All segment registers are 16 bits in size,
irrespective of the CPU. This is true even of the 32-bit CPUs. :CS DS SS FS GS

CS: Code Segment

DS: Data Segment

SS: Stack Segment. The stack is a very important component of the CPU used for temporary storage of data and addresses.

ES: Extra Segment

FS and GS are clones of ES. They exist only in the 386 and later x86 CPUs.

9、General purpose registers:

16-bit: AX   BX   CX   DX   BP   SI   DI   SP

32-bit: EAX EBX ECX EDX EBP ESI EDI ESP

The 16-bit register is in the lower position of the 32-bit register.

The AX BX CX DX registers divide into two parts such as AH(high half) and AL(low half)

image

image

ESP: Stack Pointer

EBP: Base Pointer

10、Instruction pointer register:(usually called IP or, in 32-bit protected mode, EIP)

11、Real mode segmented model:

In practice you can have any reasonable number of code and data segments.

You only have one code segment register, CS.

原文地址:https://www.cnblogs.com/wangshuo/p/1935924.html