Skip to content

Commit 6bf1b49

Browse files
Merge pull request #2847 from peterschrammel/jbmc-no-cover
Remove --cover option from JBMC
2 parents ec7356b + 92cdf0c commit 6bf1b49

File tree

12 files changed

+6
-166
lines changed

12 files changed

+6
-166
lines changed

jbmc/regression/CMakeLists.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,4 @@ add_subdirectory(jdiff)
1010
add_subdirectory(janalyzer-taint)
1111
add_subdirectory(jbmc-concurrency)
1212
add_subdirectory(jbmc-inheritance)
13-
add_subdirectory(jbmc-cover)
1413
add_subdirectory(jbmc-generics)

jbmc/regression/Makefile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
DIRS = janalyzer-taint \
55
jbmc \
66
jbmc-concurrency \
7-
jbmc-cover \
87
jbmc-inheritance \
98
jbmc-strings \
109
jdiff \

jbmc/regression/jbmc-cover/CMakeLists.txt

Lines changed: 0 additions & 3 deletions
This file was deleted.

jbmc/regression/jbmc-cover/Makefile

Lines changed: 0 additions & 34 deletions
This file was deleted.
-750 Bytes
Binary file not shown.

jbmc/regression/jbmc-cover/covered1/covered1.java

Lines changed: 0 additions & 37 deletions
This file was deleted.

jbmc/regression/jbmc-cover/covered1/test.desc

Lines changed: 0 additions & 33 deletions
This file was deleted.
-292 Bytes
Binary file not shown.

jbmc/regression/jbmc-cover/json_trace2/Test.java

Lines changed: 0 additions & 7 deletions
This file was deleted.

jbmc/regression/jbmc-cover/json_trace2/test.desc

Lines changed: 0 additions & 10 deletions
This file was deleted.

jbmc/src/jbmc/jbmc_parse_options.cpp

Lines changed: 5 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -121,9 +121,6 @@ void jbmc_parse_optionst::get_command_line_options(optionst &options)
121121
if(cmdline.isset("show-vcc"))
122122
options.set_option("show-vcc", true);
123123

124-
if(cmdline.isset("cover"))
125-
parse_cover_options(cmdline, options);
126-
127124
if(cmdline.isset("nondet-static"))
128125
options.set_option("nondet-static", true);
129126

@@ -189,14 +186,8 @@ void jbmc_parse_optionst::get_command_line_options(optionst &options)
189186
options.set_option("assumptions", false);
190187

191188
// generate unwinding assertions
192-
if(cmdline.isset("cover"))
193-
options.set_option("unwinding-assertions", false);
194-
else
195-
{
196-
options.set_option(
197-
"unwinding-assertions",
198-
cmdline.isset("unwinding-assertions"));
199-
}
189+
if(cmdline.isset("unwinding-assertions"))
190+
options.set_option("unwinding-assertions", true);
200191

201192
// generate unwinding assumptions otherwise
202193
options.set_option(
@@ -559,12 +550,6 @@ int jbmc_parse_optionst::doit()
559550
// particular function:
560551
add_failed_symbols(lazy_goto_model.symbol_table);
561552

562-
// If applicable, parse the coverage instrumentation configuration, which
563-
// will be used in process_goto_function:
564-
cover_config =
565-
get_cover_config(
566-
options, lazy_goto_model.symbol_table, get_message_handler());
567-
568553
// Provide show-goto-functions and similar dump functions after symex
569554
// executes. If --paths is active, these dump routines run after every
570555
// paths iteration. Its return value indicates that if we ran any dump
@@ -782,20 +767,12 @@ void jbmc_parse_optionst::process_goto_function(
782767
symbol_table);
783768
}
784769

785-
// If using symex-driven function loading we must insert the coverage goals
770+
// If using symex-driven function loading we must label the assertions
786771
// now so symex sees its targets; otherwise we leave this until
787772
// process_goto_functions, as we haven't run remove_exceptions yet, and that
788773
// pass alters the CFG.
789774
if(using_symex_driven_loading)
790775
{
791-
// instrument cover goals
792-
if(cmdline.isset("cover"))
793-
{
794-
INVARIANT(
795-
cover_config != nullptr, "cover config should have been parsed");
796-
instrument_cover_goals(*cover_config, function, get_message_handler());
797-
}
798-
799776
// label the assertions
800777
label_properties(goto_function.body);
801778

@@ -916,17 +893,9 @@ bool jbmc_parse_optionst::process_goto_functions(
916893
remove_unused_functions(goto_model, get_message_handler());
917894
}
918895

919-
// remove skips such that trivial GOTOs are deleted and not considered
920-
// for coverage annotation:
896+
// remove skips such that trivial GOTOs are deleted
921897
remove_skip(goto_model);
922898

923-
// instrument cover goals
924-
if(cmdline.isset("cover"))
925-
{
926-
if(instrument_cover_goals(options, goto_model, get_message_handler()))
927-
return true;
928-
}
929-
930899
// label the assertions
931900
// This must be done after adding assertions and
932901
// before using the argument of the "property" option.
@@ -970,7 +939,7 @@ bool jbmc_parse_optionst::process_goto_functions(
970939
full_slicer(goto_model);
971940
}
972941

973-
// remove any skips introduced since coverage instrumentation
942+
// remove any skips introduced
974943
remove_skip(goto_model);
975944
}
976945

@@ -1079,7 +1048,6 @@ void jbmc_parse_optionst::help()
10791048
" --no-assertions ignore user assertions\n"
10801049
" --no-assumptions ignore user assumptions\n"
10811050
" --error-label label check that label is unreachable\n"
1082-
" --cover CC create test-suite with coverage criterion CC\n" // NOLINT(*)
10831051
" --mm MM memory consistency model for concurrent programs\n" // NOLINT(*)
10841052
HELP_REACHABILITY_SLICER
10851053
" --full-slice run full slicer (experimental)\n" // NOLINT(*)

jbmc/src/jbmc/jbmc_parse_options.h

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ Author: Daniel Kroening, [email protected]
2222

2323
#include <cbmc/bmc.h>
2424

25-
#include <goto-instrument/cover.h>
2625
#include <goto-programs/class_hierarchy.h>
2726
#include <goto-programs/goto_trace.h>
2827
#include <goto-programs/lazy_goto_model.h>
@@ -69,7 +68,7 @@ class optionst;
6968
"(verbosity):" \
7069
"(nondet-static)" \
7170
"(version)" \
72-
"(cover):(symex-coverage-report):" \
71+
"(symex-coverage-report):" \
7372
OPT_TIMESTAMP \
7473
"(i386-linux)(i386-macos)(i386-win32)(win32)(winx64)" \
7574
"(ppc-macos)" \
@@ -120,7 +119,6 @@ class jbmc_parse_optionst:
120119

121120
protected:
122121
ui_message_handlert ui_message_handler;
123-
std::unique_ptr<cover_configt> cover_config;
124122
path_strategy_choosert path_strategy_chooser;
125123
object_factory_parameterst object_factory_params;
126124
bool stub_objects_are_not_null;

0 commit comments

Comments
 (0)