【正文】
emory and execute them. To perform the actions of fetch and e x e c u t e , a l l C P U s a r e e q u i p p e d w i t h resources such as follows. Inside the puter Inside CPUs CHAPTER 0 ? Register ? ALU (arithmetic/logic unit ) ? Program counter ? Instruction decoder Inside the puter Inside CPUs CHAPTER 0 ? Foremost among the resources at the disposal of the CPU are a number of registers. The CPU uses registers to store information temporarily. ? The CPU also has what is called ALU (arithmetic/logic unit). The ALU section of the CPU is responsible for performing arithmetic functions such as add, subtract, multiply, and divide, and logic function such as AND, OR, and NOT. Inside the puter Inside CPUs CHAPTER 0 ? Every CPU has what is called a program counter. The function of the program counter is to point to the address of the next instruction to be executed. It is the contents of the program counter that are placed on the address bus to find and fetch the desired instruction. In the IBM PC, the program counter is a register called IP, or the instruction pointer. ? The function of the instruction decoder is to interpret the instruction fetched into the CPU. CHAPTER 0 Inside the puter Internal working of puters CHAPTER 0 The action to be performed by the CPU is to put hexadecimal value 21 into register A, and then add to register A values 42H and 12H. Action Code Data Move value 21H into register A B0H 21H Add value 42H to register A 04H 42H Add value 12H to register A 04H 12H If the program to perform the actions listed above is stored in memory locations starting at 1400H, the following would represent the contents for each memory address location. Memory address Contents of memory address 1400 (B0) the code for moving a value to register A 1401 (21) the value to be moved 1402 (04) the code for adding a value to register A 1403 (42) the value to be moved 1404 (04) the code for adding a value to register A 1405 (12) the value to be moved 1406 (F4) the code for halt CHAPTER 0 CISC and RISC Brief History of the CPU CISC is plex instruction set puter, with hundreds of instructions designed for every possible situation. RISC is reduced instruction set puter, the saved transistors are used to enhance the power of PC. Review Questions (思考題 ) CHAPTER 0 1. What is a “stored program puter” (the von Neumann Machine)? 2. What is the “puter architecture” and what is the “puter anization”? Next Lesson CHAPTER 0 Instruction Sets (指令集)