Learning Outcomes. Spiral 2 2. Digital System Design DATAPATH COMPONENTS
|
|
- Jason Mason
- 5 years ago
- Views:
Transcription
1 Learning Outcomes piral 2 2 Arithmetic Components and Their Efficient Implementations I know how to combine overflow and subtraction results to determine comparison results of both signed and unsigned numbers I understand how combination multipliers can be built I understand how hierarchical carry lookahead logic can be used to produce logarithmic time delay for an adder Mark Redekopp Digital ystem Design Control (CU) and Datapath Unit (DPU) paradigm eparate logic into datapath elements that operate on data and control elements that generate control signals for datapath elements Datapath: s, muxes, comparators, counters, registers (shift, with enables, etc.), memories, FIFO s Control Unit: tate machines/sequencers DATAPATH COMPONENT clk reset Control ignals Control Condition ignals Data Inputs Datapath Data Outputs
2 Overflow Detecting Overflow Helps Us Perform Comparison OVERFLOW & COMPARION Overflow occurs when the result of an arithmetic operation is to be represented with the given number of bits Unsigned overflow occurs when adding or subtracting unsigned numbers igned (2 s complement overflow) overflow occurs when adding or subtracting 2 s complement numbers Unsigned Overflow 2 s Complement Overflow + 7 = 7 With 4-bit unsigned numbers we can only represent 5. Thus, we say overflow has occurred. Overflow occurs when you cross this discontinuity Plus = = - With 4-bit 2 s complement numbers we can only represent -8 to +7. Thus, we say overflow has occurred Overflow occurs when you cross this discontinuity
3 Testing for Overflow Most fundamental test Check if answer is (i.e. Positive + Positive yields a negative) Unsigned overflow test [Different for add or sub] Addition: If carry out of final position equals ubtraction: If carry out of final addition equals igned (2 s complement) overflow test [ame for add or sub] Only occurs if Alternate test: if of final column are different Testing for Unsigned Overflow Unsigned Overflow has occurred if Unsigned Addition: If final carry out = Unsigned ubtraction: If final carry out = Testing for 2 s Comp. Overflow Checking for Overflow 2 s Complement Overflow Occurs If Test : If pos. + pos. = neg. or neg. + neg. = pos. Test 2: If carry in to MB position and carry out of MB position are different Produce additional outputs to indicate if unsigned (UOV) or signed (OV) overflow has occurred + (5) (6) (-4) + (-7) + (3) (2) (-2) + (-6)
4 Comparison Via ubtraction COMPARION uppose we want to compare two numbers: A & B uppose we let DIFF = A B what could the result tell us If DIFF <, then If DIFF =, then IF DIFF >, then How would we know DIFF ==? If all bits of our answer. How would we know DIFF < (i.e. negative)? igned:! (but what about overflow) Unsigned: Huh? In unsigned there are no negative results Computing A<B from "Negative" Result Unsigned Comparator Unsigned Perform A B If A B would yield a negative result, this will appear as in an unsigned subtraction And we know unsigned subtraction overflow occurs if o just check if igned Perform A B If there is no overflow (V=), simply check if But if there is overflow?? Recall overflow has the effect of flipping the sign of the result to the opposite of what it should be. o if there is overflow (V=) check is (i.e. positive) ummary: A B is "truly" negative if: A comparator can be built by using a subtractor A=B A A[3:] A>B DIFF[3:] Res[3:] ubtractor B B[3:] C4 A<B
5 igned Comparator A comparator can be built by using a subtractor A=B A A[3:] Res[3:] DIFF[3:] A>B ADDER TIMING B ubtractor B[3:] C4 A<B Addition s Timing Be sure to connect first to = + = A chain of full adders presents an interesting timing analysis problem To correctly compute its own um and Carry out, each full adder requires the carry out bit from the full adder Because hardware works in parallel, the full adders further down the chain may produce the outputs because the carry has not had time to to them C out
6 Timing Example Assume that we were adding one set of inputs and then change to a new set of inputs: Old inputs: Old inputs: + = = New inputs: + = = Timing At the time just before we enter the new input values, all carries are s New inputs: Old inputs: + = = Time - C out Timing Now we enter the new inputs and all the s starting adding their respective inputs + = = Time Timing Each adder computes from the current inputs (notice the sum of is incorrect at this point) + = = Time New inputs: Due to propagation delay, the carries are still from the old inputs Now the carries are all based off the new inputs
7 Timing Timing The carry is rippling through each adder + = = Time 2 The carry is rippling through each adder + = = Time Timing Ripple Carry Only after the carry propagates through all the adders is the sum valid and correct + = = Time 4 The longest path through a chain of full adders is the carry path We say that the carry through the adder time C C C C C C out out in out in out C 4 C 3 C 2 C C
8 Ripple Carry Delay Glitches An n bit ripple carry adder has a worst case delay proportional to, output values due to arrival times of gate inputs Output Glitches Critical Path Delay of the carry causes glitches on the sum bits Glitch = momentarily, incorrect output value early late C C out out Critical Path = possible delay path Assume t sum = 5 ns, t carry = 4 ns 6 ns Co Ci 2 ns Co Ci 8 ns Co Ci 4 ns Co Ci 7 ns 3 ns 9 ns 5 ns Critical Path 3
9 Unsigned Multiplication Review ame rules as decimal multiplication Multiply each bit of Q by M shifting as you go An m bit * n bit mult. produces an bit result (i.e. n bit * n bit produces bit result) Notice each partial product is a shifted copy of M or (zero) MULTIPLIER * M (Multiplicand) Q (Multiplier) igned Multiplication Techniques igned Multiplication Techniques When adding signed (2 s comp.) numbers, some new issues arise Must Also, must worry about negative multiplier MB of multiplier has negative weight If MB=, * = = * = = * = = -4-6 * = = -4-6
10 Combinational Multiplier Partial Product (PP i ) Generation Multiply Q[i] * M if Q[i]= => PP i = if Q[i]= => PP i = Combinational Multiplier Partial Product (PP i ) Generation Multiply Q[i] * M if Q[i]= => PP i = if Q[i]= => PP i = gates can be used to generate each partial product M[3] M[2] M[] M[] M[3] M[2] M[] M[] if Q[ i]= if Q[ i]= Multiplication Overview Combinational Multiplier Multiplication approaches: equential: hift and Add produces one product bit per clock cycle time (usually slow) Combinational: Array multiplier uses an array of adders Can be as simple as N ripple carry adders for an NxN multiplication m3 m2 m m x q3 q2 q q m3q m2q mq mq m3q m2q mq mq - m3q2 m2q2 mq2 mq m3q3 m2q3 mq3 mq p7 p6 p5 p4 p3 p2 p p Partial Products must be added together Combinational multipliers require long propagation delay through the adders propagation delay is proportional to the number of partial products (i.e. number of bits of input) and the width of each adder AND Gate Array produces partial product terms
11 Array Multiplier Combinational Multiplier Can this be a HA? Maximum delay = Do you look for the longest path or the shortest path between any input and output? Compare with the delay of a shift and add method Critical Paths Combinational Multiplier Analysis Large Area due to bit adders n because the first adder adds the first two partial products and then each adder afterwards adds one more partial product Propagation delay is in two dimensions proportional to Critical Path Critical Path 2
12 Pipelined Multiplier Carry ave Multiplier Now try to pipeline the previous design m3q2 m2q2 mq2 mq2 m2q3 mq3 mq3 m3q3 m3q m2q mq mq m3q m2q mq mq Instead of propagating the carries to the left in the same row, carries are now sent down to the next stage to reduce stage delay and facilitate pipelining Co HA Co Ci Co Ci Co HA CA s m3q m3q m2q mq mq m2q mq mq Co Ci Co Ci Co Ci Co Ci Co Ci Co Ci Co HA m3q2 m2q2 mq2 mq2 Co Ci Co Ci Co Ci P[7] Co Ci P[6] Co Ci P[5] Co Ci P[4] Co HA Determine the maximum stage delay to decide the pipeline clock rate. Assume zero delay for stage latches. How does the latency of the pipeline compare with the simple combinational array of the previous stage? P[3] P[2] P[] P[] The upper three stages are 3 bit Carry ave s (CA s) each with 2 gate delays. The last stage is a Ripple Carry (RCA) which requires longer delay. It can be replaced by a CLA for larger multipliers. RCA m3q3 Co Ci P[7] P[6] m2q3 mq3 mq3 Co Ci Co Ci Co Ci Co Ci Co Ci P[5] P[4] P[3] P[2] P[] P[] Carry ave s Carry ave (3,2) s Consider the decimal addition of = 2 One way is to add to get and Here the column cannot be added is produced In the carry save style, we add the column and column simultaneous _ A carry save adder is also called a (3,2) adder or a (3,2) counter (refer to Computer Arithmetic Algorithms by Israel Koren) as it takes three vectors, adds them up, and reduces them to two vectors, namely a sum vector and a carry vector CA s are based on the principle that carries do not have to be added, but can be combined An n bit CA consist of n disjoint full adders + _ Carry vector um vector A[3] B[3] C[3] A[2] B[2] C[2] A[] B[] C[] A[] B[] C[] Co Z Co Z Co Z Co C[4] [3] C[3] [2] C[2] [] C[] [] Z
13 Ripple Carry s Ripple carry adders (RCA) are slow due to carry propagation At least 2 levels of logic per full adder Carry Lookahead s T ADDER Fast s Carry Lookahead Logic Rather than calculating one carry at a time and passing it down the chain, can we compute a group of carries at the same time To do this, let us define some new signals for each column of addition: p i = : This column will propagate a carry in (if there is one) to the carry out. p i is true when A i or B i is => p i = g i = : This column will generate a carry out whether or not the carry in is g i is true when A i and B i is => g i = Using these signals, we can define the carry out (c i+ ) as: c i+ = Define each carry in terms of p i, g i and the initial carry in (c ) and not in terms of carry chain (intermediate carries: c,c2,c3, ) c = c2 = c3 = c4 =
14 Carry Lookahead Analogy Consider the carry chain like a long tube broken into segments. Each segment is controlled by a valve (propagate signal) and can insert a fluid into that segment (generate signal) The carry out of the diagram below will be true if g is true or p is true and g is true, or p, p and c is true Carry Lookahead Use carry lookahead logic to generate all the carries in one shot and then create the sum Example 4 bit CLA shown below How many levels of logic is the adder? bit s 74L283 chip implements a 4 bit adder using CLA methodology A 3 A 2 A A = A + B 3 B 2 B B = B = A 3 B 3 A 2 B 2 A B A B 74L
15 6 Bit CLA But how would we make a 6 bit adder? hould we really just chain these fast 4 bit adders together? Or can we do better? A[5:2] B[5:2] A[:8] B[:8] A[7:4] B[7:4] A[3:] B[3:] C C6 _ C2 PG PG PG PG _ [5:2] [:8] [7:4] [3:] C8 _ C4 _ 6-bit RCA Delay = = gate delays Delay of the above adder design = = gates Let us improve by looking ahead at a higher level to produce C6, C2, C8, C4 in parallel What s the difference between the equation for G here and C4 on the previous slides Define P and G as the overall Propagate and Generate signals for a set of 4 bits P = p3 p2 p p G = g3 + p3 g2 + p3 p2 g + p3 p2 p g REVIEW ON OUR OWN FOR CLA LAB bit CLA Closer Look 6 Bit CLA Each 4 bit CLA only propagates its overall carry in if each of the 4 columns propagates: P = p3 p2 p p P = p7 p6 p5 p4 P2 = p p p9 p8 P3 = p5 p4 p3 p2 Each 4 bit CLA generates a carry if any column generates and the more significant columns propagate G = g3 + (p3 g2) + (p3 p2 g)+(p3 p2 p g) G3 = g5 + (p5 g4) + (p5 p4 g3)+(p5 p4 p3 g2) The higher order CLL logic (producing C4,C8,C2,C6) then is realized as: (C4) =>C = G + (P c) (C6) => C4 = G3 + (P3 G2) + (P3 P2 G) +(P3 P2 P G)+ (P3 P2 P P c) These equations are exactly the same CLL logic we derived earlier C6 Understanding 6 bit CLA hierarchy PG G c5 p3 g3 c4 P* G* CLL PG CLL PG CLL P G CLL C2 c3 p2 g2 C8 CLL p g Delay = = = Delay in producing pi,gi = = Delay in producing Pi*,Gi* = = Delay in producing C4,C8,C2,C6 = = Delay in producing c5 = = Delay in producing 5 c2 C4 c p g c C
16 64 Bit CLA We can reuse the same CLL logic to build a 64 bit CLA C c63 s35 C6 PG G C56 C52 C44 C4 C36 C28 C24 C2 C2 C8 CLL PG CLL PG CLL P G CLL C4 C48 C32 C6 p3 g3 c4 P* G* c3 p2 g2 c2 CLL p g c p g c = = Delay in producing 63 Is the delay in producing s63 the same as in s35? = = Delay in producing 2 = = Delay in producing = = Delay in producing pi*,gi* = = Delay in producing Pj**,Gj** = = Delay in producing C48 = = Delay in producing C6 = = Delay in producing C63 = = Delay in producing 63 = Total Delay
Learning Outcomes. Spiral 2-2. Digital System Design DATAPATH COMPONENTS
2-2. 2-2.2 Learning Outcomes piral 2-2 Arithmetic Components and Their Efficient Implementations I understand the control inputs to counters I can design logic to control the inputs of counters to create
More informationLearning Outcomes. Spiral 2 2. Digital System Design DATAPATH COMPONENTS
2-2. 2-2.2 Learning Outcomes piral 2 2 Arithmetic Components and Their Efficient Implementations I know how to combine overflow and subtraction results to determine comparison results of both signed and
More informationMULTIPLICATION TECHNIQUES
Learning Objectives EE 357 Unit 2a Multiplication Techniques Perform by hand the different methods for unsigned and signed multiplication Understand the various digital implementations of a multiplier
More information11.1. Unit 11. Adders & Arithmetic Circuits
. Unit s & Arithmetic Circuits .2 Learning Outcomes I understand what gates are used to design half and full adders I can build larger arithmetic circuits from smaller building blocks ADDER.3 (+) Register.4
More informationOverview. EECS Components and Design Techniques for Digital Systems. Lec 16 Arithmetic II (Multiplication) Computer Number Systems.
Overview EE 15 - omponents and Design Techniques for Digital ystems Lec 16 Arithmetic II (Multiplication) Review of Addition Overflow Multiplication Further adder optimizations for multiplication LA in
More informationMark Redekopp, All rights reserved. EE 352 Unit 8. HW Constructs
EE 352 Unit 8 HW Constructs Logic Circuits Combinational logic Perform a specific function (mapping of 2 n input combinations to desired output combinations) No internal state or feedback Given a set of
More informationArithmetic Logic Unit. Digital Computer Design
Arithmetic Logic Unit Digital Computer Design Arithmetic Circuits Arithmetic circuits are the central building blocks of computers. Computers and digital logic perform many arithmetic functions: addition,
More informationEE 101 Lab 5 Fast Adders
EE 0 Lab 5 Fast Adders Introduction In this lab you will compare the performance of a 6-bit ripple-carry adder (RCA) with a 6-bit carry-lookahead adder (CLA). The 6-bit CLA will be implemented hierarchically
More informationEE 109 Unit 6 Binary Arithmetic
EE 109 Unit 6 Binary Arithmetic 1 2 Semester Transition Point At this point we are going to start to transition in our class to look more at the hardware organization and the low-level software that is
More informationWeek 7: Assignment Solutions
Week 7: Assignment Solutions 1. In 6-bit 2 s complement representation, when we subtract the decimal number +6 from +3, the result (in binary) will be: a. 111101 b. 000011 c. 100011 d. 111110 Correct answer
More informationT insn-mem T regfile T ALU T data-mem T regfile
This Unit: rithmetic CI 371 Computer Organization and Design Unit 3: rithmetic pp pp pp ystem software Mem CPU I/O! little review! Binary + 2s complement! Ripple-carry addition (RC)! Fast integer addition!
More informationComputer Architecture and Organization
3-1 Chapter 3 - Arithmetic Computer Architecture and Organization Miles Murdocca and Vincent Heuring Chapter 3 Arithmetic 3-2 Chapter 3 - Arithmetic Chapter Contents 3.1 Fixed Point Addition and Subtraction
More informationSemester Transition Point. EE 109 Unit 11 Binary Arithmetic. Binary Arithmetic ARITHMETIC
1 2 Semester Transition Point EE 109 Unit 11 Binary Arithmetic At this point we are going to start to transition in our class to look more at the hardware organization and the low-level software that is
More informationDepartment of Electrical and Computer Engineering University of Wisconsin - Madison. ECE/CS 352 Digital System Fundamentals.
Department of Electrical and Computer Engineering University of Wisconsin - Madison ECE/C 352 Digital ystem Fundamentals Quiz #2 Thursday, March 7, 22, 7:15--8:3PM 1. (15 points) (a) (5 points) NAND, NOR
More informationECE 341 Midterm Exam
ECE 341 Midterm Exam Time allowed: 90 minutes Total Points: 75 Points Scored: Name: Problem No. 1 (10 points) For each of the following statements, indicate whether the statement is TRUE or FALSE: (a)
More informationBinary Arithmetic. Daniel Sanchez Computer Science & Artificial Intelligence Lab M.I.T.
Binary Arithmetic Daniel Sanchez Computer Science & Artificial Intelligence Lab M.I.T. MIT 6.004 Fall 2018 Reminder: Encoding Positive Integers Bit i in a binary representation (in right-to-left order)
More informationDIGITAL TECHNICS. Dr. Bálint Pődör. Óbuda University, Microelectronics and Technology Institute
DIGITAL TECHNIC Dr. Bálint Pődör Óbuda University, Microelectronics and Technology Institute 4. LECTURE: COMBINATIONAL LOGIC DEIGN: ARITHMETIC (THROUGH EXAMPLE) 2nd (Autumn) term 28/29 COMBINATIONAL LOGIC
More informationArithmetic Circuits. Nurul Hazlina Adder 2. Multiplier 3. Arithmetic Logic Unit (ALU) 4. HDL for Arithmetic Circuit
Nurul Hazlina 1 1. Adder 2. Multiplier 3. Arithmetic Logic Unit (ALU) 4. HDL for Arithmetic Circuit Nurul Hazlina 2 Introduction 1. Digital circuits are frequently used for arithmetic operations 2. Fundamental
More informationECE 30 Introduction to Computer Engineering
ECE 30 Introduction to Computer Engineering Study Problems, Set #6 Spring 2015 1. With x = 1111 1111 1111 1111 1011 0011 0101 0011 2 and y = 0000 0000 0000 0000 0000 0010 1101 0111 2 representing two s
More informationAddition and multiplication
Addition and multiplication Arithmetic is the most basic thing you can do with a computer, but it s not as easy as you might expect! These next few lectures focus on addition, subtraction, multiplication
More informationVTU NOTES QUESTION PAPERS NEWS RESULTS FORUMS Arithmetic (a) The four possible cases Carry (b) Truth table x y
Arithmetic A basic operation in all digital computers is the addition and subtraction of two numbers They are implemented, along with the basic logic functions such as AND,OR, NOT,EX- OR in the ALU subsystem
More informationChapter 3 Arithmetic for Computers
Chapter 3 Arithmetic for Computers 1 Arithmetic Where we've been: Abstractions: Instruction Set Architecture Assembly Language and Machine Language What's up ahead: Implementing the Architecture operation
More informationTiming for Ripple Carry Adder
Timing for Ripple Carry Adder 1 2 3 Look Ahead Method 5 6 7 8 9 Look-Ahead, bits wide 10 11 Multiplication Simple Gradeschool Algorithm for 32 Bits (6 Bit Result) Multiplier Multiplicand AND gates 32
More informationChapter 5. Digital Design and Computer Architecture, 2 nd Edition. David Money Harris and Sarah L. Harris. Chapter 5 <1>
Chapter 5 Digital Design and Computer Architecture, 2 nd Edition David Money Harris and Sarah L. Harris Chapter 5 Chapter 5 :: Topics Introduction Arithmetic Circuits umber Systems Sequential Building
More informationECE 341 Midterm Exam
ECE 341 Midterm Exam Time allowed: 75 minutes Total Points: 75 Points Scored: Name: Problem No. 1 (8 points) For each of the following statements, indicate whether the statement is TRUE or FALSE: (a) A
More informationChapter 3 Part 2 Combinational Logic Design
University of Wisconsin - Madison EE/omp ci 352 Digital ystems Fundamentals Kewal K. aluja and u Hen Hu pring 2002 hapter 3 Part 2 ombinational Logic Design Originals by: harles R. Kime and Tom Kamisnski
More informationDigital Circuit Design and Language. Datapath Design. Chang, Ik Joon Kyunghee University
Digital Circuit Design and Language Datapath Design Chang, Ik Joon Kyunghee University Typical Synchronous Design + Control Section : Finite State Machine + Data Section: Adder, Multiplier, Shift Register
More informationThis Unit: Arithmetic. CIS 371 Computer Organization and Design. Readings. Pre Class Exercise
This Unit: Arithmetic CI 371 Computer Organization and Design Unit 4: Arithmetic Based on slides by Prof. Amir Roth & Prof. Milo Martin App App App ystem software Mem CPU I/O A little review Binary + 2s
More informationECE 341 Final Exam Solution
ECE 341 Final Exam Solution Time allowed: 110 minutes Total Points: 100 Points Scored: Name: Problem No. 1 (10 points) For each of the following statements, indicate whether the statement is TRUE or FALSE.
More informationJan Rabaey Homework # 7 Solutions EECS141
UNIVERSITY OF CALIFORNIA College of Engineering Department of Electrical Engineering and Computer Sciences Last modified on March 30, 2004 by Gang Zhou (zgang@eecs.berkeley.edu) Jan Rabaey Homework # 7
More informationPrinciples of Computer Architecture. Chapter 3: Arithmetic
3-1 Chapter 3 - Arithmetic Principles of Computer Architecture Miles Murdocca and Vincent Heuring Chapter 3: Arithmetic 3-2 Chapter 3 - Arithmetic 3.1 Overview Chapter Contents 3.2 Fixed Point Addition
More informationDigital Logic & Computer Design CS Professor Dan Moldovan Spring 2010
Digital Logic & Computer Design CS 434 Professor Dan Moldovan Spring 2 Copyright 27 Elsevier 5- Chapter 5 :: Digital Building Blocks Digital Design and Computer Architecture David Money Harris and Sarah
More informationBinary Adders: Half Adders and Full Adders
Binary Adders: Half Adders and Full Adders In this set of slides, we present the two basic types of adders: 1. Half adders, and 2. Full adders. Each type of adder functions to add two binary bits. In order
More informationLecture 5. Other Adder Issues
Lecture 5 Other Adder Issues Mark Horowitz Computer Systems Laboratory Stanford University horowitz@stanford.edu Copyright 24 by Mark Horowitz with information from Brucek Khailany 1 Overview Reading There
More informationCS/COE0447: Computer Organization
CS/COE0447: Computer Organization and Assembly Language Chapter 3 Sangyeun Cho Dept. of Computer Science Five classic components I am like a control tower I am like a pack of file folders I am like a conveyor
More informationCS/COE0447: Computer Organization
Five classic components CS/COE0447: Computer Organization and Assembly Language I am like a control tower I am like a pack of file folders Chapter 3 I am like a conveyor belt + service stations I exchange
More informationReal Digital Problem Set #6
Real igital Problem et #6. (2 points) ketch a block diagram for a magnitude comparator bit-slice circuit. Create K-maps to define the bit-slice circuit, and use them to find optimal logic equations. ketch
More informationWriting Circuit Descriptions 8
8 Writing Circuit Descriptions 8 You can write many logically equivalent descriptions in Verilog to describe a circuit design. However, some descriptions are more efficient than others in terms of the
More information*Instruction Matters: Purdue Academic Course Transformation. Introduction to Digital System Design. Module 4 Arithmetic and Computer Logic Circuits
Purdue IM:PACT* Fall 2018 Edition *Instruction Matters: Purdue Academic Course Transformation Introduction to Digital System Design Module 4 Arithmetic and Computer Logic Circuits Glossary of Common Terms
More informationOutline. Introduction to Structured VLSI Design. Signed and Unsigned Integers. 8 bit Signed/Unsigned Integers
Outline Introduction to Structured VLSI Design Integer Arithmetic and Pipelining Multiplication in the digital domain HW mapping Pipelining optimization Joachim Rodrigues Signed and Unsigned Integers n-1
More informationUNIVERSITY OF MASSACHUSETTS Dept. of Electrical & Computer Engineering. Digital Computer Arithmetic ECE 666
UNIVERSITY OF MASSACHUSETTS Dept. of Electrical & Computer Engineering Digital Computer Arithmetic ECE 666 Part 6c High-Speed Multiplication - III Israel Koren Fall 2010 ECE666/Koren Part.6c.1 Array Multipliers
More informationMASSACHUSETTS INSTITUTE OF TECHNOLOGY Department of Electrical Engineering and Computer Sciences
MASSACHUSETTS INSTITUTE OF TECHNOLOGY Department of Electrical Engineering and Computer Sciences Introductory Digital Systems Lab (6.111) uiz - Spring 2004 Prof. Anantha Chandrakasan Student Name: Problem
More informationChapter 3: part 3 Binary Subtraction
Chapter 3: part 3 Binary Subtraction Iterative combinational circuits Binary adders Half and full adders Ripple carry and carry lookahead adders Binary subtraction Binary adder-subtractors Signed binary
More informationTailoring the 32-Bit ALU to MIPS
Tailoring the 32-Bit ALU to MIPS MIPS ALU extensions Overflow detection: Carry into MSB XOR Carry out of MSB Branch instructions Shift instructions Slt instruction Immediate instructions ALU performance
More informationChapter 4. Combinational Logic
Chapter 4. Combinational Logic Tong In Oh 1 4.1 Introduction Combinational logic: Logic gates Output determined from only the present combination of inputs Specified by a set of Boolean functions Sequential
More informationEE878 Special Topics in VLSI. Computer Arithmetic for Digital Signal Processing
EE878 Special Topics in VLSI Computer Arithmetic for Digital Signal Processing Part 6c High-Speed Multiplication - III Spring 2017 Koren Part.6c.1 Array Multipliers The two basic operations - generation
More informationMicrocomputers. Outline. Number Systems and Digital Logic Review
Microcomputers Number Systems and Digital Logic Review Lecture 1-1 Outline Number systems and formats Common number systems Base Conversion Integer representation Signed integer representation Binary coded
More informationCOMPUTER ORGANIZATION AND DESIGN. 5 th Edition. The Hardware/Software Interface. Chapter 3. Arithmetic for Computers Implementation
COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Interface 5 th Edition Chapter 3 Arithmetic for Computers Implementation Today Review representations (252/352 recap) Floating point Addition: Ripple
More informationNumber Systems. Readings: , Problem: Implement simple pocket calculator Need: Display, adders & subtractors, inputs
Number Systems Readings: 3-3.3.3, 3.3.5 Problem: Implement simple pocket calculator Need: Display, adders & subtractors, inputs Display: Seven segment displays Inputs: Switches Missing: Way to implement
More informationBinary Adders. Ripple-Carry Adder
Ripple-Carry Adder Binary Adders x n y n x y x y c n FA c n - c 2 FA c FA c s n MSB position Longest delay (Critical-path delay): d c(n) = n d carry = 2n gate delays d s(n-) = (n-) d carry +d sum = 2n
More informationArithmetic Circuits. Design of Digital Circuits 2014 Srdjan Capkun Frank K. Gürkaynak.
Arithmetic Circuits Design of Digital Circuits 2014 Srdjan Capkun Frank K. Gürkaynak http://www.syssec.ethz.ch/education/digitaltechnik_14 Adapted from Digital Design and Computer Architecture, David Money
More informationECE331: Hardware Organization and Design
ECE331: Hardware Organization and Design Lecture 9: Binary Addition & Multiplication Adapted from Computer Organization and Design, Patterson & Hennessy, UCB Pop Quiz! Using 4 bits signed integer notation:
More informationCS 5803 Introduction to High Performance Computer Architecture: Arithmetic Logic Unit. A.R. Hurson 323 CS Building, Missouri S&T
CS 5803 Introduction to High Performance Computer Architecture: Arithmetic Logic Unit A.R. Hurson 323 CS Building, Missouri S&T hurson@mst.edu 1 Outline Motivation Design of a simple ALU How to design
More informationAn FPGA based Implementation of Floating-point Multiplier
An FPGA based Implementation of Floating-point Multiplier L. Rajesh, Prashant.V. Joshi and Dr.S.S. Manvi Abstract In this paper we describe the parameterization, implementation and evaluation of floating-point
More informationChapter 3 Part 2 Combinational Logic Design
University of Wisconsin - Madison ECE/Comp Sci 352 Digital Systems Fundamentals Kewal K. Saluja and Yu Hen Hu Spring 2002 Chapter 3 Part 2 Combinational Logic Design Originals by: Charles R. Kime and Tom
More informationAn Efficient Fused Add Multiplier With MWT Multiplier And Spanning Tree Adder
An Efficient Fused Add Multiplier With MWT Multiplier And Spanning Tree Adder 1.M.Megha,M.Tech (VLSI&ES),2. Nataraj, M.Tech (VLSI&ES), Assistant Professor, 1,2. ECE Department,ST.MARY S College of Engineering
More informationAt the ith stage: Input: ci is the carry-in Output: si is the sum ci+1 carry-out to (i+1)st state
Chapter 4 xi yi Carry in ci Sum s i Carry out c i+ At the ith stage: Input: ci is the carry-in Output: si is the sum ci+ carry-out to (i+)st state si = xi yi ci + xi yi ci + xi yi ci + xi yi ci = x i yi
More informationRevision: August 31, E Main Suite D Pullman, WA (509) Voice and Fax
Exercise 7: Combinational rithmetic Circuits Revision: ugust 3, 29 25 E Main uite D Pullman, W 9963 (59) 334 636 Voice and Fax TUDENT I am submitting my own work, and I understand penalties will be assessed
More informationEKT 422/4 COMPUTER ARCHITECTURE. MINI PROJECT : Design of an Arithmetic Logic Unit
EKT 422/4 COMPUTER ARCHITECTURE MINI PROJECT : Design of an Arithmetic Logic Unit Objective Students will design and build a customized Arithmetic Logic Unit (ALU). It will perform 16 different operations
More informationComputer Architecture Set Four. Arithmetic
Computer Architecture Set Four Arithmetic Arithmetic Where we ve been: Performance (seconds, cycles, instructions) Abstractions: Instruction Set Architecture Assembly Language and Machine Language What
More informationBinary Multiplication
inary Multiplication The key to multiplication was memorizing a digit-by-digit table Everything else was just adding 2 3 4 5 6 7 8 9 2 3 4 5 6 7 8 9 2 2 4 6 8 2 4 6 8 3 3 6 9 2 5 8 2 24 27 + You ve got
More informationDIGITAL ARITHMETIC: OPERATIONS AND CIRCUITS
C H A P T E R 6 DIGITAL ARITHMETIC: OPERATIONS AND CIRCUITS OUTLINE 6- Binary Addition 6-2 Representing Signed Numbers 6-3 Addition in the 2 s- Complement System 6-4 Subtraction in the 2 s- Complement
More information1. Prove that if you have tri-state buffers and inverters, you can build any combinational logic circuit. [4]
HW 3 Answer Key 1. Prove that if you have tri-state buffers and inverters, you can build any combinational logic circuit. [4] You can build a NAND gate from tri-state buffers and inverters and thus you
More informationCAD4 The ALU Fall 2009 Assignment. Description
CAD4 The ALU Fall 2009 Assignment To design a 16-bit ALU which will be used in the datapath of the microprocessor. This ALU must support two s complement arithmetic and the instructions in the baseline
More informationFundamentals of Computer Systems
Fundamentals of Computer Systems Combinational Logic Martha. Kim Columbia University Spring 6 / Combinational Circuits Combinational circuits are stateless. Their output is a function only of the current
More informationL11: Major/Minor FSMs
L11: Major/Minor FSMs Acknowledgements: Materials in this lecture are courtesy of the following sources and are used with permission. Rex Min 1 Quiz Quiz will be Closed Book Tuesday, March 21, 2006, 7:30pm-9:30pm
More informationPESIT Bangalore South Campus
INTERNAL ASSESSMENT TEST III Date : 21/11/2017 Max Marks : 40 Subject & Code : Computer Organization (15CS34) Semester : III (A & B) Name of the faculty: Mrs. Sharmila Banu Time : 11.30 am 1.00 pm Answer
More informationCS6303 COMPUTER ARCHITECTURE LESSION NOTES UNIT II ARITHMETIC OPERATIONS ALU In computing an arithmetic logic unit (ALU) is a digital circuit that performs arithmetic and logical operations. The ALU is
More informationParallel logic circuits
Computer Mathematics Week 9 Parallel logic circuits College of Information cience and Engineering Ritsumeikan University last week the mathematics of logic circuits the foundation of all digital design
More informationChapter 3. ALU Design
COMPUTER ORGANIZATION AND DESIGN The Hardware/Software Interface 5 th Edition Chapter 3 ALU Design Review - A MIPS ALU Implementation add/subt A 0 op B 0 A 1 less + result 0 Zero detect (slt, slti,sltiu,sltu,
More informationHardware Design Environments. Dr. Mahdi Abbasi Computer Engineering Department Bu-Ali Sina University
Hardware Design Environments Dr. Mahdi Abbasi Computer Engineering Department Bu-Ali Sina University Outline Welcome to COE 405 Digital System Design Design Domains and Levels of Abstractions Synthesis
More informationECE 645: Lecture 1. Basic Adders and Counters. Implementation of Adders in FPGAs
ECE 645: Lecture Basic Adders and Counters Implementation of Adders in FPGAs Required Reading Behrooz Parhami, Computer Arithmetic: Algorithms and Hardware Design Chapter 5, Basic Addition and Counting,
More informationCPE300: Digital System Architecture and Design
CPE300: Digital System Architecture and Design Fall 2011 MW 17:30-18:45 CBC C316 Arithmetic Unit 10122011 http://www.egr.unlv.edu/~b1morris/cpe300/ 2 Outline Recap Fixed Point Arithmetic Addition/Subtraction
More informationEach DSP includes: 3-input, 48-bit adder/subtractor
Virtex-4 DSP Architecture 2 2 DSP slices per tile 16-256 tiles in 1-8 columns Each DSP includes: 3-input, 48-bit adder/subtractor P P = Z±(X+Y+Cin) Optional accum reg C (48) 18x18-bit 2's-comp multiplier
More informationArithmetic and Logical Operations
Arithmetic and Logical Operations 2 CMPE2c x +y + sum Or in tabular form Binary Addition Carry Out Sum B A Carry In Binary Addition And as a full adder a b co ci sum 4-bit Ripple-Carry adder: Carry values
More informationNumber Systems and Computer Arithmetic
Number Systems and Computer Arithmetic Counting to four billion two fingers at a time What do all those bits mean now? bits (011011011100010...01) instruction R-format I-format... integer data number text
More information9/6/2011. Multiplication. Binary Multipliers The key trick of multiplication is memorizing a digit-to-digit table Everything else was just adding
9/6/2 Multiplication Binary Multipliers The key trick of multiplication is memorizing a digit-to-digit table Everything else was just adding 2 3 4 5 6 7 8 9 2 3 4 5 6 7 8 9 2 2 4 6 8 2 4 6 8 3 3 6 9 2
More informationCOMP 303 Computer Architecture Lecture 6
COMP 303 Computer Architecture Lecture 6 MULTIPLY (unsigned) Paper and pencil example (unsigned): Multiplicand 1000 = 8 Multiplier x 1001 = 9 1000 0000 0000 1000 Product 01001000 = 72 n bits x n bits =
More informationCombinational Circuit Design
Modeling Combinational Circuits with Verilog Prof. Chien-Nan Liu TEL: 3-42275 ext:34534 Email: jimmy@ee.ncu.edu.tw 3- Combinational Circuit Design Outputs are functions of inputs inputs Combinational Circuit
More informationCS/COE 0447 Example Problems for Exam 2 Spring 2011
CS/COE 0447 Example Problems for Exam 2 Spring 2011 1) Show the steps to multiply the 4-bit numbers 3 and 5 with the fast shift-add multipler. Use the table below. List the multiplicand (M) and product
More informationFast Arithmetic. Philipp Koehn. 19 October 2016
Fast Arithmetic Philipp Koehn 19 October 2016 1 arithmetic Addition (Immediate) 2 Load immediately one number (s0 = 2) li $s0, 2 Add 4 ($s1 = $s0 + 4 = 6) addi $s1, $s0, 4 Subtract 3 ($s2 = $s1-3 = 3)
More informationUniversity of California at Berkeley College of Engineering Department of Electrical Engineering and Computer Sciences. Spring 2010 May 10, 2010
University of California at Berkeley College of Engineering Department of Electrical Engineering and Computer Sciences EECS150 J. Wawrzynek Spring 2010 May 10, 2010 Final Exam Name: ID number: This is
More informationCPE 335 Computer Organization. MIPS Arithmetic Part I. Content from Chapter 3 and Appendix B
CPE 335 Computer Organization MIPS Arithmetic Part I Content from Chapter 3 and Appendix B Dr. Iyad Jafar Adatped from Dr. Gheith Abandah Slides http://www.abandah.com/gheith/courses/cpe335_s08/index.html
More informationECE 341 Midterm Exam
ECE 341 Midterm Exam Time allowed: 90 minutes Total Points: 75 Points Scored: Name: Problem No. 1 (11 points) For parts (a) through (d), indicate whether the statement is TRUE or FALSE. For parts (e) and
More informationIntroduction to Digital Logic Missouri S&T University CPE 2210 Multipliers/Dividers
Introduction to Digital Logic Missouri S&T University CPE 2210 Multipliers/Dividers Egemen K. Çetinkaya Egemen K. Çetinkaya Department of Electrical & Computer Engineering Missouri University of Science
More informationUniversity of Illinois at Chicago. Lecture Notes # 10
ECE 366 Computer Architecture Instructor: Shantanu Dutt Department of Electrical and Computer Engineering University of Illinois at Chicago Lecture otes # 0 COMPUTER ARITHMETIC: Integer Addition and Multiplication
More informationComputer Arithmetic Multiplication & Shift Chapter 3.4 EEC170 FQ 2005
Computer Arithmetic Multiplication & Shift Chapter 3.4 EEC170 FQ 200 Multiply We will start with unsigned multiply and contrast how humans and computers multiply Layout 8-bit 8 Pipelined Multiplier 1 2
More informationECE 341. Lecture # 6
ECE 34 Lecture # 6 Instructor: Zeshan Chishti zeshan@pdx.edu October 5, 24 Portland State University Lecture Topics Design of Fast Adders Carry Looakahead Adders (CLA) Blocked Carry-Lookahead Adders Multiplication
More informationControl Unit: Binary Multiplier. Arturo Díaz-Pérez Departamento de Computación Laboratorio de Tecnologías de Información CINVESTAV-IPN
Control Unit: Binary Multiplier Arturo Díaz-Pérez Departamento de Computación Laboratorio de Tecnologías de Información CINVESTAV-IPN Example: Binary Multiplier Two versions Hardwired control Microprogrammed
More information8/27/2016. ECE 120: Introduction to Computing. Graphical Illustration of Modular Arithmetic. Representations Must be Unambiguous
University of Illinois at Urbana-Champaign Dept. of Electrical and Computer Engineering ECE 120: Introduction to Computing Signed Integers and 2 s Complement Strategy: Use Common Hardware for Two Representations
More informationCS Computer Architecture. 1. Explain Carry Look Ahead adders in detail
1. Explain Carry Look Ahead adders in detail A carry-look ahead adder (CLA) is a type of adder used in digital logic. A carry-look ahead adder improves speed by reducing the amount of time required to
More information4DM4 Lab. #1 A: Introduction to VHDL and FPGAs B: An Unbuffered Crossbar Switch (posted Thursday, Sept 19, 2013)
1 4DM4 Lab. #1 A: Introduction to VHDL and FPGAs B: An Unbuffered Crossbar Switch (posted Thursday, Sept 19, 2013) Lab #1: ITB Room 157, Thurs. and Fridays, 2:30-5:20, EOW Demos to TA: Thurs, Fri, Sept.
More informationLaboratory Exercise 6
Laboratory Exercie 6 Adder, Subtractor, and Multiplier The purpoe of thi exercie i to examine arithmetic circuit that add, ubtract, and multiply number. Each type of circuit will be implemented in two
More informationBy, Ajinkya Karande Adarsh Yoga
By, Ajinkya Karande Adarsh Yoga Introduction Early computer designers believed saving computer time and memory were more important than programmer time. Bug in the divide algorithm used in Intel chips.
More informationChapter 4 Arithmetic Functions
Logic and Computer Design Fundamentals Chapter 4 Arithmetic Functions Charles Kime & Thomas Kaminski 2008 Pearson Education, Inc. (Hyperlinks are active in View Show mode) Overview Iterative combinational
More informationECE468 Computer Organization & Architecture. The Design Process & ALU Design
ECE6 Computer Organization & Architecture The Design Process & Design The Design Process "To Design Is To Represent" Design activity yields description/representation of an object -- Traditional craftsman
More informationDue: Instructor: G. Puvvada
EE457 Homework 18 (not too long Due: Instructor: G. Puvvada in the wooden box outside EEB243 The material which was not tested in the midterm is very important for the final exam. The final exam is supposed
More informationBinary Addition. Add the binary numbers and and show the equivalent decimal addition.
Binary Addition The rules for binary addition are 0 + 0 = 0 Sum = 0, carry = 0 0 + 1 = 0 Sum = 1, carry = 0 1 + 0 = 0 Sum = 1, carry = 0 1 + 1 = 10 Sum = 0, carry = 1 When an input carry = 1 due to a previous
More informationData Representation Type of Data Representation Integers Bits Unsigned 2 s Comp Excess 7 Excess 8
Data Representation At its most basic level, all digital information must reduce to 0s and 1s, which can be discussed as binary, octal, or hex data. There s no practical limit on how it can be interpreted
More informationInteger Multiplication and Division
Integer Multiplication and Division for ENCM 369: Computer Organization Steve Norman, PhD, PEng Electrical & Computer Engineering Schulich School of Engineering University of Calgary Winter Term, 208 Integer
More information