let add_missing_inputs_actions ff calls to_prop actions =
let fi = M.ff_fi ff in
let check_call actions call_id =
let (ff_call, call) = call_id in
let call_info = CallInfo.get_info_call (ff_call, call) in
let ff_called = CallInfo.get_f_called call_info in
let _ = match ff_called with
| Some (T.CallSlice ff_called) -> assert (M.equal_ff ff_called ff)
| _ -> assert false
in
let pdg_caller = M.get_ff_pdg ff_call in
assert (not (PdgTypes.Pdg.is_top pdg_caller));
let old_marks = FctMarks.get_ff_marks ff_call in
let missing_inputs =
FctMarks.marks_for_caller_inputs pdg_caller old_marks call to_prop fi
in
match missing_inputs with
| ([], false) -> actions
| _ -> let new_action =
Act.mk_crit_missing_inputs ff_call call missing_inputs in
new_action :: actions
in let actions = List.fold_left check_call actions calls in
SlicingParameters.debug ~level:2 "[Fct_Slice.add_missing_inputs_actions] %s"
(match actions with
| [] -> " -> no missing input"
| _ -> " -> add missing inputs actions");
actions