Lecture 12: Adders, Sequential Circuits

Similar documents
Lecture 12: Adders, Sequential Circuits

Lecture 13: Sequential Circuits

Lecture 13: Sequential Circuits, FSM

Lecture 13: Sequential Circuits, FSM

COE 202: Digital Logic Design Combinational Circuits Part 2. Dr. Ahmad Almulhem ahmadsm AT kfupm Phone: Office:

Latches. October 13, 2003 Latches 1

EFFICIENT MULTIOUTPUT CARRY LOOK-AHEAD ADDERS

Chapter 5. Digital Design and Computer Architecture, 2 nd Edition. David Money Harris and Sarah L. Harris. Chapter 5 <1>

EECS150 - Digital Design Lecture 10 - Combinational Logic Circuits Part 1

Adders, subtractors comparators, multipliers and other ALU elements

Midterm Exam Two is scheduled on April 8 in class. On March 27 I will help you prepare Midterm Exam Two.

Binary addition by hand. Adding two bits

Chapter 4. Combinational: Circuits with logic gates whose outputs depend on the present combination of the inputs. elements. Dr.

CSEE 3827: Fundamentals of Computer Systems. Combinational Circuits

Adders, subtractors comparators, multipliers and other ALU elements

3. Combinational Circuit Design

IT T35 Digital system desigm y - ii /s - iii

Lecture 4. Adders. Computer Systems Laboratory Stanford University

Adders allow computers to add numbers 2-bit ripple-carry adder

Chapter 4. Sequential Logic Circuits

Hw 6 due Thursday, Nov 3, 5pm No lab this week

Chapter 5 Arithmetic Circuits

HIGH SPEED AND INDEPENDENT CARRY CHAIN CARRY LOOK AHEAD ADDER (CLA) IMPLEMENTATION USING CADENCE-EDA K.Krishna Kumar 1, A.

UNIT II COMBINATIONAL CIRCUITS:

ISSN (PRINT): , (ONLINE): , VOLUME-4, ISSUE-10,

Sequential Logic Circuits

L8/9: Arithmetic Structures

CSE140: Components and Design Techniques for Digital Systems. Decoders, adders, comparators, multipliers and other ALU elements. Tajana Simunic Rosing

CprE 281: Digital Logic

Lecture 14: State Tables, Diagrams, Latches, and Flip Flop

14:332:231 DIGITAL LOGIC DESIGN

EECS150 - Digital Design Lecture 22 - Arithmetic Blocks, Part 1

Computer Science 324 Computer Architecture Mount Holyoke College Fall Topic Notes: Digital Logic

Design of A Efficient Hybrid Adder Using Qca

CSE140: Components and Design Techniques for Digital Systems. Logic minimization algorithm summary. Instructor: Mohsen Imani UC San Diego

Overview. Arithmetic circuits. Binary half adder. Binary full adder. Last lecture PLDs ROMs Tristates Design examples

Sequential Logic Worksheet

CS61C : Machine Structures

CS/COE0447: Computer Organization

Computer Architecture. ECE 361 Lecture 5: The Design Process & ALU Design. 361 design.1

Lecture 7: Logic design. Combinational logic circuits

Lecture 5: Arithmetic

CS61C : Machine Structures

EC 413 Computer Organization

TEST 1 REVIEW. Lectures 1-5

Solutions for Appendix C Exercises

Lecture 22 Chapters 3 Logic Circuits Part 1

ALU A functional unit

Lecture: Pipelining Basics

ECEN 248: INTRODUCTION TO DIGITAL SYSTEMS DESIGN. Week 9 Dr. Srinivas Shakkottai Dept. of Electrical and Computer Engineering

Computers also need devices capable of Storing data and information Performing mathematical operations on such data

CprE 281: Digital Logic

ECE 2300 Digital Logic & Computer Organization

Memory Elements I. CS31 Pascal Van Hentenryck. CS031 Lecture 6 Page 1

CS/COE0447: Computer Organization and Assembly Language

CMPUT 329. Circuits for binary addition

CprE 281: Digital Logic

Lecture 10: Sequential Networks: Timing and Retiming

Sequential Logic (3.1 and is a long difficult section you really should read!)

CMPEN 411 VLSI Digital Circuits Spring Lecture 19: Adder Design

DESIGN OF LOW POWER-DELAY PRODUCT CARRY LOOK AHEAD ADDER USING MANCHESTER CARRY CHAIN

CS/COE0447: Computer Organization

5. Sequential Logic x Computation Structures Part 1 Digital Circuits. Copyright 2015 MIT EECS

Datapath Component Tradeoffs

Number representation

Timing Constraints in Sequential Designs. 63 Sources: TSR, Katz, Boriello & Vahid

Slides for Lecture 16

Computer Architecture. ESE 345 Computer Architecture. Design Process. CA: Design process

Counters. We ll look at different kinds of counters and discuss how to build them

Looking at a two binary digit sum shows what we need to extend addition to multiple binary digits.

DIGITAL TECHNICS. Dr. Bálint Pődör. Óbuda University, Microelectronics and Technology Institute

EECS150. Arithmetic Circuits

DESIGN OF AREA DELAY EFFICIENT BINARY ADDERS IN QUANTUM-DOT CELLULAR AUTOMATA

Chapter 03: Computer Arithmetic. Lesson 03: Arithmetic Operations Adder and Subtractor circuits Design

EE40 Lec 15. Logic Synthesis and Sequential Logic Circuits

Carry Look Ahead Adders

Digital Logic: Boolean Algebra and Gates. Textbook Chapter 3

VLSI Design. [Adapted from Rabaey s Digital Integrated Circuits, 2002, J. Rabaey et al.] ECE 4121 VLSI DEsign.1

EECS 427 Lecture 8: Adders Readings: EECS 427 F09 Lecture 8 1. Reminders. HW3 project initial proposal: due Wednesday 10/7

Floating Point Representation and Digital Logic. Lecture 11 CS301

International Journal of Scientific & Engineering Research, Volume 6, Issue 6, June ISSN

Boolean Algebra and Digital Logic 2009, University of Colombo School of Computing

Mark Redekopp, All rights reserved. Lecture 1 Slides. Intro Number Systems Logic Functions

VLSI Physical Design Prof. Indranil Sengupta Department of Computer Science and Engineering Indian Institute of Technology, Kharagpur

ELEN Electronique numérique

Introduction to Digital Logic

211: Computer Architecture Summer 2016

CS 140 Lecture 14 Standard Combinational Modules

Bit-Sliced Design. EECS 141 F01 Arithmetic Circuits. A Generic Digital Processor. Full-Adder. The Binary Adder

Logic Design II (17.342) Spring Lecture Outline

EE141- Spring 2004 Digital Integrated Circuits

Topic 8: Sequential Circuits

MASSACHUSETTS INSTITUTE OF TECHNOLOGY Department of Electrical Engineering and Computer Sciences

Sample Test Paper - I

Stop Watch (System Controller Approach)

University of Toronto Faculty of Applied Science and Engineering Final Examination

Memory, Latches, & Registers

Slide Set 6. for ENEL 353 Fall Steve Norman, PhD, PEng. Electrical & Computer Engineering Schulich School of Engineering University of Calgary

CS/COE1541: Introduction to Computer Architecture. Logic Design Review. Sangyeun Cho. Computer Science Department University of Pittsburgh

CMSC 313 Lecture 17. Focus Groups. Announcement: in-class lab Thu 10/30 Homework 3 Questions Circuits for Addition Midterm Exam returned

Transcription:

Lecture 12: Adders, Sequential Circuits Today s topics: Carry-lookahead adder Clocks, latches, sequential circuits 1

Incorporating beq Perform a b and confirm that the result is all zero s Source: H&P textbook 2

Control Lines What are the values of the control lines and what operations do they correspond to? Source: H&P textbook 3

Control Lines What are the values of the control lines and what operations do they correspond to? Ai Bn Op AND 0 0 00 OR 0 0 01 Add 0 0 10 Sub 0 1 10 SLT 0 1 11 NOR 1 1 00 Source: H&P textbook 4

Speed of Ripple Carry The carry propagates thru every 1-bit box: each 1-bit box sequentially implements AND and OR total delay is the time to go through 64 gates! We ve already seen that any logic equation can be expressed as the sum of products so it should be possible to compute the result by going through only 2 gates! Caveat: need many parallel gates and each gate may have a very large number of inputs it is difficult to efficiently build such large gates, so we ll find a compromise: moderate number of gates moderate number of inputs to each gate moderate number of sequential gates traversed 5

