Maximum Satisfiability in Software Analysis: Applications and Techniques

A central challenge in software analysis concerns balancing different competing tradeoffs. To address this challenge, we propose an approach based on the Maximum Satisfiability (MaxSAT) problem, an optimization extension of the Boolean Satisfiability (SAT) problem. We demonstrate the approach on three diverse applications that advance the state-of-the-art in balancing tradeoffs in software analysis. Enabling these applications on real-world programs necessitates solving large MaxSAT instances comprising over \(10^{30}\) clauses in a sound and optimal manner. We propose a general framework that scales to such instances by iteratively expanding a subset of clauses while providing soundness and optimality guarantees. We also present new techniques to instantiate and optimize the framework.

[1]  Leslie Pack Kaelbling,et al.  Lifted Probabilistic Inference with Counting Formulas , 2008, AAAI.

[2]  Joao Marques-Silva,et al.  Automated Design Debugging With Maximum Satisfiability , 2010, IEEE Transactions on Computer-Aided Design of Integrated Circuits and Systems.

[3]  Christopher Ré,et al.  Tuffy: Scaling up Statistical Inference in Markov Logic Networks using an RDBMS , 2011, Proc. VLDB Endow..

[4]  Isil Dillig,et al.  Automated Synthesis of Semantic Malware Signatures using Maximum Satisfiability , 2016, NDSS.

[5]  Yannis Smaragdakis,et al.  Using Datalog for Fast and Easy Program Analysis , 2010, Datalog.

[6]  Roberto Sebastiani,et al.  Optimization in SMT with LA(Q) Cost Functions , 2012 .

[7]  Vasco M. Manquinho,et al.  Pseudo-Boolean and Cardinality Constraints , 2021, Handbook of Satisfiability.

[8]  Albert Oliveras,et al.  On SAT Modulo Theories and Optimization Problems , 2006, SAT.

[9]  Sharad Malik,et al.  On Solving the Partial MAX-SAT Problem , 2006, SAT.

[10]  Kenneth L. McMillan,et al.  Ivy: safety verification by interactive generalization , 2016, PLDI.

[11]  Vasco M. Manquinho,et al.  Algorithms for Weighted Boolean Optimization , 2009, SAT.

[12]  Dan Roth,et al.  Lifted First-Order Probabilistic Inference , 2005, IJCAI.

[13]  Nikolaj Bjørner,et al.  Maximum Satisfiability Using Cores and Correction Sets , 2015, IJCAI.

[14]  Joao Marques-Silva,et al.  Iterative and core-guided MaxSAT solving: A survey and assessment , 2013, Constraints.

[15]  Xin Zhang,et al.  Volt: A Lazy Grounding Framework for Solving Very Large MaxSAT Instances , 2015, SAT.

[16]  Vasco M. Manquinho,et al.  Incremental Cardinality Constraints for MaxSAT , 2014, CP.

[17]  Alberto Griggio,et al.  Satisfiability Modulo the Theory of Costs: Foundations and Applications , 2010, TACAS.

[18]  Vasco M. Manquinho,et al.  Progression in Maximum Satisfiability , 2014, ECAI.

[19]  Roberto Sebastiani,et al.  On Optimization Modulo Theories, MaxSMT and Sorting Networks , 2017, TACAS.

[20]  Maria Luisa Bonet,et al.  SAT-based MaxSAT algorithms , 2013, Artif. Intell..

[21]  Chao Wang,et al.  ConcBugAssist: constraint solving for diagnosis and repair of concurrency bugs , 2015, ISSTA.

[22]  Inês Lynce,et al.  Reasoning over Biological Networks Using Maximum Satisfiability , 2012, CP.

[23]  Ondrej Lhoták,et al.  Pick your contexts well: understanding object-sensitivity , 2011, POPL '11.

[24]  Heiner Stuckenschmidt,et al.  RockIt: Exploiting Parallelism and Symmetry for MAP Inference in Statistical Relational Models , 2013, AAAI.

[25]  Samuel Kaski,et al.  Optimal Neighborhood Preserving Visualization by Maximum Satisfiability , 2014, AAAI.

[26]  Rupak Majumdar,et al.  Cause clue clauses: error localization using maximum satisfiability , 2010, PLDI '11.

[27]  Xin Zhang,et al.  A user-guided approach to program analysis , 2015, ESEC/SIGSOFT FSE.

[28]  Didier Dubois,et al.  Possibilistic Logic - An Overview , 2014, Computational Logic.

[29]  Pedro M. Domingos,et al.  Discriminative Training of Markov Logic Networks , 2005, AAAI.

[30]  Sharad Malik,et al.  Post-silicon fault localisation using maximum satisfiability and backbones , 2011, 2011 Formal Methods in Computer-Aided Design (FMCAD).

[31]  Niklas Sörensson,et al.  Temporal induction by incremental SAT solving , 2003, BMC@CAV.

[32]  Pedro M. Domingos,et al.  Markov Logic: An Interface Layer for Artificial Intelligence , 2009, Markov Logic: An Interface Layer for Artificial Intelligence.

[33]  Xin Zhang,et al.  On Incremental Core-Guided MaxSAT Solving , 2016, CP.

