Skip to content
Snippets Groups Projects
Commit bc0f175b authored by Julien Signoles's avatar Julien Signoles
Browse files

[E-ACSL] better handling of already-proven properties

parent 47dd0895
No related branches found
No related tags found
No related merge requests found
...@@ -53,6 +53,11 @@ let reset () = ...@@ -53,6 +53,11 @@ let reset () =
(* Duplicating property statuses *) (* Duplicating property statuses *)
(* ********************************************************************** *) (* ********************************************************************** *)
let reemit = function
| Property.IPBehavior _ | Property.IPAxiom _ | Property.IPAxiomatic _
| Property.IPPredicate (Property.PKAssumes _, _, _, _) -> false
| _ -> true
let copy_ppt old_prj new_prj old_ppt new_ppt = let copy_ppt old_prj new_prj old_ppt new_ppt =
let module P = Property_status in let module P = Property_status in
let selection = State_selection.of_list [ P.self; Emitter.self ] in let selection = State_selection.of_list [ P.self; Emitter.self ] in
...@@ -60,13 +65,8 @@ let copy_ppt old_prj new_prj old_ppt new_ppt = ...@@ -60,13 +65,8 @@ let copy_ppt old_prj new_prj old_ppt new_ppt =
Project.on ~selection new_prj Project.on ~selection new_prj
(fun s -> (fun s ->
let e = match l with [] -> assert false | e :: _ -> e in let e = match l with [] -> assert false | e :: _ -> e in
(* Options.feedback "HERE %a --> %a (%a)" Property.pretty new_ppt let emitter = Emitter.Usable_emitter.get e.P.emitter in
P.Emitted_status.pretty s Project.pretty new_prj;*) P.emit emitter ~hyps:e.P.properties new_ppt s)
if not e.P.logical_consequence then
let emitter = Emitter.Usable_emitter.get e.P.emitter in
(* Options.feedback "EMIT %a --> %a (%a)" Property.pretty new_ppt
P.Emitted_status.pretty s Project.pretty new_prj;*)
P.emit emitter ~hyps:e.P.properties new_ppt s)
s s
in in
let copy () = let copy () =
...@@ -77,7 +77,7 @@ let copy_ppt old_prj new_prj old_ppt new_ppt = ...@@ -77,7 +77,7 @@ let copy_ppt old_prj new_prj old_ppt new_ppt =
emit P.True i.P.valid; emit P.True i.P.valid;
emit P.False_and_reachable i.P.invalid emit P.False_and_reachable i.P.invalid
in in
if not (Options.Valid.get ()) then Queue.add copy actions if reemit old_ppt && not (Options.Valid.get ()) then Queue.add copy actions
(* ********************************************************************** *) (* ********************************************************************** *)
(* Duplicating functions *) (* Duplicating functions *)
......
/* run.config /* run.config
COMMENT: linear search (example of the TAP'12 article) COMMENT: linear search (example of the SAC'13 article)
EXECNOW: LOG gen_linear_search.c BIN gen_linear_search.out @frama-c@ -e-acsl-share ./share/e-acsl ./tests/e-acsl-runtime/linear_search.i -e-acsl -then-on e-acsl -print -ocode ./tests/e-acsl-runtime/result/gen_linear_search.c > /dev/null && ./gcc_test.sh linear_search EXECNOW: LOG gen_linear_search.c BIN gen_linear_search.out @frama-c@ -e-acsl-share ./share/e-acsl ./tests/e-acsl-runtime/linear_search.i -e-acsl -then-on e-acsl -print -ocode ./tests/e-acsl-runtime/result/gen_linear_search.c > /dev/null && ./gcc_test.sh linear_search
EXECNOW: LOG gen_linear_search2.c BIN gen_linear_search2.out @frama-c@ -e-acsl-share ./share/e-acsl ./tests/e-acsl-runtime/linear_search.i -e-acsl-gmp-only -e-acsl -then-on e-acsl -print -ocode ./tests/e-acsl-runtime/result/gen_linear_search2.c > /dev/null && ./gcc_test.sh linear_search2 EXECNOW: LOG gen_linear_search2.c BIN gen_linear_search2.out @frama-c@ -e-acsl-share ./share/e-acsl ./tests/e-acsl-runtime/linear_search.i -e-acsl-gmp-only -e-acsl -then-on e-acsl -print -ocode ./tests/e-acsl-runtime/result/gen_linear_search2.c > /dev/null && ./gcc_test.sh linear_search2
*/ */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment