mirror of
https://github.com/Z3Prover/z3
synced 2025-04-23 17:15:31 +00:00
working on lookahead
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
5ed3200c88
commit
2afd45b3c2
10 changed files with 388 additions and 168 deletions
|
@ -7,7 +7,8 @@
|
|||
#include"debug.h"
|
||||
#include"timeit.h"
|
||||
#include"warning.h"
|
||||
#include "memory_manager.h"
|
||||
#include"memory_manager.h"
|
||||
#include"gparams.h"
|
||||
|
||||
//
|
||||
// Unit tests fail by asserting.
|
||||
|
@ -81,6 +82,7 @@ void parse_cmd_line_args(int argc, char ** argv, bool& do_display_usage, bool& t
|
|||
char * opt_name = arg + 1;
|
||||
char * opt_arg = 0;
|
||||
char * colon = strchr(arg, ':');
|
||||
char * eq_pos = 0;
|
||||
if (colon) {
|
||||
opt_arg = colon + 1;
|
||||
*colon = 0;
|
||||
|
@ -117,6 +119,12 @@ void parse_cmd_line_args(int argc, char ** argv, bool& do_display_usage, bool& t
|
|||
enable_debug(opt_arg);
|
||||
}
|
||||
#endif
|
||||
else if (arg[0] != '"' && (eq_pos = strchr(arg, '='))) {
|
||||
char * key = arg;
|
||||
*eq_pos = 0;
|
||||
char * value = eq_pos+1;
|
||||
gparams::set(key, value);
|
||||
}
|
||||
}
|
||||
i++;
|
||||
}
|
||||
|
|
|
@ -1,4 +1,6 @@
|
|||
#include "sat_solver.h"
|
||||
#include "sat_watched.h"
|
||||
#include "statistics.h"
|
||||
#include "sat_lookahead.h"
|
||||
#include "dimacs.h"
|
||||
|
||||
|
@ -7,7 +9,7 @@ void tst_sat_lookahead(char ** argv, int argc, int& i) {
|
|||
std::cout << "require dimacs file name\n";
|
||||
return;
|
||||
}
|
||||
enable_trace("sat");
|
||||
// enable_trace("sat");
|
||||
reslimit limit;
|
||||
params_ref params;
|
||||
sat::solver solver(params, limit);
|
||||
|
@ -28,4 +30,8 @@ void tst_sat_lookahead(char ** argv, int argc, int& i) {
|
|||
IF_VERBOSE(20, solver.display_status(verbose_stream()););
|
||||
|
||||
std::cout << lh.check() << "\n";
|
||||
|
||||
statistics st;
|
||||
lh.collect_statistics(st);
|
||||
st.display(std::cout);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue