let compute_call_to_cil_function kf _initial_state with_formals call_kinstr =
let print_progress = Value_parameters.ValShowProgress.get() in
if print_progress then
Value_parameters.feedback
"@[computing for function %a <- %a.@\nCalled from %a.@]"
Kernel_function.pretty kf
pretty_call_stack (call_stack ())
pretty_loc_simply (CilE.current_stmt());
let result = match kf.fundec with
| Declaration (_,_,_,_) ->
compute_using_declaration kf with_formals
| Definition (def, _) ->
Kf_state.mark_as_called kf;
if Datatype.String.Set.mem
def.svar.vname (Value_parameters.UsePrototype.get ())
then
compute_using_declaration kf with_formals
else
compute_with_initial_state kf ~call_kinstr with_formals
in
if print_progress then
Value_parameters.feedback "Done for function %a"
Kernel_function.pretty kf;
result