Skip to content

Commit 1659314

Browse files
authored
Merge pull request diffblue#1715 from smowton/smowton/cleanup/jbmc_unused_passes
JBMC: Remove C-only passes
2 parents d4300d0 + c4304ba commit 1659314

File tree

2 files changed

+3
-33
lines changed

2 files changed

+3
-33
lines changed

src/jbmc/jbmc_parse_options.cpp

+1-31
Original file line numberDiff line numberDiff line change
@@ -30,15 +30,11 @@ Author: Daniel Kroening, [email protected]
3030
#include <goto-programs/instrument_preconditions.h>
3131
#include <goto-programs/goto_convert_functions.h>
3232
#include <goto-programs/goto_inline.h>
33-
#include <goto-programs/link_to_library.h>
3433
#include <goto-programs/loop_ids.h>
35-
#include <goto-programs/remove_function_pointers.h>
3634
#include <goto-programs/remove_virtual_functions.h>
3735
#include <goto-programs/remove_instanceof.h>
3836
#include <goto-programs/remove_returns.h>
3937
#include <goto-programs/remove_exceptions.h>
40-
#include <goto-programs/remove_vector.h>
41-
#include <goto-programs/remove_complex.h>
4238
#include <goto-programs/remove_asm.h>
4339
#include <goto-programs/remove_unused_functions.h>
4440
#include <goto-programs/remove_skip.h>
@@ -48,11 +44,8 @@ Author: Daniel Kroening, [email protected]
4844
#include <goto-programs/show_goto_functions.h>
4945
#include <goto-programs/show_symbol_table.h>
5046
#include <goto-programs/show_properties.h>
51-
#include <goto-programs/string_abstraction.h>
52-
#include <goto-programs/string_instrumentation.h>
5347
#include <goto-programs/remove_java_new.h>
5448

55-
#include <goto-symex/rewrite_union.h>
5649
#include <goto-symex/adjust_float_expressions.h>
5750

5851
#include <goto-instrument/full_slicer.h>
@@ -682,18 +675,7 @@ bool jbmc_parse_optionst::process_goto_functions(
682675
{
683676
remove_java_new(goto_model, get_message_handler());
684677

685-
// add the library
686-
link_to_library(goto_model, get_message_handler());
687-
688-
if(cmdline.isset("string-abstraction"))
689-
string_instrumentation(goto_model, get_message_handler());
690-
691-
// remove function pointers
692-
status() << "Removal of function pointers and virtual functions" << eom;
693-
remove_function_pointers(
694-
get_message_handler(),
695-
goto_model,
696-
cmdline.isset("pointer-check"));
678+
status() << "Removal of virtual functions" << eom;
697679
// Java virtual functions -> explicit dispatch tables:
698680
remove_virtual_functions(goto_model);
699681
// remove catch and throw (introduces instanceof but request it is removed)
@@ -705,9 +687,6 @@ bool jbmc_parse_optionst::process_goto_functions(
705687

706688
// remove returns, gcc vectors, complex
707689
remove_returns(goto_model);
708-
remove_vector(goto_model);
709-
remove_complex(goto_model);
710-
rewrite_union(goto_model);
711690

712691
// Similar removal of java nondet statements:
713692
// TODO Should really get this from java_bytecode_language somehow, but we
@@ -749,14 +728,6 @@ bool jbmc_parse_optionst::process_goto_functions(
749728
nondet_static(goto_model);
750729
}
751730

752-
if(cmdline.isset("string-abstraction"))
753-
{
754-
status() << "String Abstraction" << eom;
755-
string_abstraction(
756-
goto_model,
757-
get_message_handler());
758-
}
759-
760731
// add failed symbols
761732
// needs to be done before pointer analysis
762733
add_failed_symbols(goto_model.symbol_table);
@@ -887,7 +858,6 @@ void jbmc_parse_optionst::help()
887858
" --stop-on-fail stop analysis once a failed property is detected\n" // NOLINT(*)
888859
" --trace give a counterexample trace for failed properties\n" //NOLINT(*)
889860
"\n"
890-
" --no-library disable built-in abstract Java library\n"
891861
HELP_FUNCTIONS
892862
"\n"
893863
"Program representations:\n"

src/jbmc/jbmc_parse_options.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -54,13 +54,13 @@ class optionst;
5454
"(show-properties)" \
5555
"(drop-unused-functions)" \
5656
"(property):(stop-on-fail)(trace)" \
57-
"(verbosity):(no-library)" \
57+
"(verbosity):" \
5858
"(version)" \
5959
"(cover):(symex-coverage-report):" \
6060
"(i386-linux)(i386-macos)(i386-win32)(win32)(winx64)" \
6161
"(ppc-macos)" \
6262
"(arrays-uf-always)(arrays-uf-never)" \
63-
"(string-abstraction)(no-arch)(arch):" \
63+
"(no-arch)(arch):" \
6464
"(graphml-witness):" \
6565
JAVA_BYTECODE_LANGUAGE_OPTIONS \
6666
"(java-unwind-enum-static)" \

0 commit comments

Comments
 (0)