NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Balancing Scalability and Uniformity in SAT Witness Generator

Supratik Chakraborty, Kuldeep S. Meel, Moshe Y. VardiDAC 2014 · DOI

Abstract

UniGen is a breakthrough algorithm for generating random solutions (witnesses) to complex Boolean SAT problems. It provides strong mathematical guarantees of "almost-uniform" sampling while scaling to industrial-sized designs with hundreds of thousands of variables. By leveraging universal hashing and the concept of independent support, UniGen outperforms previous state-of-the-art tools by two to three orders of magnitude.

Introduction

In hardware and software verification, "constrained-random simulation" is a critical technique for bug hunting. Engineers define valid inputs through constraints and generate random examples to test designs. However, this process faces a dual challenge: uniformity and scalability. A biased generator may miss "dark corners" where bugs reside, while perfectly uniform algorithms often fail to scale beyond a few hundred variables. UniGen addresses this "holy grail" problem, offering both speed and fairness.

Methodology

UniGen utilizes a "divide and conquer" strategy based on universal hashing. The algorithm partitions the solution space into small "cells" using 3-wise independent linear hash functions.

A key innovation is the use of independent support. Rather than hashing every variable, UniGen identifies a subset of "master" variables that uniquely determine the others. This keeps constraints simple and ensures the underlying SAT solver, CryptoMiniSAT, remains efficient. Additionally, UniGen employs the approximate model counter ApproxMC to estimate the total number of solutions, allowing it to calibrate the number of hash functions required to isolate a manageable number of solutions per cell.

Experimental Evaluation

The authors evaluated UniGen using public-domain benchmarks, including Bounded Model Checking (BMC), SMTLib formulas, and automated program synthesis tasks. These problems ranged from small-scale circuits to massive designs containing nearly 500,000 variables.

Results and Discussion

UniGen demonstrated significant improvements in both performance and reliability. It consistently achieved a success probability near 1.0, exceeding its theoretical lower bound of 0.62.

Scalability and Speed

As shown in the performance data, UniGen is 100x to 1,000x faster than its predecessor, UniWit. It successfully generated witnesses for formulas with up to 486,193 variables, whereas previous tools often struggled beyond a few thousand.

Performance comparison of UniGen and UniWit across benchmarks.

Statistical Quality

The "almost-uniform" distribution provided by UniGen is statistically indistinguishable from perfect randomness. By relaxing the requirement from perfect to almost-uniform (within a factor $\epsilon$), the algorithm achieves massive gains in speed without sacrificing practical utility.

Statistical distribution of UniGen vs. a uniform sampler (US).

Conclusion

UniGen represents a major advancement in SAT witness generation. While it currently relies on pre-identified independent support and Boolean logic, future work aims to automate support detection and extend the methodology to Satisfiability Modulo Theories (SMT) for handling complex data types like integers and arrays.

Summary updated

BibTeX
@inproceedings{chakraborty2014balancing,
  author = {Supratik Chakraborty and Kuldeep S. Meel and Moshe Y. Vardi},
  title = {{Balancing Scalability and Uniformity in SAT Witness Generator}},
  booktitle = {DAC},
  year = {2014},
  doi = {10.1145/2593069.2593097},
}
Figure