Implementing SMT Theory
This guide outlines the steps to integrate a new SMT theory into ESBMC. Throughout the tutorial, we will use the QF_AUFLIRA theory as an example.
Steps to Follow
Create a New Option for ESBMC
Define the new option in theoptions.cppfile:
Source LinkAdd New Logic to BMC
Add the logic for your new SMT theory in thebmc.cppfile:
Source LinkSet the Option in Parser Options
Configure the option in the parser options at:
Source LinkAdjust Pointer Dereference Module
Review and modify the pointer dereference module if necessary:
Source LinkAdjust SMT Backends
Update the relevant SMT backends. As examples:- Bitwuzla: Source Link
- Boolector: Source Link
Add New Encoding Type
Define the new encoding type (e.g.,real_encoding) in the SMT converter:Add the New Theory
Implement the new SMT theory in the SMT-LIB converter:
Source LinkAdjust Simplification Logic
Modify the expression simplification logic as needed:
Source LinkCheck for Additional Operations
Verify whether new operations need to be added in the SMT converter:
Source Link