Bit-blasting circuits over a finite carrier #
Let enc : F → BitString w and decode : BitString w → F satisfy
Function.LeftInverse decode enc. The encoding need only be injective: unused bit strings may
be decoded arbitrarily. Thus the carrier need not have exactly 2 ^ w elements. A circuit over
the full binary basis of F (fullInterpretation (k := 2), where every constant and every
operation with at most two arguments is a gate) is simulated on valid encodings. Each gate is
replaced by w circuits, one per output bit, each a Boolean function of at most 2 * w argument
bits. Its disjunctive normal form costs 2 ^ (2 * w) * (4 * w + 2) + 1 gates by
Cslib.Circuits.Synthesis.selected, giving per-symbol cost
bitBlastCost w = w * (2 ^ (2 * w) * (4 * w + 2) + 1). The bound is unchanged from the
bijective-encoding case. No semantics on malformed input encodings are claimed.
The simulation is stated as a synthesis bound (Cslib.Circuits.Synthesis.bitBlast): if the bits
of the F-valued functions feeding the circuit's inputs are available, then the bits of all its
outputs can be made available with size * bitBlastCost w further gates.
Main definitions #
Cslib.Circuits.bitsOf: the bits of anF-valued function under an encoding function.Cslib.Circuits.bitBlastCost: the De Morgan cost of one gate of the full binary basis.
Main results #
Cslib.Circuits.Synthesis.bitBlast_program: the bits of every wire of a program over the full binary basis.Cslib.Circuits.Synthesis.bitBlast: the bits of every output of a circuit over the full binary basis.Cslib.Circuits.Synthesis.bitBlast_synthesis: the same for a synthesis bound over the full binary basis.
References #
- S. Jukna, Boolean Function Complexity: Advances and Frontiers
- [M. Sudan, L. Trevisan, S. Vadhan, Pseudorandom generators without the XOR lemma] [STV01]
The number of De Morgan gates that simulate one gate of the full binary basis on w-bit
symbols: each of the w bits of the value is a function of the 2 * w bits of the arguments.
Bit-blasting a program. If the bits of the functions φ i feeding the inputs of a
program over the full binary basis of F are available, then the bits of the values of all its
wires can be made available with bitBlastCost w De Morgan gates for each of its gates.
Bit-blasting a circuit. If the bits of the functions φ i feeding the inputs of a circuit
over the full binary basis of F are available, then the bits of all its outputs can be made
available with c.size * bitBlastCost w De Morgan gates.
Bit-blasting a synthesis bound. If a family Ψ of functions of N field inputs is
synthesized over the full binary basis from the input projections with cost gates, and the bits
of the functions φ i feeding the inputs are available, then the bits of all Ψ o (φ ·) can be
made available with cost * bitBlastCost w De Morgan gates.