boolean matching in logic synthesis

Post on 04-Jul-2015

78 Views

Category:

Education

0 Downloads

Preview:

Click to see full reader

DESCRIPTION

Boolean matching is a technique to detect equivalence of two Boolean function under permutation of the variables.

TRANSCRIPT

Boolean matching is a technique to detect equivalence of two Boolean function under permutation of the variables.

A permutation P over X is a one- to-one function P : X -> X; X = {x1, x2, x3, …, xn }

Equivalence of two functions defined under

Negation of input variables

Permutation of input variables

Negation of output

X = {x1, x2, x3, …, xn } Set of Boolean input variables.

f (X) and g (X) Denotes two Boolean functions of X.

(X) Maps each xi to itself or its complement.

If g (X) = f ( (X)) Then we say f (X) and g (X) are equivalent functions.

5

Example:

X = {x1, x2, x3}

f (X) = x1 + x2 + x3

g (X)= x1 + x2 + x3

Mapping:

x1 x1

x2 x2

x3 x3

g (X) = f ( (X) ), so f (X) and g (X) are equivalent functions.

(X) Maps each xi to any xi.

is a permutation of X.

If g (X) = f ( (X)) Then we say f (X) and g (X) are equivalent functions.

Example:X = {x1, x2, x3}f (X) = x1x3 + x2 + x3x1

g (X)= x3x2 + x1 + x2x3

Mapping:x1 x3

x2 x1

x3 x2

g (X) = f ( (X) ), so f (X) and g (X) are equivalent functions.

7

7

X = {x1, x2, x3,…, xn} Set of Boolean input variables.

f (X) and g (X) Denotes two Boolean functions of X.

If g (X) = f (X) or g (X) = f (X)

Then we say f(X) and g(X) are equivalent functions.

Example:

X = {x1, x2, x3}

f (X) = x1x2x3

g (X)= x1 + x2 + x3

g (X) = f (X), so f (X) and g (X) are equivalent functions.

N-equivalent Equivalent under input Negation.

P-equivalent Equivalent under input Permutation.

NP-equivalent Equivalent under input Negation, input Permutation.

NPN-equivalent Equivalent under input Negation, input Permutation,

output Negation.

Given functions f (X) and g (Y),

where,

X = { x1 , x2 ,…, xn}

Y = { y1 , y2 ,…, yn}

: maps each xi to a unique yj or yj

g (Y) = f ( (X) ) or f ( (X) )

Total 2n n! 2 mappings

Function f and g

Compute Signatures

of Functions

Equal?Not

Matched

No

Compute Signatures

of variables

Yes

Equal?

Equivalence of

f and g ?

Matched

Not

Matched

Not

Matched

Yes

Yes

No

No

• The positive cofactor of function f (x1, ..,xn) with respect to variable xi, denoted by fxi , is f (x1, ..,xi = 1, ...,xn).▫ The negative cofactor denoted by fx′i, is f (x1, .., xi =0, ...,xn).

• A function f (x1, ...,xn) is positive unate in variable xi if and only if the negative cofactor of f with respect to xi is covered by the

positive cofactor of f with respect to xi, i.e., fx′i⊆ fxi .

Likewise, f is negative unate in variable xi if and only if fxi ⊆ fx′i. f is called binate in xi if it is not unate in it.

A signature is defined as a necessary condition that captures some key characteristic of a Boolean function with respect to one or more of its input variables.

3 types of key characteristic :

Unateness property

Symmetry property

Size of on_set

Matched functions having the same number of Unate and Binate variables.

If we denote by b the number of binate variables, then b is a signature of the function.

The number of Unate variables (n-b) is a signature.

At most b! *(n – b)! variable permutations need to be considered in the search for a match in the worst case.

A function:

g has n = 7, 4 Unate variables, 3 Binate variables.

Consider another function with n=7.

• First, a necessary condition for f to match g is to also have 4 unate variables and 3 binate variables.

• Then, only 3!4! =144 variable orders and corresponding OBDDs need to be considered in the worst case.

Symmetry class : a set of variables that are interchangeable without affecting the logic functionality.

A symmetry class is an ensemble of symmetry sets with the same cardinality.

• A necessary condition for matching is to have symmetry classes of the same cardinality for each

i = 1,2, . . . , n.

Consider,

• The support variables of f(x) can be partitioned into three symmetry sets:{x1, x2, x3}, {x4, x5}, {x6, x7}.

• There are two non-void symmetry classes, namely:C2 ={{x4, x5}, {x6, x7}} and C3 = {{x1, x2, x3}}.

• A signature is [0,2,1,0,0,0,0].

Consider, g1 = y1 + y2 y3 + y4 y5 + y6 y7

g2 = (y1’ + y2’)(y3’+ y4)( y5 + y6 +y7 ).

The signatures of the cells are, [1,3,0,0,0,0,0] & [0,2,1,0,0,0,0].

• The signatures of f and g2 are equal, and indeed g2 is NPN equivalent to f.

Signatures can also be obtained by considering the satisfy count of a function, which is the number of itsminterms.

minterm is intended to imply it that each of the groups in the expression takes on a value of 1 only for one of the all possible combinations of the inputs and their inverses.

The number of minterms for which a function f evaluates to 1 (denoted as on_set(f) ).

matched functions have the same size of on_set.

computed on Ordered Binary Decision Diagram

Cofactor signature

Cofactor statistics and Component signature

Single fault propagation weight signature (SFP) and Partner patterns

Cofactor signature of a variable xt for function f :onsize (xt fxt)

: 0-branch

: 1-branch

xt

xt fxt

0 1

f

A sorted list of onsize (xt xj fxtxj) for all xt in the input set

xt xj fxtxj

0 1

fxt

xj

( onsize (xt fxt fxt), onsize (xt fxt fxt), onsize (fxt fxt) )

xt xt xt xt

0 1

Function f and g

Compute Signatures

of Functions

Equal?Not

Matched

No

Compute Signatures

of variables

Yes

Equal?

Equivalence of

f and g ?

Matched

Not

Matched

Not

Matched

Yes

Yes

No

No

23

Technology Mapping

Matching of complex gates.

Exploiting implicit don’t care.

Logic Verification

When input correspondence is not given.

Verify correctness of a logic circuit.

Logic Synthesis

Cell library binding process.

23

24

Boolean matching is based on exact equivalencechecking techniques that find a match wheneverpossible. Various kinds of algorithms exist forBoolean matching. An overview of BooleanS i g n a t u r e b a s e d

algorithm is discussed.

top related