Computing CarryOut CarryIn1 = b0.carryin0 + a0.carryin0 + a0.b0 CarryIn2 = b1.carryin1 + a1.carryin1 + a1.b1 = b1.b0.c0 + b1.a0.c0 + b1.a0.b0 + a1.b0.c0 + a1.a0.c0 + a1.a0.b0 + a1.b1 CarryIn32 = a really large sum of really large products Potentially fast implementation as the result is computed by going thru just 2 levels of logic unfortunately, each gate is enormous and slow 6

Generate and Propagate Equation re-phrased: Ci+1 = ai.bi + ai.ci + bi.ci = (ai.bi) + (ai + bi).ci Stated verbally, the current pair of bits will generate a carry if they are both 1 and the current pair of bits will propagate a carry if either is 1 Generate signal = ai.bi Propagate signal = ai + bi Therefore, Ci+1 = Gi + Pi. Ci 7

Generate and Propagate c1 = g0 + p0.c0 c2 = g1 + p1.c1 = g1 + p1.g0 + p1.p0.c0 c3 = g2 + p2.g1 + p2.p1.g0 + p2.p1.p0.c0 c4 = g3 + p3.g2 + p3.p2.g1 + p3.p2.p1.g0 + p3.p2.p1.p0.c0 Either, a carry was just generated, or a carry was generated in the last step and was propagated, or a carry was generated two steps back and was propagated by both the next two stages, or a carry was generated N steps back and was propagated by every single one of the N next stages 8

Divide and Conquer The equations on the previous slide are still difficult to implement as logic functions for the 32 nd bit, we must AND every single propagate bit to determine what becomes of c0 (among other things) Hence, the bits are broken into groups (of 4) and each group computes its group-generate and group-propagate For example, to add 32 numbers, you can partition the task as a tree..................... 9

P and G for 4-bit Blocks Compute P0 and G0 (super-propagate and super-generate) for the first group of 4 bits (and similarly for other groups of 4 bits) P0 = p0.p1.p2.p3 G0 = g3 + g2.p3 + g1.p2.p3 + g0.p1.p2.p3 Carry out of the first group of 4 bits is C1 = G0 + P0.c0 C2 = G1 + P1.G0 + P1.P0.c0 C3 = G2 + (P2.G1) + (P2.P1.G0) + (P2.P1.P0.c0) C4 = G3 + (P3.G2) + (P3.P2.G1) + (P3.P2.P1.G0) + (P3.P2.P1.P0.c0) By having a tree of sub-computations, each AND, OR gate has few inputs and logic signals have to travel through a modest set of gates (equal to the height of the tree) 10

Example Add A 0001 1010 0011 0011 B 1110 0101 1110 1011 g 0000 0000 0010 0011 p 1111 1111 1111 1011 P 1 1 1 0 G 0 0 1 0 C4 = 1 11

Carry Look-Ahead Adder 16-bit Ripple-carry takes 32 steps This design takes how many steps? Source: H&P textbook 12

Clocks A microprocessor is composed of many different circuits that are operating simultaneously if each circuit X takes in inputs at time TI X, takes time TE X to execute the logic, and produces outputs at time TO X, imagine the complications in co-ordinating the tasks of every circuit A major school of thought (used in most processors built today): all circuits on the chip share a clock signal (a square wave) that tells every circuit when to accept inputs, how much time they have to execute the logic, and when they must produce outputs 13

Clock Terminology Cycle time Rising clock edge Falling clock edge 4 GHz = clock speed = 1 = 1. cycle time 250 ps 14

Sequential Circuits Until now, circuits were combinational when inputs change, the outputs change after a while (time = logic delay thru circuit) Inputs Combinational Circuit Outputs Combinational Circuit We want the clock to act like a start and stop signal a latch is a storage device that separates these circuits it ensures that the inputs to the circuit do not change during a clock cycle Clock Clock Inputs Combinational Circuit Outputs Combinational Circuit Latch Latch 15

Sequential Circuits Sequential circuit: consists of combinational circuit and a storage element At the start of the clock cycle, the rising edge causes the state storage to store some input values Inputs Clock Inputs State Combinational Cct Outputs This state will not change for an entire cycle (until next rising edge) The combinational circuit has some time to accept the value of state and inputs and produce outputs Some of the outputs (for example, the value of next state ) may feed back (but through the latch so they re only seen in the next cycle) 16

Title Bullet 17