Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
caisar
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
pub
caisar
Commits
87ae4989
Commit
87ae4989
authored
2 years ago
by
Michele Alberti
Browse files
Options
Downloads
Patches
Plain Diff
[verification] Pull out non-task specific code.
parent
cf1e5ce9
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/verification.ml
+39
-41
39 additions, 41 deletions
src/verification.ml
with
39 additions
and
41 deletions
src/verification.ml
+
39
−
41
View file @
87ae4989
...
...
@@ -318,50 +318,48 @@ let verify ?(debug = false) ?format ~loadpath ?memlimit ?timelimit ?dataset
let
th
=
JSON
.
theory_of_input
env
jin
in
Wstdlib
.
Mstr
.
singleton
th
.
th_name
.
id_string
th
in
let
config_prover
=
let
altern
=
let
default
=
if
Prover
.
has_vnnlib_support
prover
&&
Option
.
is_some
dataset
then
"VNNLIB"
else
""
(* Select the default one, w/o an alternative. *)
in
Option
.
value
prover_altern
~
default
in
let
prover
=
Prover
.
to_string
prover
in
try
Whyconf
.(
filter_one_prover
config
(
mk_filter_prover
~
altern
prover
))
with
|
Whyconf
.
ProverNotFound
_
->
invalid_arg
(
Fmt
.
str
"No prover corresponds to %s%a"
prover
(
if
String
.
equal
altern
""
then
Fmt
.
nop
else
Fmt
.(
any
" "
++
parens
string
))
altern
)
|
Whyconf
.
ProverAmbiguity
_
->
invalid_arg
(
Fmt
.
str
"More than one prover correspond to %s%a"
prover
(
if
String
.
equal
altern
""
then
Fmt
.
nop
else
Fmt
.(
any
" "
++
parens
string
))
altern
)
in
let
driver
=
match
String
.
chop_prefix
~
prefix
:
"caisar_drivers/"
config_prover
.
driver
with
|
None
->
Whyconf
.(
load_driver
(
get_main
config
)
env
config_prover
)
|
Some
file
->
let
file
=
Filename
.
concat
(
Filename
.
concat
(
List
.
hd_exn
Dirs
.
Sites
.
config
)
"drivers"
)
file
in
Driver
.
load_driver_absolute
env
file
config_prover
.
extra_drivers
in
Wstdlib
.
Mstr
.
map
(
fun
theory
->
let
tasks
=
Task
.
split_theory
theory
None
None
in
let
config_prover
=
let
altern
=
let
default
=
if
Prover
.
has_vnnlib_support
prover
&&
Option
.
is_some
dataset
then
"VNNLIB"
else
""
(* Select the default one, w/o an alternative. *)
in
Option
.
value
prover_altern
~
default
in
let
prover
=
Prover
.
to_string
prover
in
try
Whyconf
.(
filter_one_prover
config
(
mk_filter_prover
~
altern
prover
))
with
|
Whyconf
.
ProverNotFound
_
->
invalid_arg
(
Fmt
.
str
"No prover corresponds to %s%a"
prover
(
if
String
.
equal
altern
""
then
Fmt
.
nop
else
Fmt
.(
any
" "
++
parens
string
))
altern
)
|
Whyconf
.
ProverAmbiguity
_
->
invalid_arg
(
Fmt
.
str
"More than one prover correspond to %s%a"
prover
(
if
String
.
equal
altern
""
then
Fmt
.
nop
else
Fmt
.(
any
" "
++
parens
string
))
altern
)
in
let
driver
=
match
String
.
chop_prefix
~
prefix
:
"caisar_drivers/"
config_prover
.
driver
with
|
None
->
Whyconf
.(
load_driver
(
get_main
config
)
env
config_prover
)
|
Some
file
->
let
file
=
Filename
.
concat
(
Filename
.
concat
(
List
.
hd_exn
Dirs
.
Sites
.
config
)
"drivers"
)
file
in
Driver
.
load_driver_absolute
env
file
config_prover
.
extra_drivers
in
List
.
map
~
f
:
(
call_prover
?
dataset
~
limit
main
env
prover
config_prover
driver
)
tasks
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment