38
38
#include " dfcc_instrument.h"
39
39
#include " dfcc_library.h"
40
40
#include " dfcc_lift_memory_predicates.h"
41
- #include " dfcc_loop_contract_mode.h"
42
41
#include " dfcc_spec_functions.h"
43
42
#include " dfcc_swap_and_wrap.h"
44
43
@@ -96,9 +95,7 @@ class invalid_function_contract_pair_exceptiont : public cprover_exception_baset
96
95
// / \param to_check function to check against its contract
97
96
// / \param allow_recursive_calls Allow the checked function to be recursive
98
97
// / \param to_replace set of functions to replace with their contract
99
- // / \param apply_loop_contracts apply loop contract transformations iff true
100
- // / \param unwind_transformed_loops unwind transformed loops after applying loop
101
- // / contracts.
98
+ // / \param loop_contract_config configuration for applying loop contracts
102
99
// / \param to_exclude_from_nondet_static set of symbols to exclude when havocing
103
100
// / static program symbols.
104
101
// / \param message_handler used for debug/warning/error messages
@@ -109,41 +106,7 @@ void dfcc(
109
106
const std::optional<irep_idt> &to_check,
110
107
const bool allow_recursive_calls,
111
108
const std::set<irep_idt> &to_replace,
112
- const bool apply_loop_contracts,
113
- const bool unwind_transformed_loops,
114
- const std::set<std::string> &to_exclude_from_nondet_static,
115
- message_handlert &message_handler);
116
-
117
- // / \ingroup dfcc-module
118
- // / \brief Applies function contracts and loop contracts transformation to GOTO
119
- // / model, using the dynamic frame condition checking approach.
120
- // /
121
- // / Functions to check/replace are explicitly mapped to contracts.
122
- // / When checking function `foo` against contract `bar`, we require the
123
- // / actual contract symbol to exist as `contract::bar` in the symbol table.
124
- // /
125
- // / \param options CLI options (used to lookup options for language config when
126
- // / re-defining the model's entry point)
127
- // / \param goto_model GOTO model to transform
128
- // / \param harness_id Proof harness name, must be the entry point of the model
129
- // / \param to_check (function,contract) pair for contract checking
130
- // / \param allow_recursive_calls Allow the checked function to be recursive
131
- // / \param to_replace Functions-to-contract mapping for replacement
132
- // / \param apply_loop_contracts Apply loop contract transformations iff true
133
- // / \param unwind_transformed_loops unwind transformed loops after applying loop
134
- // / contracts.
135
- // / \param to_exclude_from_nondet_static Set of symbols to exclude when havocing
136
- // / static program symbols.
137
- // / \param message_handler used for debug/warning/error messages
138
- void dfcc (
139
- const optionst &options,
140
- goto_modelt &goto_model,
141
- const irep_idt &harness_id,
142
- const std::optional<std::pair<irep_idt, irep_idt>> &to_check,
143
- const bool allow_recursive_calls,
144
- const std::map<irep_idt, irep_idt> &to_replace,
145
- const bool apply_loop_contracts,
146
- const bool unwind_transformed_loops,
109
+ const loop_contract_configt loop_contract_config,
147
110
const std::set<std::string> &to_exclude_from_nondet_static,
148
111
message_handlert &message_handler);
149
112
@@ -160,7 +123,7 @@ class dfcct
160
123
// / \param to_check (function,contract) pair for contract checking
161
124
// / \param allow_recursive_calls Allow the checked function to be recursive
162
125
// / \param to_replace functions-to-contract mapping for replacement
163
- // / \param loop_contract_mode mode to use for loop contracts
126
+ // / \param loop_contract_config configuration for applying loop contracts
164
127
// / \param message_handler used for debug/warning/error messages
165
128
// / \param to_exclude_from_nondet_static set of symbols to exclude when
166
129
dfcct (
@@ -170,7 +133,7 @@ class dfcct
170
133
const std::optional<std::pair<irep_idt, irep_idt>> &to_check,
171
134
const bool allow_recursive_calls,
172
135
const std::map<irep_idt, irep_idt> &to_replace,
173
- const dfcc_loop_contract_modet loop_contract_mode ,
136
+ const loop_contract_configt loop_contract_config ,
174
137
message_handlert &message_handler,
175
138
const std::set<std::string> &to_exclude_from_nondet_static);
176
139
@@ -207,7 +170,7 @@ class dfcct
207
170
const std::optional<std::pair<irep_idt, irep_idt>> &to_check;
208
171
const bool allow_recursive_calls;
209
172
const std::map<irep_idt, irep_idt> &to_replace;
210
- const dfcc_loop_contract_modet loop_contract_mode ;
173
+ const loop_contract_configt loop_contract_config ;
211
174
const std::set<std::string> &to_exclude_from_nondet_static;
212
175
message_handlert &message_handler;
213
176
messaget log;
0 commit comments