(* Lemma isLKCT_rewrite r : (forall sh sh' z P, r <> YES sh sh' (LK z) P /\ r <> YES sh sh' (CT z) P) <-> ~isLK r /\ ~isCT r. *)
(* Lemma isLK_rewrite r : (forall (sh : Share.t) Psh (z : Z) (P : preds), r <> YES sh Psh (LK z) P) <-> ~ isLK r. *)

Lemma lock_inv_at sh v R phi :
app_pred (lock_inv sh v R) phi ->
exists b ofs, v = Vptr b ofs /\ exists R, islock_pred R (phi @ (b, Ptrofs.unsigned ofs)).