|
66 | 66 | #include <java_bytecode/java_enum_static_init_unwind_handler.h>
|
67 | 67 | #include <java_bytecode/java_multi_path_symex_checker.h>
|
68 | 68 | #include <java_bytecode/java_multi_path_symex_only_checker.h>
|
| 69 | +#include <java_bytecode/java_single_path_symex_checker.h> |
| 70 | +#include <java_bytecode/java_single_path_symex_only_checker.h> |
69 | 71 | #include <java_bytecode/remove_exceptions.h>
|
70 | 72 | #include <java_bytecode/remove_instanceof.h>
|
71 | 73 | #include <java_bytecode/remove_java_new.h>
|
@@ -559,46 +561,83 @@ int jbmc_parse_optionst::doit()
|
559 | 561 | options.get_bool_option("program-only") ||
|
560 | 562 | options.get_bool_option("show-vcc"))
|
561 | 563 | {
|
562 |
| - if(!options.get_bool_option("paths")) |
| 564 | + std::unique_ptr<goto_verifiert> verifier; |
| 565 | + if(options.get_bool_option("paths")) |
563 | 566 | {
|
564 |
| - all_properties_verifiert<java_multi_path_symex_only_checkert> verifier( |
| 567 | + verifier = util_make_unique< |
| 568 | + all_properties_verifiert<java_single_path_symex_only_checkert>>( |
| 569 | + options, ui_message_handler, goto_model); |
| 570 | + } |
| 571 | + else |
| 572 | + { |
| 573 | + verifier = util_make_unique< |
| 574 | + all_properties_verifiert<java_multi_path_symex_only_checkert>>( |
565 | 575 | options, ui_message_handler, goto_model);
|
566 |
| - (void)verifier(); |
567 |
| - return CPROVER_EXIT_SUCCESS; |
568 | 576 | }
|
| 577 | + |
| 578 | + (void)(*verifier)(); |
| 579 | + return CPROVER_EXIT_SUCCESS; |
569 | 580 | }
|
570 | 581 |
|
571 | 582 | if(
|
572 | 583 | options.get_bool_option("dimacs") ||
|
573 | 584 | !options.get_option("outfile").empty())
|
574 | 585 | {
|
575 |
| - if(!options.get_bool_option("paths")) |
| 586 | + std::unique_ptr<goto_verifiert> verifier; |
| 587 | + if(options.get_bool_option("paths")) |
576 | 588 | {
|
577 |
| - stop_on_fail_verifiert<multi_path_symex_checkert> verifier( |
| 589 | + verifier = util_make_unique< |
| 590 | + stop_on_fail_verifiert<java_single_path_symex_checkert>>( |
578 | 591 | options, ui_message_handler, goto_model);
|
579 |
| - (void)verifier(); |
580 |
| - return CPROVER_EXIT_SUCCESS; |
581 | 592 | }
|
| 593 | + else |
| 594 | + { |
| 595 | + verifier = util_make_unique< |
| 596 | + stop_on_fail_verifiert<java_multi_path_symex_checkert>>( |
| 597 | + options, ui_message_handler, goto_model); |
| 598 | + } |
| 599 | + |
| 600 | + (void)(*verifier)(); |
| 601 | + return CPROVER_EXIT_SUCCESS; |
582 | 602 | }
|
583 | 603 |
|
584 | 604 | std::unique_ptr<goto_verifiert> verifier = nullptr;
|
585 | 605 |
|
586 | 606 | if(
|
587 |
| - !options.get_bool_option("paths") && !options.is_set("cover") && |
588 |
| - !options.get_bool_option("dimacs") && |
| 607 | + !options.is_set("cover") && !options.get_bool_option("dimacs") && |
589 | 608 | options.get_option("outfile").empty())
|
590 | 609 | {
|
591 | 610 | if(options.get_bool_option("stop-on-fail"))
|
592 | 611 | {
|
593 |
| - verifier = util_make_unique< |
594 |
| - stop_on_fail_verifiert<java_multi_path_symex_checkert>>( |
595 |
| - options, ui_message_handler, goto_model); |
| 612 | + if(options.get_bool_option("paths")) |
| 613 | + { |
| 614 | + verifier = util_make_unique< |
| 615 | + stop_on_fail_verifiert<java_single_path_symex_checkert>>( |
| 616 | + options, ui_message_handler, goto_model); |
| 617 | + } |
| 618 | + else |
| 619 | + { |
| 620 | + verifier = util_make_unique< |
| 621 | + stop_on_fail_verifiert<java_multi_path_symex_checkert>>( |
| 622 | + options, ui_message_handler, goto_model); |
| 623 | + } |
596 | 624 | }
|
597 | 625 | else
|
598 | 626 | {
|
599 |
| - verifier = util_make_unique<all_properties_verifier_with_trace_storaget< |
600 |
| - java_multi_path_symex_checkert>>( |
601 |
| - options, ui_message_handler, goto_model); |
| 627 | + if(options.get_bool_option("paths")) |
| 628 | + { |
| 629 | + verifier = |
| 630 | + util_make_unique<all_properties_verifier_with_trace_storaget< |
| 631 | + java_single_path_symex_checkert>>( |
| 632 | + options, ui_message_handler, goto_model); |
| 633 | + } |
| 634 | + else |
| 635 | + { |
| 636 | + verifier = |
| 637 | + util_make_unique<all_properties_verifier_with_trace_storaget< |
| 638 | + java_multi_path_symex_checkert>>( |
| 639 | + options, ui_message_handler, goto_model); |
| 640 | + } |
602 | 641 | }
|
603 | 642 | }
|
604 | 643 |
|
|
0 commit comments