[infer][CLI] remove the Tracing analyzer option and only rely on the --tracing option for the biabduction analysis

Summary: Remove the `Tracing` analyzer option

Reviewed By: sblackshear

Differential Revision: D5108036

fbshipit-source-id: 460bc57
master
Jeremy Dubreil 8 years ago committed by Facebook Github Bot
parent d470ed6edc
commit 441bf7131a

@ -21,9 +21,7 @@ let analyze_exe_env_tasks cluster exe_env :Tasks.t => {
L.log_progress_file (); L.log_progress_file ();
Specs.clear_spec_tbl (); Specs.clear_spec_tbl ();
Random.self_init (); Random.self_init ();
let biabduction_only = let biabduction_only = Config.equal_analyzer Config.analyzer Config.BiAbduction;
Config.equal_analyzer Config.analyzer Config.BiAbduction ||
Config.equal_analyzer Config.analyzer Config.Tracing;
if biabduction_only { if biabduction_only {
/* run the biabduction analysis only */ /* run the biabduction analysis only */
Tasks.create Tasks.create

@ -263,8 +263,7 @@ let should_report (issue_kind: Exceptions.err_kind) issue_type error_desc eclass
} else { } else {
let analyzer_is_whitelisted = let analyzer_is_whitelisted =
switch Config.analyzer { switch Config.analyzer {
| Eradicate | Eradicate => true
| Tracing => true
| BiAbduction | BiAbduction
| CaptureOnly | CaptureOnly
| Checkers | Checkers

@ -375,7 +375,7 @@ let analyze driver_mode =
false, false false, false
| _, (CaptureOnly | CompileOnly) -> | _, (CaptureOnly | CompileOnly) ->
false, false false, false
| _, (BiAbduction | Checkers | Crashcontext | Eradicate | Tracing) -> | _, (BiAbduction | Checkers | Crashcontext | Eradicate) ->
true, true true, true
| _, Linters -> | _, Linters ->
false, true in false, true in

@ -18,8 +18,7 @@ module CLOpt = CommandLineOption
module F = Format module F = Format
type analyzer = type analyzer =
| BiAbduction | CaptureOnly | CompileOnly | Eradicate | Checkers | Tracing | Crashcontext | BiAbduction | CaptureOnly | CompileOnly | Eradicate | Checkers | Crashcontext | Linters
| Linters
[@@deriving compare] [@@deriving compare]
let equal_analyzer = [%compare.equal : analyzer] let equal_analyzer = [%compare.equal : analyzer]
@ -27,7 +26,6 @@ let equal_analyzer = [%compare.equal : analyzer]
let string_to_analyzer = [ let string_to_analyzer = [
"capture", CaptureOnly; "checkers", Checkers; "compile", CompileOnly; "capture", CaptureOnly; "checkers", Checkers; "compile", CompileOnly;
"crashcontext", Crashcontext; "eradicate", Eradicate; "infer", BiAbduction; "linters", Linters; "crashcontext", Crashcontext; "eradicate", Eradicate; "infer", BiAbduction; "linters", Linters;
"tracing", Tracing;
] ]
let string_of_analyzer a = let string_of_analyzer a =
@ -487,7 +485,7 @@ and analyzer =
let () = match BiAbduction with let () = match BiAbduction with
(* NOTE: if compilation fails here, it means you have added a new analyzer without updating the (* NOTE: if compilation fails here, it means you have added a new analyzer without updating the
documentation of this option *) documentation of this option *)
| BiAbduction | CaptureOnly | CompileOnly | Eradicate | Checkers | Tracing | Crashcontext | BiAbduction | CaptureOnly | CompileOnly | Eradicate | Checkers | Crashcontext
| Linters -> () in | Linters -> () in
CLOpt.mk_symbol_opt ~deprecated:["analyzer"] ~long:"analyzer" ~short:'a' CLOpt.mk_symbol_opt ~deprecated:["analyzer"] ~long:"analyzer" ~short:'a'
~in_help:CLOpt.[Analyze, manual_generic; Run, manual_generic] ~in_help:CLOpt.[Analyze, manual_generic; Run, manual_generic]
@ -1416,11 +1414,10 @@ and trace_rearrange =
CLOpt.mk_bool ~deprecated:["trace_rearrange"] ~long:"trace-rearrange" CLOpt.mk_bool ~deprecated:["trace_rearrange"] ~long:"trace-rearrange"
"Detailed tracing information during prop re-arrangement operations" "Detailed tracing information during prop re-arrangement operations"
(** Report error traces for runtime exceptions (Java only): generate preconditions for runtime
exceptions in Java and report errors for public methods which throw runtime exceptions *)
and tracing = and tracing =
CLOpt.mk_bool ~deprecated:["tracing"] ~long:"tracing" CLOpt.mk_bool ~deprecated:["tracing"] ~long:"tracing"
"" "Report error traces for runtime exceptions (Java only): generate preconditions for runtime\
exceptions in Java and report errors for public methods which throw runtime exceptions"
and type_size = and type_size =
CLOpt.mk_bool ~deprecated:["type_size"] ~long:"type-size" CLOpt.mk_bool ~deprecated:["type_size"] ~long:"type-size"
@ -1612,7 +1609,6 @@ let post_parsing_initialization command_opt =
| Some BiAbduction -> biabduction := true | Some BiAbduction -> biabduction := true
| Some Crashcontext -> crashcontext := true | Some Crashcontext -> crashcontext := true
| Some Eradicate -> eradicate := true | Some Eradicate -> eradicate := true
| Some Tracing -> biabduction := true; tracing := true
| Some (CaptureOnly | CompileOnly | Checkers | Linters) -> () | Some (CaptureOnly | CompileOnly | Checkers | Linters) -> ()
| None -> | None ->
let open CLOpt in let open CLOpt in
@ -1878,8 +1874,7 @@ let clang_frontend_action_string =
let dynamic_dispatch = let dynamic_dispatch =
let default_mode = let default_mode =
match analyzer with match analyzer with
| BiAbduction | BiAbduction -> `Lazy
| Tracing -> `Lazy
| Checkers when quandary -> `Sound | Checkers when quandary -> `Sound
| _ -> `None in | _ -> `None in
Option.value ~default:default_mode !dynamic_dispatch Option.value ~default:default_mode !dynamic_dispatch

@ -16,8 +16,7 @@ module CLOpt = CommandLineOption
time by system calls, environment variables, or command line options *) time by system calls, environment variables, or command line options *)
type analyzer = type analyzer =
| BiAbduction | CaptureOnly | CompileOnly | Eradicate | Checkers | Tracing | Crashcontext | BiAbduction | CaptureOnly | CompileOnly | Eradicate | Checkers | Crashcontext | Linters
| Linters
[@@deriving compare] [@@deriving compare]
val equal_analyzer : analyzer -> analyzer -> bool val equal_analyzer : analyzer -> analyzer -> bool

@ -53,7 +53,7 @@ let add_flavor_to_target target =
add "infer-capture-all" add "infer-capture-all"
| None, (BiAbduction | Checkers) -> | None, (BiAbduction | Checkers) ->
add "infer" add "infer"
| None, (Eradicate | Tracing | Crashcontext) -> | None, (Eradicate | Crashcontext) ->
failwithf "Analyzer %s is Java-only; not supported with Buck flavors" failwithf "Analyzer %s is Java-only; not supported with Buck flavors"
(Config.string_of_analyzer Config.analyzer) (Config.string_of_analyzer Config.analyzer)

@ -7,8 +7,8 @@
TESTS_DIR = ../../.. TESTS_DIR = ../../..
ANALYZER = tracing ANALYZER = infer
INFER_OPTIONS = --no-filtering --debug-exceptions INFER_OPTIONS = --tracing --no-filtering --debug-exceptions
INFERPRINT_OPTIONS = --issues-tests INFERPRINT_OPTIONS = --issues-tests
SOURCES = $(wildcard *.java) SOURCES = $(wildcard *.java)

Loading…
Cancel
Save