[opam] upgrade atdgen to version 2

Summary:
To keep up with the times. Changes consist of new features and moving modules
around so shouldn't change anything on our side.

Depends on D9239803

The controller you requested could not be found.: facebook-clang-plugins

Reviewed By: da319

Differential Revision: D9239817

fbshipit-source-id: d02a2076a
master
Jules Villard 6 years ago committed by Facebook Github Bot
parent 832e0130cd
commit 59f09ef697

@ -1 +1 @@
Subproject commit 4c1ba505123398d1bfb81fca198cafabffa84da9
Subproject commit 2348f2ae27ea36322b3f5efacb83a11b318be844

@ -47,7 +47,9 @@ let stracktree_of_frame frame =
(** k = 1 implementation, where k is the number of levels of calls inlined *)
let stitch_summaries stacktrace_file summary_files out_file =
let stacktrace = Stacktrace.of_json_file stacktrace_file in
let summaries = List.map ~f:(Ag_util.Json.from_file Stacktree_j.read_stacktree) summary_files in
let summaries =
List.map ~f:(Atdgen_runtime.Util.Json.from_file Stacktree_j.read_stacktree) summary_files
in
let summary_map =
List.fold
~f:(fun acc stacktree ->
@ -63,7 +65,7 @@ let stitch_summaries stacktrace_file summary_files out_file =
in
let expanded_frames = List.map ~f:expand_stack_frame stacktrace.frames in
let crashcontext = {Stacktree_j.stack= expanded_frames} in
Ag_util.Json.to_file Stacktree_j.write_crashcontext_t out_file crashcontext
Atdgen_runtime.Util.Json.to_file Stacktree_j.write_crashcontext_t out_file crashcontext
let collect_all_summaries root_summaries_dir stacktrace_file stacktraces_dir =

@ -53,7 +53,7 @@ let load_and_validate () =
if Sys.file_exists state_file_path <> `Yes then
error "save state not found: '%s' does not exist" state_file_path
else
match Ag_util.Json.from_file Runstate_j.read_t state_file_path with
match Atdgen_runtime.Util.Json.from_file Runstate_j.read_t state_file_path with
| {Runstate_t.results_dir_format} as loaded_state
when String.equal !state.Runstate_t.results_dir_format results_dir_format ->
state := loaded_state ;

@ -91,7 +91,7 @@ module TransferFunctions (CFG : ProcCfg.S) = struct
let fname = F.sprintf "%s.%s.json" (Typ.Procname.to_filename caller) suffix in
let fpath = Filename.concat dir fname in
Utils.create_dir dir ;
Ag_util.Json.to_file Stacktree_j.write_stacktree fpath stacktree
Atdgen_runtime.Util.Json.to_file Stacktree_j.write_stacktree fpath stacktree
let exec_instr astate proc_data _ = function

@ -13,11 +13,13 @@ let debug_mode = Config.debug_mode || Config.frontend_stats
(** This function reads the json file in fname, validates it, and encodes in the AST data structure
defined in Clang_ast_t. *)
let validate_decl_from_file fname =
Ag_util.Biniou.from_file ~len:CFrontend_config.biniou_buffer_size Clang_ast_b.read_decl fname
Atdgen_runtime.Util.Biniou.from_file ~len:CFrontend_config.biniou_buffer_size
Clang_ast_b.read_decl fname
let validate_decl_from_channel chan =
Ag_util.Biniou.from_channel ~len:CFrontend_config.biniou_buffer_size Clang_ast_b.read_decl chan
Atdgen_runtime.Util.Biniou.from_channel ~len:CFrontend_config.biniou_buffer_size
Clang_ast_b.read_decl chan
let register_perf_stats_report source_file =

@ -32,7 +32,7 @@ let visit_ast ?(visit_decl= empty_v) ?(visit_stmt= empty_v) ?(visit_type= empty_
| Some error ->
L.(die InternalError)
"visiting the clang AST failed with error %s"
(Ag_util.Validation.string_of_error error)
(Atdgen_runtime.Util.Validation.string_of_error error)
let get_ptr_from_node node =

@ -306,5 +306,5 @@ let from_json_string str ~use_signature =
let from_json_file file ~use_signature =
from_java_profiler_samples
(Ag_util.Json.from_file Java_profiler_samples_j.read_java_profiler_samples file)
(Atdgen_runtime.Util.Json.from_file Java_profiler_samples_j.read_java_profiler_samples file)
~use_signature

@ -28,7 +28,7 @@ ocaml-version: [ >= "4.04.2" ]
depends: [
"ANSITerminal" {>="0.7"}
"apron"
"atdgen" {>="1.6.0" & <"1.13.0"}
"atdgen" {>="2.0.0"}
"base64"
"cmdliner" {>="1.0.0"}
"core"

@ -1,7 +1,8 @@
ANSITerminal = 0.8
apron = 20160125
atd = 1.12.0
atdgen = 1.12.0
atd = 2.0.0
atdgen = 2.0.0
atdgen-runtime = 2.0.0
base = v0.11.0
base64 = 2.2.0
bin_prot = v0.11.0

Loading…
Cancel
Save