(* This file was originally generated by why.
   It can be modified; only the generated parts will be overwritten. *)

Require Export caduceus_spec_why.
Require Import BinTree.


(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_1 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  (well_founded order_mark_m_and_c_and_stack).
Proof.
intros; apply order_mark_m_and_c_and_stack_wf.
Qed.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_2 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z47: ((memory) Z Z47)),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
  (((* I1 *)
    (forall (x:((pointer) Z47)),
     ((reachable l_Z47 r_Z47 alloc root x) ->
      (reachable l_Z47 r_Z47 alloc root x) \/
      (reachable l_Z47 r_Z47 alloc null x))) /\
  (* I2 *)
  (forall (x:((pointer) Z47)),
   (~(x = null) ->
    ((reachable l_Z47 r_Z47 alloc root x) \/
     (reachable l_Z47 r_Z47 alloc null x) ->
     (reachable l_Z47 r_Z47 alloc root x))))) /\
  (* I0 *)
  (exists stack:plist,
   (((((* I3 *) (clr_list c_Z47 l_Z47 r_Z47 alloc null stack) /\
   (* I4 *)
   (forall (p_0:((pointer) Z53)),
    ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
   (* I5 *)
   (forall (x:((pointer) Z47)),
    (((valid alloc x) /\ (reachable l_Z47 r_Z47 alloc root x)) /\
     (acc m_Z47 x) = 0 ->
     (unmarked_reachable m_Z47 l_Z47 r_Z47 alloc root x) \/
     (exists y:((pointer) Z53), (in_list y stack) /\
      (unmarked_reachable m_Z47 l_Z47 r_Z47 alloc (acc r_Z53 y) x))))) /\
   (* I6 *)
   (forall (x:((pointer) Z53)),
    (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
     (acc l_Z53 x) = (acc l_Z53 x)))) /\
   (* I7 *)
   (forall (p1:((pointer) Z47)),
    (forall (p2:((pointer) Z51)),
     ((pair_in_list p1 p2 (cons root stack)) ->
      (((acc c_Z51 p2) <> 0 -> (acc l_Z51 p2) = (acc l_Z51 p2) /\
        (acc r_Z51 p2) = p1)) /\
      (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
        (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
   (* I8 *)
   (forall (x:((pointer) Z47)),
    (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47 x) = (acc m_Z47 x))))).
Proof.
(* validity of access t->m in the condition of while *)
intros root alloc l m r (A,_) t _ p _
 Variant1 c0 l0 m0 p1 r0 t1 _
 ((_,I2),(stack,(_,_))).
generalize (A t1);intros.
elim H.
intros;auto.
split;auto.
apply I2.
assumption.
left; exists (@nil pointer); constructor.
Qed.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_3 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_4: t = null),
  forall (result: Z),
  forall (HW_5: result = (acc c_Z47_0 p)),
  forall (HW_6: result <> 0),
  forall (t0: ((pointer) Z47)),
  forall (HW_7: t0 = p),
  forall (result0: ((pointer) Z47)),
  forall (HW_8: result0 = (acc r_Z47_0 p)),
  forall (p0: ((pointer) Z47)),
  forall (HW_9: p0 = result0),
  forall (r_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_10: r_Z47_1 = (upd r_Z47_0 t0 t)),
  (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
  (((* I1 *)
    (forall (x:((pointer) Z47)),
     ((reachable l_Z47 r_Z47 alloc root x) ->
      (reachable l_Z47_0 r_Z47_1 alloc t0 x) \/
      (reachable l_Z47_0 r_Z47_1 alloc p0 x))) /\
  (* I2 *)
  (forall (x:((pointer) Z47)),
   (~(x = null) ->
    ((reachable l_Z47_0 r_Z47_1 alloc t0 x) \/
     (reachable l_Z47_0 r_Z47_1 alloc p0 x) ->
     (reachable l_Z47 r_Z47 alloc root x))))) /\
  (* I0 *)
  (exists stack:plist,
   (((((* I3 *) (clr_list c_Z47_0 l_Z47_0 r_Z47_1 alloc p0 stack) /\
   (* I4 *)
   (forall (p_0:((pointer) Z53)),
    ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
   (* I5 *)
   (forall (x:((pointer) Z47)),
    (((valid alloc x) /\ (reachable l_Z47 r_Z47 alloc root x)) /\
     (acc m_Z47_0 x) = 0 ->
     (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_1 alloc t0 x) \/
     (exists y:((pointer) Z53), (in_list y stack) /\
      (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_1 alloc (acc r_Z53 y) x))))) /\
   (* I6 *)
   (forall (x:((pointer) Z53)),
    (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
     (acc l_Z53 x) = (acc l_Z53 x)))) /\
   (* I7 *)
   (forall (p1:((pointer) Z47)),
    (forall (p2:((pointer) Z51)),
     ((pair_in_list p1 p2 (cons t0 stack)) ->
      (((acc c_Z51 p2) <> 0 -> (acc l_Z51 p2) = (acc l_Z51 p2) /\
        (acc r_Z51 p2) = p1)) /\
      (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
        (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
   (* I8 *)
   (forall (x:((pointer) Z47)),
    (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) = (acc m_Z47 x))))) /\
  (order_mark_m_and_c_and_stack (weight c_Z47_0 m_Z47_0 l_Z47_0 r_Z47_1 alloc
                                 p0 t0)
   (weight c_Z47_0 m_Z47_0 l_Z47_0 r_Z47_0 alloc p t)).
Proof.
(* validity of access to t->m in the condition of the first if *)
intros root alloc l m r (A,_) t _ p _
 Variant1 c0 l0 m0 p1 r0 t1 _
 ((_,I2),(stack,(_,_))).
generalize (A t1);intros.
elim H.
intros;auto.
split;auto.
apply I2.
assumption.
left; exists (@nil pointer); constructor.
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_4 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_4: t = null),
  forall (result: Z),
  forall (HW_5: result = (acc c_Z47_0 p)),
  forall (HW_6: result <> 0),
  forall (t0: ((pointer) Z47)),
  forall (HW_7: t0 = p),
  forall (result0: ((pointer) Z47)),
  forall (HW_8: result0 = (acc r_Z47_0 p)),
  forall (p0: ((pointer) Z47)),
  forall (HW_9: p0 = result0),
  (valid alloc t0).
Proof.
(* validity of access to p->c in the condition 
   of the second if *)
intros root alloc l m r (A,_) t _ p _
 Variant1 c0 l0 m0 p1 r0 t1 _
 ((_,I2),(stack,(_,_))) _ Test6 _ Test5.
elim Test6.
clear Test5; intuition.
generalize (A p1);intros.
elim H1.
intros;auto.
split;auto.
apply I2.
assumption.
right; exists (@nil pointer); constructor.
clear Test6; intuition.
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_5 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_4: t = null),
  forall (result: Z),
  forall (HW_5: result = (acc c_Z47_0 p)),
  forall (HW_6: result <> 0),
  forall (t0: ((pointer) Z47)),
  forall (HW_7: t0 = p),
  (valid alloc p).
Proof.
(* validity of t in 't->r = q' 
   in the first branch of if *)
intros; subst;auto.
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_6 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_4: t = null),
  forall (result: Z),
  forall (HW_5: result = (acc c_Z47_0 p)),
  forall (HW_11: result = 0),
  forall (result0: ((pointer) Z47)),
  forall (HW_12: result0 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_13: t0 = result0),
  forall (result1: ((pointer) Z47)),
  forall (HW_14: result1 = (acc l_Z47_0 p)),
  forall (r_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_15: r_Z47_1 = (upd r_Z47_0 p result1)),
  forall (l_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_16: l_Z47_1 = (upd l_Z47_0 p t)),
  forall (c_Z47_1: ((memory) Z Z47)),
  forall (HW_17: c_Z47_1 = (upd c_Z47_0 p 1)),
  (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
  (((* I1 *)
    (forall (x:((pointer) Z47)),
     ((reachable l_Z47 r_Z47 alloc root x) ->
      (reachable l_Z47_1 r_Z47_1 alloc t0 x) \/
      (reachable l_Z47_1 r_Z47_1 alloc p x))) /\
  (* I2 *)
  (forall (x:((pointer) Z47)),
   (~(x = null) ->
    ((reachable l_Z47_1 r_Z47_1 alloc t0 x) \/
     (reachable l_Z47_1 r_Z47_1 alloc p x) ->
     (reachable l_Z47 r_Z47 alloc root x))))) /\
  (* I0 *)
  (exists stack:plist,
   (((((* I3 *) (clr_list c_Z47_1 l_Z47_1 r_Z47_1 alloc p stack) /\
   (* I4 *)
   (forall (p_0:((pointer) Z53)),
    ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
   (* I5 *)
   (forall (x:((pointer) Z47)),
    (((valid alloc x) /\ (reachable l_Z47 r_Z47 alloc root x)) /\
     (acc m_Z47_0 x) = 0 ->
     (unmarked_reachable m_Z47_0 l_Z47_1 r_Z47_1 alloc t0 x) \/
     (exists y:((pointer) Z53), (in_list y stack) /\
      (unmarked_reachable m_Z47_0 l_Z47_1 r_Z47_1 alloc (acc r_Z53 y) x))))) /\
   (* I6 *)
   (forall (x:((pointer) Z53)),
    (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
     (acc l_Z53 x) = (acc l_Z53 x)))) /\
   (* I7 *)
   (forall (p1:((pointer) Z47)),
    (forall (p2:((pointer) Z51)),
     ((pair_in_list p1 p2 (cons t0 stack)) ->
      (((acc c_Z51 p2) <> 0 -> (acc l_Z51 p2) = (acc l_Z51 p2) /\
        (acc r_Z51 p2) = p1)) /\
      (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
        (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
   (* I8 *)
   (forall (x:((pointer) Z47)),
    (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) = (acc m_Z47 x))))) /\
  (order_mark_m_and_c_and_stack (weight c_Z47_1 m_Z47_0 l_Z47_1 r_Z47_1 alloc
                                 p t0)
   (weight c_Z47_0 m_Z47_0 l_Z47_0 r_Z47_0 alloc p t)).
Proof.
(* preservation of loop invariant for the first branch of if "pop" *)
intros.
split;subst.
inversion_clear Pre35.
inversion_clear H.
split;subst.
split;subst.
intros.
(*i1*)
generalize (H1 x H);clear H1.
intro.
inversion_clear H1.
unfold reachable in *|- *.
inversion_clear H3.
generalize (path_no_cycle alloc t1 x l0 r0 x0 H1).
intros.
inversion_clear H3.
inversion_clear H4.
inversion_clear H5.
inversion H6;subst.
left.
exists (p1::nil).
constructor 3;auto.
caduceus.
constructor.
case (In_dec eq_pointer_dec p1 lp).
intro.
generalize (split_list p1 lp i).
intros (path,(path',pathpre)).
subst.
generalize 
 (split_path alloc (t1 # l0) x l0 
  r0  (p1 :: path') path H7).
intros (p3,(reach,reach')).
inversion reach';subst.
left.
exists (p1::path').
constructor 2;auto.
apply path_upd_right ;auto.
assert (t1 :: path ++ p1 :: path' = t1 :: path ++ p1 :: path').
auto.
generalize (no_rep_sublist (t1 :: path ++ p1 :: path') (t1::path) (p1::path') H4 H8).
intro.
apply (no_rep_p p1 path' H9).
right.
exists path'.
apply path_upd_right ;auto.
assert (t1 :: path ++ p1 :: path' = t1 :: path ++ p1 :: path').
auto.
generalize (no_rep_sublist (t1 :: path ++ p1 :: path') (t1::path) (p1::path') H4 H8).
intro.
apply (no_rep_p p1 path' H9).
intro.
left;exists (p1::t1::lp).
constructor 3;auto.
caduceus.
constructor 2;auto.
apply path_upd_right ;auto.
case (In_dec eq_pointer_dec p1 lp).
intro.
generalize (split_list p1 lp i).
intros (path,(path',pathpre)).
subst.
generalize 
 (split_path alloc (t1 # r0) x l0 
  r0  (p1 :: path') path H7).
intros (p3,(reach,reach')).
inversion reach';subst.
left.
exists (p1::path').
constructor 2;auto.
apply path_upd_right ;auto.
assert (t1 :: path ++ p1 :: path' = t1 :: path ++ p1 :: path').
auto.
generalize (no_rep_sublist (t1 :: path ++ p1 :: path') (t1::path) (p1::path') H4 H8).
intro.
apply (no_rep_p p1 path' H9).
right.
exists path'.
apply path_upd_right ;auto.
assert (t1 :: path ++ p1 :: path' = t1 :: path ++ p1 :: path').
auto.
generalize (no_rep_sublist (t1 :: path ++ p1 :: path') (t1::path) (p1::path') H4 H8).
intro.
apply (no_rep_p p1 path' H9).
intro.
generalize (eq_pointer_dec p1 t1).
intros [h|h].
subst.
caduceus.
right.
exists lp.
apply path_upd_right ;auto.
left.
exists (p1::t1::lp).
constructor 3;auto.
caduceus.
constructor 3;auto.
rewrite acc_upd_neq;auto.
apply path_upd_right ;auto.
(*i1b*)
unfold reachable in *|-*.
inversion_clear H3.
generalize 
  (path_no_cycle alloc p1 x l0 r0 x0 H1).
intros (path,(_,(no_rep,reach))).
inversion reach;subst.
left;exists (@nil pointer);constructor.
left;exists (p1::lp);constructor 2;auto.
apply path_upd_right ;auto.
apply no_rep_p;auto.
right;exists  lp;apply path_upd_right ;auto.
apply no_rep_p;auto.
(*i1bis*)
intros.
generalize (H2 x H);clear H2;intros.
apply H2.
unfold reachable.
inversion_clear H3.
inversion_clear H4.
generalize 
  (path_no_cycle alloc p1 x l0 (upd r0 p1 t1) x0 H3).
intros (path,(_,(no_rep,reach))).
inversion reach;subst.
right;exists (@nil pointer);constructor.
right;exists (p1::lp);constructor 2;auto.
apply path_inv_upd_right with p1 t1; auto.
apply no_rep_p;auto.
left;exists lp.
rewrite acc_upd_eq in H5;auto.
apply path_inv_upd_right with p1 t1; auto.
apply no_rep_p;auto.
inversion_clear H4.
generalize 
  (path_no_cycle alloc (p1#r0) x l0 (upd r0 p1 t1) x0 H3).
intros (path,(_,(no_rep,reach))).
generalize (In_dec eq_pointer_dec p1 path).
intros [h|h].
generalize (split_list p1 path h).
intros (path',(path'',pathpre)).
subst.
generalize 
 (split_path alloc (p1 # r0) x l0 
    (upd r0 p1 t1) (p1 :: path'') path' reach).
intros (p3,(reach',reach'')).
inversion reach'';subst.
right;exists (p1::path'');constructor 2;auto.
apply path_inv_upd_right with p1 t1; auto.
assert (path' ++ p1 :: path'' = path' ++ p1 :: path'').
auto.
generalize (no_rep_sublist ( path' ++ p1 :: path'') path' (p1::path'') no_rep H4).
intro.
apply (no_rep_p p1 path'' H5).
rewrite acc_upd_eq in H9;auto.
left;exists path'';apply path_inv_upd_right with p1 t1; auto.
assert (path' ++ p1 :: path'' = path' ++ p1 :: path'').
auto.
generalize (no_rep_sublist ( path' ++ p1 :: path'') path' (p1::path'') no_rep H4).
intro.
apply (no_rep_p p1 path'' H5).
right;exists (p1::path);constructor 3;auto.
apply path_inv_upd_right with p1 t1; auto.
(* recuperation de la liste*)
inversion_clear H0.
inversion_clear H.
inversion_clear H0.
inversion_clear H.
inversion_clear H0.
inversion_clear H.
exists (tail x).
split.
split.
split.
split.
split.
(*i2*)
inversion H0;subst.
elimtype False.
elim Pre31;auto.
simpl.
destruct (Z_eq_dec (p1 # c0) 0).
elim (Test4 e).
unfold clr_list.
unfold llist.
apply clr_list_upd_right;auto.
unfold clr_list in H0.
generalize (llist_no_rep alloc 
  (fun t : pointer => 
     if Z_eq_dec (t # c0) 0 then t # l0 else t # r0) 
  p1 p1 l1 H0).
intuition.
(*i3*)
intros.
apply H7 .
unfold in_list.
unfold GenericLists.in_list.
destruct x.
inversion H;subst.
right;auto.
(*i4*)
intros.
generalize (H6 x0 H).
intros.
inversion_clear H8.
elim Test5.
intro;subst.
inversion_clear H9.
inversion_clear H8.
inversion_clear H.
inversion_clear H8.
inversion H10;subst.
elimtype False;elim H;auto.
elimtype False;elim H8;auto.
elimtype False;elim H8;auto.
intros (h1,h2).
inversion_clear H9.
inversion_clear H8.
inversion H10;subst.
inversion_clear H.
elim (h2 H11).
assert (In t1 (t1::lp)).
left;auto.
generalize (H9 t1 H12);intro.
elim (h2 H13).
assert (In t1 (t1::lp)).
left;auto.
generalize (H9 t1 H12);intro.
elim (h2 H13).
unfold clr_list in H0.
inversion_clear H9.
inversion_clear H8.
inversion H0;subst.
elimtype False;elim Pre32;auto.
generalize (llist_no_rep alloc 
(fun t : pointer => 
  if Z_eq_dec (t # c0) 0 then t # l0 else t # r0)
   p1 p1 l1 H0).
intros (_,no).
inversion H9;subst.
destruct (Z_eq_dec (x1 # c0) 0).
elim (Test4 e).
inversion H11;subst.
replace (x1#r0) with null in H10.
inversion H10;subst.
inversion_clear H12.
inversion H14;subst.
inversion_clear  H.
inversion_clear  H12.
elimtype False;elim H;auto.
elimtype False;elim H12;auto.
elimtype False;elim H12;auto.
assert (In (x1#r0) (x1 :: x1 # r0 :: l2)).
right;left;auto.
generalize (H7 (x1 # r0) H14).
intro.
inversion_clear H10.
inversion_clear H16.
inversion H17;subst.
inversion_clear H.
elim (H15 H18).
assert (In (x1#r0) (x1 # r0 :: lp)).
left;auto.
generalize (H10 (x1#r0) H19).
intro.
elim (H15 H20).
assert (In (x1#r0) (x1 # r0 :: lp)).
left;auto.
generalize (H10 (x1#r0) H19).
intro.
elim (H15 H20).
right.
exists x1.
split.
simpl;auto.
rewrite acc_upd_neq.
red.
inversion_clear H10.
inversion_clear H13.
exists x.
split;auto.
apply path_upd_right ;auto.
assert (In p1 (p1::l1)).
left;auto.
generalize (H7 p1 H13).
intro.
intro.
generalize (H10 p1 H16).
auto.
intro;subst.
apply no;auto.
(*i5*)
intros.
inversion H0;subst.
elimtype False;elim Pre31;auto.
simpl in H.
generalize (eq_pointer_dec x0 p1).
intros [h|h].
subst.
caduceus.
assert (pair_in_list t1 p1 (cons t1 (p1 :: l1))). 
unfold pair_in_list.
unfold GenericLists.pair_in_list.
left.
auto.
generalize (H4 t1 p1 H10).
intros (h1,h2).
generalize (h1 Test4).
clear Test6; intuition.
caduceus.
apply H5.
intro;apply H.
inversion H10;auto.
elim h;auto .
(*i6*)
intros.
inversion H0;subst.
elimtype False;elim Pre31;auto.
generalize (llist_no_rep alloc 
(fun t : pointer => 
  if Z_eq_dec (t # c0) 0 then t # l0 else t # r0)
   p1 p1 l1 H0).
intros (_,no).
rewrite acc_upd_neq.
apply H4.
right.
simpl in H;auto.
simpl in H.
intro;subst.
apply no.
apply pair_in_list_in with p0 p2;auto.
(*i7*)
intros.
apply H3;auto.
(*terminaison*)
red.
red.
subst.
inversion_clear Pre37.
inversion_clear H0.
inversion_clear Pre35.
inversion_clear H2.
inversion_clear H3.
inversion_clear H2.
inversion_clear H3.
inversion_clear H2.
inversion_clear H3.
exists (existS (fun _ => natnat) (mesure_mark m0 x)
   (existS (fun _ => nat) (mesure_mark c0 x) (List.length (tail x0)))).
red.
split.
red; simpl.
exists x.
split.
red.
inversion_clear H1.
split;auto.
intros.
red.
split;intro.
red in H9.
generalize (H9 p2);intro;clear H9.
inversion_clear H10.
apply H9.
intros Q.
inversion_clear H0.
right;apply H12;auto.
generalize (H1 Q);clear H1;intro.
inversion_clear H0.
inversion_clear H1.
generalize (path_no_cycle alloc (p1 # r0) p2 l0 (upd r0 p1 t1) x1 H0).
intros (path',(_,(no_rep,reach))).
generalize (In_dec eq_pointer_dec p1 path').
intros [O|O].
generalize (split_list p1 path' O);intros (lp1,(lp2,S)).
subst.
generalize (split_path alloc (p1 # r0) p2 l0 (upd r0 p1 t1)  (p1 :: lp2) lp1 reach ).
intros (p3,(Path,Path')).
unfold reachable.
assert (lp1 ++ p1 :: lp2 = lp1 ++ p1 :: lp2).
auto.
generalize (no_rep_sublist (lp1 ++ p1 :: lp2) lp1 (p1::lp2) no_rep H1).
intros.
inversion Path';subst.
right;exists (p1::lp2).
constructor 2;auto.
apply path_inv_upd_right with p1 t1;auto.
apply no_rep_p;auto.
rewrite acc_upd_eq  in H19.
left;exists lp2.
apply path_inv_upd_right with p1 t1;auto.
apply no_rep_p;auto.
auto.
right.
unfold reachable.
exists (p1::path').
constructor 3;auto.
apply path_inv_upd_right with p1 t1;auto.
unfold reachable in *|-*.
inversion_clear H1.
generalize (path_no_cycle alloc p1 p2 l0 (upd r0 p1 t1) x1 H0).
intros (path',(_,(no_rep,reach))).
inversion reach;subst.
right;exists (@nil pointer);
apply path_inv_upd_right with p2 t1;auto.
right.
exists (p1::lp).
constructor 2;auto.
apply path_inv_upd_right with p1 t1;auto.
apply no_rep_p;auto.
rewrite acc_upd_eq in H13.
left;exists lp.
apply path_inv_upd_right with p1 t1;auto.
apply no_rep_p;auto.
auto.
unfold reachable in *|-*.
generalize (H9 p2);intros (H11,H12);clear H9.
generalize (H12 H1);intro;clear H12.
intros Q;generalize (H9 Q);clear H9;intro.
assert ((exists lp : list pointer, path alloc l r root p2 lp) \/
      (exists lp : list pointer, path alloc l r root p2 lp)->(exists lp : list pointer, path alloc l r root p2 lp)).
intros [P|P];auto.
generalize (H10 H9);clear H10 H9;intro.
inversion_clear H0.
generalize (H10 p2 H9);clear H9;intros [P|P].
inversion_clear P.
generalize (In_dec eq_pointer_dec p1 x1).
intros [P|P].
generalize (split_list p1 x1 P);intros (L1,(L2,sub));subst.
generalize (split_path alloc t1 p2 l0 r0 (p1::L2) L1  H0);intros (p3,(P2,P3)).
generalize (path_no_cycle alloc p3 p2 l0 r0 (p1::L2) P3).
intros (path',(_,(no_rep,reach))).
inversion reach;subst.
inversion P3;subst;right;exists (@nil pointer);constructor.
right;exists (p1::lp);constructor 2;auto.
inversion P3;subst;apply path_upd_right;auto;
  apply no_rep_p;auto.
left;exists lp;inversion P3;subst;
  apply path_upd_right;auto;apply no_rep_p;auto.
right;exists (p1::x1);constructor 3;auto;caduceus;
  apply path_upd_right;auto;apply no_rep_p;auto.
inversion_clear P.
generalize (path_no_cycle alloc p1 p2 l0 r0 x1 H0).
intros (path',(_,(no_rep,reach))).
inversion reach;subst.
right ;exists (@nil pointer);constructor.
right ;exists (p1::lp);constructor 2;auto.
apply path_upd_right;auto.
apply no_rep_p;auto.
left;exists lp;apply path_upd_right;auto.
apply no_rep_p;auto.
auto.
red.
split.
red; simpl.
exists x.
split.
red.
inversion_clear H1.
split;auto.
intros.
red.
split;intro.
red in H9.
generalize (H9 p2);intro;clear H9.
inversion_clear H10.
apply H9.
inversion_clear H0.
intros Q;right;apply H12;auto.
generalize (H1 Q);clear H1;intro.
inversion_clear H0.
inversion_clear H1.
generalize (path_no_cycle alloc (p1 # r0) p2 l0 (upd r0 p1 t1) x1 H0).
intros (path',(_,(no_rep,reach))).
generalize (In_dec eq_pointer_dec p1 path').
intros [P|P].
generalize (split_list p1 path' P);intros (lp1,(lp2,S)).
subst.
generalize (split_path alloc (p1 # r0) p2 l0 (upd r0 p1 t1)  (p1 :: lp2) lp1 reach ).
intros (p3,(S1,S2)).
unfold reachable.
assert (lp1 ++ p1 :: lp2 = lp1 ++ p1 :: lp2).
auto.
generalize (no_rep_sublist (lp1 ++ p1 :: lp2) lp1 (p1::lp2) no_rep H1).
intros.
inversion S2;subst.
right;exists (p1::lp2).
constructor 2;auto.
apply path_inv_upd_right with p1 t1;auto.
apply no_rep_p;auto.
rewrite acc_upd_eq  in H19;auto.
left;exists lp2.
apply path_inv_upd_right with p1 t1;auto.
apply no_rep_p;auto.
right.
unfold reachable.
exists (p1::path').
constructor 3;auto.
apply path_inv_upd_right with p1 t1;auto.
unfold reachable in *|-*.
inversion_clear H1.
generalize (path_no_cycle alloc p1 p2 l0 (upd r0 p1 t1) x1 H0).
intros (path',(_,(no_rep,reach))).
inversion reach;subst.
right;exists (@nil pointer);
apply path_inv_upd_right with p2 t1;auto.
right.
exists (p1::lp).
constructor 2;auto.
apply path_inv_upd_right with p1 t1;auto.
apply no_rep_p;auto.
rewrite acc_upd_eq in H13.
left.
exists lp.
apply path_inv_upd_right with p1 t1;auto.
apply no_rep_p;auto.
auto.
unfold reachable in *|-*.
generalize (H9 p2);clear H9;intros (H10,H11).
intros Q;generalize (H11 H1 Q);intro;clear H11.
assert ((exists lp : list pointer, path alloc l r root p2 lp) \/
      (exists lp : list pointer, path alloc l r root p2 lp)->
(exists lp : list pointer, path alloc l r root p2 lp)).
intros [P|P];auto.
generalize (H11 H9);clear H11 H9 ;intro.
inversion_clear H0.
generalize (H11 p2 H9);clear H9;intros [P|P].
inversion_clear P.
generalize (In_dec eq_pointer_dec p1 x1).
intros [P|P].
generalize (split_list p1 x1 P);intros (L1,(L2,sub));subst.
generalize (split_path alloc t1 p2 l0 r0 (p1::L2) L1  H0);intros (p3,(P2,P3)).
generalize (path_no_cycle alloc p3 p2 l0 r0 (p1::L2) P3).
intros (path',(_,(no_rep,reach))).
inversion reach;subst.
inversion P3;subst;right;exists (@nil pointer);constructor.
right;exists (p1::lp);constructor 2;auto.
inversion P3;subst;apply path_upd_right;auto;
  apply no_rep_p;auto.
left;exists lp;inversion P3;subst;
  apply path_upd_right;auto;apply no_rep_p;auto.
right;exists (p1::x1);constructor 3;auto;caduceus;
  apply path_upd_right;auto;apply no_rep_p;auto.
inversion_clear P.
generalize (path_no_cycle alloc p1 p2 l0 r0 x1 H0).
intros (path',(_,(no_rep,reach))).
inversion reach;subst.
right;exists (@nil pointer);constructor.
right;exists (p1::lp);constructor 2;auto.
apply path_upd_right;auto;apply no_rep_p;auto.
left;exists lp;apply path_upd_right;auto;apply no_rep_p;auto.
auto.
red.
exists (tail x0).
split;auto.
simpl.
inversion H2;subst.
elimtype False;elim Pre31;auto.
destruct (Z_eq_dec (p1 # c0) 0).
elim (Test4 e).
simpl.
unfold clr_list.
unfold llist.
apply clr_list_upd_right;auto.
unfold clr_list in H3.
generalize (llist_no_rep alloc 
(fun t : pointer => if Z_eq_dec (t # c0) 0 then t # l0 else t # r0) p1 p1 l1 H2).
tauto.
intros.
unfold interp_mark_m_and_c_and_stack in H2.
red.
destruct m1.
inversion_clear H3.
unfold interp_mark_c_and_stack in H10.
destruct n.
inversion_clear H10.
assert (x1 = (mesure_mark m0 x)).
red in H9; simpl in H9.
inversion_clear H9.
inversion_clear H10.
unfold reachable_elements in *|-*.
inversion_clear H9.
inversion_clear H1.
subst x1.
apply mesure_mark_eq;auto.
intro.
generalize (H13 p);generalize (H14 p);intros;clear H13;clear H14.
inversion_clear H12.
generalize (H14 H15);intro;clear H14.
inversion_clear H1.
inversion_clear H0.
apply H14.
intros Q.
right.
apply H17;auto.
generalize (H12 Q);clear H7;intro.
inversion_clear H0.
right ;auto.
left;auto.
intro.
generalize (H14 p);generalize (H13 p);intros.
inversion_clear H12;inversion_clear H1.
generalize (H17 H15);intro;clear H17.
apply H12.
intros Q.
generalize (H1  Q);clear H1;intro.
assert (reachable alloc l r root p \/ reachable alloc l r root p ->
reachable alloc l r root p).
intros [P|P];auto.
inversion_clear H0.
generalize (H17 H1);clear H1;clear H17;intro.
generalize (H19 p H0).
intros [h|h] ; [ right ; apply h | left ; apply h].
subst x1.
unfold lex.
apply Relation_Operators.right_lex.
assert (x2 = (mesure_mark c0 x)).
red in H3; simpl in H3.
inversion_clear H3.
inversion_clear H10.
unfold reachable_elements in *|-*.
inversion_clear H3;inversion_clear H0.
subst x2.
inversion_clear H1.
apply mesure_mark_eq;auto.
intro.
generalize (H13 p);generalize (H12 p);intros.
inversion_clear H15.
generalize (H18 H16);intro.
inversion_clear H1.
generalize (H14 p);intros.
apply H19.
intros Q.
right.
apply H1;auto.
generalize (H15 Q);clear H7;intro.
inversion_clear H7.
right ;auto.
left;auto.
intro.
generalize (H12 p);generalize (H13 p);intros.
inversion_clear H1;inversion_clear H15.
generalize (H14 p);intros.
generalize (H19 H16);intro.
apply H17.
intros Q.
generalize (H20 Q);clear H20;intro.
assert (reachable alloc l r root p \/ reachable alloc l r root p ->
reachable alloc l r root p).
intros [P|P];auto.
generalize (H21 H20);clear H20;clear H21;intro.
generalize (H3 p  H20).
intros [h|h] ; [right ; apply h | left ; apply h].
subst x2.
unfold lex_nat.
unfold lex.
apply Relation_Operators.right_lex.
red in H11;simpl in H11.
inversion_clear H11.
inversion_clear H10.
subst.
destruct x0.
inversion H2;subst.
elimtype False;elim Pre32;auto.
simpl.
unfold clr_list in *|-*.
generalize (@llist_function alloc alloc (fun t : pointer => if Z_eq_dec (t # c0) 0 then t # l0 else t # r0) 
(p::x0) x1 p1 H2 H11).
intro;subst.
auto.
Save.


(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_7 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_4: t = null),
  forall (result: Z),
  forall (HW_5: result = (acc c_Z47_0 p)),
  forall (HW_11: result = 0),
  forall (result0: ((pointer) Z47)),
  forall (HW_12: result0 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_13: t0 = result0),
  forall (result1: ((pointer) Z47)),
  forall (HW_14: result1 = (acc l_Z47_0 p)),
  forall (r_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_15: r_Z47_1 = (upd r_Z47_0 p result1)),
  forall (l_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_16: l_Z47_1 = (upd l_Z47_0 p t)),
  (valid alloc p).
Proof.
(* validity of p in "p->r = p->l" in second branch of if "swing" *)
intros; subst;auto.
Qed.



(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_8 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_4: t = null),
  forall (result: Z),
  forall (HW_5: result = (acc c_Z47_0 p)),
  forall (HW_11: result = 0),
  forall (result0: ((pointer) Z47)),
  forall (HW_12: result0 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_13: t0 = result0),
  forall (result1: ((pointer) Z47)),
  forall (HW_14: result1 = (acc l_Z47_0 p)),
  forall (r_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_15: r_Z47_1 = (upd r_Z47_0 p result1)),
  (valid alloc p).
Proof.
intros.
split;subst;auto with *.
intros.
split;subst;auto with *.
intros;split.
intros;split.
intros.
inversion_clear Pre35.
inversion_clear H0.
split.
clear H3.
intros.
(*1*)
generalize (H2 x H0);clear H2.
intros [H3|H4].
unfold reachable.
inversion H3;subst.
generalize (path_no_cycle alloc t1 x l0 r0 x0 H2).
intros (path,(H6,(H4,H5))).
generalize ( In_dec eq_pointer_dec p1 path).
intros [H|H].
generalize (split_list p1 path H). 
intros (path',(path'',H7)).
subst.
generalize (split_path alloc t1 x l0 r0  
  (p1::path'') path' H5).
intros (p3,(H7,H8)).
inversion H8;subst.
right.
exists (p1::path'').
constructor 3;auto.
rewrite acc_upd_eq.
assert (path' ++ p1 :: path'' = path' ++ p1 :: path'').
auto.
generalize (no_rep_sublist (path' ++ p1 :: path'') path' (p1::path'') H4 H9).
intros.
apply path_upd_left;auto.
apply no_rep_p;auto.
apply path_upd_right;auto.
apply no_rep_p;auto.
auto.
left.
exists (path'').
assert (path' ++ p1 :: path'' = path' ++ p1 :: path'').
auto.
generalize (no_rep_sublist (path' ++ p1 :: path'') path' (p1::path'') H4 H9).
intros.
apply path_upd_left;auto.
apply no_rep_p;auto.
apply path_upd_right;auto.
apply no_rep_p;auto.
right.
exists (p1::path).
constructor 2;auto.
rewrite acc_upd_eq.
apply  path_upd_left ;auto.
apply path_upd_right ;auto.
auto.
inversion_clear H4.
unfold reachable.
generalize (path_no_cycle alloc p1 x l0 r0 x0 H2).
intros (path,(no_effect,(no_rep,reach))).
inversion reach;subst.
right.
exists (@nil pointer).
constructor.
right.
exists (p1::lp).
constructor 3;auto.
rewrite acc_upd_eq.
apply path_upd_right ;auto.
apply no_rep_p;auto.
apply  path_upd_left ;auto.
apply no_rep_p;auto.
auto.
left.
exists lp.
apply path_upd_right ;auto.
apply no_rep_p;auto.
apply  path_upd_left ;auto.
apply no_rep_p;auto.
(*i1bis*)
clear H2.
intros.
apply H3.
auto.
inversion_clear H2.
inversion_clear H4.
generalize (path_no_cycle alloc (p1#r0) x 
  (upd l0 p1 t1) (upd r0 p1 (p1 # l0)) x0 H2).
intros (path,(incl,(no_rep,reach))).
case (In_dec eq_pointer_dec p1 path).
intro.
generalize (split_list p1 path i).
intros (path',(path'',sub)).
subst.
generalize (split_path alloc (p1#r0) x
 (upd l0 p1 t1) (upd r0 p1 (p1 # l0)) 
  (p1 :: path'') path' reach).
intros (p3,(no_used,reach2)).
unfold reachable.
inversion reach2;subst.
rewrite acc_upd_eq in H8;auto.
left.
exists (path'').
apply path_inv_upd_right with p1 (p1#l0).
apply no_rep_p.
apply no_rep_sublist with (path'++p1::path'') path' ;auto.
apply path_inv_upd_left  with p1 t1;auto.
apply no_rep_p.
apply no_rep_sublist with (path'++p1::path'') path' ;auto.
rewrite acc_upd_eq in H8;auto.
right.
exists (p1::path'').
constructor 2;auto.
apply path_inv_upd_right with p1 (p1#l0).
apply no_rep_p.
apply no_rep_sublist with (path'++p1::path'') path' ;auto.
apply path_inv_upd_left  with p1 t1;auto.
apply no_rep_p.
apply no_rep_sublist with (path'++p1::path'') path' ;auto.
intro.
right.
unfold reachable.
exists (p1::path).
constructor 3;auto.
apply path_inv_upd_right with p1 (p1#l0).
auto.
apply path_inv_upd_left  with p1 t1;auto.
unfold reachable in *|-*.
inversion_clear H4.
generalize (path_no_cycle alloc p1 x
  (upd l0 p1 t1) (upd r0 p1 (p1 # l0)) x0 H2).
intros (path,(incl,(no_rep,reach))).
inversion reach;subst.
right.
exists (@nil pointer).
constructor.
rewrite acc_upd_eq in H5;auto.
left.
exists lp.
apply path_inv_upd_right with p1 (p1#l0).
apply no_rep_p;auto.
apply path_inv_upd_left  with p1 t1;auto.
apply no_rep_p;auto.
rewrite acc_upd_eq in H5;auto.
right.
exists (p1::lp).
constructor 2;auto.
apply path_inv_upd_right with p1 (p1#l0).
apply no_rep_p;auto.
apply path_inv_upd_left  with p1 t1;auto.
apply no_rep_p;auto.
(*recuperation de la list*)
inversion_clear Pre35.
inversion_clear H1.
exists x.
inversion_clear H2.
inversion_clear H1.
inversion_clear H2.
inversion_clear H1.
inversion_clear H2.
split.
split.
split.
split.
split.
(*i2*)
inversion H1;subst.
inversion Pre19.
elim H.
auto.
unfold clr_list.
unfold llist.
destruct (Z_eq_dec (p1 # (upd c0 p1 1)) 0).
rewrite acc_upd_eq in e.
inversion e.
auto.
unfold clr_list in H2.
generalize (llist_no_rep alloc 
  (fun t : pointer => 
    if Z_eq_dec (t # c0) 0 then t # l0 else t # r0)
   p1 p1 l1 H1).
intros (p,In).
constructor 2;auto.
caduceus.
simpl.
rewrite Test3 in H8.
simpl in H8.
apply lpath_eq_fun with 
  (fun t : pointer => 
     if Z_eq_dec (t # c0) 0 then t # l0 else t # r0); 
  auto.
intros.
assert (p1<> p0).
intro;subst.
apply In;auto.
rewrite acc_upd_neq;auto.
rewrite acc_upd_neq;auto.
rewrite acc_upd_neq;auto.
auto.
intros.
generalize (H6 x0 H2);clear H6;intros [H6|H6].
unfold unmarked_reachable in H6.
inversion_clear H6.
inversion_clear H8.
unfold clr_list in H1.
inversion H9;subst.
decompose [and] H2.
elim Test5.
intro;subst.
inversion H10.
elim H;auto.
intros (H13,H14).
elim H14;auto.
elim Test5.
intro;subst.
inversion H8.
elim H;auto.
intros (H13,H14).
elim H14;auto.
generalize (H6 t1).
intro.
apply H.
left;auto.
elim Test5.
intro;subst.
inversion H8.
elim H;auto.
intros (H13,H14).
elim H14.
generalize (H6 t1).
intro.
apply H.
left;auto.
inversion_clear H6.
inversion_clear H8.
inversion_clear H9.
inversion_clear H8.
destruct x.
inversion H6.
unfold clr_list in H1.
generalize (llist_no_rep alloc 
(fun t : pointer => if Z_eq_dec (t # c0) 0 then t # l0 else t # r0) p1 p x H1).
intros (sub,H12).
subst.
inversion H10;subst.
inversion H6.
subst x1.
left.
unfold unmarked_reachable.
exists (@nil pointer).
split;auto.
constructor.
assert (In x1 x).
auto.
clear H.
right.
exists x1.
split.
right;auto.
rewrite acc_upd_neq.
unfold unmarked_reachable.
exists (@nil pointer).
split;auto.
constructor.
intro;subst;apply H12;auto.
inversion H6.
subst.
left.
unfold unmarked_reachable.
exists (x1 # r0 :: lp).
split;auto.
constructor 2;auto.
apply path_upd_right .
intro.
generalize (H7 x1 H6).
intro.
apply H13.
apply H9.
right;auto.
apply  path_upd_left .
intro.
generalize (H7 x1 H6).
intro.
apply H13.
apply H9.
right;auto.
rewrite acc_upd_neq;auto.
generalize (H7 x1 H6).
intro.
intro.
assert (In (x1#r0) ((x1#r0)::lp)).
left;auto.
generalize (H9 (x1#r0) H14).
intro.
rewrite <- H13 in H15.
elim (H11 H15).
assert (In x1 x).
auto.
clear H11.
right.
exists x1.
split;auto.
unfold unmarked_reachable.
exists (x1#r0::lp).
split;auto.
rewrite acc_upd_neq.
constructor 2;auto.
assert (In p (p::x)).
left;auto.
rewrite acc_upd_neq.
apply path_upd_right .
generalize (H7 p H11).
intros.
intro.
apply H14.
apply H9.
right;auto.
apply  path_upd_left .
generalize (H7 p H11).
intros.
intro.
apply H14.
apply H9.
right;auto.
auto.
intro;subst.
generalize (H7 (x1#r0) H11).
intro.
apply H14.
apply H9.
left;auto.
intro;subst.
apply H12;auto.
inversion H6.
subst.
left.
unfold unmarked_reachable.
exists (x1 # r0 :: lp).
split;auto.
constructor 3;auto.
apply path_upd_right .
intro.
generalize (H7 x1 H6).
intro.
apply H13.
apply H9.
right;auto.
apply  path_upd_left .
intro.
generalize (H7 x1 H6).
intro.
apply H13.
apply H9.
right;auto.
rewrite acc_upd_neq;auto.
generalize (H7 x1 H6).
intro.
assert (In (x1#r0) ((x1#r0)::lp)).
left;auto.
generalize (H9 (x1#r0) H13).
intro.
intro.
rewrite <- H15 in H14.
elim (H11 H14).
assert (In x1 x).
auto.
clear H11.
right.
exists x1.
split;auto.
unfold unmarked_reachable.
exists (x1#r0::lp).
split;auto.
rewrite acc_upd_neq.
constructor 3;auto.
assert (In p (p::x)).
left;auto.
rewrite acc_upd_neq.
apply path_upd_right .
generalize (H7 p H11).
intros.
intro.
apply H14.
apply H9.
right;auto.
apply  path_upd_left .
generalize (H7 p H11).
intros.
intro.
apply H14.
apply H9.
right;auto.
auto.
intro;subst.
generalize (H7 (x1#r0) H11).
intro.
apply H14.
apply H9.
left;auto.
intro;subst.
apply H12;auto.
(*i5*)
intros.
generalize (H5 x0 H2).
assert (x0 <> p1).
unfold clr_list in H1.
destruct x.
inversion H1.
subst.
inversion Pre17.
elim H;auto.
generalize (llist_no_rep alloc 
(fun t : pointer => if Z_eq_dec (t # c0) 0 then t # l0 else t # r0) p1 p x H1).
intros (sub,H12).
subst.
intro;subst.
apply H2;left;auto.
rewrite acc_upd_neq;auto.
rewrite acc_upd_neq;auto.
(*i6*)
intros.
generalize (eq_pointer_dec p0 (p1#r0)).
intros [H9|H9].
subst.
unfold clr_list in H1.
destruct x.
inversion H1.
subst.
inversion Pre17.
elim H;auto.
generalize (llist_no_rep alloc 
(fun t : pointer => if Z_eq_dec (t # c0) 0 then t # l0 else t # r0) p1 p x H1).
intros (sub,H12).
subst.
inversion_clear H2;subst;caduceus.
inversion_clear H;subst.
caduceus.
split;intro.
assert (pair_in_list t1 p2 (cons t1 (p2 :: x)) ).
simpl;left;auto.
generalize (H4 t1 p2 H8).
intros (H10,H11).
apply H11;auto.
inversion H.
inversion_clear H.
inversion_clear H2.
destruct x.
inversion H8.
subst p0.
assert (p2<>p).
intro;subst p.
apply H12;left;auto.
caduceus.
apply H4.
right.
rewrite <- H.
left;auto.
destruct x.
tauto.
assert (In p2 x).
apply (pair_in_list_in x (p#r0) p2 p0 ).
auto.
assert (p2<> p).
intro;subst.
apply H12;right;auto.
caduceus.
apply H4.
right;right;auto.
inversion_clear H2.
inversion_clear H8.
elim (H9 ).
auto.
destruct x;auto.
inversion H8.
unfold clr_list in H1.
generalize (llist_no_rep alloc 
(fun t : pointer => if Z_eq_dec (t # c0) 0 then t # l0 else t # r0) p1 p x H1).
intros (sub,H12).
subst.
generalize (pair_in_list_in x p0 p2 p H8).
intro.
assert (p2<>p).
intro;subst;apply H12;auto.
caduceus.
apply H4.
right;auto.
(*i7*)
auto.
(*termination*)
red.
red.
subst.
inversion_clear Pre35.
inversion_clear H.
inversion_clear H0.
inversion_clear Pre37.
inversion_clear H3.
exists (existS (fun _ => natnat) (mesure_mark m0 x0)
   (existS (fun _ => nat) (mesure_mark (upd c0 p1 1) x0) (List.length x))).
red.
split.
red; simpl.
exists x0.
split.
red.
inversion_clear H4.
split;auto.
intros.
red.
split;intro.
red in H5.
generalize (H5 p2);intro;clear H5.
inversion_clear H6.
apply (H5).
intros Q.
right;apply H2;auto.
generalize (H4 Q);clear H4;intro.
inversion_clear H4.
inversion_clear H6.
generalize (path_no_cycle alloc (p1) p2 (upd l0 p1 t1)  (upd r0 p1 (p1#l0)) x1 H4).
intros (path',(_,(no_rep,reach))).
unfold reachable.
inversion reach;subst.
right;exists (@nil pointer);constructor.
left;exists (lp).
apply path_inv_upd_right with p1 (p1#l0);auto.
apply no_rep_p;auto.
apply path_inv_upd_left  with p1 t1;auto.
apply no_rep_p;auto.
rewrite acc_upd_eq  in H8;auto.
rewrite acc_upd_eq  in H8.
right;exists (p1::lp).
constructor 2;auto.
apply path_inv_upd_left  with p1 t1;auto.
apply no_rep_p;auto.
apply path_inv_upd_right with p1 (p1#l0);auto.
apply no_rep_p;auto.
auto.
inversion_clear H6.
unfold reachable.
generalize (path_no_cycle alloc (p1#r0) p2 (upd l0 p1 t1)  (upd r0 p1 (p1#l0)) x1 H4).
intros (path',(_,(no_rep,reach))).
generalize (In_dec eq_pointer_dec p1 path').
intros [P|P].
generalize (split_list p1 path' P);intros (lp1,(lp2,sub));subst.
generalize (split_path alloc (p1#r0) p2 (upd l0 p1 t1) (upd r0 p1 (p1 # l0))
(p1::lp2) lp1 reach);intros (p3,(_,reach')).
assert ((lp1 ++ p1 :: lp2) = (lp1 ++ p1 :: lp2)).
auto.
generalize (no_rep_sublist (lp1 ++ p1 :: lp2) lp1 (p1::lp2) no_rep H6).
intros.
inversion reach';subst.
left;exists (lp2).
apply path_inv_upd_right with p1 (p1#l0);auto.
apply no_rep_p;auto.
apply path_inv_upd_left  with p1 t1;auto.
apply no_rep_p;auto.
rewrite acc_upd_eq  in H14;auto.
rewrite acc_upd_eq  in H14.
right;exists (p1::lp2).
constructor 2;auto.
apply path_inv_upd_left  with p1 t1;auto.
apply no_rep_p;auto.
apply path_inv_upd_right with p1 (p1#l0);auto.
apply no_rep_p;auto.
auto.
right;exists (p1::path').
constructor 3;auto.
apply path_inv_upd_right with p1 (p1#l0);auto.
apply path_inv_upd_left  with p1 t1;auto.
unfold reachable in *|-*.
generalize (H5 p2);clear H5;intros.
inversion_clear H5.
generalize ( H8 H4);clear H8;intros.
generalize (H5 H6);clear H5;intro.
assert ((exists lp : list pointer, path alloc l r root p2 lp) \/
      (exists lp : list pointer, path alloc l r root p2 lp)->(exists lp : list pointer, path alloc l r root p2 lp)).
intros [P|P];auto.
generalize (H8 H5);clear H8 H5;intro.
generalize (H1 p2 H5);clear H5;intros [H12|H12];inversion_clear H12.
generalize (In_dec eq_pointer_dec p1 x1).
intros [P|P].
generalize (split_list p1 x1 P);intros (L1,(L2,sub));subst.
generalize (split_path alloc t1 p2 l0 r0 (p1::L2) L1  H5);intros (p3,(P2,P3)).
generalize (path_no_cycle alloc p3 p2 l0 r0 (p1::L2) P3).
intros (path',(_,(no_rep,reach))).
inversion reach;subst.
inversion P3;subst;left;exists (@nil pointer);constructor.
left;exists (p1::lp);constructor 3;auto;caduceus.
inversion P3;subst;apply path_upd_right ;auto.
apply no_rep_p;auto.
apply  path_upd_left ;auto.
apply no_rep_p;auto.
apply no_rep_p;auto.
apply  path_upd_left ;auto.
apply no_rep_p;auto.
right;exists lp;inversion P3;subst;apply path_upd_right ;auto.
apply no_rep_p;auto.
apply  path_upd_left ;auto.
apply no_rep_p;auto.
apply no_rep_p;auto.
apply  path_upd_left ;auto.
apply no_rep_p;auto.
left;exists (p1::x1);constructor 2;auto;caduceus;apply path_upd_right ;auto.
apply  path_upd_left ;auto.
generalize (path_no_cycle alloc p1 p2 l0 r0 x1 H5).
intros (path',(_,(no_rep,reach))).
inversion reach;subst.
left ;exists (@nil pointer);constructor.
left ;exists (p1::lp);constructor 3;auto;caduceus.
apply path_upd_right ;auto.
apply no_rep_p;auto.
apply path_upd_left ;auto.
apply no_rep_p;auto.
right;exists lp;apply path_upd_right ;auto.
apply no_rep_p;auto.
apply path_upd_left ;auto.
apply no_rep_p;auto.
auto.
red.
split.
red; simpl.
exists x0.
split.
red.
inversion_clear H4.
split;auto.
intros.
red.
split;intro.
red in H5.
generalize (H5 p2);intro;clear H5.
inversion_clear H6.
apply (H5).
intros Q.
right;apply H2;auto.
generalize (H4 Q);clear H4;intro.
inversion_clear H4.
inversion_clear H6.
generalize (path_no_cycle alloc (p1) p2 (upd l0 p1 t1)  (upd r0 p1 (p1#l0)) x1 H4).
intros (path',(_,(no_rep,reach))).
unfold reachable.
inversion reach;subst.
right;exists (@nil pointer);constructor.
left;exists (lp).
apply path_inv_upd_right with p1 (p1#l0);auto.
apply no_rep_p;auto.
apply path_inv_upd_left  with p1 t1;auto.
apply no_rep_p;auto.
rewrite acc_upd_eq  in H8;auto.
rewrite acc_upd_eq  in H8.
right;exists (p1::lp).
constructor 2;auto.
apply path_inv_upd_left  with p1 t1;auto.
apply no_rep_p;auto.
apply path_inv_upd_right with p1 (p1#l0);auto.
apply no_rep_p;auto.
auto.
inversion_clear H6.
unfold reachable.
generalize (path_no_cycle alloc (p1#r0) p2 (upd l0 p1 t1)  (upd r0 p1 (p1#l0)) x1 H4).
intros (path',(_,(no_rep,reach))).
generalize (In_dec eq_pointer_dec p1 path').
intros [P|P].
generalize (split_list p1 path' P);intros (lp1,(lp2,sub));subst.
generalize (split_path alloc (p1#r0) p2 (upd l0 p1 t1) (upd r0 p1 (p1 # l0))
(p1::lp2) lp1 reach);intros (p3,(_,reach')).
assert ((lp1 ++ p1 :: lp2) = (lp1 ++ p1 :: lp2)).
auto.
generalize (no_rep_sublist (lp1 ++ p1 :: lp2) lp1 (p1::lp2) no_rep H6).
intros.
inversion reach';subst.
left;exists (lp2).
apply path_inv_upd_right with p1 (p1#l0);auto.
apply no_rep_p;auto.
apply path_inv_upd_left  with p1 t1;auto.
apply no_rep_p;auto.
rewrite acc_upd_eq  in H14;auto.
rewrite acc_upd_eq  in H14.
right;exists (p1::lp2).
constructor 2;auto.
apply path_inv_upd_left  with p1 t1;auto.
apply no_rep_p;auto.
apply path_inv_upd_right with p1 (p1#l0);auto.
apply no_rep_p;auto.
auto.
right;exists (p1::path').
constructor 3;auto.
apply path_inv_upd_right with p1 (p1#l0);auto.
apply path_inv_upd_left  with p1 t1;auto.
unfold reachable in *|-*.
generalize (H5 p2);clear H5;intros.
inversion_clear H5.
generalize ( H8 H4);clear H8;intros.
generalize (H5 H6);clear H5;intro.
assert ((exists lp : list pointer, path alloc l r root p2 lp) \/
      (exists lp : list pointer, path alloc l r root p2 lp)->(exists lp : list pointer, path alloc l r root p2 lp)).
intros [P|P];auto.
generalize (H8 H5);clear H8 H5;intro.
generalize (H1 p2 H5);clear H5;intros [H12|H12];inversion_clear H12.
generalize (In_dec eq_pointer_dec p1 x1).
intros [P|P].
generalize (split_list p1 x1 P);intros (L1,(L2,sub));subst.
generalize (split_path alloc t1 p2 l0 r0 (p1::L2) L1  H5);intros (p3,(P2,P3)).
generalize (path_no_cycle alloc p3 p2 l0 r0 (p1::L2) P3).
intros (path',(_,(no_rep,reach))).
inversion reach;subst.
inversion P3;subst;left;exists (@nil pointer);constructor.
left;exists (p1::lp);constructor 3;auto;caduceus.
inversion P3;subst;apply path_upd_right ;auto.
apply no_rep_p;auto.
apply path_upd_left ;auto.
apply no_rep_p;auto.
apply no_rep_p;auto.
apply path_upd_left ;auto.
apply no_rep_p;auto.
right;exists lp;inversion P3;subst;apply path_upd_right ;auto.
apply no_rep_p;auto.
apply path_upd_left ;auto.
apply no_rep_p;auto.
apply no_rep_p;auto.
apply path_upd_left ;auto.
apply no_rep_p;auto.
left;exists (p1::x1);constructor 2;auto;caduceus;apply path_upd_right ;auto.
apply path_upd_left ;auto.
generalize (path_no_cycle alloc p1 p2 l0 r0 x1 H5).
intros (path',(_,(no_rep,reach))).
inversion reach;subst.
left ;exists (@nil pointer);constructor.
left ;exists (p1::lp);constructor 3;auto;caduceus.
apply path_upd_right ;auto.
apply no_rep_p;auto.
apply path_upd_left ;auto.
apply no_rep_p;auto.
right;exists lp;apply path_upd_right ;auto.
apply no_rep_p;auto.
apply path_upd_left ;auto.
apply no_rep_p;auto.
auto.
exists x.
split;auto.
simpl.
inversion_clear H.
inversion_clear H3.
inversion_clear H.
inversion_clear H3.
inversion_clear H.
inversion H3;subst.
inversion_clear Pre19;elim H;auto.
unfold clr_list.
unfold llist.
destruct (Z_eq_dec (p1 # (upd c0 p1 1)) 0).
rewrite acc_upd_eq in e.
inversion e.
auto.
unfold clr_list in H.
generalize (llist_no_rep alloc 
  (fun t : pointer => 
     if Z_eq_dec (t # c0) 0 then t # l0 else t # r0) 
   p1 p1 l1 H3).
intros (p,In).
constructor 2;auto.
caduceus.
simpl.
rewrite Test3 in H10.
simpl in H10.
apply lpath_eq_fun with      (fun t : pointer => if Z_eq_dec (t # c0) 0 then t # l0 else t # r0);auto.
intros.
assert (p1<> p0).
intro;subst.
apply In;auto.
rewrite acc_upd_neq;auto.
rewrite acc_upd_neq;auto.
rewrite acc_upd_neq;auto.
intros.
unfold interp_mark_m_and_c_and_stack in H3.
red.
destruct m1.
inversion_clear H3.
unfold interp_mark_c_and_stack in H6.
destruct n.
inversion_clear H6.
assert (x1 = (mesure_mark m0 x0)).
red in H5; simpl in H5.
inversion_clear H5.
inversion_clear H6.
unfold reachable_elements in *|-*.
inversion_clear H5;inversion_clear H4.
subst x1.
apply mesure_mark_eq;auto.
intro.
generalize (H10 p);generalize (H9 p);intros.
inversion_clear H4.
generalize (H13 H11);intro.
inversion_clear H8.
apply H14.
intros Q.
right.
apply H2;auto.
generalize (H13 H11 Q);clear H13;intro.
inversion_clear H8.
right ;auto.
left;auto.
intro.
generalize (H10 p);generalize (H9 p);clear H10 H9;intros.
inversion_clear H4;inversion_clear H8.
generalize (H12 H9);clear H12;intro.
apply H10.
intros Q.
generalize (H8 Q);clear H8;intro.
assert (reachable alloc l r root p \/ reachable alloc l r root p ->
reachable alloc l r root p).
intros [P|P];auto.
generalize (H12 H8);clear H8 H12;intro.
generalize (H1 p H8).
intros [h|h] ; [right ; apply h | left ; apply h].
subst x1.
unfold lex.
apply Relation_Operators.right_lex.
unfold lex_nat.
unfold lex.
apply Relation_Operators.left_lex.
unfold interp_mark_c in H3.
simpl in H3.
inversion_clear H3.
inversion_clear H6.
subst x2.
assert ((forall p : pointer, In p x0 -> In p x1)).
intro.
inversion_clear H4;inversion_clear H3.
generalize (H8 p);generalize (H9 p);clear H8 H9;intros.
inversion_clear H3.
apply H10;intros.
inversion_clear H8.
generalize (H13 H9 H3 );clear H13;intro.
assert (reachable alloc l r root p \/ reachable alloc l r root p ->reachable alloc l r root p).
intros [P|P];auto.
generalize (H13 H8);clear H13 H8;intros.
generalize (H1 p H8);intros [P|P].
right;auto.
left;auto.
assert ((forall p : pointer, In p x1 -> In p x0)).
intros.
inversion_clear H4;inversion_clear H3.
generalize (H10 p);generalize (H11 p);clear H10 H11;intros.
inversion_clear H10;inversion_clear H3.
apply H11;intro.
right.
apply H2;auto.
generalize (H13 H8 H3);intros [P|P].
right;auto.
left;auto.
inversion_clear H4;inversion_clear H3.
generalize (mesure_mark_eq c0 x0 x1 H6 H8  H9 H4);intro.
rewrite <- H3.
case (In_dec eq_pointer_dec p1 x0).
intro.
generalize (split_list p1 x0 i);intros (lp1,(lp2,sub)).
subst.
rewrite <- mesure_mark_app.
rewrite <- mesure_mark_app.
rewrite mesure_mark_upd.
apply plus_lt_compat_l.
simpl.
rewrite acc_upd_eq;auto.
rewrite Test3.
simpl.
rewrite mesure_mark_upd; auto.
apply no_rep_p.
apply no_rep_sublist with (lp1 ++ p1 :: lp2) lp1;auto.
apply no_rep_p_bis with lp2;auto.
intro.
elimtype False.
apply n0.
generalize (H11 p1);clear H11;intro.
inversion_clear H11.
apply H8.
apply H12.
intro.
left.
unfold reachable; exists (@nil pointer);constructor.
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_9 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_4: t = null),
  forall (result: Z),
  forall (HW_5: result = (acc c_Z47_0 p)),
  forall (HW_11: result = 0),
  forall (result0: ((pointer) Z47)),
  forall (HW_12: result0 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_13: t0 = result0),
  forall (result1: ((pointer) Z47)),
  forall (HW_14: result1 = (acc l_Z47_0 p)),
  (valid alloc p).
Proof.
intuition.
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_10 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_4: t = null),
  forall (result: Z),
  forall (HW_5: result = (acc c_Z47_0 p)),
  forall (HW_11: result = 0),
  forall (result0: ((pointer) Z47)),
  forall (HW_12: result0 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_13: t0 = result0),
  (valid alloc p).
Proof.
intros;subst;tauto.
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_11 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_4: t = null),
  forall (result: Z),
  forall (HW_5: result = (acc c_Z47_0 p)),
  forall (HW_11: result = 0),
  (valid alloc p).
Proof.
(*push*)
intros.
split;subst;auto with *.
intros.
split;subst;auto with *.
intros;split.
intros;split.
intros.
subst.
inversion_clear Pre35.
inversion_clear H.
split.
(*i1*)
clear H2.
intros.
generalize (H1 x H).
intros [H50|H50].
inversion_clear H50.
generalize 
  (path_no_cycle alloc t1 x l0 r0 x0 H2). 
intros (path,(no_use,(H50,H3))).
unfold reachable.
inversion H3;subst.
right.
exists (@nil pointer).
apply path_upd_left ;auto.
left.
exists lp.
apply path_upd_left ;auto.
apply no_rep_p;auto.
right.
exists (t1::lp).
constructor 3;auto.
apply path_upd_left ;auto.
apply no_rep_p;auto.
unfold reachable.
inversion_clear H50.
generalize  (path_no_cycle alloc p1 x l0 r0 x0 H2).
intros (path,(no_used,(H50,H3))).
generalize (In_dec eq_pointer_dec t1 path).
intros [H4|H4].
generalize (split_list t1 path H4).
intros (path',(path'',H5)).
subst path.
generalize 
 (split_path alloc p1 x l0 r0 (t1 :: path'') path' H3 ).
intros (p3,(H5,H6)).
inversion H6;subst.
left.
exists (path'').
apply path_upd_left ;auto.
generalize (no_rep_sublist (path' ++ t1 :: path'') path' (t1::path'') H50). 
intro.
apply no_rep_p.
apply H7.
auto.
right.
exists (t1::path'').
constructor 3;auto.
caduceus.
apply path_upd_left ;auto.
generalize (no_rep_sublist (path' ++ t1 :: path'') path' (t1::path'') H50). 
intro.
apply no_rep_p.
apply H7.
auto.
right.
exists (t1::path).
constructor 2;auto.
caduceus.
apply path_upd_left ;auto.
(*i1bis*)
intros.
clear H1.
apply H2.
auto.
unfold reachable in *|-*.
inversion_clear H3;inversion_clear H1.
generalize (path_no_cycle alloc (t1#l0) x 
  (upd l0 t1 p1) r0 x0 H3).
intros (path,(incl,(no_rep,reach))).
case (In_dec eq_pointer_dec t1 path).
intro.
generalize (split_list t1 path i).
intros (path',(path'',sub)).
subst.
generalize (split_path alloc (t1#l0) x
   (upd l0 t1 p1) r0 (t1 :: path'') path' reach).
intros (p3,(_,reach2)).
inversion reach2;subst.
rewrite acc_upd_eq in H8;auto.
right.
exists path''.
apply path_inv_upd_left  with t1 p1;auto.
apply no_rep_p;auto.
apply no_rep_sublist with (path' ++ t1 :: path'') path';auto.
left.
exists (t1::path'').
constructor 3;auto.
apply path_inv_upd_left  with t1 p1;auto.
apply no_rep_p;auto.
apply no_rep_sublist with (path' ++ t1 :: path'') path';auto.
intro.
left.
exists (t1::path).
constructor 2;auto.
apply path_inv_upd_left  with t1 p1;auto.
generalize (path_no_cycle alloc t1 x
   (upd l0 t1 p1) r0 x0 H3).
intros (path,(incl,(no_rep,reach))).
inversion reach;subst.
left.
exists (@nil pointer).
constructor.
rewrite acc_upd_eq in H4;auto.
right.
exists lp.
apply path_inv_upd_left  with t1 p1;auto.
apply no_rep_p;auto.
left.
exists (t1::lp).
constructor 3;auto.
apply path_inv_upd_left  with t1 p1;auto.
apply no_rep_p;auto.
(*recuperation de la list*)
inversion_clear Pre35.
inversion_clear H1.
exists (t1::x).
inversion_clear H2.
inversion_clear H1.
inversion_clear H2.
inversion_clear H1.
inversion_clear H2.
split.
split.
split.
split.
split.
(*i2*)
inversion H1;subst.
unfold clr_list.
unfold llist.
destruct (Z_eq_dec (t1 # (upd c0 t1 0)) 0).
constructor 2;auto.
rewrite acc_upd_eq;auto.
rewrite acc_upd_eq;auto.
constructor 2;auto.
rewrite acc_upd_eq;auto.
rewrite acc_upd_eq;auto.
unfold clr_list.
unfold llist.
destruct (Z_eq_dec (p1 # (upd c0 p1 1)) 0).
rewrite acc_upd_eq in e;auto.
inversion e.
constructor 2;auto.
caduceus.
simpl.
inversion_clear Test2.
assert (~In t1 (p1::l1)).
intro.
generalize (H7 t1 H10).
intro.
apply H11;auto.
apply lpath_eq_fun with      (fun t : pointer => if Z_eq_dec (t # c0) 0 then t # l0 else t # r0);auto.
intros.
assert (t1<> p).
intro;subst.
apply H10;auto.
caduceus.
(*i3*)
intros.
inversion_clear H2.
subst.
rewrite acc_upd_eq;auto.
omega.
generalize (H7 p_0 H8);clear H8.
intro.
rewrite acc_upd_neq;auto.
inversion_clear Test2.
intro;subst.
apply H2;auto.
(*i4*)
intros.
generalize (H6 x0);clear H6.
intros H6.
generalize (eq_pointer_dec x0 t1).
intros [H9|H9].
subst.
inversion_clear H2.
rewrite acc_upd_eq in H8;auto.
inversion H8.
rewrite acc_upd_neq in H2;auto.
generalize (H6 H2);clear H6.
intros H6.
inversion_clear H6.
inversion_clear H8.
inversion_clear H6.
unfold unmarked_reachable.
generalize (path_no_cycle alloc t1 x0 l0 r0 x1 H10).
intros (path,(incl,(no_rep,reach))).
inversion reach;subst.
elimtype False.
apply H9;auto.
left.
exists lp.
split.
intros.
case (In_dec eq_pointer_dec t1 lp);intros H13.
generalize (no_rep_p t1 lp no_rep H13).
intros.
inversion H12.
assert (t1<> x2).
intro;subst;apply H13;auto.
caduceus.
apply path_upd_left ;auto.
apply no_rep_p;auto.
right.
exists t1.
split.
left;auto.
exists lp.
split.
intros.
case (In_dec eq_pointer_dec t1 lp);intros H13.
generalize (no_rep_p t1 lp no_rep H13).
intros.
inversion H12.
assert (t1<> x2).
intro;subst;apply H13;auto.
caduceus.
apply path_upd_left ;auto.
apply no_rep_p;auto.
unfold unmarked_reachable in *|-*.
inversion_clear H8.
inversion_clear H6.
inversion_clear H10.
inversion_clear H6.
generalize (path_no_cycle _ _ _ _ _ _ H11).
intros (path,(incl,(no_rep,reach))).
case (In_dec eq_pointer_dec t1 path);intros H13.
generalize (split_list t1 path H13).
intros (path',(path'',sub)).
subst.
generalize 
 (split_path alloc (x1#r0) x0 l0 r0 (t1::path'') path' reach).
intros (p3,(no_used,reacha)).
inversion reacha;subst.
left.
exists path''.
split.
intros.
assert (~In t1 path'').
apply no_rep_p.
apply (no_rep_sublist (path' ++ t1 :: path'') ) with path';auto.
assert (x3<> t1).
intro;subst;apply H6;auto.
caduceus.
apply H10.
intuition.
apply path_upd_left ;auto.
apply no_rep_p.
apply (no_rep_sublist (path' ++ t1 :: path'') ) with path';auto.
right.
exists t1.
split.
left;auto.
exists path''.
split.
intros.
assert (~In t1 path'').
apply no_rep_p.
apply (no_rep_sublist (path' ++ t1 :: path'') ) with path';auto.
assert (x3<> t1).
intro;subst;apply H6;auto.
caduceus.
apply H10.
intuition.
apply path_upd_left ;auto.
apply no_rep_p.
apply (no_rep_sublist (path' ++ t1 :: path'') ) with path';auto.
right.
exists x1.
split.
right;auto.
exists path.
split.
intros.
assert (x3<> t1).
intro;subst;apply H13;auto.
caduceus.
apply path_upd_left ;auto.
(*i5*)
intros.
assert (~in_list x0 x).
intro.
apply H2.
right;auto.
generalize (H5 x0 H8).
assert (x0 <>t1).
intro;subst;apply H2;left;auto.
caduceus.
(*i6*)
intros.
assert (~ in_list t1 x).
intro.
generalize (H7 t1 H8).
intro.
apply H9.
inversion_clear Test2;auto.
case (eq_pointer_dec p2 t1).
intro;subst.
caduceus.
split.
intro.
elim H;auto.
intro.
inversion H2.
inversion_clear H9.
subst p0.
generalize (H5 t1 H8).
intros(p,t).
auto.
generalize (pair_in_list_in x p0 t1 t1 H9).
intro.
elim (H8 H10).
intro.
caduceus.
inversion H2.
inversion_clear H9.
elim (n );auto.
generalize (H4 p0 p2 H9).
intros (case1,case2).
split.
intro.
apply case1.
subst c.
rewrite acc_upd_neq in H10;auto.
intro.
subst c.
rewrite acc_upd_neq in H10;auto.
(*i7*)
intros.
assert (x0 <>t1).
intro;subst;apply H2.
inversion_clear H0.
apply H8.
inversion Pre7;auto.
left.
unfold reachable;exists (@nil pointer);constructor.
(*i8*)
caduceus.
(*i9*)
auto.
(*terminason*)
red.
red.
subst.
inversion_clear Pre35.
inversion_clear H.
inversion_clear H0.
inversion_clear Pre37.
inversion_clear H3.
exists (existS (fun _ => natnat) (mesure_mark (upd m0 t1 1) x0)
   (existS (fun _ => nat) (mesure_mark (upd c0 t1 0) x0) (List.length (t1::x)))).
red.
split.
red; simpl.
exists x0.
split.
red.
inversion_clear H4.
split;auto.
intros.
red.
split;intro.
red in H5.
generalize (H5 p2);intro;clear H5.
inversion_clear H6.
apply (H5).
intros Q.
right;apply H2;auto.
generalize (H4 Q);clear H4;intro.
inversion_clear H4.
inversion_clear H6.
generalize (path_no_cycle alloc t1 p2 (upd l0 t1 p1)  r0 x1 H4).
intros (path',(_,(no_rep,reach))).
unfold reachable.
inversion reach;subst.
left;exists (@nil pointer);constructor.
right;exists (lp).
apply path_inv_upd_left  with t1 p1;auto.
apply no_rep_p;auto.
rewrite acc_upd_eq  in H8;auto.
left;exists (t1::lp).
constructor 3;auto.
apply path_inv_upd_left  with t1 p1;auto.
apply no_rep_p;auto.
inversion_clear H6.
unfold reachable.
generalize (path_no_cycle alloc (t1#l0) p2 (upd l0 t1 p1)  r0 x1 H4).
intros (path',(_,(no_rep,reach))).
generalize (In_dec eq_pointer_dec t1 path').
intros [P|P].
generalize (split_list t1 path' P);intros (lp1,(lp2,sub));subst.
generalize (split_path alloc (t1#l0) p2 (upd l0 t1 p1) r0 
(t1::lp2) lp1 reach);intros (p3,(_,reach')).
assert ((lp1 ++ t1 :: lp2) = (lp1 ++ t1 :: lp2)).
auto.
generalize (no_rep_sublist (lp1 ++ t1 :: lp2) lp1 (t1::lp2) no_rep H6).
intros.
inversion reach';subst.
rewrite acc_upd_eq  in H14;auto.
right;exists (lp2).
apply path_inv_upd_left  with t1 p1;auto.
apply no_rep_p;auto.
left;exists (t1::lp2).
constructor 3;auto.
apply path_inv_upd_left  with t1 p1;auto.
apply no_rep_p;auto.
left;exists (t1::path').
constructor 2;auto.
apply path_inv_upd_left  with t1 p1;auto.
unfold reachable in *|-*.
generalize (H5 p2);clear H5;intros.
inversion_clear H5.
generalize ( H8 H4);clear H8;intros.
generalize (H5 H6);clear H5;intro.
assert ((exists lp : list pointer, path alloc l r root p2 lp) \/
      (exists lp : list pointer, path alloc l r root p2 lp)->(exists lp : list pointer, path alloc l r root p2 lp)).
intros [P|P];auto.
generalize (H8 H5);clear H8 H5;intro.
generalize (H1 p2 H5);clear H5;intros [H12|H12];inversion_clear H12.
generalize (path_no_cycle alloc t1 p2 l0 r0 (x1) H5).
intros (path',(_,(no_rep,reach))).
inversion reach;subst.
left;exists (@nil pointer);constructor.
right;exists lp;auto.
apply path_upd_left ;auto.
apply no_rep_p;auto.
left;exists (t1::lp);constructor 3;auto;apply path_upd_left ;auto.
apply no_rep_p;auto.
generalize (In_dec eq_pointer_dec t1 x1).
intros [P|P].
generalize (split_list t1 x1 P);intros (lp1,(lp2,sub));subst.
generalize ( split_path alloc p1 p2 l0 r0 (t1::lp2) lp1 H5);intros (p3,(_,reach)).
generalize (path_no_cycle alloc p3 p2 l0 r0 (t1::lp2) reach).
intros (path',(_,(no_rep,reach'))).
inversion reach';subst.
left ;exists (@nil pointer);inversion reach;subst;constructor ;auto.
right ;exists lp.
inversion reach;subst;apply path_upd_left ;auto;apply no_rep_p;auto.
left;exists (t1::lp);constructor 3;auto;inversion reach;subst;apply path_upd_left ;auto;apply no_rep_p;auto.
left;exists (t1::x1);constructor 2;auto;caduceus;auto;apply path_upd_left ;auto.
auto.
red.
split.
red; simpl.
exists x0.
split.
red.
inversion_clear H4.
split;auto.
intros.
red.
split;intro.
red in H5.
generalize (H5 p2);intro;clear H5.
inversion_clear H6.
apply (H5).
intros Q.
right;apply H2;auto.
generalize (H4 Q);clear H4;intro.
inversion_clear H4.
inversion_clear H6.
generalize (path_no_cycle alloc t1 p2 (upd l0 t1 p1)  r0 x1 H4).
intros (path',(_,(no_rep,reach))).
unfold reachable.
inversion reach;subst.
left;exists (@nil pointer);constructor.
right;exists (lp).
apply path_inv_upd_left  with t1 p1;auto.
apply no_rep_p;auto.
rewrite acc_upd_eq  in H8;auto.
left;exists (t1::lp).
constructor 3;auto.
apply path_inv_upd_left  with t1 p1;auto.
apply no_rep_p;auto.
inversion_clear H6.
unfold reachable.
generalize (path_no_cycle alloc (t1#l0) p2 (upd l0 t1 p1)  r0 x1 H4).
intros (path',(_,(no_rep,reach))).
generalize (In_dec eq_pointer_dec t1 path').
intros [P|P].
generalize (split_list t1 path' P);intros (lp1,(lp2,sub));subst.
generalize (split_path alloc (t1#l0) p2 (upd l0 t1 p1) r0 
(t1::lp2) lp1 reach);intros (p3,(_,reach')).
assert ((lp1 ++ t1 :: lp2) = (lp1 ++ t1 :: lp2)).
auto.
generalize (no_rep_sublist (lp1 ++ t1 :: lp2) lp1 (t1::lp2) no_rep H6).
intros.
inversion reach';subst.
rewrite acc_upd_eq  in H14;auto.
right;exists (lp2).
apply path_inv_upd_left  with t1 p1;auto.
apply no_rep_p;auto.
left;exists (t1::lp2).
constructor 3;auto.
apply path_inv_upd_left  with t1 p1;auto.
apply no_rep_p;auto.
left;exists (t1::path').
constructor 2;auto.
apply path_inv_upd_left  with t1 p1;auto.
unfold reachable in *|-*.
generalize (H5 p2);clear H5;intros.
inversion_clear H5.
generalize ( H8 H4);clear H8;intros.
generalize (H5 H6);clear H5;intro.
assert ((exists lp : list pointer, path alloc l r root p2 lp) \/
      (exists lp : list pointer, path alloc l r root p2 lp)->(exists lp : list pointer, path alloc l r root p2 lp)).
intros [P|P];auto.
generalize (H8 H5);clear H8 H5;intro.
generalize (H1 p2 H5);clear H5;intros [H12|H12];inversion_clear H12.
generalize (path_no_cycle alloc t1 p2 l0 r0 (x1) H5).
intros (path',(_,(no_rep,reach))).
inversion reach;subst.
left;exists (@nil pointer);constructor.
right;exists lp;auto.
apply path_upd_left ;auto.
apply no_rep_p;auto.
left;exists (t1::lp);constructor 3;auto;apply path_upd_left ;auto.
apply no_rep_p;auto.
generalize (In_dec eq_pointer_dec t1 x1).
intros [P|P].
generalize (split_list t1 x1 P);intros (lp1,(lp2,sub));subst.
generalize ( split_path alloc p1 p2 l0 r0 (t1::lp2) lp1 H5);intros (p3,(_,reach)).
generalize (path_no_cycle alloc p3 p2 l0 r0 (t1::lp2) reach).
intros (path',(_,(no_rep,reach'))).
inversion reach';subst.
left ;exists (@nil pointer);inversion reach;subst;constructor ;auto.
right ;exists lp.
inversion reach;subst;apply path_upd_left ;auto;apply no_rep_p;auto.
left;exists (t1::lp);constructor 3;auto;inversion reach;subst;apply path_upd_left ;auto;apply no_rep_p;auto.
left;exists (t1::x1);constructor 2;auto;caduceus;auto;apply path_upd_left ;auto.
auto.
exists (t1::x).
split;auto.
simpl.
inversion_clear H.
inversion_clear H3.
inversion_clear H.
inversion_clear H3.
inversion_clear H.
inversion H3;subst.
unfold clr_list.
unfold llist.
destruct (Z_eq_dec (t1 # (upd c0 t1 0)) 0).
constructor 2;auto.
rewrite acc_upd_eq;auto.
rewrite acc_upd_eq;auto.
constructor 2;auto.
rewrite acc_upd_eq;auto.
rewrite acc_upd_eq;auto.
unfold clr_list.
unfold llist.
destruct (Z_eq_dec (p1 # (upd c0 p1 1)) 0).
rewrite acc_upd_eq in e;auto.
inversion e.
constructor 2;auto.
caduceus.
simpl.
inversion_clear Test2.
assert (~In t1 (p1::l1)).
intro.
generalize (H9 t1 H13).
intro.
apply H14;auto.
apply lpath_eq_fun with      (fun t : pointer => if Z_eq_dec (t # c0) 0 then t # l0 else t # r0);auto.
intros.
assert (t1<> p).
intro;subst.
apply H13;auto.
caduceus.
intros.
unfold interp_mark_m_and_c_and_stack in H3.
red.
destruct m1.
inversion_clear H3.
assert (x1 = (mesure_mark m0 x0)).
red in H5; simpl in H5.
inversion_clear H5.
unfold reachable_elements in *|-*.
inversion_clear H3;inversion_clear H4.
inversion_clear H5.
subst x1.
apply mesure_mark_eq;auto.
intro.
generalize (H8 p);generalize (H9 p);intros.
inversion_clear H5.
generalize (H12 H10);intro.
inversion_clear H7.
apply H13.
intros Q.
right.
apply H2;auto.
generalize (H5 Q);clear H5;intro.
inversion_clear H5.
right ;auto.
left;auto.
intro.
generalize (H9 p);generalize (H8 p);clear H8 H9;intros.
inversion_clear H5;inversion_clear H7.
generalize (H10 H8);clear H10;intro.
apply H5.
intros Q.
generalize (H7 Q);clear H8;intro.
assert (reachable alloc l r root p \/ reachable alloc l r root p ->
reachable alloc l r root p).
intros [P|P];auto.
generalize (H10 H8);clear H8 H10;intro.
generalize (H1 p H8).
tauto.
subst x1.
unfold lex.
apply Relation_Operators.left_lex.
unfold interp_mark_m in H5.
simpl in H5.
inversion_clear H5.
inversion_clear H3.
inversion_clear H4;inversion_clear H5.
case (In_dec eq_pointer_dec t1 x0).
intro.
generalize (split_list t1 x0 i);intros (lp1,(lp2,sub)).
subst.
do 2 rewrite <- mesure_mark_app.
rewrite mesure_mark_upd.
apply plus_lt_compat_l.
simpl.
rewrite acc_upd_eq;auto.
inversion_clear Test2.
rewrite H10.
simpl.
rewrite mesure_mark_upd; auto.
apply no_rep_p.
apply no_rep_sublist with (lp1 ++ t1 :: lp2) lp1;auto.
apply no_rep_p_bis with lp2;auto.
assert (forall p , In p x1 -> In p x0).
intro.
generalize (H9 p);generalize (H8 p);clear H9  H8;intros.
inversion_clear H5;inversion_clear H8.
apply H10.
intro.
right.
apply H2;auto.
generalize (H12 H9 H8).
intros [P|P];auto.
intro.
elimtype False.
apply n0.
generalize (H9 t1);clear H9;intro.
inversion_clear H9.
generalize (H8 t1);clear H8;intro.
inversion_clear H8.
apply H9.
intro.
left.
apply H2;auto.
left.
unfold reachable; exists (@nil pointer);constructor.
Save.



(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_12 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_4: t = null),
  (valid alloc p).
Proof.
intros.
inversion_clear Post36.
subst.
auto.
Save.




(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_13 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_18: ~(t = null)),
  forall (result: Z),
  forall (HW_19: result = (acc m_Z47_0 t)),
  forall (HW_20: result <> 0),
  forall (result0: Z),
  forall (HW_21: result0 = (acc c_Z47_0 p)),
  forall (HW_22: result0 <> 0),
  forall (t0: ((pointer) Z47)),
  forall (HW_23: t0 = p),
  forall (result1: ((pointer) Z47)),
  forall (HW_24: result1 = (acc r_Z47_0 p)),
  forall (p0: ((pointer) Z47)),
  forall (HW_25: p0 = result1),
  forall (r_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_26: r_Z47_1 = (upd r_Z47_0 t0 t)),
  (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
  (((* I1 *)
    (forall (x:((pointer) Z47)),
     ((reachable l_Z47 r_Z47 alloc root x) ->
      (reachable l_Z47_0 r_Z47_1 alloc t0 x) \/
      (reachable l_Z47_0 r_Z47_1 alloc p0 x))) /\
  (* I2 *)
  (forall (x:((pointer) Z47)),
   (~(x = null) ->
    ((reachable l_Z47_0 r_Z47_1 alloc t0 x) \/
     (reachable l_Z47_0 r_Z47_1 alloc p0 x) ->
     (reachable l_Z47 r_Z47 alloc root x))))) /\
  (* I0 *)
  (exists stack:plist,
   (((((* I3 *) (clr_list c_Z47_0 l_Z47_0 r_Z47_1 alloc p0 stack) /\
   (* I4 *)
   (forall (p_0:((pointer) Z53)),
    ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
   (* I5 *)
   (forall (x:((pointer) Z47)),
    (((valid alloc x) /\ (reachable l_Z47 r_Z47 alloc root x)) /\
     (acc m_Z47_0 x) = 0 ->
     (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_1 alloc t0 x) \/
     (exists y:((pointer) Z53), (in_list y stack) /\
      (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_1 alloc (acc r_Z53 y) x))))) /\
   (* I6 *)
   (forall (x:((pointer) Z53)),
    (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
     (acc l_Z53 x) = (acc l_Z53 x)))) /\
   (* I7 *)
   (forall (p1:((pointer) Z47)),
    (forall (p2:((pointer) Z51)),
     ((pair_in_list p1 p2 (cons t0 stack)) ->
      (((acc c_Z51 p2) <> 0 -> (acc l_Z51 p2) = (acc l_Z51 p2) /\
        (acc r_Z51 p2) = p1)) /\
      (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
        (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
   (* I8 *)
   (forall (x:((pointer) Z47)),
    (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) = (acc m_Z47 x))))) /\
  (order_mark_m_and_c_and_stack (weight c_Z47_0 m_Z47_0 l_Z47_0 r_Z47_1 alloc
                                 p0 t0)
   (weight c_Z47_0 m_Z47_0 l_Z47_0 r_Z47_0 alloc p t)).
Proof.
(* post-condition of the function *)
intros.
inversion_clear Pre35.
inversion_clear H0.
inversion_clear H1.
inversion_clear H0.
inversion_clear H1.
inversion_clear H0.
inversion_clear H1.
assert (x= (@nil pointer)).
inversion_clear Test1.
subst.
inversion H0.
auto.
subst.
inversion H1.
elim H9;auto.
split.
split.
intro.
subst .
generalize (H4 x0).
intuition.
intro.
intros (val,rea).
subst.
intro.
generalize (H5 x0).
intro.
assert 
((valid alloc x0 /\ reachable alloc l r root x0) 
 /\ x0 # m0 = 0).
split;auto.
split;auto.
unfold reachable in *|-*.
inversion_clear rea.
exists x.
assert (forall x : pointer ,x#r0 = x #r /\ x# l0 = x # l).
intro.
assert (~ in_list x1 nil).
auto.
generalize (H4 x1 H9).
intuition.
clear H0 H7 H1 H6 H5 H4 val H3 H2 H Test1 Pre34 Pre37.
induction H8.
constructor.
constructor 2;auto.
generalize (H9 p0). 
intros (q1,q2).
rewrite <- q2.
auto.
constructor 3;auto.
generalize (H9 p0). 
intros (q1,q2).
rewrite <- q1.
auto.
generalize (H7 H8).
intros [H11|H11].
inversion_clear H11.
inversion_clear H9.
inversion H11;subst.
inversion_clear Test1.
inversion_clear H12.
subst.
inversion val.
elim H9;auto.
inversion_clear H13.
elim (H14 H1).
inversion_clear Test1.
inversion_clear H14.
subst.
inversion H9.
elim H13;auto.
inversion_clear H15.
assert ( In t1 ( t1::lp)).
left;auto.
generalize (H10 t1 H15).
auto.
inversion_clear Test1.
inversion_clear H14.
subst.
inversion H9.
elim H13;auto.
inversion_clear H15.
assert ( In t1 ( t1::lp)).
left;auto.
generalize (H10 t1 H15).
auto.
inversion_clear H11.
inversion_clear H9.
inversion H10.
intros .
subst.
assert (~ reachable alloc l r root x0).
intro.
apply H7.
unfold reachable in *|-*.
inversion_clear H1.
exists x.
assert (forall x : pointer ,x#r0 = x #r /\ x# l0 = x # l).
intro.
assert (~ in_list x1 nil).
auto.
generalize (H4 x1 H1).
intuition.
clear H7 H0 H6 H5 H4 H3 H2 H Test1 Pre34 Pre37.
induction H8.
constructor.
constructor 2;auto.
generalize (H1 p0). 
intros (q1,q2).
rewrite q2.
auto.
constructor 3;auto.
generalize (H1 p0). 
intros (q1,q2).
rewrite q1.
auto.
apply H2;auto.
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_14 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_18: ~(t = null)),
  forall (result: Z),
  forall (HW_19: result = (acc m_Z47_0 t)),
  forall (HW_20: result <> 0),
  forall (result0: Z),
  forall (HW_21: result0 = (acc c_Z47_0 p)),
  forall (HW_22: result0 <> 0),
  forall (t0: ((pointer) Z47)),
  forall (HW_23: t0 = p),
  forall (result1: ((pointer) Z47)),
  forall (HW_24: result1 = (acc r_Z47_0 p)),
  forall (p0: ((pointer) Z47)),
  forall (HW_25: p0 = result1),
  (valid alloc t0).
Proof.

(* loop invariant true at the beginning *)
intros.
split.
split;subst;auto with *.
intros.
inversion_clear H0;auto.
inversion H1.
inversion H0;subst.
elim H;auto.
inversion H2;elim H4;auto.
inversion H2;elim H4;auto.
exists (@nil pointer).
intuition.
subst.
constructor.
left; subst; auto.
red.
inversion_clear H4.
exists x0.
split;auto.
intros.
generalize (split_list x1 x0 H4).
intros (path',(path,subst)).
subst.
generalize (split_path alloc root _ l r ( x1 :: path) (path') H2).
intros (p3,(reach,reach2)).
assert ((p3=null-> False) /\ reachable alloc l r root p3).
split.
intro.
subst.
inversion reach2;subst;inversion H9;elim H3;auto.
unfold reachable;exists path';auto.
generalize (H  p3 H5).
intros (Q1,Q2). 
inversion reach2;subst;auto.
simpl in H1; tauto.
simpl in H1; tauto.
Save.

Proof.
intuition.
(* FILL PROOF HERE *)
Save.

Proof.
intuition.
(* FILL PROOF HERE *)
Save.

Proof.
intuition.
(* FILL PROOF HERE *)
Save.

Proof.
intuition.
(* FILL PROOF HERE *)
Save.

Proof.
intuition.
(* FILL PROOF HERE *)
Save.

Proof.
intuition.
(* FILL PROOF HERE *)
Save.

Proof.
intuition.
(* FILL PROOF HERE *)
Save.

Proof.
intuition.
(* FILL PROOF HERE *)
Save.

Proof.
intuition.
(* FILL PROOF HERE *)
Save.

Proof.
intuition.
(* FILL PROOF HERE *)
Save.

Proof.
intuition.
(* FILL PROOF HERE *)
Save.

Proof.
intuition.
(* FILL PROOF HERE *)
Save.

Proof.
intuition.
(* FILL PROOF HERE *)
Save.

Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_15 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_18: ~(t = null)),
  forall (result: Z),
  forall (HW_19: result = (acc m_Z47_0 t)),
  forall (HW_20: result <> 0),
  forall (result0: Z),
  forall (HW_21: result0 = (acc c_Z47_0 p)),
  forall (HW_22: result0 <> 0),
  forall (t0: ((pointer) Z47)),
  forall (HW_23: t0 = p),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_16 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_18: ~(t = null)),
  forall (result: Z),
  forall (HW_19: result = (acc m_Z47_0 t)),
  forall (HW_20: result <> 0),
  forall (result0: Z),
  forall (HW_21: result0 = (acc c_Z47_0 p)),
  forall (HW_27: result0 = 0),
  forall (result1: ((pointer) Z47)),
  forall (HW_28: result1 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_29: t0 = result1),
  forall (result2: ((pointer) Z47)),
  forall (HW_30: result2 = (acc l_Z47_0 p)),
  forall (r_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_31: r_Z47_1 = (upd r_Z47_0 p result2)),
  forall (l_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_32: l_Z47_1 = (upd l_Z47_0 p t)),
  forall (c_Z47_1: ((memory) Z Z47)),
  forall (HW_33: c_Z47_1 = (upd c_Z47_0 p 1)),
  (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
  (((* I1 *)
    (forall (x:((pointer) Z47)),
     ((reachable l_Z47 r_Z47 alloc root x) ->
      (reachable l_Z47_1 r_Z47_1 alloc t0 x) \/
      (reachable l_Z47_1 r_Z47_1 alloc p x))) /\
  (* I2 *)
  (forall (x:((pointer) Z47)),
   (~(x = null) ->
    ((reachable l_Z47_1 r_Z47_1 alloc t0 x) \/
     (reachable l_Z47_1 r_Z47_1 alloc p x) ->
     (reachable l_Z47 r_Z47 alloc root x))))) /\
  (* I0 *)
  (exists stack:plist,
   (((((* I3 *) (clr_list c_Z47_1 l_Z47_1 r_Z47_1 alloc p stack) /\
   (* I4 *)
   (forall (p_0:((pointer) Z53)),
    ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
   (* I5 *)
   (forall (x:((pointer) Z47)),
    (((valid alloc x) /\ (reachable l_Z47 r_Z47 alloc root x)) /\
     (acc m_Z47_0 x) = 0 ->
     (unmarked_reachable m_Z47_0 l_Z47_1 r_Z47_1 alloc t0 x) \/
     (exists y:((pointer) Z53), (in_list y stack) /\
      (unmarked_reachable m_Z47_0 l_Z47_1 r_Z47_1 alloc (acc r_Z53 y) x))))) /\
   (* I6 *)
   (forall (x:((pointer) Z53)),
    (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
     (acc l_Z53 x) = (acc l_Z53 x)))) /\
   (* I7 *)
   (forall (p1:((pointer) Z47)),
    (forall (p2:((pointer) Z51)),
     ((pair_in_list p1 p2 (cons t0 stack)) ->
      (((acc c_Z51 p2) <> 0 -> (acc l_Z51 p2) = (acc l_Z51 p2) /\
        (acc r_Z51 p2) = p1)) /\
      (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
        (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
   (* I8 *)
   (forall (x:((pointer) Z47)),
    (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) = (acc m_Z47 x))))) /\
  (order_mark_m_and_c_and_stack (weight c_Z47_1 m_Z47_0 l_Z47_1 r_Z47_1 alloc
                                 p t0)
   (weight c_Z47_0 m_Z47_0 l_Z47_0 r_Z47_0 alloc p t)).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_17 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_18: ~(t = null)),
  forall (result: Z),
  forall (HW_19: result = (acc m_Z47_0 t)),
  forall (HW_20: result <> 0),
  forall (result0: Z),
  forall (HW_21: result0 = (acc c_Z47_0 p)),
  forall (HW_27: result0 = 0),
  forall (result1: ((pointer) Z47)),
  forall (HW_28: result1 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_29: t0 = result1),
  forall (result2: ((pointer) Z47)),
  forall (HW_30: result2 = (acc l_Z47_0 p)),
  forall (r_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_31: r_Z47_1 = (upd r_Z47_0 p result2)),
  forall (l_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_32: l_Z47_1 = (upd l_Z47_0 p t)),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_18 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_18: ~(t = null)),
  forall (result: Z),
  forall (HW_19: result = (acc m_Z47_0 t)),
  forall (HW_20: result <> 0),
  forall (result0: Z),
  forall (HW_21: result0 = (acc c_Z47_0 p)),
  forall (HW_27: result0 = 0),
  forall (result1: ((pointer) Z47)),
  forall (HW_28: result1 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_29: t0 = result1),
  forall (result2: ((pointer) Z47)),
  forall (HW_30: result2 = (acc l_Z47_0 p)),
  forall (r_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_31: r_Z47_1 = (upd r_Z47_0 p result2)),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_19 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_18: ~(t = null)),
  forall (result: Z),
  forall (HW_19: result = (acc m_Z47_0 t)),
  forall (HW_20: result <> 0),
  forall (result0: Z),
  forall (HW_21: result0 = (acc c_Z47_0 p)),
  forall (HW_27: result0 = 0),
  forall (result1: ((pointer) Z47)),
  forall (HW_28: result1 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_29: t0 = result1),
  forall (result2: ((pointer) Z47)),
  forall (HW_30: result2 = (acc l_Z47_0 p)),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_20 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_18: ~(t = null)),
  forall (result: Z),
  forall (HW_19: result = (acc m_Z47_0 t)),
  forall (HW_20: result <> 0),
  forall (result0: Z),
  forall (HW_21: result0 = (acc c_Z47_0 p)),
  forall (HW_27: result0 = 0),
  forall (result1: ((pointer) Z47)),
  forall (HW_28: result1 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_29: t0 = result1),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_21 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_18: ~(t = null)),
  forall (result: Z),
  forall (HW_19: result = (acc m_Z47_0 t)),
  forall (HW_20: result <> 0),
  forall (result0: Z),
  forall (HW_21: result0 = (acc c_Z47_0 p)),
  forall (HW_27: result0 = 0),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_22 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_18: ~(t = null)),
  forall (result: Z),
  forall (HW_19: result = (acc m_Z47_0 t)),
  forall (HW_20: result <> 0),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_23 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_18: ~(t = null)),
  forall (result: Z),
  forall (HW_19: result = (acc m_Z47_0 t)),
  forall (HW_34: result = 0),
  forall (p0: ((pointer) Z47)),
  forall (HW_35: p0 = t),
  forall (result0: ((pointer) Z47)),
  forall (HW_36: result0 = (acc l_Z47_0 t)),
  forall (t0: ((pointer) Z47)),
  forall (HW_37: t0 = result0),
  forall (l_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_38: l_Z47_1 = (upd l_Z47_0 p0 p)),
  forall (m_Z47_1: ((memory) Z Z47)),
  forall (HW_39: m_Z47_1 = (upd m_Z47_0 p0 1)),
  forall (c_Z47_1: ((memory) Z Z47)),
  forall (HW_40: c_Z47_1 = (upd c_Z47_0 p0 0)),
  (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
  (((* I1 *)
    (forall (x:((pointer) Z47)),
     ((reachable l_Z47 r_Z47 alloc root x) ->
      (reachable l_Z47_1 r_Z47_0 alloc t0 x) \/
      (reachable l_Z47_1 r_Z47_0 alloc p0 x))) /\
  (* I2 *)
  (forall (x:((pointer) Z47)),
   (~(x = null) ->
    ((reachable l_Z47_1 r_Z47_0 alloc t0 x) \/
     (reachable l_Z47_1 r_Z47_0 alloc p0 x) ->
     (reachable l_Z47 r_Z47 alloc root x))))) /\
  (* I0 *)
  (exists stack:plist,
   (((((* I3 *) (clr_list c_Z47_1 l_Z47_1 r_Z47_0 alloc p0 stack) /\
   (* I4 *)
   (forall (p_0:((pointer) Z53)),
    ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
   (* I5 *)
   (forall (x:((pointer) Z47)),
    (((valid alloc x) /\ (reachable l_Z47 r_Z47 alloc root x)) /\
     (acc m_Z47_1 x) = 0 ->
     (unmarked_reachable m_Z47_1 l_Z47_1 r_Z47_0 alloc t0 x) \/
     (exists y:((pointer) Z53), (in_list y stack) /\
      (unmarked_reachable m_Z47_1 l_Z47_1 r_Z47_0 alloc (acc r_Z53 y) x))))) /\
   (* I6 *)
   (forall (x:((pointer) Z53)),
    (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
     (acc l_Z53 x) = (acc l_Z53 x)))) /\
   (* I7 *)
   (forall (p1:((pointer) Z47)),
    (forall (p2:((pointer) Z51)),
     ((pair_in_list p1 p2 (cons t0 stack)) ->
      (((acc c_Z51 p2) <> 0 -> (acc l_Z51 p2) = (acc l_Z51 p2) /\
        (acc r_Z51 p2) = p1)) /\
      (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
        (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
   (* I8 *)
   (forall (x:((pointer) Z47)),
    (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_1 x) = (acc m_Z47 x))))) /\
  (order_mark_m_and_c_and_stack (weight c_Z47_1 m_Z47_1 l_Z47_1 r_Z47_0 alloc
                                 p0 t0)
   (weight c_Z47_0 m_Z47_0 l_Z47_0 r_Z47_0 alloc p t)).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_24 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_18: ~(t = null)),
  forall (result: Z),
  forall (HW_19: result = (acc m_Z47_0 t)),
  forall (HW_34: result = 0),
  forall (p0: ((pointer) Z47)),
  forall (HW_35: p0 = t),
  forall (result0: ((pointer) Z47)),
  forall (HW_36: result0 = (acc l_Z47_0 t)),
  forall (t0: ((pointer) Z47)),
  forall (HW_37: t0 = result0),
  forall (l_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_38: l_Z47_1 = (upd l_Z47_0 p0 p)),
  forall (m_Z47_1: ((memory) Z Z47)),
  forall (HW_39: m_Z47_1 = (upd m_Z47_0 p0 1)),
  (valid alloc p0).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_25 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_18: ~(t = null)),
  forall (result: Z),
  forall (HW_19: result = (acc m_Z47_0 t)),
  forall (HW_34: result = 0),
  forall (p0: ((pointer) Z47)),
  forall (HW_35: p0 = t),
  forall (result0: ((pointer) Z47)),
  forall (HW_36: result0 = (acc l_Z47_0 t)),
  forall (t0: ((pointer) Z47)),
  forall (HW_37: t0 = result0),
  forall (l_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_38: l_Z47_1 = (upd l_Z47_0 p0 p)),
  (valid alloc p0).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_26 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_18: ~(t = null)),
  forall (result: Z),
  forall (HW_19: result = (acc m_Z47_0 t)),
  forall (HW_34: result = 0),
  forall (p0: ((pointer) Z47)),
  forall (HW_35: p0 = t),
  forall (result0: ((pointer) Z47)),
  forall (HW_36: result0 = (acc l_Z47_0 t)),
  forall (t0: ((pointer) Z47)),
  forall (HW_37: t0 = result0),
  (valid alloc p0).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_27 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_18: ~(t = null)),
  forall (result: Z),
  forall (HW_19: result = (acc m_Z47_0 t)),
  forall (HW_34: result = 0),
  forall (p0: ((pointer) Z47)),
  forall (HW_35: p0 = t),
  (valid alloc t).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_28 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_3: ~(p = null)),
  forall (HW_18: ~(t = null)),
  (valid alloc t).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_29 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z41: ((memory) ((pointer) Z47) Z41)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z41: ((memory) ((pointer) Z47) Z41)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_44: result <> 0),
  (* File \"schorr_waite.c\", line 63, characters 5-202:\n *)
  (((forall (x:((pointer) Z41)), (acc l_Z41 x) = (acc l_Z41 x) /\
     (acc r_Z41 x) = (acc r_Z41 x)) /\
  (forall (x:((pointer) Z47)),
   ((valid alloc x) /\ (reachable l_Z47_0 r_Z47_0 alloc root x) ->
    (acc m_Z47_0 x) <> 0))) /\
  (forall (x:((pointer) Z47)),
   (~(reachable l_Z47_0 r_Z47_0 alloc root x) -> (acc m_Z47_0 x) =
    (acc m_Z47 x)))).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_30 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_46: t = null),
  forall (result0: Z),
  forall (HW_47: result0 = (acc c_Z47_0 p)),
  forall (HW_48: result0 <> 0),
  forall (t0: ((pointer) Z47)),
  forall (HW_49: t0 = p),
  forall (result1: ((pointer) Z47)),
  forall (HW_50: result1 = (acc r_Z47_0 p)),
  forall (p0: ((pointer) Z47)),
  forall (HW_51: p0 = result1),
  forall (r_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_52: r_Z47_1 = (upd r_Z47_0 t0 t)),
  (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
  (((* I1 *)
    (forall (x:((pointer) Z47)),
     ((reachable l_Z47 r_Z47 alloc root x) ->
      (reachable l_Z47_0 r_Z47_1 alloc t0 x) \/
      (reachable l_Z47_0 r_Z47_1 alloc p0 x))) /\
  (* I2 *)
  (forall (x:((pointer) Z47)),
   (~(x = null) ->
    ((reachable l_Z47_0 r_Z47_1 alloc t0 x) \/
     (reachable l_Z47_0 r_Z47_1 alloc p0 x) ->
     (reachable l_Z47 r_Z47 alloc root x))))) /\
  (* I0 *)
  (exists stack:plist,
   (((((* I3 *) (clr_list c_Z47_0 l_Z47_0 r_Z47_1 alloc p0 stack) /\
   (* I4 *)
   (forall (p_0:((pointer) Z53)),
    ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
   (* I5 *)
   (forall (x:((pointer) Z47)),
    (((valid alloc x) /\ (reachable l_Z47 r_Z47 alloc root x)) /\
     (acc m_Z47_0 x) = 0 ->
     (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_1 alloc t0 x) \/
     (exists y:((pointer) Z53), (in_list y stack) /\
      (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_1 alloc (acc r_Z53 y) x))))) /\
   (* I6 *)
   (forall (x:((pointer) Z53)),
    (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
     (acc l_Z53 x) = (acc l_Z53 x)))) /\
   (* I7 *)
   (forall (p1:((pointer) Z47)),
    (forall (p2:((pointer) Z51)),
     ((pair_in_list p1 p2 (cons t0 stack)) ->
      (((acc c_Z51 p2) <> 0 -> (acc l_Z51 p2) = (acc l_Z51 p2) /\
        (acc r_Z51 p2) = p1)) /\
      (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
        (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
   (* I8 *)
   (forall (x:((pointer) Z47)),
    (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) = (acc m_Z47 x))))) /\
  (order_mark_m_and_c_and_stack (weight c_Z47_0 m_Z47_0 l_Z47_0 r_Z47_1 alloc
                                 p0 t0)
   (weight c_Z47_0 m_Z47_0 l_Z47_0 r_Z47_0 alloc p t)).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_31 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_46: t = null),
  forall (result0: Z),
  forall (HW_47: result0 = (acc c_Z47_0 p)),
  forall (HW_48: result0 <> 0),
  forall (t0: ((pointer) Z47)),
  forall (HW_49: t0 = p),
  forall (result1: ((pointer) Z47)),
  forall (HW_50: result1 = (acc r_Z47_0 p)),
  forall (p0: ((pointer) Z47)),
  forall (HW_51: p0 = result1),
  (valid alloc t0).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_32 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_46: t = null),
  forall (result0: Z),
  forall (HW_47: result0 = (acc c_Z47_0 p)),
  forall (HW_48: result0 <> 0),
  forall (t0: ((pointer) Z47)),
  forall (HW_49: t0 = p),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_33 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_46: t = null),
  forall (result0: Z),
  forall (HW_47: result0 = (acc c_Z47_0 p)),
  forall (HW_53: result0 = 0),
  forall (result1: ((pointer) Z47)),
  forall (HW_54: result1 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_55: t0 = result1),
  forall (result2: ((pointer) Z47)),
  forall (HW_56: result2 = (acc l_Z47_0 p)),
  forall (r_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_57: r_Z47_1 = (upd r_Z47_0 p result2)),
  forall (l_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_58: l_Z47_1 = (upd l_Z47_0 p t)),
  forall (c_Z47_1: ((memory) Z Z47)),
  forall (HW_59: c_Z47_1 = (upd c_Z47_0 p 1)),
  (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
  (((* I1 *)
    (forall (x:((pointer) Z47)),
     ((reachable l_Z47 r_Z47 alloc root x) ->
      (reachable l_Z47_1 r_Z47_1 alloc t0 x) \/
      (reachable l_Z47_1 r_Z47_1 alloc p x))) /\
  (* I2 *)
  (forall (x:((pointer) Z47)),
   (~(x = null) ->
    ((reachable l_Z47_1 r_Z47_1 alloc t0 x) \/
     (reachable l_Z47_1 r_Z47_1 alloc p x) ->
     (reachable l_Z47 r_Z47 alloc root x))))) /\
  (* I0 *)
  (exists stack:plist,
   (((((* I3 *) (clr_list c_Z47_1 l_Z47_1 r_Z47_1 alloc p stack) /\
   (* I4 *)
   (forall (p_0:((pointer) Z53)),
    ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
   (* I5 *)
   (forall (x:((pointer) Z47)),
    (((valid alloc x) /\ (reachable l_Z47 r_Z47 alloc root x)) /\
     (acc m_Z47_0 x) = 0 ->
     (unmarked_reachable m_Z47_0 l_Z47_1 r_Z47_1 alloc t0 x) \/
     (exists y:((pointer) Z53), (in_list y stack) /\
      (unmarked_reachable m_Z47_0 l_Z47_1 r_Z47_1 alloc (acc r_Z53 y) x))))) /\
   (* I6 *)
   (forall (x:((pointer) Z53)),
    (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
     (acc l_Z53 x) = (acc l_Z53 x)))) /\
   (* I7 *)
   (forall (p1:((pointer) Z47)),
    (forall (p2:((pointer) Z51)),
     ((pair_in_list p1 p2 (cons t0 stack)) ->
      (((acc c_Z51 p2) <> 0 -> (acc l_Z51 p2) = (acc l_Z51 p2) /\
        (acc r_Z51 p2) = p1)) /\
      (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
        (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
   (* I8 *)
   (forall (x:((pointer) Z47)),
    (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) = (acc m_Z47 x))))) /\
  (order_mark_m_and_c_and_stack (weight c_Z47_1 m_Z47_0 l_Z47_1 r_Z47_1 alloc
                                 p t0)
   (weight c_Z47_0 m_Z47_0 l_Z47_0 r_Z47_0 alloc p t)).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_34 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_46: t = null),
  forall (result0: Z),
  forall (HW_47: result0 = (acc c_Z47_0 p)),
  forall (HW_53: result0 = 0),
  forall (result1: ((pointer) Z47)),
  forall (HW_54: result1 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_55: t0 = result1),
  forall (result2: ((pointer) Z47)),
  forall (HW_56: result2 = (acc l_Z47_0 p)),
  forall (r_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_57: r_Z47_1 = (upd r_Z47_0 p result2)),
  forall (l_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_58: l_Z47_1 = (upd l_Z47_0 p t)),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_35 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_46: t = null),
  forall (result0: Z),
  forall (HW_47: result0 = (acc c_Z47_0 p)),
  forall (HW_53: result0 = 0),
  forall (result1: ((pointer) Z47)),
  forall (HW_54: result1 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_55: t0 = result1),
  forall (result2: ((pointer) Z47)),
  forall (HW_56: result2 = (acc l_Z47_0 p)),
  forall (r_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_57: r_Z47_1 = (upd r_Z47_0 p result2)),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_36 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_46: t = null),
  forall (result0: Z),
  forall (HW_47: result0 = (acc c_Z47_0 p)),
  forall (HW_53: result0 = 0),
  forall (result1: ((pointer) Z47)),
  forall (HW_54: result1 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_55: t0 = result1),
  forall (result2: ((pointer) Z47)),
  forall (HW_56: result2 = (acc l_Z47_0 p)),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_37 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_46: t = null),
  forall (result0: Z),
  forall (HW_47: result0 = (acc c_Z47_0 p)),
  forall (HW_53: result0 = 0),
  forall (result1: ((pointer) Z47)),
  forall (HW_54: result1 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_55: t0 = result1),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_38 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_46: t = null),
  forall (result0: Z),
  forall (HW_47: result0 = (acc c_Z47_0 p)),
  forall (HW_53: result0 = 0),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_39 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_46: t = null),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_40 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_60: ~(t = null)),
  forall (result0: Z),
  forall (HW_61: result0 = (acc m_Z47_0 t)),
  forall (HW_62: result0 <> 0),
  forall (result1: Z),
  forall (HW_63: result1 = (acc c_Z47_0 p)),
  forall (HW_64: result1 <> 0),
  forall (t0: ((pointer) Z47)),
  forall (HW_65: t0 = p),
  forall (result2: ((pointer) Z47)),
  forall (HW_66: result2 = (acc r_Z47_0 p)),
  forall (p0: ((pointer) Z47)),
  forall (HW_67: p0 = result2),
  forall (r_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_68: r_Z47_1 = (upd r_Z47_0 t0 t)),
  (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
  (((* I1 *)
    (forall (x:((pointer) Z47)),
     ((reachable l_Z47 r_Z47 alloc root x) ->
      (reachable l_Z47_0 r_Z47_1 alloc t0 x) \/
      (reachable l_Z47_0 r_Z47_1 alloc p0 x))) /\
  (* I2 *)
  (forall (x:((pointer) Z47)),
   (~(x = null) ->
    ((reachable l_Z47_0 r_Z47_1 alloc t0 x) \/
     (reachable l_Z47_0 r_Z47_1 alloc p0 x) ->
     (reachable l_Z47 r_Z47 alloc root x))))) /\
  (* I0 *)
  (exists stack:plist,
   (((((* I3 *) (clr_list c_Z47_0 l_Z47_0 r_Z47_1 alloc p0 stack) /\
   (* I4 *)
   (forall (p_0:((pointer) Z53)),
    ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
   (* I5 *)
   (forall (x:((pointer) Z47)),
    (((valid alloc x) /\ (reachable l_Z47 r_Z47 alloc root x)) /\
     (acc m_Z47_0 x) = 0 ->
     (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_1 alloc t0 x) \/
     (exists y:((pointer) Z53), (in_list y stack) /\
      (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_1 alloc (acc r_Z53 y) x))))) /\
   (* I6 *)
   (forall (x:((pointer) Z53)),
    (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
     (acc l_Z53 x) = (acc l_Z53 x)))) /\
   (* I7 *)
   (forall (p1:((pointer) Z47)),
    (forall (p2:((pointer) Z51)),
     ((pair_in_list p1 p2 (cons t0 stack)) ->
      (((acc c_Z51 p2) <> 0 -> (acc l_Z51 p2) = (acc l_Z51 p2) /\
        (acc r_Z51 p2) = p1)) /\
      (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
        (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
   (* I8 *)
   (forall (x:((pointer) Z47)),
    (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) = (acc m_Z47 x))))) /\
  (order_mark_m_and_c_and_stack (weight c_Z47_0 m_Z47_0 l_Z47_0 r_Z47_1 alloc
                                 p0 t0)
   (weight c_Z47_0 m_Z47_0 l_Z47_0 r_Z47_0 alloc p t)).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_41 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_60: ~(t = null)),
  forall (result0: Z),
  forall (HW_61: result0 = (acc m_Z47_0 t)),
  forall (HW_62: result0 <> 0),
  forall (result1: Z),
  forall (HW_63: result1 = (acc c_Z47_0 p)),
  forall (HW_64: result1 <> 0),
  forall (t0: ((pointer) Z47)),
  forall (HW_65: t0 = p),
  forall (result2: ((pointer) Z47)),
  forall (HW_66: result2 = (acc r_Z47_0 p)),
  forall (p0: ((pointer) Z47)),
  forall (HW_67: p0 = result2),
  (valid alloc t0).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_42 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_60: ~(t = null)),
  forall (result0: Z),
  forall (HW_61: result0 = (acc m_Z47_0 t)),
  forall (HW_62: result0 <> 0),
  forall (result1: Z),
  forall (HW_63: result1 = (acc c_Z47_0 p)),
  forall (HW_64: result1 <> 0),
  forall (t0: ((pointer) Z47)),
  forall (HW_65: t0 = p),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_43 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_60: ~(t = null)),
  forall (result0: Z),
  forall (HW_61: result0 = (acc m_Z47_0 t)),
  forall (HW_62: result0 <> 0),
  forall (result1: Z),
  forall (HW_63: result1 = (acc c_Z47_0 p)),
  forall (HW_69: result1 = 0),
  forall (result2: ((pointer) Z47)),
  forall (HW_70: result2 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_71: t0 = result2),
  forall (result3: ((pointer) Z47)),
  forall (HW_72: result3 = (acc l_Z47_0 p)),
  forall (r_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_73: r_Z47_1 = (upd r_Z47_0 p result3)),
  forall (l_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_74: l_Z47_1 = (upd l_Z47_0 p t)),
  forall (c_Z47_1: ((memory) Z Z47)),
  forall (HW_75: c_Z47_1 = (upd c_Z47_0 p 1)),
  (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
  (((* I1 *)
    (forall (x:((pointer) Z47)),
     ((reachable l_Z47 r_Z47 alloc root x) ->
      (reachable l_Z47_1 r_Z47_1 alloc t0 x) \/
      (reachable l_Z47_1 r_Z47_1 alloc p x))) /\
  (* I2 *)
  (forall (x:((pointer) Z47)),
   (~(x = null) ->
    ((reachable l_Z47_1 r_Z47_1 alloc t0 x) \/
     (reachable l_Z47_1 r_Z47_1 alloc p x) ->
     (reachable l_Z47 r_Z47 alloc root x))))) /\
  (* I0 *)
  (exists stack:plist,
   (((((* I3 *) (clr_list c_Z47_1 l_Z47_1 r_Z47_1 alloc p stack) /\
   (* I4 *)
   (forall (p_0:((pointer) Z53)),
    ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
   (* I5 *)
   (forall (x:((pointer) Z47)),
    (((valid alloc x) /\ (reachable l_Z47 r_Z47 alloc root x)) /\
     (acc m_Z47_0 x) = 0 ->
     (unmarked_reachable m_Z47_0 l_Z47_1 r_Z47_1 alloc t0 x) \/
     (exists y:((pointer) Z53), (in_list y stack) /\
      (unmarked_reachable m_Z47_0 l_Z47_1 r_Z47_1 alloc (acc r_Z53 y) x))))) /\
   (* I6 *)
   (forall (x:((pointer) Z53)),
    (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
     (acc l_Z53 x) = (acc l_Z53 x)))) /\
   (* I7 *)
   (forall (p1:((pointer) Z47)),
    (forall (p2:((pointer) Z51)),
     ((pair_in_list p1 p2 (cons t0 stack)) ->
      (((acc c_Z51 p2) <> 0 -> (acc l_Z51 p2) = (acc l_Z51 p2) /\
        (acc r_Z51 p2) = p1)) /\
      (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
        (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
   (* I8 *)
   (forall (x:((pointer) Z47)),
    (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) = (acc m_Z47 x))))) /\
  (order_mark_m_and_c_and_stack (weight c_Z47_1 m_Z47_0 l_Z47_1 r_Z47_1 alloc
                                 p t0)
   (weight c_Z47_0 m_Z47_0 l_Z47_0 r_Z47_0 alloc p t)).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_44 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_60: ~(t = null)),
  forall (result0: Z),
  forall (HW_61: result0 = (acc m_Z47_0 t)),
  forall (HW_62: result0 <> 0),
  forall (result1: Z),
  forall (HW_63: result1 = (acc c_Z47_0 p)),
  forall (HW_69: result1 = 0),
  forall (result2: ((pointer) Z47)),
  forall (HW_70: result2 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_71: t0 = result2),
  forall (result3: ((pointer) Z47)),
  forall (HW_72: result3 = (acc l_Z47_0 p)),
  forall (r_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_73: r_Z47_1 = (upd r_Z47_0 p result3)),
  forall (l_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_74: l_Z47_1 = (upd l_Z47_0 p t)),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_45 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_60: ~(t = null)),
  forall (result0: Z),
  forall (HW_61: result0 = (acc m_Z47_0 t)),
  forall (HW_62: result0 <> 0),
  forall (result1: Z),
  forall (HW_63: result1 = (acc c_Z47_0 p)),
  forall (HW_69: result1 = 0),
  forall (result2: ((pointer) Z47)),
  forall (HW_70: result2 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_71: t0 = result2),
  forall (result3: ((pointer) Z47)),
  forall (HW_72: result3 = (acc l_Z47_0 p)),
  forall (r_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_73: r_Z47_1 = (upd r_Z47_0 p result3)),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_46 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_60: ~(t = null)),
  forall (result0: Z),
  forall (HW_61: result0 = (acc m_Z47_0 t)),
  forall (HW_62: result0 <> 0),
  forall (result1: Z),
  forall (HW_63: result1 = (acc c_Z47_0 p)),
  forall (HW_69: result1 = 0),
  forall (result2: ((pointer) Z47)),
  forall (HW_70: result2 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_71: t0 = result2),
  forall (result3: ((pointer) Z47)),
  forall (HW_72: result3 = (acc l_Z47_0 p)),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_47 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_60: ~(t = null)),
  forall (result0: Z),
  forall (HW_61: result0 = (acc m_Z47_0 t)),
  forall (HW_62: result0 <> 0),
  forall (result1: Z),
  forall (HW_63: result1 = (acc c_Z47_0 p)),
  forall (HW_69: result1 = 0),
  forall (result2: ((pointer) Z47)),
  forall (HW_70: result2 = (acc r_Z47_0 p)),
  forall (t0: ((pointer) Z47)),
  forall (HW_71: t0 = result2),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_48 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_60: ~(t = null)),
  forall (result0: Z),
  forall (HW_61: result0 = (acc m_Z47_0 t)),
  forall (HW_62: result0 <> 0),
  forall (result1: Z),
  forall (HW_63: result1 = (acc c_Z47_0 p)),
  forall (HW_69: result1 = 0),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_49 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_60: ~(t = null)),
  forall (result0: Z),
  forall (HW_61: result0 = (acc m_Z47_0 t)),
  forall (HW_62: result0 <> 0),
  (valid alloc p).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_50 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_60: ~(t = null)),
  forall (result0: Z),
  forall (HW_61: result0 = (acc m_Z47_0 t)),
  forall (HW_76: result0 = 0),
  forall (p0: ((pointer) Z47)),
  forall (HW_77: p0 = t),
  forall (result1: ((pointer) Z47)),
  forall (HW_78: result1 = (acc l_Z47_0 t)),
  forall (t0: ((pointer) Z47)),
  forall (HW_79: t0 = result1),
  forall (l_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_80: l_Z47_1 = (upd l_Z47_0 p0 p)),
  forall (m_Z47_1: ((memory) Z Z47)),
  forall (HW_81: m_Z47_1 = (upd m_Z47_0 p0 1)),
  forall (c_Z47_1: ((memory) Z Z47)),
  forall (HW_82: c_Z47_1 = (upd c_Z47_0 p0 0)),
  (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
  (((* I1 *)
    (forall (x:((pointer) Z47)),
     ((reachable l_Z47 r_Z47 alloc root x) ->
      (reachable l_Z47_1 r_Z47_0 alloc t0 x) \/
      (reachable l_Z47_1 r_Z47_0 alloc p0 x))) /\
  (* I2 *)
  (forall (x:((pointer) Z47)),
   (~(x = null) ->
    ((reachable l_Z47_1 r_Z47_0 alloc t0 x) \/
     (reachable l_Z47_1 r_Z47_0 alloc p0 x) ->
     (reachable l_Z47 r_Z47 alloc root x))))) /\
  (* I0 *)
  (exists stack:plist,
   (((((* I3 *) (clr_list c_Z47_1 l_Z47_1 r_Z47_0 alloc p0 stack) /\
   (* I4 *)
   (forall (p_0:((pointer) Z53)),
    ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
   (* I5 *)
   (forall (x:((pointer) Z47)),
    (((valid alloc x) /\ (reachable l_Z47 r_Z47 alloc root x)) /\
     (acc m_Z47_1 x) = 0 ->
     (unmarked_reachable m_Z47_1 l_Z47_1 r_Z47_0 alloc t0 x) \/
     (exists y:((pointer) Z53), (in_list y stack) /\
      (unmarked_reachable m_Z47_1 l_Z47_1 r_Z47_0 alloc (acc r_Z53 y) x))))) /\
   (* I6 *)
   (forall (x:((pointer) Z53)),
    (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
     (acc l_Z53 x) = (acc l_Z53 x)))) /\
   (* I7 *)
   (forall (p1:((pointer) Z47)),
    (forall (p2:((pointer) Z51)),
     ((pair_in_list p1 p2 (cons t0 stack)) ->
      (((acc c_Z51 p2) <> 0 -> (acc l_Z51 p2) = (acc l_Z51 p2) /\
        (acc r_Z51 p2) = p1)) /\
      (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
        (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
   (* I8 *)
   (forall (x:((pointer) Z47)),
    (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_1 x) = (acc m_Z47 x))))) /\
  (order_mark_m_and_c_and_stack (weight c_Z47_1 m_Z47_1 l_Z47_1 r_Z47_0 alloc
                                 p0 t0)
   (weight c_Z47_0 m_Z47_0 l_Z47_0 r_Z47_0 alloc p t)).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_51 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_60: ~(t = null)),
  forall (result0: Z),
  forall (HW_61: result0 = (acc m_Z47_0 t)),
  forall (HW_76: result0 = 0),
  forall (p0: ((pointer) Z47)),
  forall (HW_77: p0 = t),
  forall (result1: ((pointer) Z47)),
  forall (HW_78: result1 = (acc l_Z47_0 t)),
  forall (t0: ((pointer) Z47)),
  forall (HW_79: t0 = result1),
  forall (l_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_80: l_Z47_1 = (upd l_Z47_0 p0 p)),
  forall (m_Z47_1: ((memory) Z Z47)),
  forall (HW_81: m_Z47_1 = (upd m_Z47_0 p0 1)),
  (valid alloc p0).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_52 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_60: ~(t = null)),
  forall (result0: Z),
  forall (HW_61: result0 = (acc m_Z47_0 t)),
  forall (HW_76: result0 = 0),
  forall (p0: ((pointer) Z47)),
  forall (HW_77: p0 = t),
  forall (result1: ((pointer) Z47)),
  forall (HW_78: result1 = (acc l_Z47_0 t)),
  forall (t0: ((pointer) Z47)),
  forall (HW_79: t0 = result1),
  forall (l_Z47_1: ((memory) ((pointer) Z47) Z47)),
  forall (HW_80: l_Z47_1 = (upd l_Z47_0 p0 p)),
  (valid alloc p0).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_53 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_60: ~(t = null)),
  forall (result0: Z),
  forall (HW_61: result0 = (acc m_Z47_0 t)),
  forall (HW_76: result0 = 0),
  forall (p0: ((pointer) Z47)),
  forall (HW_77: p0 = t),
  forall (result1: ((pointer) Z47)),
  forall (HW_78: result1 = (acc l_Z47_0 t)),
  forall (t0: ((pointer) Z47)),
  forall (HW_79: t0 = result1),
  (valid alloc p0).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_54 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_60: ~(t = null)),
  forall (result0: Z),
  forall (HW_61: result0 = (acc m_Z47_0 t)),
  forall (HW_76: result0 = 0),
  forall (p0: ((pointer) Z47)),
  forall (HW_77: p0 = t),
  (valid alloc t).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_55 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  forall (result: Z),
  forall (HW_43: result = (acc m_Z47_0 t)),
  forall (HW_45: result = 0),
  forall (HW_60: ~(t = null)),
  (valid alloc t).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_56 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_42: ~(t = null)),
  (valid alloc t).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

(* Why obligation from file "", line 0, characters 0-0: *)
(*Why goal*) Lemma schorr_waite_impl_po_57 : 
  forall (root: ((pointer) Z47)),
  forall (alloc: alloc_table),
  forall (c_Z51: ((memory) Z Z51)),
  forall (l_Z41: ((memory) ((pointer) Z47) Z41)),
  forall (l_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (l_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (l_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (m_Z47: ((memory) Z Z47)),
  forall (m_Z53: ((memory) Z Z53)),
  forall (r_Z41: ((memory) ((pointer) Z47) Z41)),
  forall (r_Z47: ((memory) ((pointer) Z47) Z47)),
  forall (r_Z51: ((memory) ((pointer) Z47) Z51)),
  forall (r_Z53: ((memory) ((pointer) Z47) Z53)),
  forall (HW_1: (* File \"schorr_waite.c\", line 59, characters 5-138:\n *)
                ((forall (x:((pointer) Z47)),
                  (~(x = null) /\ (reachable l_Z47 r_Z47 alloc root x) ->
                   (valid alloc x) /\ (acc m_Z47 x) = 0)) /\
                (exists l_0:plist,
                 (reachable_elements l_Z47 r_Z47 alloc root root l_0)))),
  forall (c_Z47_0: ((memory) Z Z47)),
  forall (l_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (m_Z47_0: ((memory) Z Z47)),
  forall (p: ((pointer) Z47)),
  forall (r_Z47_0: ((memory) ((pointer) Z47) Z47)),
  forall (t: ((pointer) Z47)),
  forall (HW_2: (* File \"schorr_waite.c\", line 75, characters 7-1023:\n *)
                (((* I1 *)
                  (forall (x:((pointer) Z47)),
                   ((reachable l_Z47 r_Z47 alloc root x) ->
                    (reachable l_Z47_0 r_Z47_0 alloc t x) \/
                    (reachable l_Z47_0 r_Z47_0 alloc p x))) /\
                (* I2 *)
                (forall (x:((pointer) Z47)),
                 (~(x = null) ->
                  ((reachable l_Z47_0 r_Z47_0 alloc t x) \/
                   (reachable l_Z47_0 r_Z47_0 alloc p x) ->
                   (reachable l_Z47 r_Z47 alloc root x))))) /\
                (* I0 *)
                (exists stack:plist,
                 (((((* I3 *)
                     (clr_list c_Z47_0 l_Z47_0 r_Z47_0 alloc p stack) /\
                 (* I4 *)
                 (forall (p_0:((pointer) Z53)),
                  ((in_list p_0 stack) -> (acc m_Z53 p_0) <> 0))) /\
                 (* I5 *)
                 (forall (x:((pointer) Z47)),
                  (((valid alloc x) /\
                   (reachable l_Z47 r_Z47 alloc root x)) /\ (acc m_Z47_0 x) =
                   0 ->
                   (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc t x) \/
                   (exists y:((pointer) Z53), (in_list y stack) /\
                    (unmarked_reachable m_Z47_0 l_Z47_0 r_Z47_0 alloc
                     (acc r_Z53 y) x))))) /\
                 (* I6 *)
                 (forall (x:((pointer) Z53)),
                  (~(in_list x stack) -> (acc r_Z53 x) = (acc r_Z53 x) /\
                   (acc l_Z53 x) = (acc l_Z53 x)))) /\
                 (* I7 *)
                 (forall (p1:((pointer) Z47)),
                  (forall (p2:((pointer) Z51)),
                   ((pair_in_list p1 p2 (cons t stack)) ->
                    (((acc c_Z51 p2) <> 0 ->
                      (acc l_Z51 p2) = (acc l_Z51 p2) /\ (acc r_Z51 p2) = p1)) /\
                    (((acc c_Z51 p2) = 0 -> (acc l_Z51 p2) = p1 /\
                      (acc r_Z51 p2) = (acc r_Z51 p2))))))) /\
                 (* I8 *)
                 (forall (x:((pointer) Z47)),
                  (~(reachable l_Z47 r_Z47 alloc root x) -> (acc m_Z47_0 x) =
                   (acc m_Z47 x)))))),
  forall (HW_41: p = null),
  forall (HW_83: t = null),
  (* File \"schorr_waite.c\", line 63, characters 5-202:\n *)
  (((forall (x:((pointer) Z41)), (acc l_Z41 x) = (acc l_Z41 x) /\
     (acc r_Z41 x) = (acc r_Z41 x)) /\
  (forall (x:((pointer) Z47)),
   ((valid alloc x) /\ (reachable l_Z47_0 r_Z47_0 alloc root x) ->
    (acc m_Z47_0 x) <> 0))) /\
  (forall (x:((pointer) Z47)),
   (~(reachable l_Z47_0 r_Z47_0 alloc root x) -> (acc m_Z47_0 x) =
    (acc m_Z47 x)))).
Proof.
intuition.
(* FILL PROOF HERE *)
Save.

