(** Load-store properties. *)

(* Specifications: *)
Axiom load_store_similar:
forall chunk m1 b ofs v m2, store chunk m1 b ofs v = Some m2 ->
forall chunk',
size_chunk chunk' = size_chunk chunk ->
align_chunk chunk' <= align_chunk chunk ->
exists v', load chunk' m2 b ofs = Some v' /\ decode_encode_val v chunk chunk' v'.
Axiom load_store_same:
forall chunk m1 b ofs v m2, store chunk m1 b ofs v = Some m2 ->
load chunk m2 b ofs = Some (Val.load_result chunk v).
Axiom load_store_other:
forall chunk m1 b ofs v m2, store chunk m1 b ofs v = Some m2 ->
forall chunk' b' ofs',
b' <> b
\/ ofs' + size_chunk chunk' <= ofs
\/ ofs + size_chunk chunk <= ofs' ->
load chunk' m2 b' ofs' = load chunk' m1 b' ofs'.
Axiom loadbytes_storebytes_same:
forall m1 b ofs bytes m2, storebytes m1 b ofs bytes = Some m2 ->
loadbytes m2 b ofs (Z.of_nat (length bytes)) = Some bytes.
Axiom loadbytes_storebytes_other:
forall m1 b ofs bytes m2, storebytes m1 b ofs bytes = Some m2 ->
forall b' ofs' len,
len >= 0 ->
b' <> b
\/ ofs' + len <= ofs
\/ ofs + Z.of_nat (length bytes) <= ofs' ->
loadbytes m2 b' ofs' len = loadbytes m1 b' ofs' len.
Axiom load_storebytes_other:
forall m1 b ofs bytes m2, storebytes m1 b ofs bytes = Some m2 ->
forall chunk b' ofs',
b' <> b
\/ ofs' + size_chunk chunk <= ofs
\/ ofs + Z.of_nat (length bytes) <= ofs' ->
load chunk m2 b' ofs' = load chunk m1 b' ofs'.