110 likes | 126 Views
Reduced Functional Consistency of Uninterpreted Functions. Equality logic with uninterpreted functions. formula : formula Ç formula | : formula | atom atom : term = term | Boolean-variable term : term-variable | function ( list of terms ).
E N D
Equality logic with uninterpreted functions • formula : formulaÇformula | :formula | atom • atom : term = term | Boolean-variable • term : term-variable | function ( list of terms ) term-variables are defined over some (possible infinite) domain. Note that constants are functions with empty list of terms. Technion
Example: Circuit Transformations ? = Technion
Uninterpreted Functions (UF’s) • The most general axiom for any function is functional consistency. • Example: if x = y, then f(x) = f(y) for any function f. • Functional consistency axiom scheme: x1=x1’ Æ … Æxn=xn’ !f(x1,…, xn) = f(x1’,…, xn’) • Sometimes, functional consistency is all that is needed for the proof. Technion
F( ), G( ),… f1 F2(F1(x)) = 0 f2 f2 =0 UFs Equality Logic: Ackermann’s reduction • For each function in UF: • Number function instances (from the inside out) • Replace each function instance with a new variable • Condition UF with a functional consistency constraint for every pair of instances of thesame function. Given a formula UF with uninterpreted functions ((x=f1) f1=f2 ) (f2=0) Technion
Ackermann’s reduction : Example • Given the formula(x1x2) Ç (F(x1) =F(x2)) Ç (F(x1) F(x3))which we want to check for validity, we first number the function instances: (x1x2) Ç (F1(x1) =F2(x2)) Ç (F1(x1) F3(x3)) Technion
Ackermann’s reduction : Example (x1x2) Ç (F1(x1) =F2(x2)) Ç (F1(x1) F3(x3)) • Replace each function with a new variable, (x1x2) Ç (f1 =f2 ) Ç (f1f3 ) • Condition with Functional Consistency constraints: Technion
Ackermann’s reduction: summary • Let UF be the EUF formula representing the verification condition • After Ackermann’s reduction: • Let be the result of replacing all UFs in UF with new variables • Let FC be the corresponding set of functional consistency constraints • Need to prove: Technion
The problem and the setting • Ackermann’s reduction imposes a quadratic growth in the formula • Practically, we have formulas with hundreds of function instances, resulting in thousands of constraints. • No theorem-prover (as of 2002) could solve them. • Our own decision procedure: BDD based + range allocation. Technion
The solution • Find FC’ ½ FC such that Technion
The solution (cont’d) • Possible solution: Abstraction-refinement loop Technion