CS 161Computer Architecture Chapter 5Lecture 9.ppt

  1. 1、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。。
  2. 2、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载
  3. 3、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
CS 161Computer Architecture Chapter 5Lecture 9.ppt

CS 161Computer Architecture Chapter 5 Lecture 9 Instructor: L.N. Bhuyan /~bhuyan Adapted from notes by Dave Patterson (/~patterson) Where We Are: Machine Organization MIPS-lite processor Want to build a processor for a subset of MIPS instruction set (“MIPS-lite”) just enough to illustrate key ideas instruction set subset (3 groups): arithmetic-logical: add, sub, and, or, slt memory reference: lw, sw control flow: j, beq can we write real programs with just these? Need up to 5 steps to execute any instruction in our subset: Step 1: fetch instruction Step 2-5: ? Instruction Execution Steps 1. Read IM[PC] 2. Instruction Decode, PC = PC + 4, Register read ALU operation, Branch address computation LW/STORE in Data memory Register Write building a Datapath for MIPS (step 1) Datapath Step 1: any instruction building a Datapath for MIPS (step 2) Datapath Step 2: any instruction Up to 5 Steps in Executing MIPS Subset 3rd step onwards depends on instruction class EX: for ALU instructions, add $t0, $t1, $t2 outputs from registers t1 and t2 will be sent to the ALU input. For Memory-reference instruction: Address ? Base + offset lw $t0,20($s0) building a Datapath for MIPS (lw step 3) Datapath Step 3-4: R-format Instructions Datapath Step 3: Branch Datapath Step 3: Branch Up to 5 Steps in Executing MIPS Subset 4th step depends on instruction class Ex: for lw: Fetch Data from Memory Data ? Mem[Address] For sw: Put the contents of a register in Memory Datapath Step 3-5: Load/Store Compose Datapath: R-form + Load/Store .* 1999 ?UCB Personal Computer Processor (CPU) Computer Control (“brain”) Datapath (“brawn”) Memory Devices Input Output Arithmetic- Logic Unit (ALU) Chap. 7 (done) Chap. 8 Processor = Chaps. 5 NOW Chap 5 : 2 weeks Chap 6 : 1 week Chap 7 : 3 weeks Instruction Fetch Decode, Inc PC and Read Registers ALU Operation, Branch address Data Memory operation Write Back PC Memory Step 1 . . . add $t0,$t0,$t0 add $t0,$s1,$t0 lw $t1,20($s0)

文档评论(0)

gshshxx + 关注
实名认证
内容提供者

该用户很懒,什么也没介绍

1亿VIP精品文档

相关文档