(*! Instantiation of modules *)
Set Bullet Behavior "Strict Subproofs".
(** * join_all and permutations *)
Section Machine.
Context {ge : Clight.genv}.
Definition getLocksR (tp : jstate ge) := listoption_inv (map snd (AMap.elements (lset tp))).
Definition maps tp := (getThreadsR tp ++ getLocksR tp)%list.

(** * Results about handling threads' rmaps *)
Lemma seq_pmap_decent {A B} (f : A -> option B) l :
seq.pmap f l = listoption_inv (map f l).