1
1
#! /bin/bash
2
2
3
3
# Matthias Heizmann ([email protected] )
4
- # SMT-COMP 2016 post-processor for the unsat -core track
4
+ # SMT-COMP 2017 post-processor for the Unsat -core Track
5
5
6
- # This postprocessor contains a copy of z3-4.4.1 which is located in the
7
- # validation_solvers/z3 subfolder.
6
+ # This postprocessor contains a copy several SMT solvers that are located in
7
+ # the validation_solvers subfolder
8
8
9
9
# This bash script mainly does the following
10
10
# 1. Examine if the check-sat result of the solver was "sat".
15
15
# 3. Write the "unsat-core-validation-script.smt2" SMT script. This script
16
16
# is a copy of the input which contains only the assert commands whose
17
17
# corresponding named terms were in the unsat-core returned by the solver.
18
- # 4. Use another solver to validate the unsat core. We use this validation
19
- # solver to check the unsat-core-validation-script.smt2. We consider
20
- # the unsat-core valid if the validation solver did not return "sat"
18
+ # 4. Use other solvers to validate the unsat core. We use the validation
19
+ # solvers to check the unsat-core-validation-script.smt2. We consider
20
+ # the unsat-core valid if none of the validation solvers returns "sat"
21
21
# within its timeout.
22
+ # We note that this slightly deviates from the SMT-COMP rules, hence in
23
+ # case of an erroneous result and ambiguous validation results a manual
24
+ # postprocessing of the final verdict might be neccessary.
22
25
23
26
# $1: solver output
24
27
# $2: path to pre-processed benchmark
25
28
26
29
# timeout in seconds for each validating solver
27
- VALIDATION_TIMOUT=120
30
+ VALIDATION_TIMOUT=300
28
31
29
32
set -u
30
33
# do not use 'set -e' since the scrambler my fail while trying to parse the unsat core
@@ -78,12 +81,14 @@ if [ "$CHECK_SAT_RESPONSE" == "unsat" ]; then
78
81
# use validation solvers to check validation script
79
82
VALIDATION_SOLVERS[1]=" cvc4"
80
83
VALIDATION_SOLVERS[2]=" mathsat"
81
- VALIDATION_SOLVERS[3]=" z3"
82
- VALIDATION_SOLVER_COMMANDS[1]=" ./validation_solvers/cvc4/cvc4-2016-05-21-x86_64-linux-opt"
84
+ VALIDATION_SOLVERS[3]=" vampire"
85
+ VALIDATION_SOLVERS[4]=" z3"
86
+ VALIDATION_SOLVER_COMMANDS[1]=" ./validation_solvers/cvc4/cvc4"
83
87
VALIDATION_SOLVER_COMMANDS[2]=" ./validation_solvers/mathsat/bin/mathsat"
84
- VALIDATION_SOLVER_COMMANDS[3]=" ./validation_solvers/z3/z3 -smt2"
88
+ VALIDATION_SOLVER_COMMANDS[3]=" ./validation_solvers/vampire/vampire -t 2000s -m 60000 --mode smtcomp --cores 4"
89
+ VALIDATION_SOLVER_COMMANDS[4]=" ./validation_solvers/z3/z3 -smt2"
85
90
UNSAT_CORE_VALIDATED=" true"
86
- for i in {1..3 }
91
+ for i in {1..4 }
87
92
do
88
93
TIME_START=` date +%s`
89
94
timeout -k 10 $VALIDATION_TIMOUT ${VALIDATION_SOLVER_COMMANDS[$i]} ./unsat-core-validation-script.smt2 & > validationOutput.txt
@@ -100,6 +105,7 @@ if [ "$CHECK_SAT_RESPONSE" == "unsat" ]; then
100
105
if [ " $VALIDATION_CHECK_SAT_RESULT " == " sat" ] || [ " $UNSAT_CORE_VALIDATED " == " false" ]; then
101
106
UNSAT_CORE_VALIDATED=" false"
102
107
RESULT_IS_ERRONEOUS=" 1"
108
+ REDUCTION=" 0"
103
109
fi
104
110
done
105
111
echo " unsat-core-validated=$UNSAT_CORE_VALIDATED "
0 commit comments