EDA (CS286.5b) Day 16 Logic Synthesis: Multi-Level.

Slides:



Advertisements
Similar presentations
Prof. Sin-Min Lee Department of Computer Science
Advertisements

FPGA-Based System Design: Chapter 4 Copyright  2004 Prentice Hall PTR Topics n Logic synthesis. n Placement and routing.
ECE 667 Synthesis & Verification - Algebraic Division 1 ECE 667 ECE 667 Synthesis and Verification of Digital Systems Multi-level Minimization Algebraic.
ECE C03 Lecture 21 Lecture 2 Two Level Minimization Hai Zhou ECE 303 Advanced Digital Design Spring 2002.
ECE 331 – Digital System Design
Logic Synthesis 2 Outline –Two-Level Logic Optimization –ESPRESSO Goal –Understand two-level optimization –Understand ESPRESSO operation.
MULTI-LEVEL GATE NETWORKS
1 Outline Division is central in many operations. –What is it (in the context of Boolean functions)? –What to divide (divisor) with? –How to divide (quotient.
Logic Synthesis Part II
Penn ESE353 Spring DeHon 1 ESE535: Electronic Design Automation Day 6: February 5, 2008 Multi-level Synthesis.
ELEN 468 Lecture 121 ELEN 468 Advanced Logic Design Lecture 12 Synthesis of Combinational Logic I.
EDA (CS286.5b) Day 15 Logic Synthesis: Two-Level.
EDA (CS286.5b) Day 17 Sequential Logic Synthesis (FSM Optimization)
Logic Synthesis Outline –Logic Synthesis Problem –Logic Specification –Two-Level Logic Optimization Goal –Understand logic synthesis problem –Understand.
Logic Synthesis 5 Outline –Multi-Level Logic Optimization –Recursive Learning - HANNIBAL Goal –Understand recursive learning –Understand HANNIBAL algorithms.
Logic Synthesis 1 Outline –Logic Synthesis Problem –Logic Specification –Two-Level Logic Optimization Goal –Understand logic synthesis problem –Understand.
Penn ESE353 Spring DeHon 1 ESE535: Electronic Design Automation Day 14: March 16, 2009 Multi-level Synthesis.
1 Exact Two-Level Minimization of Hazard-Free Logic with Multiple Input Changes Montek Singh Tue, Oct 16, 2007.
Give qualifications of instructors: DAP
Gate Logic: Two Level Canonical Forms
Penn ESE535 Spring DeHon 1 ESE535: Electronic Design Automation Day 12: March 2, 2009 Sequential Optimization (FSM Encoding)
Multilevel Logic Synthesis -- Algebraic Methods. ENEE 6442 Why Algebraic Methods? > What is our goal? minimization, maximally factored form. > Algebraic.
Contemporary Logic Design Two-Level Logic © R.H. Katz Transparency No. 4-1 Chapter #2: Two-Level Combinational Logic Section 2.3, Switches and Tools.
CS 140 Lecture 4 Professor CK Cheng 4/11/02. Part I. Combinational Logic Implementation K-Map Given F R D Obj: Minimize sum of products Proc: Draw K-Map.
ECE 667 Synthesis & Verification - Multi-level Optimization 1 ECE 667 ECE 667 Synthesis and Verification of Digital Systems Multi-level Minimization (Kernel-based)
ECE 667 Synthesis and Verification of Digital Systems
Canonical Forms and Logic Miniminization
Penn ESE535 Spring DeHon 1 ESE535: Electronic Design Automation Day 15: March 18, 2009 Static Timing Analysis and Multi-Level Speedup.
Logic Decomposition ECE1769 Jianwen Zhu (Courtesy Dennis Wu)
Overview Part 2 – Circuit Optimization 2-4 Two-Level Optimization
ECE Synthesis & Verification - Lecture 8 1 ECE 697B (667) Spring 2006 ECE 697B (667) Spring 2006 Synthesis and Verification of Digital Systems Multi-level.
CS231 Fundamentals1 Fundamentals What kind of data do computers work with? – Deep down inside, it’s all 1s and 0s What can you do with 1s and 0s? – Boolean.
EEE324 Digital Electronics Ian McCrumRoom 5B18, Lecture 4: Boolean Algebra.
Overview of Chapter 3 °K-maps: an alternate approach to representing Boolean functions °K-map representation can be used to minimize Boolean functions.
Logic Synthesis Minimization of Boolean logic –Technology-independent mapping Objective: minimize # of implicants, # of literals, etc. Not directly related.
State university of New York at New Paltz Electrical and Computer Engineering Department Logic Synthesis Optimization Lect19: Multi Level Logic Minimization.
Zvi Kohavi and Niraj K. Jha 1 Multi-level Logic Synthesis.
ECE 331 – Digital System Design NAND and NOR Circuits, Multi-level Logic Circuits, and Multiple-output Logic Circuits (Lecture #9) The slides included.
Optimization Algorithm
Two-Level Simplification Approaches Algebraic Simplification: - algorithm/systematic procedure is not always possible - No method for knowing when the.
CALTECH CS137 Fall DeHon 1 CS137: Electronic Design Automation Day 5: October 7, 2005 Multi-level Synthesis.
Penn ESE353 Spring DeHon 1 ESE535: Electronic Design Automation Day 22: April 15, 2015 Multi-level Synthesis.
Linear Algebra. Circuits The circuits in computers and other input devices have inputs, each of which is either a 0 or 1, the output is also 0s and 1s.
2-1 Introduction Gate Logic: Two-Level Simplification Design Example: Two Bit Comparator Block Diagram and Truth Table A 4-Variable K-map for each of the.
ETE 204 – Digital Electronics
CALTECH CS137 Winter DeHon CS137: Electronic Design Automation Day 5: January 21, 2004 Multi-level Synthesis.
Multi-Level Logic Optimization. Multi-Level Logic Synthesis Two Level Logic : –Espresso –Programmable Logic Array (PLA) Multilevel Logic : –Standard Cell.
Penn ESE535 Spring DeHon 1 ESE535: Electronic Design Automation Day 23: April 20, 2015 Static Timing Analysis and Multi-Level Speedup.
Ch.5 Logic Design Standard Cell Design TAIST ICTES Program VLSI Design Methodology Hiroaki Kunieda Tokyo Institute of Technology 1.
Output Grouping Method Based on a Similarity of Boolean Functions Petr Fišer, Pavel Kubalík, Hana Kubátová Czech Technical University in Prague Department.
CALTECH CS137 Winter DeHon CS137: Electronic Design Automation Day 15: March 4, 2002 Two-Level Logic-Synthesis.
CSE 140: Components and Design Techniques for Digital Systems Lecture 3: Incompletely Specified Functions and K Maps CK Cheng Dept. of Computer Science.
Digital Logic (Karnaugh Map). Karnaugh Maps Karnaugh maps (K-maps) are graphical representations of boolean functions. One map cell corresponds to a row.
Output Grouping-Based Decomposition of Logic Functions Petr Fišer, Hana Kubátová Department of Computer Science and Engineering Czech Technical University.
CALTECH CS137 Winter DeHon CS137: Electronic Design Automation Day 17: March 11, 2002 Sequential Optimization (FSM Encoding)
Lecture 5: K-Map minimization in larger input dimensions and K-map minimization using max terms CSE 140: Components and Design Techniques for Digital Systems.
Penn ESE535 Spring DeHon 1 ESE535: Electronic Design Automation Day 20: April 4, 2011 Static Timing Analysis and Multi-Level Speedup.
CBSSS 2002: DeHon Universal Programming Organization André DeHon Tuesday, June 18, 2002.
ICS 252 Introduction to Computer Design Lecture 8 Winter 2004 Eli Bozorgzadeh Computer Science Department-UCI.
1 CS 352 Introduction to Logic Design Lecture 4 Ahmed Ezzat Multi-level Gate Circuits and Combinational Circuit Design Ch-7 + Ch-8.
State university of New York at New Paltz Electrical and Computer Engineering Department Logic Synthesis Optimization Lect18: Multi Level Logic Minimization.
Optimized Implementation of Logic Function
Optimized Implementation of Logic Function
ECE 331 – Digital System Design
Optimization Algorithm
Topics Logic synthesis. Placement and routing..
ESE535: Electronic Design Automation
VLSI CAD Flow: Logic Synthesis, Placement and Routing Lecture 5
Alan Mishchenko Department of EECS UC Berkeley
CS137: Electronic Design Automation
Presentation transcript:

EDA (CS286.5b) Day 16 Logic Synthesis: Multi-Level

Today Multilevel Synthesis/Optimization –Why –Transforms –Division/extraction –Boolean Division –Don’t care

Multi-level General circuit netlist May have –sums within products –products within sum –arbitrarily deep y=((a (b+c)+e)fg+h)i

Why multi-level? ab(c+d+e)(f+g)

Why multi-level? ab(c+d+e)(f+g) abcf+abdf+abef+abcg+abdg+abeg 6 product terms 3 gates: and4,or3,or2 Cannot share sub-expressions

Why Multilevel a  b –a/b+/ab a  b  c –a/bc+/abc+/a/b/c+ab/c a  b  c  d –a/bcd+/abcd+/a/b/cd+ab/cd+/ab/c/d+a/b/c/d+abc/d+/a/bc/d

Why Multilevel a  b –x1=a/b+/ab a  b  c –x2=x1/c+/x1*c a  b  c  d –x3=x2/d+x2*d Multi-level –exploit common sub- expressions –linear complexity Two-level –exponential complexity

Multi-level Transformations Decomposition Extraction Factoring Substitution Collapsing

Decomposition F=abc+abd+/a/c/d+/b/c/d F=XY+/X/Y X=ab Y=c+d

Decomposition F=abc+abd+/a/c/d+/b/c/d –4 3-input input F=XY+/X/Y X=ab Y=c+d –5 2-input gates Note: use X and /X, use at multiple places

Extraction F=(a+b)cd+e G=(a+b)/e H=cde F=XY+e G=x/e H=Ye X=a+b Y=cd

Extraction F=(a+b)cd+e G=(a+b)/e H=cde 2-input: 4 3-input: 2 F=XY+e G=x/e H=Ye X=a+b Y=cd 2-input: 6 Common sub-expressions over multiple output

Factoring F=ac+ad+bc+bd+e F=(a+b)(c+d)+e

Factoring F=ac+ad+bc+bd+e –4 2-input, 1 5-input –9 literals F=(a+b)(c+d)+e –4 2-input –5 literals

Substitution G=a+b F=a+bc Substitute G into F F=G(a+c) –(verify) F=(a+b)(a+c)=aa+ab+ac+bc=a+bc useful if also have H=a+c? (F=GH)

Collapsing F=Ga+/Gb G=c+d F=ac+ad+b/c/d opposite of substitution –sometimes want to collapse and refactor –especially for delay optimization

Division Given: function (f) and divisor (p) Find: quotient and remainder f=pq+r E.g. f=abc+abd+ef, p=ab q=c+d, r=ef

Algebraic Division Use basic rules of algebra, rather than full boolean properties Computationally simple Weaker than boolean division f=a+bc p=(a+b) Algebra: not divisible Boolean: q=(a+c), r=0

Algebraic Division f and p are expressions (lists of cubes) p={a 1,a 2,…} h i ={c j | a i * c j  f} f/p = h 1  h 2  h 3 …

Algebraic Division Example f=abc+abd+de g=ab+e

Algebraic Division Example f=abc+abd+de p=ab+e p={ab,e} h1={c,d} h2={d} h1  h2={d} f/g=d r=f-f/g=abc+abd+de-(ab+e)d=abc

Algebraic Division Time O(|f||p|) as described –compare every cube pair Sort cubes first –O((|f|+|p|)log(|f|+|p|)

Primary Divisor f/c such that c is a cube f =abc+abde f/a=bc+bde is a primary divisor

Cube Free The only cube that divides p is 1 c+de is cube free bc+bde is not cube free

Kernel Kernels of f are –cube free primary divisors of f f=abc+abde f/ab = c+de is a kernel ab is cokernel of f to (c+de) –cokernels always cubes

Kernel Extraction Find c largest cube factor of f K=Kernel1(0,f/c) if (f is cube-free) –return(f  K) else –return(K) Kernel1(j,g) –R=g –N max index in g –for(i=j+1 to N) if (li in 2 or more cubes) –c=largest cube divide g/li –if (forall k  I,lk  c) »R=R  KERNEL1(I,g/(li  c) ) –return(R)

Kernel Extract Example f=abcd+abce+abef c=ab f/c=cd+ce+ef R={cd+ce+ef} N=6 a,b not present (cd+ce+ef)/c=e+d largest cube 1 recurse->e+d R={cd+ce+ef,e+d} only 1 d (d+ce+ef)/e=c+f recurse->c+f R+{cd+ce+ef,e+d,c+f}

Factoring Gfactor(f) –if (terms==1) return(f) –p=CHOOSE_DIVISOR(f) –(h,r)=DIVIDE(f,p) –f=Gfactor(h)*Gfactor(p)+Gfactor(r) –return(f) // factored

Factoring Trick is picking divisor –pick from kernels –goal minimize literals after resubstitution

Extraction Identify cube-free expressions in many functions (common sub expressions) Generate kernels for each function select pair such that k1  k2 is not a cube new variable from intersection update functions (resubstitute) (similar for common cubes)

Extraction Example X=ab(c(d+e)+f+g)+g Y=ai(c(d+e)+f+j)+k

Extraction Example X=ab(c(d+e)+f+g)+g Y=ai(c(d+e)+f+j)+k d+e kernel of both L=d+e X=ab(cL+f+g)+h Y=ai(cL+f+j)+k

Extraction Example L=d+e X=ab(cL+f+g)+h Y=ai(cL+f+j)+k kernels:(cL+f+g), (cL+f+j) extract: M=cL+f X=ab(M+g)+h Y=ai(M+f)+h

Extraction Example L=d+e M=cL+f X=ab(M+g)+h Y=ai(M+j)+h no kernels common cube: aM N=aM M=cL+f L=d+e X=b(N+ag)+h Y=I(N+aj)+k

Extraction Example N=aM M=cL+f L=d+e X=b(N+ag)+h Y=I(N+aj)+k Can collapse –L into M into N Get larger common kernel N –maybe useful if components becoming too small for efficient gate implementation

Resubstitution Also useful to try complement on new factors f=ab+ac+/b/cd X=b+c f=aX+/b/cd /X=/b/c f=aX+/Xd …extracting complements not a direct target

Good Divisors? Key to CHOOSE_DIVISOR in GFACTOR Variations to improve –e.g. rectangle covering

Boolean Division f//p assuming sup(p)  sup(f) add input P to f (for p) new function F –DC-set D=P/p+/Pp –ON-set f  /D –OFF-set /(f  D) minimize F for minimum literals in sum-of- products

Boolean Division (check) Sanity: (F*Pp+F*/P/p)p=Fp

Boolean Division Example f=abc+a/b/c+/ab/c+/a/bc g=ab+/a/b F-DC=ab/G+/a/b/G+/abG+a/bG F-On=abcG+/a/bcG+/ab/cG+a/b/c/G minimize: –F=cG+/c/G

Boolean Division Trick is finding boolean divisors Not as clear how to find –(not as much work on) Can always use boolean division on algebraic divisors –give same or better reuslts

Don’t Care Mentioned last time Structure of logic restricts values intermediates can take on

Don’t Care Example e=/a/b g=/c/d f=/e/g e=0, a=0, b=0 cannot occur DC: e(a+b)+/e/a/b

Satisfiability DC In general: –y=F(x,y) –y/F(x,y) + /yF(x,y) is don’t care

Observability DC If F output not differentiated by input y, –then don’t care value of y F y =F /y ODC =  (F y =F /y ) –(product over all outputs)

Summary Want to exploit structure in problems to reduce (contain) size –common subexpressions –structural don’t cares Identify component elements –decomposition, factoring, extraction Division

Today’s Big Ideas Exploit freedom –form –don’t care Exploit structure/sharing –common sub expressions