




已阅读5页,还剩9页未读, 继续免费阅读
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
microprocessorsa microprocessor is a computation engine that is fabricated on a single chip. the first microprocessor was the intel 4004, introduced in 1971 .the 4004 was not very powerful all it could do was add and subtract, and it could only do that 4 bits at a time. but it was amazing that everything was on one chip. prior to the 4004, engineers built computers either from collections of chips or from discrete components. the 4004 powered one of the first portable electronic calculators.the first microprocessor to make it into a home computer was the intel 8080, a complete 8-bit computer on the chip, introduced in 1974. the first microprocessor to make a real splash in the market was the intel 8088 , introduced in 1979 and incorporated into the ibm pc. the pc market moved from the 8088 to the 80286 to the 80386 to the 80486 to the pentium to the pentium ii to the pentium iii to the pentium 4. all of these microprocessors are made by intel and all of them are improvements on the basic design of the 8088. the pentium 4 can execute any piece of code that ran on the original 8088, but it does it about 5,000 times faster!the following table shows the differences between the different processors that intel has introduced over the years.table1.2namedatetransistorsmicron1clockspeeddata width2mips3808019746,00062 mhz8 bits0.648088197929,00035 mhz16 bits8-bit bus0.33802861982134,0001.56 mhz16 bits1803861985275,0001.516 mhz32 bits58048619891,200,000125 mhz32 bits20pentium19933,100,0000.860 mhz32 bits64-bit bus100pentium ii19977,500,0000.35233 mhz32 bits64-bit bus300pentium iii19999,500,0000.25450 mhz32 bits64-bit bus510pentium 4200042,000,0000.181.5 ghz32 bits64-bit bus1,700from this table you can see that, in general, there is a relationship between clock speed and mips. the maximum clock speed is a function of the manufacturing process and delays within the chip. there is also a relationship between the number of transistors and mips. for example, the 8088 clocked at 5 mhz but only executed at 0.33 mips(about one instruction per 15 clock cycles). modern processors can often execute at a rate of two instructions per clock cycle. that improvement is directly related to the number of transistors on the chip.inside a microprocessor a microprocessor executes a collection of machine instructions that tell the processor what to do. based on the instruction, a microprocessor does three basic things:1. using its alu (arithmetic/logic unit), a microprocessor can perform mathematical operations like addition, subtraction, multiplication and division. modern microprocessors contain complete floating point processors that can perform extremely sophisticated operations on large floating point numbers.2. a microprocessor can move data from one memory location to another.3. a microprocessor can make decisions and jump to a new set of instructions based on those decisions.these may be very sophisticated things that a microprocessor does, but those are its three basic activities. the following diagram shows an extremely simple microprocessor capable of doing those three things:this microprocessor has an address bus that sends an address to memory, a data bus that can send data to memory or receive data from memory, an rd (read) and wr (write) line to tell the memory whether it wants to set or get the addressed location, a clock line that lets a clock pulse sequence the processor and a reset4 line that resets the program counter to zero (or whatever) and restarts execution. and lets assume that both the address and data buses are 8 bits wide here.here are the components of this simple microprocessor (figure 1.1):figure 1.11. registers a, b and c are simply latches made out of flip flops.2. the address latch is just like registers a, b and c.3. the program counter is a latch with the extra ability to increment by 1 when told to do so, and also to reset to zero when told to do so.4. the alu could be as simple as an 8 - bit adder, or it might be able to add, subtract, multiply and divide 8 bit values. lets assume the latter here.5. the test register is a special latch that can hold values from comparisons performed in the alu. an alu can normally compare two numbers and determine if they are equal, if one is greater than the other, etc. the test register can also normally hold a carry bit from the last stage of the adder. it stores these values in flip-flops and then the instruction decoder can use the values to make decisions.6. there are six boxes marked “3-state” in the diagram. these are tri-state buffers5. a tri-state buffer can pass a 1, a 0 or it can essentially disconnect its output. a tri-state buffer allows multiple outputs to connect to a wire, but only one of them to actually drive a 1 or a 0 onto the line.7. the instruction register and instruction decoder are responsible for controlling all of the other components.although they are not shown in this diagram, there would be control lines from the instruction decoder that would:1. tell the a register to latch the value currently on the data bus2. tell the b register to latch the value currently on the data bus3. tell the c register to latch the value currently on the data bus4. tell the program counter register to latch the value currently on the data bus 5. tell the address register to latch the value currently on the data bus6. tell the instruction register to latch the value currently on the data bus7. tell the program counter to increment8. tell the program counter to reset to zero9. activate any of the six tri-state buffers (six separate lines)10. tell the alu what operation to perform11. tell the test register to latch the alus test bibs12. activate the rd line 13. activate the wr linecoming into the instruction decoder are the bits from the test register and the clock line, as well as the bits from the instruction register.ram and rom the address and data buses, as well as the rd and wr lines connect either to ram or rom-generally both. in our sample microprocessor, we have an address bus 8 bits wide and a data bus 8 bits wide. that means that the microprocessor can address (28) 256 bytes of memory, and it can read or write 8 bits of the memory at a time. lets assume that this simple microprocessor has 128 bytes of rom starting at address 0 and 128 bytes of ram starting at address 128.rom stands for read-only memory. a rom chip is programmed with a permanent collection of pre-set bytes. the address bus tells the rom chip which byte to get and place on the data bus. when the rd line changes state, the rom chip presents the selected byte onto the data bus.ram stands for random-access memory. ram contains bytes of information, and the microprocessor can read or write to those bytes depending on whether the rd or wr line is signaled. one problem with todays ram chips is that they forget everything once the power goes off. that is why the computer needs rom.by the way, nearly all computers contain some amount of rom (it is possible to create a simple computer that contains no ram-many microcontrollers do this by placing a handful of ram bytes on the processor chip itself-but generally impossible to create one that contains no rom). on a pc, the rom is called the bios (basic input/output system). when the microprocessor starts, it begins executing instructions it finds in the bios. the bios instructions do things like test the hardware in the machine, and then it goes to the hard disk to fetch the boot sector. this boot sector is another small program, and the bios stores it in ram after reading it off the disk. the microprocessor then begins executing the boot sectors instructions from ram. the boot sector program will tell the microprocessor to fetch something else from the hard disk into ram, which the microprocessor then executes, and so on. this is how the microprocessor loads and executes the entire operating system.microprocessor instructions even the incredibly simple microprocessor shown here will have a fairly large set of instructions that it can perform. the collection of instructions is implemented as bit patterns, each one of which has a different meaning when loaded into the instruction register. humans are not particularly good at remembering bit patterns, so a set of short words are defined to represent the different bit patterns. this collection of words is called the assembly language of the processor. an assembler can translate the words into their bit patterns very easily, and then the output of the assembler is placed in memory for the microprocessor to execute. if you use c language programming, a c compiler will translates the c code into assembly language.so now the question is, “how do all of these instructions look in rom?” each of these assembly language instructions must be represented by a binary number . these numbers are known as opcodes. the instruction decoder needs to turn each of the opcodes into a set of signals that drive the different components inside the microprocessor. lets take the add instruction as an example and look at what it needs to do:during the first clock cycle, we need to actually load the instruction. therefore the instruction decoder needs to:activate the tri-state buffer for the program counteractivate the rd lineactivate the data-in tri-state bufferlatch the instruction into the instruction registerduring the second clock cycle, the add instruction is decoded. it needs to do very little:set the operation of the alu to additionlatch the output of the alu into the c register during the third clock cycle, the program counter is incremented (in theory this could be overlapped into the second clock cycle).every instruction can be broken down as a set of sequenced operations like these that manipulate the components of the microprocessor in the proper order. some instructions, like this add instruction, might take two or three clock cycles. others might take five or six clock cycles.microprocessor performance the number of transistors available has a huge effect on the performance of a processor. as seen earlier, a typical instruction in a processor like an 8088 took 15 clock cycles to execute. because of the design of the multiplier, it took approximately 80 cycles just to do one 16-bit multiplication on the 8088. with more transistors, much more powerful multipliers capable of single-cycle speeds become possible.more transistors also allow for a technology called pipelining6. in a pipelined architecture, instruction execution overlaps. so even though it might take five clock cycles to execute each instruction, there can be five instructions in various stages of execution simultaneously. that way it looks like one instruction completes every clock cycle.many modern processors have multiple instruction decoders, each with its own pipeline. this allows for multiple instruction streams, which means that more than one instruction can complete during each clock cycle. this technique can be quite complex to implement, so it takes lots of transistors.the trend in processor design has been toward full 32-bit alus with fast floating point processors built in and pipelined execution with multiple instruction streams. there has also been a tendency toward special instructions that make certain operations particularly efficient. there has also been the addition of hardware virtual memory support and l1 caching on the processor chip. all of these trends push up the transistor count, leading to the multi-million transistor powerhouses available today. these processors can execute about one billion instructions per second!微处理器微处理器是建在一块芯片上的一个计算器,1971年因特尔公司推出世界上第一款微处理器intel4004。intel4004功能不齐全,它只能做加减,并且一次只能处理4位,但令人吃惊的是一切都在一块芯片上。在intel 4004之前,工程师利用芯片或其他零部件开发计算机,从此揭开了微型计算机发展的序幕。1974年,利用intel8088微处理开始生产家用电脑,它能处理8个二进制数,1979年推出的intel8088,第一次打开了市场。ibm公司运用这块芯片推出了个人电脑,电脑发展经历了8088、80286、80386、80486、奔腾、奔腾ii、奔腾iii、奔腾4,所有这些微处理都是因特尔公司生产的,它们都是在8088的设计基础上开发的,奔腾4能执行8088上的任一套指令,但是它比8088快5000倍。从以下表格我们可以看出因特尔公司近几年来所生产的各种处理器。(表格2)名 称时间晶体管数量微 米时钟频率数据位宽mips3808019746,00062 mhz8 位0.648088197929,00035 mhz16位8-位总线0.33802861982134,0001.56 mhz16位1803861985275,0001.516 mhz32位58048619891,200,000125 mhz32位20奔腾19933,100,0000.860 mhz32位64-位总线100奔腾ii19977,500,0000.35233 mhz32位64-位总线300奔腾iii19999,500,0000.25450 mhz32位64-位总线510奔腾4200042,000,0000.181.5 ghz32位64-位总线1,700从这个表中,大体可以看出时钟频率和mips之间存在一定的关系,最大的时钟频率是生产进程的一个函数,并且它在芯片内会延迟,晶体管和mips之间有一定的关系,例如8088在5兆赫兹时就运行一次,但只是以0.33mips的速度来执行(大于每15时钟周期执行一条指令)。现在的处理器通常能达到每一个时钟周期执行两条指令的速度,那种运算速度的提高与芯片上的晶体管数量有直接关系。微处理器的内部结构:微处理器执行告诉处理器该做什么的一系列的机器指令,在这个指令的基础上,微处理器完成3个基本的功能:1、微处理器用它的算术逻辑单元,能够完成像加减乘除这一系列算术操作,现在的微处理器包含有完整的浮点处理器,它们能够完成非常复杂的浮点数的操作。2、微处理器能把数据从一个存储单元移到另一个存储单元。3、微处理器能做出决定,并且在那些决定的基础上发出一系列新的指令。这些或许就是微处理器能完成的复杂的功能,但那些仅是它的3个基本功能,下面的图表说明微处理器是如何执行这些简单功能的:微处理器有地址总线,它把地址送到储存器,它还有一个数据总线,把数据送到储存器或者从储存器里接收数据,它也有读写总线,告诉储存器是想设置还是想取出这个定了位置的储存单元,它还有时钟线,告诉时钟脉冲记录处理器的结果,以及重新设置线把编码器重新设置到零(或者其他什么的)以及重新执行命令。我们假定这儿的位置和数据总线均为8位宽。下面是这个简单微处理器的结构表:(图表1.1)图表1.11、记录器a,b和c 都是构成触发器的简单的锁存器。2、位置锁恰好记录器a,b和c。3、编码计算器是具有特别递增能力的锁,当接到指令时,它就增加1或者重新设置到零。4、数据逻辑单元可能和8位的加法器一样简单,或者它可能会做加、减、乘和除8位数值,我们假定这儿属于后者。5、检测记录器是一个特殊的锁,它能够把经过比较的数值锁在算术逻辑单元里,算术逻辑单元就能正常的比较两个数字,并判断他们是否相等,是否一个大于另一个等,检测记录器也能正常锁住一个阶段加法的进位位,它把这些数值储存在触发器上,然后信息译码器能用这些数值来做出判断。6、图表中6个标注了“3state”的方框,这些是三态缓冲器,它能传递a 1 ,a 0 或者它能基本上断开它信息的输出,它允许多个信息输出,连接到电源线,但是他们中只有一个能准确驱动a 1 或a 0 到流水线上去。7、信息记录器和译码器要控制其余所有的部件。虽然这些图表上没有显示这些结构,但是信息译码里将有控制线做以下事情:1、告诉a记录器锁定当前数据总线上的数值2、告诉b记录器锁定当前数据总线上的数值3、告诉c记录器锁定当前数据总线上的数值4、告诉编码计算器锁定当前数据总线上的数值5、告诉位地址记录器锁定当前数据总线上的数值6、告诉信息记录器 锁定当前数据总线上的数值7、告诉编码计算器增加数值8、告诉编码计算器重新设置到零9、激活6个三态缓冲器中的任意一个 10、告诉算术逻辑单元该执行什么指令11、告诉检测记录器锁定算术逻辑单元的检测结果12、激活rd线13、激活wr线进入信息译码器的是那些检测记录器,时钟流水线以及信息记录器里面的二进制数字行大约十亿条指令。随机存贮器、只读存贮器、位址和数据总线。读、写一般说来都与随机存贮及只读存贮有关。在我们的样本微处理器中,我们有8位总线地址宽,8位数据总线宽,那意味着微处理器能存入(28)256个字节,它一次能读或写8个二进字位,我们假定这个简单的微处理器只读存贮0开始的位置上有128个字节及随机存
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 采石场承包合同范本及资源保护与利用协议
- 招生团队协议书范本
- 民族风情步行街个人店铺租赁与文化传承合同
- 餐饮场地租赁合同范本:包含租赁合同终止及清算条款
- 代理人协议书范本
- 拆除工程临时交通疏导合同范本
- 宠物寄养买卖协议书范本
- 餐饮行业厨师劳务派遣与菜品创新合同
- 资产清算拍卖委托代理合同书范本
- 水利设施拆除工程安全监管协议
- 智能包装设计知到课后答案智慧树章节测试答案2025年春湖南工业大学
- 学校校长聘任合同
- SJG 75-2020 装饰工程消耗量定额
- 海岸带资源开发与评价知到智慧树章节测试课后答案2024年秋宁波大学
- 滴滴网约车出行品牌-品牌视觉识别手册【出行打车】【VI设计】
- 2025年贵州贵阳市城市发展投资集团股份有限公司招聘笔试参考题库附带答案详解
- 反应釜设备知识培训课件
- 《危险房屋鉴定标准JGJ125-2016》
- 汽车制造业廉政风险控制措施
- 2025年甘肃省农垦集团限责任公司招聘428人历年高频重点提升(共500题)附带答案详解
- 生物制造产业园项目实施规划与进度安排
评论
0/150
提交评论