Presentation is loading. Please wait.

Presentation is loading. Please wait.

Interpolating Functions from Large Boolean Relations

Similar presentations


Presentation on theme: "Interpolating Functions from Large Boolean Relations"— Presentation transcript:

1 Interpolating Functions from Large Boolean Relations
Jie-Hong Roland Jiang, Hsuan-Po Lin, and Wei-Lun Hung Grad. Inst. of Electronics Eng. / Dept of Electrical Eng. National Taiwan University

2 Outline ◆ Introduction ◆ Our Approach ◆ Experimental Results
◆ Conclusions

3 Relations vs. Functions
Boolean relation R(X, Y) Boolean function F(X) Allow one-to-many mappings Can describe non- deterministic behavior More generic than functions Disallow one-to-many mappings Can only describe deterministic behavior A special case of relation 11 10 01 00 x1x2 y1y2 11 10 01 00 x1x2 y1y2 f1 = x1 x2 f2 =  x1 x2

4 Total Relations vs. Partial Relations
Every input element is mapped to at least one output element Some input element is not mapped to any output element 11 10 01 00 1 x1x2 y 11 10 01 00 1 x1x2 y

5 T(X, y) = R(X, y)  y.  R(X, y)
Totalization A partial relation can be totalized Assume that the input element not mapped to any output element is a don’t care Partial relation Total relation 11 10 01 00 1 x1x2 y 11 10 01 00 1 x1x2 y Totalize T(X, y) = R(X, y)  y.  R(X, y)

6 Application of Boolean Relations
In high-level design, Boolean relations can be used to describe (nondeterministic) specifications In gate-level design, Boolean relations can be used to characterize the flexibility of sub-circuits Boolean relations are more powerful than traditional don’t-care representations 11 10 01 00 x1x2 y1y2

7 Needs of Relation Determinization
For hardware implement of a system, we need functions rather than relations Physical realization are deterministic by nature One input stimulus results in one output response

8 Needs of Relation Determinization
To simplify implementation, we can explore the flexibilities described by a relation for optimization y1 y1 x1 z1 z1 x1 x2 x2 z2 z2 y2 y2 f1 = x1 x2 f2 =  x1 x2 f1 = x2 f2 =  x1 x1x2 y1y2 z1z2 11 10 01 00 11 10 01 00 11 10 01 00

9 Problem Statement Given a nondeterministic Boolean relation R(X, Y), how to determinize and extract functions from it? For a deterministic total relation, we can uniquely extract the corresponding functions

10 Related Work Prior Work Ours BDD- or SOP-based representation
Not scalable Focused on function optimization Ours AIG representation Focus on scalability with reasonable optimization quality

11 Enabling Technique Craig Interpolation Theorem I φB φA
If φA  φB is UNSAT for propositional formulas φA ,φB, then there exists an interpolant I such that φA → I I  φB is UNSAT I refers only to the common variables of φA and φB I φB φA

12 Single-Output Relations
For a single-output total relation R(X, y), we derive a function f for variable y using interpolation  R(X,0)   R(X,1) is UNSAT I φB φA 11 10 01 00 1 x1x2 y 11 10 00 φB :  R(X,1) Minimal care offset of f φA :  R(X,0) Minimal care onset of f

13 Interpolantion vs. Cofactoring
Naïve derivation of f is by cofactoring R(X,1) (largest onset of f) or  R(X,0) (smallest onset of f)  φB= R(X,1) Largest onset of f I φB φA 11 10 01 00 1 x1x2 y 11 φA= R(X,0) Smallest onset of f 10 00 The function extracted from a single-output relation using cofactor is usually of similar size as the relation Interpolation may extract smaller functions and prevent AIG explosion  R(X,0) ⊆ I ⊆ R(X,1)

14 Multiple-Output Relations
Two-phase computation: Phase 1 : Backward reduction Reduce to single-output case R(X, y1, …, yn) → y2, …, yn. R(x, y1, …, yn) Existential quantification using expansion y. φ(x,y) = φ(x,1) + φ(x,0) Existential quantification using substitution [CAV 2009]  y. φ(x,y) = φ(x, f(x)) Phase 2 : Forward substitution Extract functions

15 Multiple-Output Relations
Example (Xp) R(3) R R(2) Phase1: (expansion reduction) y3.R(X, y1, y2 , y3) → R(3)(X, y1, y2) y2.R(3)(X, y1, y2) → R(2)(X, y1) X y1 y2 y3 Phase2: R(2)(X, y1) → y1 = f1 (X) R(3)(X, y1, y2) → R(3)(X, f1(X), y2) → y2 = f2 (X) R(X, y1, y2 , y3) → R(X, f1(X), f2(X), y2) → y3 = f3 (X) f1 X f2 X f3 X

