(*     Mem.unchanged_on (local_out_of_reach nu23 m2) m3 m3' /\*)
(*FreshSrc:*) (fun b => andb (DomSrc nu' b) (negb (DomSrc nu12 b))) (*FreshMid:*) (FreshDom (as_inj nu23) j23')) /\ nu23' = (convertR nu23 j23' (*FreshMid:*) (FreshDom (as_inj nu23) j23') (*FreshTgt:*) (fun b => andb (DomTgt nu' b) (negb (DomTgt nu23 b)))) /\ nu'=compose_sm nu12' nu23' /\ extern_incr nu12 nu12' /\ extern_incr nu23 nu23' /\ sm_inject_separated nu12 nu12' m1 m2 /\ sm_inject_separated nu23 nu23' m2 m3 /\ sm_valid nu12' m1' m2' /\ sm_valid nu23' m2' m3' /\ (SM_wd nu12' /\ SM_wd nu23' /\ locBlocksTgt nu12' = locBlocksSrc nu23' /\ extBlocksTgt nu12' = extBlocksSrc nu23' /\ (forall b, pubBlocksTgt nu12' b = true -> pubBlocksSrc nu23' b = true) /\ (forall b, frgnBlocksTgt nu12' b = true -> frgnBlocksSrc nu23' b = true)) /\ (forall b1 b2 d1, extern_of nu12' b1 = Some(b2,d1) -> exists b3 d2, extern_of nu23' b2 = Some(b3, d2)) /\ mem_forward m2 m2' /\ Mem.inject (as_inj nu12') m1' m2' /\ Mem.inject (as_inj nu23') m2' m3'.  Section MEMORY_CONSTRUCTION_EFF. Variable nu23 nu12 : SM_Injection. Variable j23 j12':meminj. Variable m1 m1' m2 : mem.  Definition AccessMap_EFF_FUN (b2:block): Z -> perm_kind -> option permission := if plt b2 (Mem.nextblock m2) then fun ofs2 k => if (locBlocksSrc nu23 b2) then if (pubBlocksSrc nu23 b2) then match source (local_of nu12) m1 b2 ofs2 with Some(b1,ofs1) => if pubBlocksSrc nu12 b1 then PMap.get b1 m1'.(Mem.mem_access) ofs1 k else PMap.get b2 m2.(Mem.mem_access) ofs2 k | None => PMap.get b2 m2.(Mem.mem_access) ofs2 k end else PMap.get b2 m2.(Mem.mem_access) ofs2 k else match source (as_inj nu12) m1 b2 ofs2 with Some(b1,ofs1) => PMap.get b1 m1'.(Mem.mem_access) ofs1 k | None => match j23 b2 with None => PMap.get b2 m2.(Mem.mem_access) ofs2 k | Some (b3,d3) => None end (*Was:                            PMap.get b2 m2.(Mem.mem_access) ofs2 k*)

(*Excactly the same proof as in mem_interpolation_II.v*)
Lemma mkAccessMap_EFF_existsT: forall N
(VB : (Mem.nextblock m2 <= N)%positive)
(VBJ12': forall b1 b2 delta, j12' b1 = Some (b2,delta) ->
(b2 < N)%positive),
{ M : PMap.t (Z -> perm_kind -> option permission) |
fst M = (fun k ofs => None) /\
forall b, PMap.get b M = AccessMap_EFF_FUN b}.