1. Trang chủ
  2. » Luận Văn - Báo Cáo

Giao trinh bai tap chương 1 mở đầu

55 501 0

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 55
Dung lượng 1,87 MB

Nội dung

dce 2015 COMPUTER ARCHITECTURE CSE Faculty of Computer Science and Engineering Department of Computer Engineering BK TP.HCM Vo Tan Phuong http://www.cse.hcmut.edu.vn/~vtphuong dce 2015 Chapter Introduction Computer Architecture – Chapter © Fall 2015 dce 2015 Presentation Outline • Welcome to CA CSE • Computer Architectures and Trends • High-Level, Assembly-, and Machine-Languages • Components of a Computer System • Chip Manufacturing Process • Programmer's View of a Computer System Computer Architecture – Chapter © Fall 2015 dce 2015 Welcome to CA CSE • Instructor: Võ Tấn Phương  Email: vtphuong@cse.hcmut.edu.vn • TA: Trần Thanh Bình  Email: thanhbinh.hcmut@gmail.com • Course Web Page: – http://www.cse.hcmut.edu.vn/~vtphuong/KTMT Computer Architecture – Chapter © Fall 2015 dce 2015 Which Textbook will be Used? • Computer Organization & Design: The Hardware/Software Interface – Fourth Edition – David Patterson and John Hennessy – Morgan Kaufmann Publishers, 2009 • Read the textbook in addition to slides Computer Architecture – Chapter © Fall 2015 dce 2015 Estimated Schedule • • • • • • • • • Introduction, Performance (1 week) Integer arithmetic, Floating Point Numbers (1 week) MIPS Instruction Set Architecture (3 weeks) MIPS Assembly Programming (1 weeks) Basic Digital Function Block, ALU (1 week) Single Cycle MIPS Processor (2 weeks) Pipelined MIPS Processor (2 weeks) Memory System (1 week) Cache Memory System (2 week) Computer Architecture – Chapter © Fall 2015 dce 2015 Course Learning Outcomes • Towards the end of this course, you should be able to … – Describe the instruction set architecture of a MIPS processor – Analyze, write, and test MIPS assembly language programs – Design the datapath and control of a single-cycle CPU – Design the datapath/control of a pipelined CPU & handle hazards – Describe the organization/operation of memory and caches – Analyze the performance of processors and caches • Required Background – Ability to program confidently in Java or C – Ability to design a combinational and sequential circuit Computer Architecture – Chapter © Fall 2015 dce 2015 Tentative Grading Policy • • Labs & Assignment 40% – MIPS assembly programming 20% – Design simple CPU 20% Mid Exam – • • Quiz questions, opened book Final Exam – 30% 40% Quiz questions, opened book Bonus by white board quick exercises (max + 2) Computer Architecture – Chapter © Fall 2015 dce 2015 Software Tools • MIPS Simulators – MARS: MIPS Assembly and Runtime Simulator • Runs MIPS-32 assembly language programs • Website: http://courses.missouristate.edu/KenVollmar/MARS/ – SPIM • Also Runs MIPS-32 assembly language programs • Website: http://www.cs.wisc.edu/~larus/spim.html • Design simple CPU – NandToTetris • Link: http://www.nand2tetris.org/course.php Computer Architecture – Chapter © Fall 2015 dce 2015 Presentation Outline • Welcome to CA CSE • Computer Architectures and Trends • High-Level, Assembly-, and Machine-Languages • Components of a Computer System • Chip Manufacturing Process • Programmer's View of a Computer System Computer Architecture – Chapter © Fall 2015 10 dce 2015 Magnetic Disk Storage A Magnetic disk consists of a collection of platters Provides a number of recording surfaces Read/write head Actuator Recording area Arm provides read/write heads for all surfaces The disk heads are connected together and move in conjunction Computer Architecture – Chapter Track Track Track Arm Direction of rotation Platter Spindle © Fall 2015 41 dce 2015 Magnetic Disk Storage Disk Access Time = Seek Time + Rotation Latency + Transfer Time Read/write head Sector Actuator Recording area Seek Time: head movement to the desired track (milliseconds) Rotation Latency: disk rotation until desired sector arrives under the head Transfer Time: to transfer data Computer Architecture – Chapter Track Track Track Arm Direction of rotation Platter Spindle © Fall 2015 42 dce 2015 Inside the Processor (CPU) Computer Architecture – Chapter © Fall 2015 43 Inside the Processor (CPU) • Datapath: part of a processor that executes instructions • Control: generates control signals for each instruction Clock Next Program Counter Instruction 2015 Program Counter dce Instruction Cache Registers A L U Data Cache Control Computer Architecture – Chapter © Fall 2015 44 dce 2015 Datapath Components • Program Counter (PC) – Contains address of instruction to be fetched – Next Program Counter: computes address of next instruction • Instruction and Data Caches – Small and fast memory containing most recent instructions/data • Register File – General-purpose registers used for intermediate computations • ALU = Arithmetic and Logic Unit – Executes arithmetic and logic instructions • Buses – Used to wire and interconnect the various components Computer Architecture – Chapter © Fall 2015 45 2015 Fetch - Execute Cycle Infinite Cycle implemented in Hardware dce Instruction Fetch Instruction Decode Execute Fetch instruction Compute address of next instruction Generate control signals for instruction Read operands from registers Compute result value Memory Access Read or write memory (load/store) Writeback Result Writeback result in a register Computer Architecture – Chapter © Fall 2015 46 dce 2015 Clocking Operation of digital hardware is governed by a clock Clock period Clock (cycles) Data transfer and computation Update state  Clock period: duration of a clock cycle   e.g., 250 ps = 0.25 ns = 0.25 ×10–9 sec Clock frequency (rate) = / clock period  e.g., 1/ 0.25 ×10–9 sec = 4.0×109 Hz = 4.0 GHz Computer Architecture – Chapter © Fall 2015 47 dce 2015 Presentation Outline • Welcome to CA CSE • Computer Architectures and Trends • High-Level, Assembly-, and Machine-Languages • Components of a Computer System • Chip Manufacturing Process • Programmer's View of a Computer System Computer Architecture – Chapter © Fall 2015 48 dce 2015 Chip Manufacturing Process Blank wafers Silicon ingot Slicer 20 to 40 processing steps 8-12 in diameter 12-24 in long < 0.1 in thick Tested dies Patterned wafer Individual dies Die Tester Packaged dies Bond die to package Computer Architecture – Chapter Dicer Tested Packaged dies Part Tester Ship to Customers © Fall 2015 49 dce 2015 Wafer of Pentium Processors • inches (20 cm) in diameter • Die area is 250 mm2 – About 16 mm per side • 55 million transistors per die – 0.18 μm technology – Size of smallest transistor – Improved technology uses • 0.13 μm and 0.09 μm • Dies per wafer = 169 – When yield = 100% – Number is reduced after testing – Rounded dies at boundary are useless Computer Architecture – Chapter © Fall 2015 50 dce 2015 Effect of Die Size on Yield Good Die Defective Die 120 dies, 109 good 26 dies, 15 good Dramatic decrease in yield with larger dies Yield = (Number of Good Dies) / (Total Number of Dies) Yield = (1 + (Defect per area  Die area / 2))2 Die Cost = (Wafer Cost) / (Dies per Wafer  Yield) Computer Architecture – Chapter © Fall 2015 51 dce 2015 Presentation Outline • Welcome to CA CSE • Computer Architectures and Trends • High-Level, Assembly-, and Machine-Languages • Components of a Computer System • Chip Manufacturing Process • Programmer's View of a Computer System Computer Architecture – Chapter © Fall 2015 52 dce 2015 Programmer’s View of a Computer System Software Application Programs High-Level Language Level Assembly Language Level Operating System Interface SW & HW Level Instruction Set Architecture Level Microarchitecture Level Hardware Physical Design Computer Architecture – Chapter Increased level of abstraction Level Each level hides the details of the level below it © Fall 2015 53 dce 2015 Programmer's View – • Application Programs (Level 5) – Written in high-level programming languages – Such as Java, C++, Pascal, Visual Basic – Programs compile into assembly language level (Level 4) • Assembly Language (Level 4) – Instruction mnemonics are used – Have one-to-one correspondence to machine language – Calls functions written at the operating system level (Level 3) – Programs are translated into machine language (Level 2) • Operating System (Level 3) – Provides services to level and programs – Translated to run at the machine instruction level (Level 2) Computer Architecture – Chapter © Fall 2015 54 dce 2015 Programmer's View – • Instruction Set Architecture (Level 2) – Interface between software and hardware – Specifies how a processor functions – Machine instructions, registers, and memory are exposed – Machine language is executed by Level (microarchitecture) • Microarchitecture (Level 1) – Controls the execution of machine instructions (Level 2) – Implemented by digital logic • Physical Design (Level 0) – Implements the microarchitecture – Physical layout of circuits on a chip Computer Architecture – Chapter © Fall 2015 55 [...]... 1 © Fall 2 015 14 dce 2 015 Trend 3: Energy/Power Constrain all Modern Systems Computer Architecture – Chapter 1 © Fall 2 015 15 dce 2 015 Emerging Device Technologies Computer Architecture – Chapter 1 © Fall 2 015 16 dce 2 015 Power Constrains Single-Processor Scaling Computer Architecture – Chapter 1 © Fall 2 015 17 dce 2 015 Transition to Multicore Processors Computer Architecture – Chapter 1 © Fall 2 015 ... in this course Computer Architecture – Chapter 1 © Fall 2 015 11 dce 2 015 Computer Architecture In Context Computer Architecture – Chapter 1 © Fall 2 015 12 dce 2 015 Trend 1: Growing Diversity In Apps & Systems Computer Architecture – Chapter 1 © Fall 2 015 13 dce 2 015 Trend 2: Software trend • • • • • No longer just executing C/FORTRAN code Object Oriented Programming Java Architectural features to assist... Chapter 1 © Fall 2 015 20 dce 2 015 Computer Sales Computer Architecture – Chapter 1 © Fall 2 015 21 dce 2 015 Microprocessor Sales • ARM processor sales exceeded Intel IA-32 processors, which came second • ARM processors are used mostly in cellular phones • Most processors today are embedded in cell phones, digital TVs, video games, and a variety of consumer devices Computer Architecture – Chapter 1 © Fall... dce 2 015 Compiler and Assembler Computer Architecture – Chapter 1 © Fall 2 015 27 dce 2 015 Translating Languages Program (C Language): A statement in a high-level language is translated typically into several machine-level instructions swap(int v[], int k) { int temp; temp = v[k]; v[k] = v[k +1] ; v[k +1] = temp; } Compiler MIPS Assembly Language: sll add lw lw sw sw jr $2,$5, 2 $2,$4,$2 $15 ,0($2) $16 ,4($2)... v[k +1] ; v[k +1] = temp; } Compiler MIPS Assembly Language: sll add lw lw sw sw jr $2,$5, 2 $2,$4,$2 $15 ,0($2) $16 ,4($2) $16 ,0($2) $15 ,4($2) $ 31 Computer Architecture – Chapter 1 MIPS Machine Language: Assembler 000 510 80 008 210 20 8C620000 8CF20004 ACF20000 AC620004 03E00008 © Fall 2 015 28 dce 2 015 Advantages of High-Level Languages • Program development is faster – High-level statements: fewer instructions... Fall 2 015 32 dce 2 015 MARS Assembler and Simulator Tool Computer Architecture – Chapter 1 © Fall 2 015 33 dce 2 015 Presentation Outline • Welcome to CA CSE • Computer Architectures and Trends • High-Level, Assembly-, and Machine-Languages • Components of a Computer System • Chip Manufacturing Process • Programmer's View of a Computer System Computer Architecture – Chapter 1 © Fall 2 015 34 dce 2 015 Opening... Single-Processor Scaling Computer Architecture – Chapter 1 © Fall 2 015 17 dce 2 015 Transition to Multicore Processors Computer Architecture – Chapter 1 © Fall 2 015 18 dce 2 015 Multicore Performance Scaling Computer Architecture – Chapter 1 © Fall 2 015 19 dce 2 015 Classes of Computers • Desktop / Notebook Computers – General purpose, variety of software – Subject to cost/performance tradeoff • Server Computers...dce 2 015 What is “Computer Architecture” ? • Computer Architecture = Instruction Set Architecture + Computer Organization • Instruction Set Architecture (ISA) – WHAT the computer does (logical view) • Computer Organization – HOW the ISA is implemented (physical view) • We will study both in this course Computer Architecture – Chapter 1 © Fall 2 015 11 dce 2 015 Computer Architecture... an Assembler, Linker, and Debugger? Computer Architecture – Chapter 1 © Fall 2 015 24 dce 2 015 A Hierarchy of Languages Application Programs High-Level Languages Machine independent High-Level Language Machine specific Low-Level Language Assembly Language Machine Language Hardware Computer Architecture – Chapter 1 © Fall 2 015 25 dce 2 015 Assembly and Machine Language • Machine language – Native to a processor:... Chapter 1 © Fall 2 015 31 dce 2 015 Assemble and Link Process Source File Source File Source File Assembler Object File Assembler Object File Linker Assembler Object File Link Libraries Executable File A program may consist of multiple source files Assembler translates each source file separately into an object file Linker links all object files together with link libraries Computer Architecture – Chapter 1 ... 2 015 11 dce 2 015 Computer Architecture In Context Computer Architecture – Chapter © Fall 2 015 12 dce 2 015 Trend 1: Growing Diversity In Apps & Systems Computer Architecture – Chapter © Fall 2 015 ... 2 015 16 dce 2 015 Power Constrains Single-Processor Scaling Computer Architecture – Chapter © Fall 2 015 17 dce 2 015 Transition to Multicore Processors Computer Architecture – Chapter © Fall 2 015 ... temp; temp = v[k]; v[k] = v[k +1] ; v[k +1] = temp; } Compiler MIPS Assembly Language: sll add lw lw sw sw jr $2,$5, $2,$4,$2 $15 ,0($2) $16 ,4($2) $16 ,0($2) $15 ,4($2) $ 31 Computer Architecture – Chapter

Ngày đăng: 09/12/2016, 07:13

TỪ KHÓA LIÊN QUAN