Definition pures_eq (phi phi' : rmap) :=
  pures_sub phi phi' /\
  (forall adr,
   match resource_at phi' adr with
    | PURE k pp' => exists pp, resource_at phi adr = PURE k pp
    | _ => True
  end).

(* Specifications: *)
Lemma pures_eq_refl phi : pures_eq phi phi.
Lemma pures_eq_trans phi1 phi2 phi3 : level phi3 <= level phi2 -> pures_eq phi1 phi2 -> pures_eq phi2 phi3 -> pures_eq phi1 phi3.