CBP 2002ITY 270 Computer Architecture1 Digital Logic This Time … Control Path, Arithmetic Ops 12 a U1 34 b Last Time …

Slides:



Advertisements
Similar presentations
Modular Combinational Logic
Advertisements

CBP Comp 1017 Digital Technologies1 Let’s make a Computer … at least the CPU … Pentium 4 Pentium 3 Opteron Ultra Sparc Itanium 2 McKinley.
CBP Comp 1017 Digital Technologies1 Let’s make a Computer.
L14 – Control & Execution 1 Comp 411 – Fall /04/09 Control & Execution Finite State Machines for Control MIPS Execution.
Computer ArchitectureFall 2008 © August 25, CS 447 – Computer Architecture Lecture 3 Computer Arithmetic (1)
L15 – Control & Execution 1 Comp 411 – Spring /25/08 Control & Execution Finite State Machines for Control MIPS Execution.
CPEN Digital System Design Chapter 9 – Computer Design
16/07/2015CSE1303 Part B lecture notes 1 Hardware Implementation Lecture B17 Lecture notes section B17.
Chapter 6 Memory and Programmable Logic Devices
Part 2: DESIGN CIRCUIT. LOGIC CIRCUIT DESIGN x y z F F = x + y’z x y z F Truth Table Boolean Function.
More Basics of CPU Design Lecture for CPSC 5155 Edward Bosworth, Ph.D. Computer Science Department Columbus State University.
Princess Sumaya Univ. Computer Engineering Dept. Chapter 4: IT Students.
Princess Sumaya Univ. Computer Engineering Dept. Chapter 4:
CSU0014 Assembly Languages Homepage: Textbook: Kip R. Irvine, Assembly Language for Intel-Based Computers,
Summer 2014 Chapter 1: Basic Concepts. Irvine, Kip R. Assembly Language for Intel-Based Computers 6/e, Chapter Overview Welcome to Assembly Language.
1 CS/COE0447 Computer Organization & Assembly Language Chapter 3.
1 Modified from  Modified from 1998 Morgan Kaufmann Publishers Chapter Three: Arithmetic for Computers citation and following credit line is included:
Digital Computer Concept and Practice Copyright ©2012 by Jaejin Lee Logic Circuits I.
CS1Q Computer Systems Lecture 9 Simon Gay. Lecture 9CS1Q Computer Systems - Simon Gay2 Addition We want to be able to do arithmetic on computers and therefore.
Computer Fundamentals ELEC 330 Digital Systems Engineering Dr. Ron Hayne.
Computer Systems Organization CS 1428 Foundations of Computer Science.
Digital Computer Concept and Practice Copyright ©2012 by Jaejin Lee Logic Circuits I.
EKT221 ELECTRONICS DIGITAL II CHAPTER 4: Computer Design Basics
Chapter 4 Computer Design Basics. Chapter Overview Part 1 – Datapaths  Introduction  Datapath Example  Arithmetic Logic Unit (ALU)  Shifter  Datapath.
Princess Sumaya Univ. Computer Engineering Dept. Chapter 5:
CS 111 – Sept. 15 Chapter 2 – Manipulating data by performing instructions “What is going on in the CPU?” Commitment: –Please read through section 2.3.
Lec 15Systems Architecture1 Systems Architecture Lecture 15: A Simple Implementation of MIPS Jeremy R. Johnson Anatole D. Ruslanov William M. Mongan Some.
Gary MarsdenSlide 1University of Cape Town Chapter 5 - The Processor  Machine Performance factors –Instruction Count, Clock cycle time, Clock cycles per.
Exam 2 Review Two’s Complement Arithmetic Ripple carry ALU logic and performance Look-ahead techniques Basic multiplication and division ( non- restoring)
Kavita Bala CS 3410, Spring 2014 Computer Science Cornell University.
EKT 221 : Chapter 4 Computer Design Basics
CBP 2006Comp 4070 Concepts and Philosophy of Computing 1 Wrestling with Complex Stuff. With the Correct Approach, even the smallest guy will succeed!
Our programmer needs to do this !
Computer Architecture Lecture 9 MIPS ALU and Data Paths Ralph Grishman Oct NYU.
Computer Organization and Assembly Languages Yung-Yu Chuang 2005/09/29
CBP 2002ITY 270 Computer Architecture1 Module Structure Whirlwind Review – Fetch-Execute Simulation Instruction Set Architectures RISC vs x86 How to build.
Gates AND, OR, NOT NAND, NOR Combinational logic No memory A set of inputs uniquely and unambiguously specifies.
EKT 221 : Digital 2 Computer Design Basics Date : Lecture : 2 hrs.
EE204 L03-ALUHina Anwar Khan EE204 Computer Architecture Lecture 03- ALU.
COMPUTER ARCHITECTURE & OPERATIONS I Instructor: Yaohang Li.
Logic Gates Dr.Ahmed Bayoumi Dr.Shady Elmashad. Objectives  Identify the basic gates and describe the behavior of each  Combine basic gates into circuits.
More on Digital Logic Devices and Circuits Trac D. Tran ECE Department The Johns Hopkins University Baltimore, MD
REGISTER TRANSFER AND MICROOPERATIONS
Dr.Ahmed Bayoumi Dr.Shady Elmashad
Combinational Circuits
CS161 – Design and Architecture of Computer Systems
CS 270: Mathematical Foundations of Computer Science
CS161 – Design and Architecture of Computer Systems
REGISTER TRANSFER AND MICROOPERATIONS
Control & Execution Finite State Machines for Control MIPS Execution.
Computer Science 210 Computer Organization
COMP541 Datapaths I Montek Singh Mar 28, 2012.
Digital Logic Last Time … This Time … Control Path, Arithmetic Ops a
The fetch-execute cycle
Control & Execution Finite State Machines for Control MIPS Execution.
Computer Science 210 Computer Organization
Rocky K. C. Chang 6 November 2017
CS/COE0447 Computer Organization & Assembly Language
Guest Lecturer TA: Shreyas Chand
CS/COE0447 Computer Organization & Assembly Language
22 October 3 classes before 2nd exam! Control 1/16/2019
Logic Circuits I Lecture 3.
COMP541 Datapaths I Montek Singh Mar 18, 2010.
Combinational Circuits
Electronics for Physicists
Lecture 6 CdM-8 CPU overview
Computer Organization and Assembly Languages Yung-Yu Chuang 2005/09/29
Digital Circuits and Logic
Instruction execution and ALU
Computer Architecture Assembly Language
Presentation transcript:

