Local Open Scope pred.

(* Specifications: *)
Lemma andp_TT {A}`{ageable A}: forall (P: pred A), P && TT = P.
Lemma sepcon_andp_prop' {A}  {JA: Join A}{PA: Perm_alg A}{SA: Sep_alg A}{agA: ageable A}{AgeA: Age_alg A}: forall P Q R, (!!Q && P)*R = !!Q&&(P*R).
Hint Rewrite @sepcon_emp @emp_sepcon @TT_and @andp_TT
@exp_sepcon1 @exp_sepcon2
@exp_andp1 @exp_andp2
@sepcon_andp_prop @sepcon_andp_prop'
: normalize.
Lemma unfash_derives {A} `{agA : ageable A}:
forall {P Q}, (P |-- Q) -> @derives A _ (! P) (! Q).
Lemma subp_sepcon {A} {JA: Join A}{PA: Perm_alg A}{SA: Sep_alg A}{AG: ageable A}{XA: Age_alg A} : forall G P P' Q Q',
G |-- P >=> P' ->
G |-- Q >=> Q' ->
G |-- P * Q >=> P' * Q'.
Lemma sub_wand {A} {JA: Join A}{PA: Perm_alg A}{SA: Sep_alg A}{AG: ageable A}{XA: Age_alg A} : forall G P P' Q Q',
G |-- P' >=> P ->
G |-- Q >=> Q' ->
G |-- (P -* Q) >=> (P' -* Q').
Lemma find_superprecise {A} {JA: Join A}{PA: Perm_alg A}{SA: Sep_alg A}{AG: ageable A}{XA: Age_alg A}:
forall Q, Q |-- EX P:_, P && !(P >=> Q) && !!superprecise (P).
Lemma sepcon_subp' {A} {JA: Join A}{PA: Perm_alg A}{SA: Sep_alg A}{AG: ageable A}{XA: Age_alg A}:
forall (P P' Q Q' : pred A) (st: nat),
(P >=> P') st ->
(Q >=> Q') st ->
(P * Q >=> P' * Q') st.
Lemma subp_refl'  {A} `{agA : ageable A} :  forall (Q: pred A) (st: nat), (Q >=> Q) st.
Lemma subp_trans' {A} `{agA : ageable A}:
forall (B C D: pred A) (w: nat), (B >=> C)%pred w -> (C >=> D)% pred w -> (B >=> D)%pred w.
Lemma andp_subp'  {A} `{agA : ageable A} :
forall (P P' Q Q': pred A) (w: nat), (P >=> P') w -> (Q >=> Q') w -> (P && Q >=> P' && Q') w.
Lemma allp_subp' {A} `{agA : ageable A}: forall T (F G: T -> pred A) (w: nat),
(forall x,  (F x >=> G x) w) -> (allp (fun x:T => (F x >=> G x)) w).
Lemma pred_eq_e1 {A} `{agA : ageable A}: forall (P Q: pred A) w,
((P <=> Q) w -> (P >=> Q) w).
Lemma pred_eq_e2 {A} `{agA : ageable A}: forall (P Q: pred A)  w,
((P <=> Q) w -> (Q >=> P) w).
Lemma mapsto_uniq: forall (x y: adr) w w', core w = core w' -> mapsto x y w -> mapsto x y w' -> w=w'.
Lemma mapsto_e1: forall v1 v2 w,
app_pred (mapsto v1 v2 * TT) w ->
w @ v1 = YES pfullshare (VAL v2) NoneP.