Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
Iris
c
Commits
69a792f0
Commit
69a792f0
authored
Apr 23, 2018
by
Dan Frumin
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of gitlab.science.ru.nl:lgg/iris-c-monad
parents
0672696e
644307d8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
9 deletions
+12
-9
theories/c_translation/monad.v
theories/c_translation/monad.v
+12
-9
No files found.
theories/c_translation/monad.v
View file @
69a792f0
...
...
@@ -78,17 +78,20 @@ Section a_wp.
WP
a_run
v
{{
Φ
}}.
Proof
.
iIntros
"HR Hwp"
.
rewrite
/
a_run
/=.
wp_let
.
wp_let
.
wp_alloc
env
.
wp_let
.
(*
wp_apply (newlock_cancel_spec R with "[$]").
iIntros (k γ') "Hlock". wp_let. iApply wp_fupd.
iApply (wp_wand with "[Hwp Hlock]"); first by iApply "Hwp".
wp_bind
(
newset
#()).
iApply
set_newset_spec
.
done
.
iNext
.
iIntros
(
v0
)
"%"
.
wp_alloc
env
as
"H"
.
wp_let
.
wp_apply
(
newlock_cancel_spec
(
env_inv
#
env
∗
R
)%
I
with
"[H HR]"
).
iFrame
.
iExists
∅
.
iExists
env
,
v0
.
iFrame
.
done
.
iIntros
(
k
γ
'
)
"Hlock"
.
wp_let
.
rewrite
-
wp_fupd
.
iApply
(
wp_wand
with
"[Hwp Hlock]"
).
unfold
awp
.
iApply
(
"Hwp"
with
"Hlock"
).
iIntros
(
w
)
"[HΦ Hlock]"
.
i
Mod (cancel_lock with "Hlock") as
"H
R
".
by iApply "HΦ"
.
i
Apply
"H
Φ
"
.
iMod
(
cancel_lock
with
"Hlock"
)
as
"[HEnv HR]"
.
done
.
Qed
.
*)
Admitted
.
Lemma
awp_atomic
(
v
:
val
)
R
Φ
`
{
Timeless
_
R
}
:
(
R
-
∗
∃
R'
,
⌜
Timeless
R'
⌝
∧
R'
∗
awp
v
R'
(
λ
w
,
R'
-
∗
R
∗
Φ
w
))
-
∗
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment