CWRU EECS 3221 Language of the Machine I speak Spanish to God, Italian to women, French to men, and German to my Horse. Charles V, King of France 1337-1380.

Slides:



Advertisements
Similar presentations
1 ECE369 ECE369 Chapter 2. 2 ECE369 Instruction Set Architecture A very important abstraction –interface between hardware and low-level software –standardizes.
Advertisements

TU/e Processor Design 5Z0321 Processor Design 5Z032 Computer Systems Overview Chapter 1 Henk Corporaal Eindhoven University of Technology 2011.
Cs 61C L1 Intro.1 Patterson Fall00 ©UCB CS61C Machine Structures Lecture 1 August 30,2000 Dave Patterson (http.cs.berkeley.edu/~patterson)
Spring 2008, Jan. 14 ELEC / Lecture 2 1 ELEC / Computer Architecture and Design Spring 2007 Introduction Vishwani D. Agrawal.
COMP3221 lec08-arith.1 Saeid Nooshabadi COMP 3221 Microprocessors and Embedded Systems Lecture 8: C/Assembler Data Processing
CS 61C L06 MIPS Intro (1) A Carle, Summer 2005 © UCB inst.eecs.berkeley.edu/~cs61c/su05 CS61C : Machine Structures Lecture #6: Intro to MIPS
Cs 61C L2 Asm Ops.1 Patterson Spring 99 ©UCB CS61C C/Assembler Operators and Operands Lecture 2 January 22, 1999 Dave Patterson (http.cs.berkeley.edu/~patterson)
Chapter 1. Introduction This course is all about how computers work But what do we mean by a computer? –Different types: desktop, servers, embedded devices.
Computer Architecture Instructor: Wen-Hung Liao Office: 大仁樓三樓 Office hours: TBA Course web page:
1  1998 Morgan Kaufmann Publishers Lectures for 2nd Edition Note: these lectures are often supplemented with other materials and also problems from the.
CPEN Digital System Design Chapter 10 – Instruction SET Architecture (ISA) © Logic and Computer Design Fundamentals, 4 rd Ed., Mano Prentice Hall.
CS1104 Assembly Language: Part 1
CS / Schlesinger Lec1.1 1/20/99©UCB Spring 1999 Computer Architecture Lecture 1 Introduction and Five Components of a Computer Spring, 1999 Arie Schlesinger.
CIS 314 : Computer Organization Lecture 1 – Introduction.
CS 61C L08 Introduction to MIPS Assembly Language: Arithmetic (1) Garcia, Spring 2004 © UCB Lecturer PSOE Dan Garcia inst.eecs.berkeley.edu/~cs61c.
August 26 TA: Angela Van Osdol Questions?. What is a computer? Tape drives? Big box with lots of lights? Display with huge letters? Little box with no.
ECE 232 L1 Intro.1 Adapted from Patterson 97 ©UCBCopyright 1998 Morgan Kaufmann Publishers ECE 232 Hardware Organization and Design Lecture 1 Introduction.
Computer Organization and Architecture (AT70. 01) Comp. Sc. and Inf
Part 1.  Intel x86/Pentium family  32-bit CISC processor  SUN SPARC and UltraSPARC  32- and 64-bit RISC processors  Java  C  C++  Java  Why Java?
Introduction Course Overview and Basic understanding of Computer Architecture.
COE Computer Organization & Assembly Language Talal Alkharobi.
Computer Architecture ECE 4801 Berk Sunar Erkay Savas.
1 CS37: Computer Architecture Spring Term, 2004 Instructor: Kate Forbes Riley Teaching Assistant:
Fall 2015, Aug 17 ELEC / Lecture 1 1 ELEC / Computer Architecture and Design Fall 2015 Introduction Vishwani D. Agrawal.
Computers organization & Assembly Language Chapter 0 INTRODUCTION TO COMPUTING Basic Concepts.
Implementation of a Stored Program Computer ITCS 3181 Logic and Computer Systems 2014 B. Wilkinson Slides2.ppt Modification date: Oct 16,
COMP3221 lec04--prog-model.1 Saeid Nooshabadi COMP 3221 Microprocessors and Embedded Systems Lecture 4: Programmer’s Model of Microprocessors
(1) ECE 3056: Architecture, Concurrency and Energy in Computation Lecture Notes by MKP and Sudhakar Yalamanchili Sudhakar Yalamanchili (Some small modifications.
Computer Organization and Design Computer Abstractions and Technology
Computer Architecture Mehran Rezaei
1 International Technology University CEN 951 Computer Architecture Lecture 1 - Introduction.
Part 1.  Intel x86/Pentium family  32-bit CISC processor  SUN SPARC and UltraSPARC  32- and 64-bit RISC processors  Java  C  C++  Java  Why Java?
Lecture 4: MIPS Instruction Set Reminders: –Homework #1 posted: due next Wed. –Midterm #1 scheduled Friday September 26 th, 2014 Location: TODD 430 –Midterm.
Computer System Design Lecture 1 Wannarat Suntiamorntut.
Chapter 2 Instructions: Language of the Computer Part I.
by Computer System Design Lecture 1 Wannarat Suntiamorntut
1 ECE3055 Computer Architecture and Operating Systems Lecture 1 Introduction Prof. Hsien-Hsin Sean Lee School of Electrical and Computer Engineering Georgia.
CWRU EECS 3221 Language of the Machine EECS 322 Computer Architecture Instructor: Francis G. Wolff Case Western Reserve University.
순천향대학교 정보기술공학부 이 상 정 1 1. Computer Abstractions and Technology.
CWRU EECS 3141 Computer designers must be experienced: in both hardware and software co-design, as well as in embedded applications, be familiar with optimization.
Computer Organization Instructors Course By: Lecturer: Shimaa Ibrahim Hassan TA: Eng: Moufeda Hussien Lecture: 9:45 Address:
1 chapter 1 Computer Architecture and Design ECE4480/5480 Computer Architecture and Design Department of Electrical and Computer Engineering University.
August 27 Books? ? Accounts?. What does a computer look like? Tape drives? Big box with lots of lights? Display with huge letters? Little box with.
1  1998 Morgan Kaufmann Publishers Where we are headed Performance issues (Chapter 2) vocabulary and motivation A specific instruction set architecture.
EECS 314 Computer Architecture
DR. SIMING LIU SPRING 2016 COMPUTER SCIENCE AND ENGINEERING UNIVERSITY OF NEVADA, RENO CS 219 Computer Organization.
Spring 2016, Jan 13 ELEC / Lecture 1 1 ELEC / Computer Architecture and Design Spring 2016 Introduction Vishwani D. Agrawal.
1 TM 1 Embedded Systems Lab./Honam University ARM Microprocessor Programming Model.
CHAPTER 2 Instruction Set Architecture 3/21/
1 CHAPTER 1 COMPUTER ABSTRACTIONS AND TECHNOLOGY Parts of these notes have been adapter from those of Prof. Professor Mike Schulte, Prof. D. Patterson,
By Wannarat Computer System Design Lecture 1 Wannarat Suntiamorntut.
CS4100: 計算機結構 Course Outline 國立清華大學資訊工程學系 九十九年度第二學期.
Computer Architecture Furkan Rabee
Assembly Language Basic job of a CPU: execute lots of instructions. Instructions are the primitive operations that the CPU may execute. Different CPUs.
Computer Architecture & Operations I
Computer Architecture & Operations I
ECE 3055: Computer Architecture and Operating Systems
Instruction Set Architecture
INTRODUCTION TO MICROPROCESSORS
INTRODUCTION TO MICROPROCESSORS
EEL 4713/EEL 5764 Computer Architecture
Systems Architecture Lecture 5: MIPS Instruction Set
T Computer Architecture, Autumn 2005
August 29 New address for Fang-Yi
COMS 361 Computer Organization
Instructions in Machine Language
Computer Architecture
CPU Structure CPU must:
Computer Architecture
ELEC / Computer Architecture and Design Fall 2014 Introduction
Presentation transcript:

CWRU EECS 3221 Language of the Machine I speak Spanish to God, Italian to women, French to men, and German to my Horse. Charles V, King of France EECS 322 Computer Architecture Instructor: Francis G. Wolff Case Western Reserve University This presentation uses powerpoint animation: please viewshow

CWRU EECS million processors 100 million processors were sold for desktop computers 3 BILLION processors 3 BILLION processors were sold for embedded systems Computer Architecture Trends: Post PC era

CWRU EECS 3223 $66 Billion by 2004 Embedded Systems Market Worth It’s expected that the average car will be Internet ready and have over $2000 worth of embedded computers Internet Appliances Internet Appliances will grow by more than 1500% between now and the end of That translates into some 37 million devices shipping in This market includes TV-based Internet access devices, web phones, and other terminals that use wires to connect to the web. Consumer Markets: Processor trends

CWRU EECS 3224 Bionics: Sensors in latex fingers instantly register hot and cold, and an electronic interface in his artificial limb stimulates the nerve endings in his upper arm, which then pass the information to his brain. The $3,000 system allows his hand to feel pressure and weight, so for the first time since losing his arms in a 1986 accident, he can pick up a can of soda without crushing it or having it slip through his fingers. One Digital Day Medical Markets: Biotechnology

CWRU EECS 3225 Computer designers must be experienced: in both hardware and software co-design, as well as in embedded applications, be familiar with optimization techniques to perform the specific program using the least size, power, and time. Future PC Design: System-on-a-Chip How do we design such large systems…. 12 million logic gates can now be placed on a single chip

CWRU EECS 3226 Design Abstractions I/O systemProcessor Compiler Operating System (Linux) Application (Netscape) Digital Design Circuit Design Instruction Set Architecture Coordination of many levels of abstraction Datapath & Control transistors Memory Hardware Software Assembler

CWRU EECS 3227 Design Abstractions High Level Language Program (e.g., C) Assembly Language Program (e.g. MIPS) Machine Language Program (MIPS) Control Signal Specification Compiler Assembler Machine Interpretation temp = v[k]; v[k] = v[k+1]; v[k+1] = temp; lw$to,0($2) lw$t1,4($2) sw$t1,0($2) sw$t0,4($2) ALUOP[0:3] <= InstReg[9:11] & MASK An abstraction omits unneeded detail, helps us cope with complexity

CWRU EECS 3228 Instruction Set Architecture A very important abstraction: Instruction Set Architecture interface between hardware and low-level software standardizes instructions, machine language bit patterns,... advantage: different implementations of the same architecture disadvantage: sometimes prevents using new innovations True or False: Binary compatibility is important? Modern instruction set architectures: 80x86/Pentium/K6, PowerPC, DEC Alpha, MIPS, SPARC, HP Yes (Microsoft/Intel alliance) No - (Unix, Linux, C++, Java) Yes - Sales, Marketing No - Speed, Engineers, Programmers

CWRU EECS 3229 Example: Digital Pager Architecture Two completely differently optimized Instruction Set Architectures Why not just use an Intel Pentium instead? Cost, size, power, speed, weight,...

CWRU EECS I speak Hundreds of years later, and IEEE/ABET accreditation, this course has evolved as follows: Course Overview C++ to my Compiler, Machine Instructions to Assemblers, Datapath Design to Digital Logic Gates, and German to my Horse. Software Hardware Performance Issues

CWRU EECS Smart cards differ from credit cards in using onboard memory chips and microprocessors or micro-controllers instead of magnetic strips. Each chip can hold 100 times the information contained on a standard magnetic-stripe card. Smart cards make personal and business data available only to the appropriate users. Smart Cards: Hardware/Software Co-Design There are currently 2.8 billion smart cards in use: 575 million phone, 36 million financial, 30 million ID cards, 17 million pay TV, … Smart Cards

CWRU EECS Smart cards have embedded within them a processor and often a cryptographically enhanced co-processor. Today's smart card hardware controller typically includes an 8- bit CPU (such as the Motorola 68HC05), 780 bytes of RAM, 20 KB of ROM, 16 KB of EEPROM on a single die, and (optionally) an on-chip hardware encryption module. Smart Cards: Computer Architecture

CWRU EECS An example of the software handshaking protocol is shown below Smart Cards: Hardware/Software Co-Design

CWRU EECS Course Textbook Textbook: Computer Organization and Design “The Hardware/Software Interface” 2nd edition John L. Hennessy & Patterson Morgan Kaufmann Publishers ISBN = Homeworks, exams, lecture material are heavily based on the textbook! Avoiding it will be hard

CWRU EECS Course Instructor Office: Olin Building Room 514 Phone: Preferred form of communication Course Website: Office hours: generally before & after class Instructor:Frank Wolff

CWRU EECS Course Graders / Teaching Assistants Primary Grader: Ramakrishnan Vijayakumar Office:Olin 413, Embedded Systems Lab Phone:TBA Preferred form of communication Office hours: TBA Priority: Graders/TAs then Instructor

CWRU EECS Course Grading Exams = Projects = 25% each February 12:Chapters 3,2,1 March 7:Chapter 4 April 4:Chapter 5-6 April 30:Chapter Total: 4 exams and 1 programming project Tentative Exam dates: (disclaimer: subject to change in time/topics) 1 week advanced confirmation notice Homeworks assigned for next class day

CWRU EECS Course Schedule Class: Monday & Wednesday 4:30-5:45pm Last Class Day:April 30 (Last Exam) Spring Break: March First Class Day:January 17 Get Unix & NT accounts

CWRU EECS Course Outline 1. Introduction 2. Instruction Set Design 3. Computer System Design 4. Data Path Design 5. Instruction Sequencing and Control 6. Pipeline Design 7. Memory Systems 8. Input - Output and Communications

CWRU EECS Course Outline Concepts (1-3) 1. Introduction: Introduction to architecture. Turing machine computational model. Basic principles of machine design. Computer evolution. Technology impact on architecture. 2. Instruction Set Design: Instruction set architecture. Cost and performance measurements. Classification of instruction sets. Example of instruction set macines. Quantitative comparisons. Reduced Instruction set design (RISC). 3. Computer System Design: Computer design methodology. Design Levels. Review of gate-level design. Register level components and design. Design CAD systems.

CWRU EECS Course Outline Concepts (4-6) 4. Data Path Design: Basic processor datapath design. Design of Arithmetic Logic Unit (ALU). Design of Fast ALUs. Multipliers and Dividers. Floating Point Units. 5. Instruction Sequencing & Control: Instruction control steps & sequencing. State machine controllers. Hardwaired control. Microprogrammed control. PLA controllers. Microsequencers. Examples. 6. Pipeline Design: Fundamental principles. Arithmetic structures. Instruction pipeline techniques. RISC instruction pipelines. Pipeline sequencing & control. Floating-point pipelines.

CWRU EECS Course Outline Concepts (7-8) 7. Memory Systems: Memory technologies. RAM design. Memory hierarchies. Cache memories. Memory allocation techniques & memory management. 8. Input - Output and Communications: Communication methods. Bus control and timing. More about buses. Interrupts and DMA.

CWRU EECS C Operators/Operands Arithmetic operators: +, -, *, /, % (mod) Assignment statements: Variable = expression; celsius = 5 * (fahr - 32) / 9; Operands: Variables: lower, upper, fahr, celsius Constants: e.g., 0, 1000, -17, 15 In C (and most High Level Languages) variables declared 1st and given a data type –Example: int celsius; /* declare celsius as an integer */ int a, b, c, d, e; Note: we begin at chapter 3 of the text book

CWRU EECS Assembly Operators Syntax of Assembly Operator 1) operation by name 2) operand getting result 3) 1st operand for operation 4) 2nd operand for operation Example add b to c and put the result in a: add a, b, c –Called an (assembly language) Instruction Equivalent assignment statement in C: a = b + c;

