Lecture 3 Combinational units. Adders

Slides:



Advertisements
Similar presentations
Modular Combinational Logic
Advertisements

1 KU College of Engineering Elec 204: Digital Systems Design Lecture 9 Programmable Configurations Read Only Memory (ROM) – –a fixed array of AND gates.
CSE-221 Digital Logic Design (DLD)
CSCE 211: Digital Logic Design Chin-Tser Huang University of South Carolina.
Combinatorial Logic Design Process. Example: Three 1s pattern detector Detect whether a pattern of at least three adjacent 1s occurs anywhere in an 8-bit.
ECE 301 – Digital Electronics
Chapter 5 Arithmetic Logic Functions. Page 2 This Chapter..  We will be looking at multi-valued arithmetic and logic functions  Bitwise AND, OR, EXOR,
Part 2: DESIGN CIRCUIT. LOGIC CIRCUIT DESIGN x y z F F = x + y’z x y z F Truth Table Boolean Function.
Outline Analysis of Combinational Circuits Signed Number Arithmetic
1 Introduction to Abstract Mathematics Applications : Digital Logic Circuits 2.4 and Number Systems 2.5 Instructor: Hayk Melikya
Digital Computer Concept and Practice Copyright ©2012 by Jaejin Lee Logic Circuits I.
ECE 3130 – Digital Electronics and Design
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.
Functions of Combinational Logic
Computer Organization & Programming Chapter4 Combinatorial Components.
Digital Computer Concept and Practice Copyright ©2012 by Jaejin Lee Logic Circuits I.
Digital Logic Problems (II) Prof. Sin-Min Lee Department of Mathematics and Computer Science.
Digital Logic Structures: Chapter 3 COMP 2610 Dr. James Money COMP
Lecture 9 Topics: –Combinational circuits Basic concepts Examples of typical combinational circuits –Half-adder –Full-adder –Ripple-Carry adder –Decoder.
Nov 10, 2008ECE 561 Lecture 151 Adders. Nov 10, 2008ECE 561 Lecture 152 Adders Basic Ripple Adders Faster Adders Sequential Adders.
4. Computer Maths and Logic 4.2 Boolean Logic Logic Circuits.
9/15/09 - L15 Decoders, Multiplexers Copyright Joanne DeGroat, ECE, OSU1 Decoders and Multiplexer Circuits.
1 Fundamentals of Computer Science Combinational Circuits.
Digital Design Lecture 8 Combinatorial Logic (Continued)
How does a Computer Add ? Logic Gates within chips: AND Gate A B Output OR Gate A B Output A B A B
Discrete Systems I Lecture 10 Adder and ALU Profs. Koike and Yukita.
1 The ALU l ALU includes combinational logic. –Combinational logic  a change in inputs directly causes a change in output, after a characteristic delay.
Mu.com.lec 11.  Used not only to perform addition but also to perform subtraction, multiplication and division  The most basic of the adders is the.
Lecture No. 14 Combinational Functional Devices. Digital Logic &Design Dr. Waseem Ikram Lecture 14.
Gunjeet Kaur Dronacharya Group of Institutions. Binary Adder-Subtractor A combinational circuit that performs the addition of two bits is called a half.
Combinational Circuits
ECE 3130 Digital Electronics and Design
ECE 3130 Digital Electronics and Design
Lecture 12 Logistics Last lecture Today HW4 due today Timing diagrams
Homework Reading Machine Projects Labs
Combinational Logic Logic circuits for digital systems may be combinational or sequential. A combinational circuit consists of input variables, logic gates,
Lecture 4: Combinational Functions and Circuits
Summary Half-Adder Basic rules of binary addition are performed by a half adder, which has two binary inputs (A and B) and two binary outputs (Carry out.
FUNCTION OF COMBINATIONAL LOGIC CIRCUIT
Unit5 Combinational circuit and instrumentation system.
EEL 3705 / 3705L Digital Logic Design
Basics Combinational Circuits Sequential Circuits
Basics Combinational Circuits Sequential Circuits Ahmad Jawdat
Combinatorial Logic Design Practices
ECE 331 – Digital System Design
CSE Winter 2001 – Arithmetic Unit - 1
CSCE 211: Digital Logic Design
CSCE 211: Digital Logic Design
Lecture 14 Logistics Last lecture Today
Arithmetic Circuits (Part I) Randy H
Programmable Configurations
Number Systems and Circuits for Addition
CSCE 211: Digital Logic Design
Homework Reading Machine Projects Labs
CSCE 211: Digital Logic Design
Part III The Arithmetic/Logic Unit
COMS 361 Computer Organization
Logic Circuits I Lecture 3.
Lecture 14 Logistics Last lecture Today
ECE 352 Digital System Fundamentals
Combinational Circuits
ECE 352 Digital System Fundamentals
Electronics for Physicists
XOR Function Logic Symbol  Description  Truth Table 
Digital Circuits and Logic
ECE 352 Digital System Fundamentals
Instruction execution and ALU
DeMorgan’s Law and Gates
Lecture 2 Platform 0 revisited
Lecture 4 Sequential units. Registers
Presentation transcript:

Lecture 3 Combinational units. Adders Computing platforms, semester 2 Novosibirsk State University University of Hertfordshire D. Irtegov, A.Shafarenko 2019

Some terminology Combinational units: pure logical functions. Output depends only on input No side effect (except delay) Can be described by single logical expression Sequential units: have internal state Output depends not only on the inputs Input can have side-effect (changing internal state) Require logical elements we did not study yet.

Popular combinatory units Decoder k inputs, 2k outputs. Interprets inputs as k-bit number n, sets n-th output to 1, all others to 0 Standard decoders usually have “Enable” input. When Enable is down, all outputs are down Multiplexer 2k m-bit inputs and one k-bit selector input Connects n-th input to the output

2x4 decoder

Multiplexer (mux)

So, the adder Two bit half adder Adds two bits and produces result and carry bit S=A⊕B, Cout=A^B

The full adder Has three inputs: A, B, Cin Also has two outputs: R and Cout Can be constructed from two half adders

Three-bit adder Place three full adders in a row Connect Cout0 to Cin1, etc Sounds simple and good enough for Logisim For real devices, carry must propagate from bit 0 to N This design is known as ripple carry adder Delay ~= O(N) We discuss this later

Logisim notation for repeating circuits

How to deal with carry propagation delay? A sequential adder. Carry propagation time for N-bit adder ~=N(delay of single adder) Why bother building N adders if they cannot actually work in parallel?

Carry-save adder Result is provided as two bits (carry not propagated) 10111010101011011111000000001101 + 11011110101011011011111011101111 = 21122120202022022122111011102212 To produce binary number, we still need to propagate carry But we can add these saved-carry numbers without converting to binary And propagate only on last stage Carry-save adders are used in multiplicators, in cryptography, etc

Carry-lookahead Instead of Cout, every adder provides two signals, P (propagate) and G (generate) P(A,B)=AvB G(A,B)=A^B Ci+1=Giv(Pi^Ci) Actually, a recursive formula C4=G3v(P3^G2)v(G1^P2^P3)v (G0^P1^P2^P3)v(C0^P0^P1^P2^P3) Gate count O(N2), but delay close to constant

4-bit carry lookahead in Logisim Delay depends on number of gates the signal passes between input and output NOT on total number of gates In this design, C3 produced from 7 input signals, but each of these signals pass only two gates So, we can improve speed by increasing number of gates In computing, simpler is not always better

Ways to produce multibit adder Often, a combination of ripple carry and carry lookahead is used 16-bit adder can be implemented from 4-bit units as: ripple-carry connected via carry-lookahead carry lookaheads connected via ripple carry carry lookaheads connected via second level carry lookahead Other tricks, like carry-skip (aka carry bypass) adder Read the Wikipedia…