1 / 22

Simulation and SAT-Based Boolean Matching for Large Boolean Networks

Simulation and SAT-Based Boolean Matching for Large Boolean Networks . Kuo-Hua Wang, Chung-Ming Chang, and Jung-Chang Liu Dept. of Computer Science and Information Engineering Fu Jen Catholic University Hsinchuang City, Taipei County 24205, Taiwan, R.O.C. khwang@csie.fju.edu.tw.

chelsey
Télécharger la présentation

Simulation and SAT-Based Boolean Matching for Large Boolean Networks

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Simulation and SAT-Based Boolean Matching for Large Boolean Networks Kuo-Hua Wang, Chung-Ming Chang,and Jung-Chang Liu Dept. of Computer Science and Information Engineering Fu Jen Catholic University Hsinchuang City, Taipei County 24205, Taiwan, R.O.C. khwang@csie.fju.edu.tw

  2. Outline • Introduction • Background • S&S-Based Functional Properties Detection • Simulation-Based Boolean Matching • Experimental Results • Conclusions

  3. Introduction • Boolean Matching • to check the equivalence of two functions and under the input permutation and input/output phase assignment. • Example:

  4. X if unsatisfiable Background • Boolean Satisfiability (SAT) Problem • Given a CNF (Conjunctive Normal Form), find a variable assignment to satisfy it or prove it is equal to the constant 0. v=1 Circuit CNF mitter

  5. : And : Complement e a d c b Background – Cont. • And-Inverter Graphs (AIGs) • Nodes • Primary Input • 2-input AND • Constant 0 (1) • Edges • with complement attribute or not • Major Advantages • It is fast to simulate on AIGs. • It allows easy conversion from any circuit into AIGs. • It is more compact than BDD’s for many large functions.

  6. Phase 1: Initialization S&S-Based Functional Properties Detection - use signatures to generate an initial input mapping Phase- 2: Simulation Simulation-Based Boolean Matching - use random simulation results to distinguish inputs Phase 3: Recursion Recursive Matching Algorithm - match the remaining inputs for hard cases SAT Verification and Return Result Overview of Matching Algorithm

  7. Group Symmetry: Rotational Symmetry: Group Symmetry and Rotational Symmetry

  8. S&S Based Functional Properties Detection • Three Types of Functional Properties • 2-Variable • E (Equivalence) symmetry & NE (Non-equivalence) Symmetry • Single Variable Symmetry • 1-Variable • Functional Unateness • Detection Algorithm • Using random simulation to remove impossible properties • 2 input vectors with Hamming distance 2 (or 1) • different output values will remove some functional properties • Using SAT technique to check some properties, i.e, the equivalence of two cofactors.

  9. Notation Condition Notation Condition xi A=D 1 A=C 0 B=C xj xj B=D 0 1 0 1 A=B C=D A B C D Functional Properties • Functional Symmetries E: Equivalence Symmetry NE: Non-Equivalence Symmetry • Functional Unateness • positive unate : , i.e., • negative unate : , i.e., • binate • The inputs with different functional properties can not match to each other.

  10. Examples:Hamming_Distance(v1, v2) = 21.2. Hamming_Distance(v1, v2) = 13.4. Removal of Functional Properties

  11. Definitions and Notations • Two functions and with5 inputs.Let • Mapping Group • is unique since • Mapping Relation • It is unique if all mapping groups are unique. • Input /Output Weight • The number of 1’s in the input/output vector. • The weight of the vector 11000 is 2.

  12. Simulation-Based Boolean Matching • Main Concept • to incrementally refine the mapping relation through many simulation rounds • until no improvement is made under a threshold ( the maximum number of simulation rounds) • Each Simulation Round • Generate input vectorsto simulate on AIGs. • Check their output valuesto distinguish the inputs in non-unique mapping groups. • Three Types of Input Vectors • Type-1, Type-2, and • Type-3 (only for Boolean functions with NE-symmetries)

  13. Incompatible Match • Two functions can not be matched if • the output weights of two functions are different w.r.t. the same input vector set for simulation. • Example: f (a, b, c) = a + b · c g (x, y, z) = x · y · z Input vectors: 100, 010, 001output vector of f : 1 0 0 (weight = 1) output vector of g : 0 0 0 (weight = 0) ∵ 1≠0  f and g can not be matched

  14. Type-1 Input Vectors • x1,.............,xnf(X) 1 0 0…..0 0 0 1 the signature of x10 1 0…..0 0 0 0 the signature of x2 . . . . . .0 0 0…..0 0 11 the signature of xn Input weight = 1 • The output value of f w.r.t. each input vector (row) can be used as the signature of the corresponding input variables. • It can divide the input set into 2 groups with signature 0 and 1, respectively.

  15. Type-1 - a Simple Example • f (a, b, c, d ) f a1 0 0 0 1b 0 1 0 0 1c 0 0 1 0 0d 0 0 0 11 • g (w, x, y, z ) g w1 0 0 0 1x 0 1 0 0 0y 0 0 1 0 1z 0 0 0 11 f : output=1: {a, b, d }output=0: {c} g: output=1:{w, y, z }output=0: {x} {a, b, d } map to {w, y, z } and {c} map to {x}  R = {{a, b, d}{w, y, z}, {c}{x}}

  16. Type-2 Input Vectors • For each input , consider the following input vectors with input weight 2 and . 10…10…0 001…10…0 1 . . . . 00…10.. 11 • The inputs with different output weights can not match to each other. • If we can find a unique mapping group, we can further partition the remaining input variables. Output Weight : the # of 1’s output values The signature of xi

  17. Type-2: a Simple Example • Step 1:use the output weights to get some mapping groups • R = {{a, c}{w, x}, {b}{y}}(Unique) • f (a,b,c) g (w,x,y) a b c fw x y g 11 0 0 11 0 0 1 0 1010 10 ab cw x y 11 0 111 0 0 0 1 1 0 0 110 a b cwx y 0 110 0 11 0 1 0 1010 11 w a 0 0 1 0 1 0 Step 2:use the results by groups b and y to get more input mappings  R = {{a}{w},{c}{x},{b}{y}} b x y c Output Weight Output Weight

  18. : with input weight w1 w1 ≠w2 O1 S1 : with input weight w2 S2 O2 … … Sm Om Type-3 Input Vectors • Consider f which has mNE-symmetric sets with k input variables. • Using the vectors : s1 s2 … smf w1 w1 w1 S1 S1 S2 S2 Oi: the signature of set Si k = 34 Patterns : {000, 001, 011, 111 } weight: { 0, 1, 2, 3 } Sm

  19. Non-unique mapping group {a, b, c}{x, y, z} . Recursive Matching – An Example

  20. Matching and Comparison Results Table 1: Matching Results on 112 Circuits 112 109 Table 2: Comparison Results on Three Phases

  21. Circuit Orig Unate +Symm First All First All First All SAT s4863 * * 2.56 * 1.87 1.88 0.01 s5378 1.31 * 3.38 * 2.42 2.42 0.00 s6669 6.30 * 2.83 * 4.08 50.54 46.50 s38584.1 76.31 * 210.13 * 457.82 457.82 0.03 s38417 91.81 * 324.57 * 998.53 998.53 0.13 0.37 0.03 1.00 1.03 0.15 Ratio Matching Results for Large Networks Table 3: Benchmarking Results for Circuits in ISCAS89 $: memory explosion Table 3: Cont. *: CPUtime > 5000 sec.

  22. Conclusions • Our Boolean Matching Algorithm • Integrate Simulation and SAT techniques • Exploit Functional Properties • Propose Three Types of Input Vectors • Apply a Recursive Matching Algorithm • Handle Large Boolean Networks • Future Work • Input/Output Phase Assignment • More Effective Random Simulation Vectors

More Related