From fba8c256d045a5f4333916c68f3373e5085c5e36 Mon Sep 17 00:00:00 2001 From: Jeremy Dubreil Date: Wed, 8 Mar 2017 20:28:21 -0800 Subject: [PATCH] [infer][java] When calling InferPrint, only consider the specs file in the local results directory Summary: On Java Buck projects, InferPrint was loading all the specs files from all the jars in the classpath. This was affecting the performance a lot when the analysis was reporting a lot of issues. Reviewed By: cristianoc Differential Revision: D4673226 fbshipit-source-id: 6927836 --- infer/src/backend/InferPrint.re | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/infer/src/backend/InferPrint.re b/infer/src/backend/InferPrint.re index c801f0a16..5374a312e 100644 --- a/infer/src/backend/InferPrint.re +++ b/infer/src/backend/InferPrint.re @@ -35,11 +35,8 @@ let load_specfiles () => { let all_filepaths = List.map f::(fun fname => Filename.concat dir fname) all_filenames; List.filter f::is_specs_file all_filepaths }; - let specs_dirs = { - let result_specs_dir = DB.filename_to_string DB.Results_dir.specs_dir; - [result_specs_dir, ...Config.specs_library] - }; - List.concat_map f::specs_files_in_dir specs_dirs + let result_specs_dir = DB.filename_to_string DB.Results_dir.specs_dir; + specs_files_in_dir result_specs_dir };