Documentation

Std.Tactic.BVDecide.Bitblast.BVExpr.Circuit.Impl.Substructure

This module contains the logic to turn a BVLogicalExpr into an AIG with maximum subterm sharing, through the use of a cache that re-uses sub-circuits if possible. Additionally a term level cache is used to prevent rerunning bitblasting on common bitvector subexpressions.

Instances For
    @[inline]
    def Std.Tactic.BVDecide.BVLogicalExpr.Cache.insert {aig : Sat.AIG BVBit} (cache : Cache aig) (expr : BVLogicalExpr) (ref : aig.Ref) :
    Cache aig
    Equations
    Instances For
      @[inline]
      Equations
      • One or more equations did not get rendered due to their size.
      Instances For
        @[inline]
        def Std.Tactic.BVDecide.BVLogicalExpr.Cache.cast {aig1 aig2 : Sat.AIG BVBit} (cache : Cache aig1) (h : aig1.decls.size ≤ aig2.decls.size) :
        Cache aig2
        Equations
        • { exprs := exprs, map := map, hbound := hbound }.cast h = have this := ⋯; { exprs := exprs.cast h, map := map, hbound := this }
        Instances For
          @[irreducible]
          Equations
          • One or more equations did not get rendered due to their size.
          Instances For
            @[irreducible]
            Equations
            Instances For
              theorem Std.Tactic.BVDecide.BVLogicalExpr.bitblastWithCache.goCache_decl_eq (aig : Sat.AIG BVBit) (expr : BVLogicalExpr) (cache : Cache aig) (idx : Nat) (h1 : idx < aig.decls.size) (h2 : idx < (goCache aig expr cache).result.val.aig.decls.size) :
              (goCache aig expr cache).result.val.aig.decls[idx] = aig.decls[idx]
              theorem Std.Tactic.BVDecide.BVLogicalExpr.bitblastWithCache.go_decl_eq (aig : Sat.AIG BVBit) (expr : BVLogicalExpr) (cache : Cache aig) (idx : Nat) (h1 : idx < aig.decls.size) (h2 : idx < (go aig expr cache).result.val.aig.decls.size) :
              (go aig expr cache).result.val.aig.decls[idx] = aig.decls[idx]
              theorem Std.Tactic.BVDecide.BVLogicalExpr.bitblastWithCache.goCache_denote_mem_prefix {assign : BVBit → Bool} {expr : BVLogicalExpr} {start : Nat} {inv : Bool} (aig : Sat.AIG BVBit) (cache : Cache aig) (hstart : start < aig.decls.size) :
              ⟦assign, { aig := (goCache aig expr cache).result.val.aig, ref := { gate := start, invert := inv, hgate := ⋯ } }⟧ = ⟦assign, { aig := aig, ref := { gate := start, invert := inv, hgate := hstart } }⟧