[34]  Alexander Aiken,et al.  Introduction to Set Constraint-Based Program Analysis , 1999, Sci. Comput. Program..

[35]  Sriram K. Rajamani,et al.  Combining Relational Learning with SMT Solvers Using CEGAR , 2013, CAV.

[36]  Pavol Cerný,et al.  Optimizing horn solvers for network repair , 2016, 2016 Formal Methods in Computer-Aided Design (FMCAD).

[37]  Joao Marques-Silva,et al.  Core-Guided Binary Search Algorithms for Maximum Satisfiability , 2011, AAAI.

[38]  Joao Marques-Silva,et al.  Core-Guided MaxSAT with Soft Cardinality Constraints , 2014, International Conference on Principles and Practice of Constraint Programming.

[39]  Yannis Smaragdakis,et al.  Strictly declarative specification of sophisticated points-to analyses , 2009, OOPSLA.

[40]  Yannis Smaragdakis,et al.  Hybrid context-sensitivity for points-to analysis , 2013, PLDI.

[41]  Luc De Raedt,et al.  Lifted Probabilistic Inference by First-Order Knowledge Compilation , 2011, IJCAI.

[42]  Pedro M. Domingos,et al.  Lifted First-Order Belief Propagation , 2008, AAAI.

[43]  Nikolaj Bjørner,et al.  νZ - An Optimizing SMT Solver , 2015, TACAS.

[44]  Niklas Sörensson,et al.  Translating Pseudo-Boolean Constraints into SAT , 2006, J. Satisf. Boolean Model. Comput..

[45]  Nikolaj Bjørner,et al.  νZ - Maximal Satisfaction with Z3 , 2014, SCSS.

[46]  Finn V. Jensen,et al.  Bayesian Networks and Decision Graphs , 2001, Statistics for Engineering and Information Science.

[47]  Matthew Richardson,et al.  The Alchemy System for Statistical Relational AI: User Manual , 2007 .

[48]  Sean Safarpour,et al.  Improved Design Debugging Using Maximum Satisfiability , 2007 .

[49]  Sebastian Riedel Improving the Accuracy and Efficiency of MAP Inference for Markov Logic , 2008, UAI.

[50]  Marsha Chechik,et al.  Symbolic optimization with SMT solvers , 2014, POPL.

[51]  Nikolaj Bjørner,et al.  Horn Clause Solvers for Program Verification , 2015, Fields of Logic and Computation II.

[52]  Alberto Griggio,et al.  A Modular Approach to MaxSAT Modulo Theories , 2013, SAT.

[53]  Leonid Libkin,et al.  Elements of Finite Model Theory , 2004, Texts in Theoretical Computer Science.

[54]  Carsten Sinz,et al.  Towards an Optimal CNF Encoding of Boolean Cardinality Constraints , 2005, CP.

[55]  Wolfgang Küchlin,et al.  Applications of MaxSAT in Automotive Configuration , 2013, Configuration Workshop.

[56]  Radu Grigore,et al.  Abstraction refinement guided by a learnt probabilistic model , 2015, POPL.

[57]  Xin Zhang,et al.  On abstraction refinement for program analyses in Datalog , 2014, PLDI 2014.

[58]  Yannis Smaragdakis,et al.  Introspective analysis: context-sensitivity, across the board , 2014, PLDI.

[59]  Xin Zhang,et al.  Scaling Relational Inference Using Proofs and Refutations , 2016, AAAI.

[60]  Joao Marques-Silva,et al.  Algorithms for Maximum Satisfiability using Unsatisfiable Cores , 2008, 2008 Design, Automation and Test in Europe.

[61]  Edmund M. Clarke,et al.  Counterexample-guided abstraction refinement , 2003, 10th International Symposium on Temporal Representation and Reasoning, 2003 and Fourth International Conference on Temporal Logic. Proceedings..

[62]  Xin Zhang,et al.  Query-guided maximum satisfiability , 2016, POPL.

[63]  David Poole,et al.  First-order probabilistic inference , 2003, IJCAI.

[64]  Ondrej Lhoták,et al.  In defense of soundiness , 2015, Commun. ACM.

[65]  Nina Narodytska,et al.  Maximum Satisfiability Using Core-Guided MaxSAT Resolution , 2014, AAAI.

[66]  Maria Luisa Bonet,et al.  Solving (Weighted) Partial MaxSAT through Satisfiability Testing , 2009, SAT.

[67]  Kenneth A. Ross,et al.  Modular stratification and magic sets for Datalog programs with negation , 1994, JACM.

[68]  Xin Zhang,et al.  Effective interactive resolution of static analysis alarms , 2017, Proc. ACM Program. Lang..

[69]  Sorin Lerner,et al.  OPIUM: Optimal Package Install/Uninstall Manager , 2007, 29th International Conference on Software Engineering (ICSE'07).

[70]  Matti Järvisalo,et al.  Applications of MaxSAT in Data Analysis , 2019, POS@SAT.

[71]  Serge Abiteboul,et al.  Foundations of Databases: The Logical Level , 1995 .

[72]  Alessandro Orso,et al.  Improving Efficiency and Accuracy of Formula-Based Debugging , 2016, Haifa Verification Conference.