CWRU EECS Assembly Operators/Instructions MIPS Assembly Syntax is rigid: 1 operation, 3 variables Why? Keep Hardware simple via regularity Note: Unlike C each line of assembly contains at most 1 instruction How do following C statement? a = b + c + d - e; Break into multiple instructions add a, b, c # a = sum of b & c add a, a, d # a = sum of b,c,d sub a, a, e # a = b+c+d-e # is a comment terminated by end of the line /* comment */ is a C comments & can span many lines

CWRU EECS Compilation Example: compile by hand this C code: f = (g + h) - (i + j); First sum of g and h. Where put result? add f,g,h # f contains g+h Now sum of i and j. Where put result? –Cannot use f ! –Compiler creates temporary variable to hold sum: t1 add t1,i,j # t1 contains i+j Finally produce difference sub f,f,t1 # f=(g+h)-(i+j)

CWRU EECS Compilation Summary C statement (5 operands, 3 operators): f = (g + h) - (i + j); Becomes 3 assembly instructions (6 unique operands, 3 operators): add f,g,h # f contains g+h add t1,i,j # t1 contains i+j sub f,f,t1 # f=(g+h)-(i+j) Big Idea: compiler translates notation from 1 level of abstraction to lower level In general, each line of C produces many assembly instructions –One reason why people program in C vs. Assembly; fewer lines of code –Other reasons? Portability, Optimization

CWRU EECS Registers Unlike C++, assembly instructions cannot use variables Why not? Keep Hardware Simple Instruction operands are registers: limited number of special locations; 32 registers in MIPS (r0 - r31) Why 32? Smaller is faster Each MIPS register is 32 bits wide Groups of 32 bits called a word in MIPS clk b0 b31

CWRU EECS Assembly Operands: Registers Naming of 32 registers: instead of $r0, $r1, …, $r31, use $s0, $s1, … for registers corresponding to C variables $t0, $t1, … for registers corresponding to temporary variables Will explain mapping convention later of $s0, $s1, …, $t0, $t1, …, to $r0, $r1, … Note: whereas C declares its operands, Assembly operands (registers) are fixed and not declared

CWRU EECS Compilation using Registers Compile by hand using registers: f = (g + h) - (i + j); # assign registers #int f: $s0, int g: $s1, int h: $s2, #int i: $s3, int j: $s4 MIPS Instructions: add $s0,$s1,$s2# $s0 = g+h add $t1,$s3,$s4# $t1 = i+j sub $s0,$s0,$t1# f=(g+h)-(i+j)