16 Multiple-Output Relations
Example (St) R<2> R R<3> Phase1: (substitution reduction) R(X, y1, y2 , y3) → y3 = f3’(X , y1, y2 ) → R<3>(X, y1, y2) R<3>(X, y1, y2) → y2 = f2’(X , y1 ) → R<2>(X, y1) X y1 y2 y3 Phase2: R<2>(X, y1) → y1 = f1 (X) R<3>(X, y1, y2) → R<3>(X, f1(X), y2) → y2 = f2 (X) R(X, y1, y2 , y3) → R(X, f1(X), f2(X), y2) → y3 = f3 (X) y1 X f3' y2 y1 X f2' f1 X f2 X f3 X

17 Multiple-Output Relations
Example (SD) R<3> R<2> R Phase1: (substitution reduction) R(X, y1, y2 , y3) → y3 = f3’(X , y1, y2 ) → R<3>(X, y1, y2) R<3>(X, y1, y2) → y2 = f2’(X , y1 ) → R<2>(X, y1) R<2>(X, y1, y2) → y1 = f1’(X) X y1 y2 y3 Phase2: (interpolation for deterministic rel.) D = R Λ ∏i (yi ≡ fi’) fi (X) = Interpolant(Dyi, D yi) y1 X f3' y2 y1 X f2' X f1' f1 X f2 X f3 X

18 Experimental Setup Our methods were implemented in ABC using MiniSAT
We prepare Boolean relations by computing the transition relations of ISCAS and ITC circuits Insert don’t cares to introduce nondeterminism Represent transition relations using AIGs

19 Experimental Results – w/o DC
Original BDD Xp Circuit (#pi, #po) #n #l #v time s5378 (214, 179) 624 12 1570 783 10 1561 286.4 1412 25 49.6 s9234.1 (247, 211) 1337 3065 --- 7837 59 2764 158.6 s13207 (700, 669) 1979 23 3836 5772 140 3554 769.3 s15850 (611, 597) 2648 36 15788 42622 188 13348 2700 s35932 (1763, 1728) 8820 7099 7280 6843 4178.5 s38584 (1464, 1452) 9664 26 19239 22589 277 17678 5772.8 b10 (28, 17) 167 11 159 200 152 0.1 197 8 0.9 b11 (38, 31) 482 21 416 1301 18 394 1504 57 5.1 b12 (126, 121) 953 16 1639 1663 14 1574 56.7 2166 24 b13 (63, 53) 231 383 240 349 3.1 224 2.2 Ratio 1 1 3.40 4.16 0.91 Ratio 2 1.70 0.89 0.97 2.24 1.79 Ratio 3 1.31 2.02 --- : BDD nodes are over 500K during computation

20 Experimental Results – w/ DC
Original BDD Xp Circuit (#pi, #po) #n #l #v time s5378 (214, 179) 624 12 1570 769 11 1561 200.2 1332 25 49.1 s9234.1 (247, 211) 1337 3065 --- 7696 55 2765 166.7 s13207 (700, 669) 1979 23 3836 5818 202 3554 897.9 s15850 (611, 597) 2648 36 15788 40078 136 13309 2596.9 s35932 (1763, 1728) 8820 7099 7360 6843 4811.1 s38584 (1464, 1452) 9664 26 19239 23726 331 17676 5476.7 b10 (28, 17) 167 159 199 9 152 0.1 193 8 1.0 b11 (38, 31) 482 21 416 1221 20 394 0.9 1562 52 5.5 b12 (126, 121) 953 16 1639 1619 15 1574 452.5 2261 27.0 b13 (63, 53) 231 10 383 243 349 1.6 229 2.5 Ratio 1 1 3.35 4.53 0.91 Ratio 2 1.65 0.94 0.97 2.27 1.71 Ratio 3 1.38 1.82 --- : BDD nodes are over 500K during computation

21 Experimental Results (cont’d)
Further synthesis by ABC commands “collapse” and “dc2” Original Xp Circuit #n #l #v #n_c #l_C #v_C time_c s5378 624 12 1570 772 11 1561 1412 25 760 0.4 s9234.1 1337 3065 2791 2764 7837 59 2751 22 6.4 s13207 1979 23 3836 2700 20 3554 5772 140 2709 5.2 S15850* 2648 36 15788 --- 42622 188 13348 s35932 8820 7099 7825 9 6843 7280 10 7857 39.9 s38584 9664 26 19239 12071 17676 22589 277 17678 12132 21 36.5 b10 167 159 195 152 197 8 b11 482 416 1187 394 1504 57 1226 0.2 b12 953 16 1639 1556 17 1574 2166 1645 b13 231 383 237 349 224 0.1 Ratio 1 1 1.21 0.93 2.02 3.92 1.22 0.89 Ratio 2 1.01 0.96

22 Experimental Results (cont’d)
Interpolant vs. cofactor

23 Conclusions Scalable function extraction from Boolean relations
Interpolation plays an essential role Relations with up to thousands of variables can be determinized inexpensively Extracted functions are of reasonable sizes Future work Determinization scheduling Simple function extraction


Download ppt "Interpolating Functions from Large Boolean Relations"

Similar presentations


Ads by Google