Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
frama-c
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container Registry
Model registry
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
frama-c
Commits
04b9a4a7
Commit
04b9a4a7
authored
2 years ago
by
Loïc Correnson
Committed by
Allan Blanchard
2 years ago
Browse files
Options
Downloads
Patches
Plain Diff
[wp] preparing new report
parent
80e1a3d2
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/plugins/wp/register.ml
+40
-12
40 additions, 12 deletions
src/plugins/wp/register.ml
with
40 additions
and
12 deletions
src/plugins/wp/register.ml
+
40
−
12
View file @
04b9a4a7
...
@@ -127,10 +127,6 @@ let pp_warnings fmt wpo =
...
@@ -127,10 +127,6 @@ let pp_warnings fmt wpo =
(* --- Prover Stats --- *)
(* --- Prover Stats --- *)
(* ------------------------------------------------------------------------ *)
(* ------------------------------------------------------------------------ *)
let
do_wpo_display
goal
=
let
result
=
if
Wpo
.
is_trivial
goal
then
"trivial"
else
"not tried"
in
Wp_parameters
.
feedback
"Goal %s : %s"
(
Wpo
.
get_gid
goal
)
result
module
PM
=
module
PM
=
Map
.
Make
(
struct
Map
.
Make
(
struct
type
t
=
VCS
.
prover
type
t
=
VCS
.
prover
...
@@ -340,17 +336,43 @@ let do_wpo_smoke status goal =
...
@@ -340,17 +336,43 @@ let do_wpo_smoke status goal =
(
VCS
.
pp_result_qualif
~
updating
p
r
)
(
VCS
.
pp_result_qualif
~
updating
p
r
)
)
(
results
goal
)
;
)
(
results
goal
)
;
end
end
[
@@@
warning
"-32"
]
let
do_wpo_success
goal
s
=
let
do_report_stats
~
shell
~
updating
~
smoke
goal
(
verdict
,
stats
)
=
let
status
=
if
smoke
then
match
verdict
with
|
VCS
.
NoResult
|
Computing
_
->
""
|
Invalid
->
"Passed"
|
Valid
->
"Failed"
|
Failed
->
"Unknown (Failure)"
|
Unknown
->
"Passed (Unknown)"
|
Timeout
->
"Passed (Timeout)"
|
Stepout
->
"Passed (Stepout)"
else
match
verdict
with
|
VCS
.
NoResult
|
Computing
_
->
""
|
Valid
->
"Valid"
|
Invalid
->
"Invalid"
|
Failed
->
"Failure"
|
Unknown
->
"Unknown"
|
Timeout
->
"Timeout"
|
Stepout
->
"Stepout"
in
if
status
<>
""
then
Wp_parameters
.
feedback
"[%s] %s%a%a"
status
(
Wpo
.
get_gid
goal
)
(
Stats
.
pp_stats
~
shell
~
updating
)
stats
pp_warnings
goal
[
@@@
warning
"+32"
]
let
do_wpo_success
~
shell
~
updating
goal
success
=
if
Wp_parameters
.
Generate
.
get
()
then
if
Wp_parameters
.
Generate
.
get
()
then
match
s
with
match
s
uccess
with
|
None
->
()
|
None
->
()
|
Some
prover
->
|
Some
prover
->
Wp_parameters
.
feedback
~
ontty
:
`Silent
Wp_parameters
.
feedback
~
ontty
:
`Silent
"[%a] Goal %s : Valid"
VCS
.
pp_prover
prover
(
Wpo
.
get_gid
goal
)
"[%a] Goal %s : Valid"
VCS
.
pp_prover
prover
(
Wpo
.
get_gid
goal
)
else
else
if
Wpo
.
is_smoke_test
goal
then
if
Wpo
.
is_smoke_test
goal
then
begin
match
s
with
begin
match
s
uccess
with
|
None
->
|
None
->
Wp_parameters
.
feedback
~
ontty
:
`Silent
Wp_parameters
.
feedback
~
ontty
:
`Silent
"[Passed] Smoke-test %s"
(
Wpo
.
get_gid
goal
)
"[Passed] Smoke-test %s"
(
Wpo
.
get_gid
goal
)
...
@@ -362,15 +384,15 @@ let do_wpo_success goal s =
...
@@ -362,15 +384,15 @@ let do_wpo_success goal s =
Wp_parameters
.
warning
~
source
"Failed smoke-test"
Wp_parameters
.
warning
~
source
"Failed smoke-test"
end
end
else
else
begin
match
s
with
begin
match
s
uccess
with
|
None
->
do_wpo_failed
goal
|
None
->
do_wpo_failed
goal
|
Some
(
VCS
.
Tactical
as
script
)
->
|
Some
(
VCS
.
Tactical
as
script
)
->
Wp_parameters
.
feedback
~
ontty
:
`Silent
Wp_parameters
.
feedback
~
ontty
:
`Silent
"[%a] Goal %s : Valid"
"[%a] Goal %s : Valid"
VCS
.
pp_prover
script
(
Wpo
.
get_gid
goal
)
VCS
.
pp_prover
script
(
Wpo
.
get_gid
goal
)
|
Some
prover
->
|
Some
prover
->
ignore
shell
;
let
result
=
Wpo
.
get_result
goal
prover
in
let
result
=
Wpo
.
get_result
goal
prover
in
let
updating
=
Cache
.
is_updating
()
in
Wp_parameters
.
feedback
~
ontty
:
`Silent
Wp_parameters
.
feedback
~
ontty
:
`Silent
"[%a] Goal %s : %t"
"[%a] Goal %s : %t"
VCS
.
pp_prover
prover
(
Wpo
.
get_gid
goal
)
VCS
.
pp_prover
prover
(
Wpo
.
get_gid
goal
)
...
@@ -497,6 +519,8 @@ let spawn_wp_proofs ~script goals =
...
@@ -497,6 +519,8 @@ let spawn_wp_proofs ~script goals =
begin
begin
let
server
=
ProverTask
.
server
()
in
let
server
=
ProverTask
.
server
()
in
ignore
(
Wp_parameters
.
Share
.
get_dir
"."
);
(* To prevent further errors *)
ignore
(
Wp_parameters
.
Share
.
get_dir
"."
);
(* To prevent further errors *)
let
shell
=
Wp_parameters
.
has_dkey
VCS
.
dkey_shell
in
let
updating
=
Cache
.
is_updating
()
in
Bag
.
iter
Bag
.
iter
(
fun
goal
->
(
fun
goal
->
if
script
.
tactical
if
script
.
tactical
...
@@ -513,7 +537,7 @@ let spawn_wp_proofs ~script goals =
...
@@ -513,7 +537,7 @@ let spawn_wp_proofs ~script goals =
~
start
:
do_wpo_start
~
start
:
do_wpo_start
~
progress
:
do_progress
~
progress
:
do_progress
~
result
:
do_wpo_result
~
result
:
do_wpo_result
~
success
:
do_wpo_success
~
success
:
(
do_wpo_success
~
shell
~
updating
)
goal
goal
else
else
Prover
.
spawn
goal
Prover
.
spawn
goal
...
@@ -521,7 +545,7 @@ let spawn_wp_proofs ~script goals =
...
@@ -521,7 +545,7 @@ let spawn_wp_proofs ~script goals =
~
start
:
do_wpo_start
~
start
:
do_wpo_start
~
progress
:
do_progress
~
progress
:
do_progress
~
result
:
do_wpo_result
~
result
:
do_wpo_result
~
success
:
do_wpo_success
~
success
:
(
do_wpo_success
~
shell
~
updating
)
script
.
provers
script
.
provers
)
goals
;
)
goals
;
Task
.
on_server_wait
server
do_wpo_wait
;
Task
.
on_server_wait
server
do_wpo_wait
;
...
@@ -714,6 +738,10 @@ let do_session ~script goals =
...
@@ -714,6 +738,10 @@ let do_session ~script goals =
do_update_session
script
session
;
do_update_session
script
session
;
do_show_session
script
.
update
session
do_show_session
script
.
update
session
let
do_wpo_display
goal
=
let
result
=
if
Wpo
.
is_trivial
goal
then
"trivial"
else
"not tried"
in
Wp_parameters
.
feedback
"Goal %s : %s"
(
Wpo
.
get_gid
goal
)
result
let
do_wp_proofs
?
provers
?
tip
(
goals
:
Wpo
.
t
Bag
.
t
)
=
let
do_wp_proofs
?
provers
?
tip
(
goals
:
Wpo
.
t
Bag
.
t
)
=
let
script
=
default_script_mode
()
in
let
script
=
default_script_mode
()
in
let
mode
=
VCS
.
parse_mode
(
Wp_parameters
.
Interactive
.
get
()
)
in
let
mode
=
VCS
.
parse_mode
(
Wp_parameters
.
Interactive
.
get
()
)
in
...
...
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