Debian Codegraph @

contrib/competitions/smt-comp/run-script-smtcomp2017

raw
1 #!/bin/bash
2
3 cvc4=./cvc4
4 bench="$1"
5
6 logic=$(expr "$(grep -m1 '^[^;]*set-logic' "$bench")" : ' *(set-logic *\([A-Z_]*\) *) *$')
7
8 # use: trywith [params..]
9 # to attempt a run. Only thing printed on stdout is "sat" or "unsat", in
10 # which case this run script terminates immediately. Otherwise, this
11 # function returns normally.
12 function trywith {
13 limit=$1; shift;
14 result="$(ulimit -S -t "$limit";$cvc4 -L smt2.6 --no-incremental --no-checking --no-interactive "$@" $bench)"
15 case "$result" in
16 sat|unsat) echo "$result"; exit 0;;
17 esac
18 }
19
20 # use: finishwith [params..]
21 # to run cvc4 and let it output whatever it will to stdout.
22 function finishwith {
23 $cvc4 -L smt2.6 --no-incremental --no-checking --no-interactive "$@" $bench
24 }
25
26 case "$logic" in
27
28 QF_LRA)
29 trywith 200 --enable-miplib-trick --miplib-trick-subs=4 --use-approx --lemmas-on-replay-failure --replay-early-close-depth=4 --replay-lemma-reject-cut=128 --replay-reject-cut=512 --unconstrained-simp --use-soi
30 finishwith --no-restrict-pivots --use-soi --new-prop --unconstrained-simp
31 ;;
32 QF_LIA)
33 # same as QF_LRA but add --pb-rewrites
34 finishwith --enable-miplib-trick --miplib-trick-subs=4 --use-approx --lemmas-on-replay-failure --replay-early-close-depth=4 --replay-lemma-reject-cut=128 --replay-reject-cut=512 --unconstrained-simp --use-soi --pb-rewrites
35 ;;
36 QF_NIA)
37 trywith 300 --nl-ext --nl-ext-tplanes --decision=internal
38 trywith 1800 --solve-int-as-bv=2 --bitblast=eager --bv-sat-solver=cryptominisat
39 trywith 1800 --solve-int-as-bv=4 --bitblast=eager --bv-sat-solver=cryptominisat
40 trywith 1800 --solve-int-as-bv=8 --bitblast=eager --bv-sat-solver=cryptominisat
41 trywith 1800 --solve-int-as-bv=16 --bitblast=eager --bv-sat-solver=cryptominisat
42 finishwith --solve-int-as-bv=32 --bitblast=eager --bv-sat-solver=cryptominisat
43 ;;
44 QF_NRA)
45 trywith 300 --nl-ext --nl-ext-tplanes --decision=justification
46 finishwith --nl-ext --nl-ext-tplanes
47 ;;
48 # all logics with UF + quantifiers should either fall under this or special cases below
49 ALIA|AUFLIA|AUFLIRA|AUFNIRA|UF|UFIDL|UFLIA|UFLRA|UFNIA|UFDT|UFDTLIA|AUFDTLIA|AUFBVDTLIA)
50 # the following is designed for a run time of 2400s (40 min).
51 # initial runs 1min
52 trywith 20 --simplification=none --full-saturate-quant
53 trywith 20 --no-e-matching --full-saturate-quant
54 trywith 20 --fs-inst --decision=internal --full-saturate-quant
55 # trigger selections 3min
56 trywith 30 --relevant-triggers --full-saturate-quant
57 trywith 30 --trigger-sel=max --full-saturate-quant
58 trywith 30 --multi-trigger-when-single --full-saturate-quant
59 trywith 30 --multi-trigger-when-single --multi-trigger-priority --full-saturate-quant
60 trywith 30 --multi-trigger-cache --full-saturate-quant
61 trywith 30 --no-multi-trigger-linear --full-saturate-quant
62 # other 3min
63 trywith 30 --pre-skolem-quant --full-saturate-quant
64 trywith 30 --inst-when=full --full-saturate-quant
65 trywith 30 --no-e-matching --no-quant-cf --full-saturate-quant
66 trywith 30 --nl-ext --full-saturate-quant
67 trywith 30 --full-saturate-quant --quant-ind
68 trywith 60 --decision=internal --simplification=none --no-inst-no-entail --no-quant-cf --full-saturate-quant
69 # finite model find 2min
70 trywith 20 --finite-model-find --mbqi=none
71 trywith 20 --finite-model-find
72 trywith 20 --finite-model-find --uf-ss=no-minimal
73 trywith 60 --finite-model-find --fmf-inst-engine
74 # long runs 20min
75 trywith 200 --decision=internal --full-saturate-quant
76 trywith 200 --term-db-mode=relevant --full-saturate-quant
77 trywith 200 --fs-inst --full-saturate-quant
78 trywith 600 --finite-model-find --decision=internal
79 # finite model find 1min
80 trywith 30 --finite-model-find --fmf-bound-int
81 trywith 30 --finite-model-find --sort-inference
82 # finish 10min
83 finishwith --full-saturate-quant
84 ;;
85 UFBV)
86 # most problems in UFBV are essentially BV
87 trywith 300 --full-saturate-quant
88 trywith 300 --full-saturate-quant --no-cbqi
89 trywith 300 --full-saturate-quant --cbqi --decision=internal
90 finishwith --finite-model-find
91 ;;
92 BV)
93 trywith 300 --full-saturate-quant
94 trywith 300 --full-saturate-quant --no-cbqi
95 finishwith --full-saturate-quant --cbqi --decision=internal
96 ;;
97 LIA|LRA)
98 trywith 30 --full-saturate-quant
99 trywith 300 --full-saturate-quant --cbqi-midpoint
100 trywith 300 --full-saturate-quant --cbqi-nested-qe
101 finishwith --full-saturate-quant --cbqi --cbqi-nested-qe --decision=internal
102 ;;
103 NIA|NRA)
104 trywith 30 --full-saturate-quant
105 trywith 300 --full-saturate-quant --nl-ext
106 trywith 300 --full-saturate-quant --cbqi-nested-qe
107 finishwith --full-saturate-quant --cbqi --cbqi-nested-qe --decision=internal
108 ;;
109 QF_AUFBV)
110 trywith 600
111 finishwith --decision=justification-stoponly
112 ;;
113 QF_ABV)
114 trywith 50 --ite-simp --simp-with-care --repeat-simp --arrays-weak-equiv
115 trywith 500 --arrays-weak-equiv
116 finishwith --ite-simp --simp-with-care --repeat-simp --arrays-weak-equiv
117 ;;
118 QF_UFBV)
119 finishwith --bitblast=eager --bv-sat-solver=cryptominisat
120 ;;
121 QF_BV)
122 exec ./pcvc4 -L smt2.6 --no-incremental --no-checking --no-interactive --thread-stack=1024 \
123 --threads 2 \
124 --thread0 '--unconstrained-simp --bv-div-zero-const --bv-intro-pow2 --bitblast=eager --bv-sat-solver=cryptominisat --bitblast-aig --no-bv-abstraction' \
125 --thread1 '--unconstrained-simp --bv-div-zero-const --bv-intro-pow2 --bv-eq-slicer=auto --no-bv-abstraction' \
126 --no-wait-to-join \
127 "$bench"
128 #trywith 10 --bv-eq-slicer=auto --decision=justification
129 #trywith 60 --decision=justification
130 #trywith 600 --decision=internal --bitblast-eager
131 #finishwith --decision=justification --decision-use-weight --decision-weight-internal=usr1
132 ;;
133 QF_AUFLIA)
134 finishwith --no-arrays-eager-index --arrays-eager-lemmas --decision=justification
135 ;;
136 QF_AX)
137 finishwith --no-arrays-eager-index --arrays-eager-lemmas --decision=internal
138 ;;
139 QF_AUFNIA)
140 finishwith --decision=justification --no-arrays-eager-index --arrays-eager-lemmas
141 ;;
142 QF_ALIA)
143 trywith 70 --decision=justification --arrays-weak-equiv
144 finishwith --decision=justification-stoponly --no-arrays-eager-index --arrays-eager-lemmas
145 ;;
146 *)
147 # just run the default
148 finishwith
149 ;;
150
151 esac
152