Definition transf_function' (f: function) (approxs: PMap.t numbering) : function :=
mkfunction
f.(fn_sig)
f.(fn_params)
f.(fn_stacksize)
(transf_code approxs f.(fn_code))
f.(fn_entrypoint).
Definition regs_lessdef (rs1 rs2: regset) : Prop :=
forall r, Val.lessdef (rs1#r) (rs2#r).

(* Specifications: *)
Lemma regs_lessdef_regs:
forall rs1 rs2, regs_lessdef rs1 rs2 ->
forall rl, Val.lessdef_list rs1##rl rs2##rl.
Lemma set_reg_lessdef:
forall r v1 v2 rs1 rs2,
Val.lessdef v1 v2 -> regs_lessdef rs1 rs2 -> regs_lessdef (rs1#r <- v1) (rs2#r <- v2).
Lemma init_regs_lessdef:
forall rl vl1 vl2,
Val.lessdef_list vl1 vl2 ->
regs_lessdef (init_regs vl1 rl) (init_regs vl2 rl).
Lemma find_function_translated:
forall ros rs fd rs',
find_function ge ros rs = Some fd ->
regs_lessdef rs rs' ->
exists cu tfd, find_function tge ros rs' = Some tfd
/\ transf_fundef (romem_for cu) fd = OK tfd
/\ linkorder cu prog.