CBP 2002ITY 270 Computer Architecture1 Digital Logic This Time … Control Path, Arithmetic Ops 12 a U1 34 b Last Time …

CBP 2002ITY 270 Computer Architecture2 Data Memory Code Memory ALU X Y W XY W Digital Logic Where? Control Circuits – CPU control path - system board (later) ALU Structure – add, sub, and, or, not MUXES Address Decoder

CBP 2002ITY 270 Computer Architecture3 Boolean Notation, Truth Tables A and B AB A or B A + B NOT A A _ ABC Easy Way to write truth tables - count in binary ! A B O A B O A O ABO ABO AO 01 10

CBP 2002ITY 270 Computer Architecture4 Digi Logic Design 1 - use Gates A B C O ABCO O ABC _ _ _ A B C A B C A B C _ _ ABC + ABC + ABC + ABC _ _ _ Majority Function

CBP 2002ITY 270 Computer Architecture5 A B C ABC + ABC + ABC + ABC ABC _ _ _ __ _

CBP 2002ITY 270 Computer Architecture6 Address Decoder Exercise AB O1O1 O2O2 O3O3 O4O A B O1 O2 O3 O4 O1 = AB _ _ A B

CBP 2002ITY 270 Computer Architecture7 r0 Decoder Application r1 r2 r0 X Y W XY W Selecting Registers, e.g, add r2,r1,r0 MIPS has 5-bit fields for registers, so are 32 addrdrsrtunused 0 cs r0 Registers decoder

CBP 2002ITY 270 Computer Architecture8 MUX Exercise CABO A B Op C A B O C = 0 A B O C = 1 What is MUX doing here ?

CBP 2002ITY 270 Computer Architecture9 MUX is a Selector A B Op C A B C

CBP 2002ITY 270 Computer Architecture10 Multibit MUX A B O C A B C

