[hil] always run liveness analysis before HIL lowering

Reviewed By: jeremydubreil

Differential Revision: D6216276

fbshipit-source-id: 855d6d6
master
Sam Blackshear 7 years ago committed by Facebook Github Bot
parent 183cefdad4
commit e2a75f2b46

@ -95,7 +95,8 @@ struct
module Interpreter =
AbstractInterpreter.Make (CFG) (Make (MakeTransferFunctions) (DefaultConfig))
let compute_post proc_data ~initial =
let compute_post ({ProcData.pdesc; tenv} as proc_data) ~initial =
if not (Procdesc.did_preanalysis pdesc) then Preanal.do_liveness pdesc tenv ;
let initial' = (initial, IdAccessPathMapDomain.empty) in
Option.map ~f:fst (Interpreter.compute_post ~debug:false proc_data ~initial:initial')

@ -921,7 +921,6 @@ let analyze_procedure {Callbacks.proc_desc; get_proc_desc; tenv; summary} =
in
let open RacerDDomain in
if should_analyze_proc proc_desc tenv then (
if not (Procdesc.did_preanalysis proc_desc) then Preanal.do_liveness proc_desc tenv ;
let formal_map = FormalMap.make proc_desc in
let proc_data = ProcData.make proc_desc tenv get_proc_desc in
let initial =

@ -847,9 +847,7 @@ module Make (TaintSpecification : TaintSpec.S) = struct
in
(access_tree, IdAccessPathMapDomain.empty)
in
if not (Procdesc.did_preanalysis proc_desc) then (
Preanal.do_liveness proc_desc tenv ;
Preanal.do_dynamic_dispatch proc_desc (Cg.create (SourceFile.invalid __FILE__)) tenv ) ;
Preanal.do_dynamic_dispatch proc_desc (Cg.create (SourceFile.invalid __FILE__)) tenv ;
let initial = make_initial proc_desc in
let extras =
let formal_map = FormalMap.make proc_desc in

Loading…
Cancel
Save