1、Chapter 2 Computer System Organization,2/32,New Words & Expressions: memory subsystem 内存子系统 I/O subsystem 输入/输出子系统 bus 总线 system bus 系统总线 chip 芯片 address bus 地址总线 instructions 指令 memory location 存储单元 data bus 数据总线 control bus 控制总线 local bus 局部总线 microprocessor 微处理器 register set 寄存器组 arithmetic logic
2、 unit(ALU) 运算器 clock cycle 时钟周期 control unit 控制器 computer architecture计算机体系结构 instruction format 指令格式 addressing modes 寻址方式 instruction set 指令集 internal memory 内存 main memory 主存 secondary storage 辅助存储器 virtual memory 虚拟存储器 refresh circuitry 刷新电路 cache memory 高速缓冲存储器 masked ROM 掩模ROM ultraviolet ligh
3、t 紫外线 flash EEPROM 快闪存储器,Basic Technical Words and expressions,3/32,New Words & Expressions: memory hierarchy 存储器体系结构 auxiliary memory 辅助存储器 storage capacity 存储容量 keyboard 键盘 alphanumeric key 字母数字键 function key 功能键 cursor key 光标键 numeric keypad 数字键 mouse 鼠标 touch screens 触摸屏 infrared ray 红外线 monitor
4、 监视器 display screen 显示屏 laser printer 激光打印机 ink-jet printer 喷墨打印机 dot-matrix printer 点阵式打印机 modem 调制解调器 peripherals 外部设备 input-output interface (I/O interface) 输入输出接口 interrupt 中断 program counter 程序计数器 vectored interrupt 向量中断 nonvectored interrupt 非向量中断 interrupt vector 中断向量 timeout 超时,Basic Technic
5、al Words and expressions,4/32,Basic Technical Words and expressions,Abbreviations: I/O subsystem (Input/Output subsystem) 输入输出子系统ALU (arithmetic logic unit)运算器(算术逻辑单元) RAM (Random Access Memory)随机存取(访问)存储器 ROM (Read Only Memory)只读存储器 DRAM (Dynamic RAM) 动态RAM SRAM (Static RAM)静态RAM PROM (Programmable
6、 ROM) 可编程ROM EPROM (Erasable Programmable ROM)可擦写PROM EEPROM ( Electrical Erasable Programmable ROM) 电可擦写PROM BIOS (Basic input output system)基本输入/输出系统 DMA (Direct Memory Access ) 直接存储器存取,5/32,2.1 Basic Organization of Computers,Fig.2-1 computer organization,6/32,2.1 Computer Organization Introducti
7、on,The memory subsystem is used to store program being executed by the CPU, along with the programs data. The I/O subsystem allows the CPU to interact with input and output devices, such as the keyboard and monitor of a personal computer.,存储子系统用于存储被CPU执行的程序及其数据。I/O子系统可使CPU和输入/输出设备交互,比如个人计算机的键盘和显示器。,
8、7/32,To send information from one component to another, the source component outputs data onto the bus. The destination component then inputs this data from the bus. As the complexity of a computer system increases, it becomes more efficient at using buses rather than direct connections between ever
9、y pair of devices.,2.2 System Buses,为了从一个部件向其他部件发送信息,源部件输出数据到总线,目标部件从总线上输入这一的数据。随着计算机系统复杂性的不断提高,使用总线比各个设备直接相连更加有效。,8/32,When the CPU reads data or instructions from or writes data to memory, it must specify the address of the memory location it wishes to access. It outputs this address to the addres
10、s bus; memory inputs this address from the address bus and use it to access the proper memory location. Unlike the other buses, the address bus always receives data from the CPU; the CPU never reads the address bus.,当CPU从存储器读取数据或指令,或写数据到存储器时,它必须指明将要访问的存储器单元地址。CPU将地址输出到地址总线上,而存储器从地址总线上读取地址,并且用它来访问正确的
11、存储单元。 与其他总线不同,地址总线总是从CPU上接收信息,而CPU从不读取地址总线。,1. Address Bus,9/32,Data is transferred via the data bus. When the CPU fetches data from memory, it first outputs the memory address on its address bus. Then memory outputs the data onto the data bus, the CPU can then read the data from the data bus. When
12、writing data to memory, the CPU first outputs the address onto the address bus, then outputs the data onto the data bus.,数据是通过数据总线传送的。当CPU从存储器中取数据时,它首先把存储器地址输出到地址总线上,然后存储器将数据输出到数据总线上,这样CPU就可以从数据总线上读取数据了。当CPU向存储器中写数据时,它首先将地址输出到地址总线上,然后把数据输出到数据总线上。,2. Data Bus,10/32,These signals indicate whether data
13、 is to be read into or written out of the CPU, whether the CPU is accessing memory or an I/O device, and whether the I/O device or memory is ready to transfer data. Most of these signals are output from the CPU to the memory and I/O subsystems, and a few are output by these subsystems to the CPU.,这些
14、信号用来指示数据是要读入CPU还是要从CPU写出,CPU是要访问存储器还是要访问I/O设备,是I/O设备还是存储器已就绪要传送数据等等。 大多数信号是从CPU输出到存储器与I/O子系统的,只有少数是从这些子系统输出到CPU的。,3. Control Bus,11/32,1.Register Set The relatively simple CPU includes registers to latch the address being accessed in memory and a temporary storage register, as well as other register
15、s that are not a part of its instruction set architectures.,1.寄存器组 相对简单的CPU包含用来闭锁在内存中被访问到地址的寄存器、临时存储寄存器以及其他不是指令系统结构组成部分的寄存器。,2.3 CPU ORGANIZATION,12/32,2.ALUThe arithmetic logic unit, or ALU, performs most arithmetic and logical operations, such as adding or ANDing values. Since the ALU must complet
16、e its operations within a single clock cycle, it is constructed by using only combinational logic.,2.ALU 算术逻辑单元(ALU)执行大多数的算术和逻辑操作,诸如“加”或“与”操作。由于ALU必须在单个周期内完成运算,所以ALU仅使用一个组合逻辑来构成。,2.3 CPU ORGANIZATION,13/32,3.Control Unit The Control unit ,or CU, supervises the transfer of information among the regis
17、ters and instructs the ALU as to which operation to perform.,3、控制单元 控制单元(CU)控制寄存器之间的信息传输和指示ALU完成操作。,2.3 CPU ORGANIZATION,14/32,2.4 Memory Subsystem Organization,Memory is also known as internal memory or main memory. It refers to the circuits in the computer that hold whatever programs and data are
18、available for immediate use by the CPU,存储器也被称为内存或主存。它指在计算机中存储CPU可以直接使用的任何程序和数据的电路。,15/32,Unlike ROM, RAM is erasable, temporary, and volatile- meaning that it blanks out each time you turn the computer off.,2.4.1 Types of Memory,与ROM不同,RAM是可擦写的、临时的和易失的-意为每次关机时它都将清空。,16/32,2.4.1 Types of Memory,To st
19、retch the amount of RAM, an operating system can use a strategy called virtual memory that reserves part of the hard disk for use as an extension to RAM.,为了扩展内存,操作系统可以使用一种被称为虚拟存储器的策略,该策略使用部分硬盘空间作为RAM的扩展。,17/32,2.4.1 Types of Memory,(1)DRAM Initially data is stored in the DRAM chip, charging its memo
20、ry cells to their maximum values. The charges slowly leaks out and would eventually go too low to represent valid data.,当初始数据被存储在DRAM芯片中时,存储单元的电荷达到最大值,电荷慢慢泄漏以致太低而不能表示正确的数据。,18/32,2.4.1 Types of Memory,(2)SRAM Static RAM, or SRAM, is more like a register than a leaky capacitor. Once data is written t
21、o SRAM, its contents stay valid, and it does not have to be refreshed.,静态RAM(SRAM)与泄露电荷的电容器相比更像寄存器。一旦数据写入SRAM,内容保持正确,而且不需要重新刷新。,19/32,(1) Masked ROM A masked ROM, or simply a ROM, is programmed with data as the chip is fabricated. These chips are useful for consumer appliances, where large number of
22、 units are produced, and, once installed, data will not be changed.,(1)掩模ROM 掩模ROM或简单的ROM, 在制作芯片时程序数据就被固化。这些芯片对那些批量生产并且一旦装入数据便不可改变的用户产品非常有用。,20/32,(3) EPROM A EPROM is an erasable PROM, These chips have a small clear window on their faces. The chip is erased by being placed under ultraviolet light t
23、hat causes the capacitors to leak their charge, thus we can reset the chips contents.,(3)EPROM EPROM是可擦写的PROM。 这些芯片在表面有一个小的透明窗口, 芯片放在紫外线下照射导致电容器露电而被擦除,这样就可以重新设置芯片内容。,21/32,(4) EEPROM or E2PROM A EEPROM, sometimes denoted as E2PROM, is an electrically erasable PROM.,(4) EEPROM or E2PROM EEPROM, 有时表示为
24、E2PROM,是电擦写PROM。,22/32,(5) Flash EEPROM A special type of EEPROM called a flash EEPROM is electrically erasable in blocks of data, rather than individual locations.,(5)Flash EEPROM 一种特殊类型的EEPROM被称为快闪EEPROM,它是以电擦除方式擦除大块数据,而不是单独的单元。,23/32,The memory hierarchy system consists of all storage devices emp
25、loyed in a computer system from the slow but high-capacity auxiliary memory to a relatively faster main memory, to a even small and faster cache memory accessible to the high-speed processing logic.,2.4.2 Memory hierarchy,存储器分级体系包括在计算机系统中的所有存储设备,从低速但容量高的辅助存储器到相对较快的主存,到更小更快的靠近高速处理逻辑的高速缓冲存储器。,24/32,2.
26、4.2 Memory hierarchy,A special very-high-speed memory called a cache is sometimes used to increase the speed of processing by making current programs and data available to the CPU at a rapid rate.,有时使用一种被称为高速缓存(Cache)的高速存储器使CPU可以快速地存取当前的程序和数据。,25/32,2.4.2 Memory hierarchy,CPU logic is usually faster
27、 than main memory access time, with the result that processing speed is limited primarily by the speeds of main memory.,CPU 通常比主存的存取时间更快,以致处理器速度主要受限于主存速度。,26/32,2.5 I/O Subsystem Organization,1、KeyboardsThe precise purpose of any function key varies from one program to another. Cursor keys are used
28、to move the cursor around on the screen. The cursor is the little blinking symbol that indicates where things will happen next on the screen.,每个功能键的精确定义随程序不同而不同。光标键用于在屏幕上移动光标,光标是小的闪烁符号,它在屏幕上显示将要发生事情的位置。,2.5.1 I/O Devices,27/32,2、Mouse Depending on the sensing method used by the touch screen, your fi
29、nger might interrupt a network of infrared rays protected across the screens surface.,依靠触摸屏上使用的传感方法,手指可以打断保护屏幕表面的红外线网络。,2.5.1 I/O Devices,28/32,3、Monitor A monitor, or display screen, provides a convenient but temporary way to view information.,监视器或显示屏提供方便的但临时的观看信息方法。,2.5.1 I/O Devices,4、Printers So
30、me printers squirt ink, some apply heat to sensitive paper, other hammer inked ribbons, and still others create images with lasers.,有的打印机使用喷墨技术;有的使用热感技术;有的使用击打色带技术;还有的使用激光产生图像。,29/32,2.5.1 I/O Devices,5、Modem The modem converts a computers electronic impulses to a form that can be transmitted over a
31、 telephone line. When the signal reaches the destination computer, another modem reconverts the signal to computer understandable form.,调制解调器将计算机的电子脉冲转换成电话线可以传输的格式,当信号到达目的计算机时,另一个调制解调器将信号重新转换为计算机可以识别的格式。,30/32,2.5.3 Modes of Transfer 1.Programmed I/O,Once a data transfer is initiated, the CPU is req
32、uired to monitor the interface to see when a transfer can again be made.It is up to the programmed instructions executed in the CPU to keep close tabs on everything that is taking place in the interface unit and the I/O device.It can be avoided by using an interrupt request signal when the data are
33、available from the device.,一旦数据传输开始,CPU需要监控接口来发现什么时候可以再传输。在CPU中执行的程序化指令密切监视发生在接口单元和I/O设备中的所有事情。当来自于设备的数据可用时,通过使用一条中断需求信号,它是可以避免的。,31/32,2.Interrupts,The CPU responds to the interrupt signal by storing the return address from the program counter into a memory stack and then controls branches to a ser
34、vice routine that processes the required I/O transfer.,CPU 通过把程序计数器中的返回地址保存到存储器堆栈,从而响应中断信号,然后控制跳转分支到处理I/O传输要求的服务程序。,32/32,3.Direct memory access (DMA),Another aspect of computer system performance that can be improved is the transfer of data between memory and I/O devices. The CPU does not modify the data at all, so it only serves as an additional stop for data on the way to its final destination.,可以提高计算机系统性能的另一种方法是在存储器和I/O设备之间传输数据。CPU根本不修改数据,它只是在数据通向最后目的地过程中起到附加保留的作用。,