CBP 2002ITY 270 Computer Architecture11 MUX Application ALU Y’ Y Selection of Datapath into one ALU input. Datapath Y from instruction add r2,r0,r1 Datapth Y’ from instruction addi r2,r0,4 Sam has been designed so all immediate constants come in via Y’ addrdrsrtunused Immediate bit of op-code

CBP 2002ITY 270 Computer Architecture12 Address/Data Bus MUXing CPUMEM addr data CPUMEM add/dat address data address data Multiplexed Address/Data Bus, e.g. PCI Bus Pentium System Bus

CBP 2002ITY 270 Computer Architecture13 Digi design 2 - use MUXes ABO 00I1 01I2 10I3 11I4 A B Op In 1 In 2 In 3 In 4 ABO A B Op “ Muxes can be used to implement arbitrary combinatorial circuits “

CBP 2002ITY 270 Computer Architecture14 MUX Design Exercise 3 input parity detector ABCO

CBP 2002ITY 270 Computer Architecture15 Designing Using ROM/RAM A B O A B O decoder A B O O Several MUX’es fed with the same AB produce a multibit output. So does a ROM or RAM.

CBP 2002ITY 270 Computer Architecture16 Programmable Logic Arrays Fuse ABC _ majority

CBP 2002ITY 270 Computer Architecture17 Addition of Binary Numbers Sum = 1 Carry = 0 A B Sum = 0 Carry = 1 A B Multibit add - cascade sum and carry ops.

CBP 2002ITY 270 Computer Architecture18 Full Adder ABCiSCo S Full Adder B A Carry In Carry OutSum

CBP 2002ITY 270 Computer Architecture19 Full Adder ABCiOCo O A B C SUMSUM A B C CARRYCARRY

CBP 2002ITY 270 Computer Architecture20 4-bit Adder Full Adder a3a2a1a0 b3b2b1b0 s3 0 Carry Out

CBP 2002ITY 270 Computer Architecture21 Let’s Build an ALU + B A Carry In Carry Out S1 S0

CBP 2002ITY 270 Computer Architecture22 Issues Concerning Numbers Multiplication and Division Subtraction Negative Numbers Fractional and Real Numbers Characters and Strings

CBP 2002ITY 270 Computer Architecture23 Sequential Circuits Traffic Lights Washing Machines Fetch-Execute Cycle

CBP 2002ITY 270 Computer Architecture24 Counters T0T1T2T3T Clock 4-bit Counter (4) Reset How to get this to sequence ?

CBP 2002ITY 270 Computer Architecture25 Traffic Light Sequencing Clock 4-bit Counter (4) Reset T0T1T2T3 Combinatorial Logic T2 T3 T0 T1

CBP 2002ITY 270 Computer Architecture26 Fetch Execute Sequencing T1T2T3T4T5 Fetch Decode, Reg Op ALU Op Mem Access Reg Write ALU ALU Counter Decoder Clock Data Memory Code Memory AL U X Y W XY W 0 1 7

CBP 2002ITY 270 Computer Architecture27 Representing Numbers Let’s take some 3-bit numbers. “2’s Complement” – complement it (0->1 and 1->0) then add 1

CBP 2002ITY 270 Computer Architecture28 2’s Complement Properties Most Significant Bit (MSB) gives sign. Addition ? = 3 + (-2) = 1 Subtraction by Addition MSB is Sign Bit !

CBP 2002ITY 270 Computer Architecture29 Full Adder a3a2a1a0 b3 b2b1 b0 s3 1 Subtraction by Addition

CBP 2002ITY 270 Computer Architecture30 HEX and Chars Hexadecimal Shorthand each nibble rep’d as a character … B 7 BinaryHex A B C D E 1 1 F Useful in Machine Level Programming and HTML scripting HEXAscii A 61a 6Dm 0DCR ASCII UNICODE

CBP 2002ITY 270 Computer Architecture31 Multiplication x x x

CBP 2002ITY 270 Computer Architecture32 Multiplication B 1101 C Initial values Add A to B SHR Add A to B SHR No Add SHR Add A to B A C Add/no-add A adder B Add A to B. Then Shift Right (SHR). Look at LSB bit. If this is 1 then Add A to B. A = B = AxB =