Debian Codegraph @

contrib/competitions/smt-comp/run-script-smtcomp2019-incremental

raw
1 #!/bin/bash
2
3 cvc4=./cvc4
4
5 line=""
6 while [[ -z "$line" ]]; do
7 read line
8 done
9 if [ "$line" != '(set-option :print-success true)' ]; then
10 echo 'ERROR: first line supposed to be set-option :print-success, but got: "'"$line"'"' >&2
11 exit 1
12 fi
13 echo success
14 line=""
15 while [[ -z "$line" ]]; do
16 read line
17 done
18 logic=$(expr "$line" : ' *(set-logic *\([A-Z_]*\) *) *$')
19 if [ -z "$logic" ]; then
20 echo 'ERROR: second line supposed to be set-logic, but got: "'"$line"'"' >&2
21 exit 1
22 fi
23 echo success
24
25 function runcvc4 {
26 # we run in this way for line-buffered input, otherwise memory's a
27 # concern (plus it mimics what we'll end up getting from an
28 # application-track trace runner?)
29 $cvc4 --force-logic="$logic" -L smt2.6 --print-success --no-checking --no-interactive "$@" <&0-
30 }
31
32 case "$logic" in
33
34 ALIA|QF_ALIA|QF_LRA|QF_UFLIA|QF_UFLRA|UFLRA)
35 runcvc4 --incremental
36 ;;
37 ANIA|QF_ANIA|QF_NIA|QF_UFNIA|QF_NRA)
38 runcvc4 --tear-down-incremental=1
39 ;;
40 LIA|LRA)
41 runcvc4 --incremental
42 ;;
43 QF_AUFLIA)
44 runcvc4 --no-arrays-eager-index --arrays-eager-lemmas --incremental
45 ;;
46 QF_BV)
47 runcvc4 --incremental --bitblast=eager --bv-sat-solver=cadical
48 ;;
49 QF_LIA)
50 runcvc4 --tear-down-incremental=1 --unconstrained-simp
51 ;;
52 QF_UFBV)
53 runcvc4 --incremental
54 ;;
55 QF_UF)
56 runcvc4 --incremental
57 ;;
58 QF_AUFBV)
59 runcvc4 --incremental
60 ;;
61 QF_ABV)
62 runcvc4 --incremental
63 ;;
64 ABVFP)
65 runcvc4 --incremental
66 ;;
67 BVFP)
68 runcvc4 --incremental
69 ;;
70 QF_ABVFP)
71 runcvc4 --incremental
72 ;;
73 QF_BVFP)
74 runcvc4 --incremental
75 ;;
76 QF_FP)
77 runcvc4 --incremental
78 ;;
79 *)
80 # just run the default
81 runcvc4 --incremental
82 ;;
83
84 esac