Ltac dsepcon :=
match goal with
  [ H : sepcon _ _ _ |- _ ] =>
  let s1 := fresh "s" in
    let s2 := fresh "s" in
      let JOIN := fresh "JOIN" in
        let H1 := fresh "H" in
          let H2 := fresh "H" in
      destruct H as [s1 [s2 [JOIN [H1 H2]]]]
end.

Lemma join_stacks_eq : forall s0 s1 s : state, join s0 s1 s -> stk s0=stk s1 /\ stk s0=stk s.