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
George Pirlea
Iris
Commits
3bed085d
Commit
3bed085d
authored
May 24, 2018
by
Ralf Jung
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' into gen_proofmode
parents
7ae0b644
891cbf51
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
12 additions
and
12 deletions
+12
-12
opam
opam
+1
-1
theories/program_logic/ectx_lifting.v
theories/program_logic/ectx_lifting.v
+2
-2
theories/program_logic/lifting.v
theories/program_logic/lifting.v
+1
-1
theories/program_logic/ownp.v
theories/program_logic/ownp.v
+2
-2
theories/program_logic/total_ectx_lifting.v
theories/program_logic/total_ectx_lifting.v
+2
-2
theories/program_logic/total_lifting.v
theories/program_logic/total_lifting.v
+1
-1
theories/proofmode/classes.v
theories/proofmode/classes.v
+2
-2
theories/proofmode/coq_tactics.v
theories/proofmode/coq_tactics.v
+1
-1
No files found.
opam
View file @
3bed085d
...
...
@@ -11,5 +11,5 @@ install: [make "install"]
remove: ["rm" "-rf" "%{lib}%/coq/user-contrib/iris"]
depends: [
"coq" { (>= "8.7.1" & < "8.9~") | (= "dev") }
"coq-stdpp" { (= "dev.2018-05-2
3
.0.
a8f65af5
") | (= "dev") }
"coq-stdpp" { (= "dev.2018-05-2
4
.0.
de797b31
") | (= "dev") }
]
theories/program_logic/ectx_lifting.v
View file @
3bed085d
...
...
@@ -68,7 +68,7 @@ Lemma wp_lift_atomic_head_step {s E Φ} e1 :
⌜
head_reducible
e1
σ
1
⌝
∗
▷
∀
e2
σ
2
efs
,
⌜
head_step
e1
σ
1 e2
σ
2
efs
⌝
={
E
}=
∗
state_interp
σ
2
∗
default
False
(
to_val
e2
)
Φ
∗
[
∗
list
]
ef
∈
efs
,
WP
ef
@
s
;
⊤
{{
_
,
True
}})
from_option
Φ
False
(
to_val
e2
)
∗
[
∗
list
]
ef
∈
efs
,
WP
ef
@
s
;
⊤
{{
_
,
True
}})
⊢
WP
e1
@
s
;
E
{{
Φ
}}.
Proof
.
iIntros
(?)
"H"
.
iApply
wp_lift_atomic_step
;
eauto
.
...
...
@@ -82,7 +82,7 @@ Lemma wp_lift_atomic_head_step_no_fork {s E Φ} e1 :
(
∀
σ
1
,
state_interp
σ
1
={
E
}=
∗
⌜
head_reducible
e1
σ
1
⌝
∗
▷
∀
e2
σ
2
efs
,
⌜
head_step
e1
σ
1 e2
σ
2
efs
⌝
={
E
}=
∗
⌜
efs
=
[]
⌝
∗
state_interp
σ
2
∗
default
False
(
to_val
e2
)
Φ
)
⌜
efs
=
[]
⌝
∗
state_interp
σ
2
∗
from_option
Φ
False
(
to_val
e2
))
⊢
WP
e1
@
s
;
E
{{
Φ
}}.
Proof
.
iIntros
(?)
"H"
.
iApply
wp_lift_atomic_head_step
;
eauto
.
...
...
theories/program_logic/lifting.v
View file @
3bed085d
...
...
@@ -71,7 +71,7 @@ Lemma wp_lift_atomic_step {s E Φ} e1 :
⌜
if
s
is
NotStuck
then
reducible
e1
σ
1
else
True
⌝
∗
▷
∀
e2
σ
2
efs
,
⌜
prim_step
e1
σ
1 e2
σ
2
efs
⌝
={
E
}=
∗
state_interp
σ
2
∗
default
False
(
to_val
e2
)
Φ
∗
[
∗
list
]
ef
∈
efs
,
WP
ef
@
s
;
⊤
{{
_
,
True
}})
from_option
Φ
False
(
to_val
e2
)
∗
[
∗
list
]
ef
∈
efs
,
WP
ef
@
s
;
⊤
{{
_
,
True
}})
⊢
WP
e1
@
s
;
E
{{
Φ
}}.
Proof
.
iIntros
(?)
"H"
.
iApply
(
wp_lift_step
s
E
_
e1
)=>//
;
iIntros
(
σ
1
)
"Hσ1"
.
...
...
theories/program_logic/ownp.v
View file @
3bed085d
...
...
@@ -138,7 +138,7 @@ Section lifting.
Lemma
ownP_lift_atomic_step
{
s
E
Φ
}
e1
σ
1
:
(
if
s
is
NotStuck
then
reducible
e1
σ
1
else
to_val
e1
=
None
)
→
(
▷
ownP
σ
1
∗
▷
∀
e2
σ
2
efs
,
⌜
prim_step
e1
σ
1 e2
σ
2
efs
⌝
-
∗
ownP
σ
2
-
∗
default
False
(
to_val
e2
)
Φ
∗
[
∗
list
]
ef
∈
efs
,
WP
ef
@
s
;
⊤
{{
_
,
True
}})
from_option
Φ
False
(
to_val
e2
)
∗
[
∗
list
]
ef
∈
efs
,
WP
ef
@
s
;
⊤
{{
_
,
True
}})
⊢
WP
e1
@
s
;
E
{{
Φ
}}.
Proof
.
iIntros
(?)
"[Hσ H]"
;
iApply
ownP_lift_step
.
...
...
@@ -240,7 +240,7 @@ Section ectx_lifting.
head_reducible
e1
σ
1
→
▷
ownP
σ
1
∗
▷
(
∀
e2
σ
2
efs
,
⌜
head_step
e1
σ
1 e2
σ
2
efs
⌝
-
∗
ownP
σ
2
-
∗
default
False
(
to_val
e2
)
Φ
∗
[
∗
list
]
ef
∈
efs
,
WP
ef
@
s
;
⊤
{{
_
,
True
}})
from_option
Φ
False
(
to_val
e2
)
∗
[
∗
list
]
ef
∈
efs
,
WP
ef
@
s
;
⊤
{{
_
,
True
}})
⊢
WP
e1
@
s
;
E
{{
Φ
}}.
Proof
.
iIntros
(?)
"[? H]"
.
iApply
ownP_lift_atomic_step
;
eauto
.
...
...
theories/program_logic/total_ectx_lifting.v
View file @
3bed085d
...
...
@@ -43,7 +43,7 @@ Lemma twp_lift_atomic_head_step {s E Φ} e1 :
⌜
head_reducible
e1
σ
1
⌝
∗
∀
e2
σ
2
efs
,
⌜
head_step
e1
σ
1 e2
σ
2
efs
⌝
={
E
}=
∗
state_interp
σ
2
∗
default
False
(
to_val
e2
)
Φ
∗
[
∗
list
]
ef
∈
efs
,
WP
ef
@
s
;
⊤
[{
_
,
True
}])
from_option
Φ
False
(
to_val
e2
)
∗
[
∗
list
]
ef
∈
efs
,
WP
ef
@
s
;
⊤
[{
_
,
True
}])
⊢
WP
e1
@
s
;
E
[{
Φ
}].
Proof
.
iIntros
(?)
"H"
.
iApply
twp_lift_atomic_step
;
eauto
.
...
...
@@ -56,7 +56,7 @@ Lemma twp_lift_atomic_head_step_no_fork {s E Φ} e1 :
(
∀
σ
1
,
state_interp
σ
1
={
E
}=
∗
⌜
head_reducible
e1
σ
1
⌝
∗
∀
e2
σ
2
efs
,
⌜
head_step
e1
σ
1 e2
σ
2
efs
⌝
={
E
}=
∗
⌜
efs
=
[]
⌝
∗
state_interp
σ
2
∗
default
False
(
to_val
e2
)
Φ
)
⌜
efs
=
[]
⌝
∗
state_interp
σ
2
∗
from_option
Φ
False
(
to_val
e2
))
⊢
WP
e1
@
s
;
E
[{
Φ
}].
Proof
.
iIntros
(?)
"H"
.
iApply
twp_lift_atomic_head_step
;
eauto
.
...
...
theories/program_logic/total_lifting.v
View file @
3bed085d
...
...
@@ -45,7 +45,7 @@ Lemma twp_lift_atomic_step {s E Φ} e1 :
⌜
if
s
is
NotStuck
then
reducible
e1
σ
1
else
True
⌝
∗
∀
e2
σ
2
efs
,
⌜
prim_step
e1
σ
1 e2
σ
2
efs
⌝
={
E
}=
∗
state_interp
σ
2
∗
default
False
(
to_val
e2
)
Φ
∗
[
∗
list
]
ef
∈
efs
,
WP
ef
@
s
;
⊤
[{
_
,
True
}])
from_option
Φ
False
(
to_val
e2
)
∗
[
∗
list
]
ef
∈
efs
,
WP
ef
@
s
;
⊤
[{
_
,
True
}])
⊢
WP
e1
@
s
;
E
[{
Φ
}].
Proof
.
iIntros
(?)
"H"
.
iApply
(
twp_lift_step
_
E
_
e1
)=>//
;
iIntros
(
σ
1
)
"Hσ1"
.
...
...
theories/proofmode/classes.v
View file @
3bed085d
...
...
@@ -526,7 +526,7 @@ Hint Mode IntoInv + ! - : typeclass_instances.
instances to recognize the [emp] case and make it look nicer. *)
Definition
accessor
{
PROP
:
bi
}
{
X
:
Type
}
(
M1
M2
:
PROP
→
PROP
)
(
α
β
:
X
→
PROP
)
(
m
γ
:
X
→
option
PROP
)
:
PROP
:
=
M1
(
∃
x
,
α
x
∗
(
β
x
-
∗
M2
(
default
emp
(
m
γ
x
)
id
)))%
I
.
M1
(
∃
x
,
α
x
∗
(
β
x
-
∗
M2
(
from_option
id
emp
(
m
γ
x
))))%
I
.
(* Typeclass for assertions around which accessors can be elliminated.
Inputs: [Q], [E1], [E2], [α], [β], [γ]
...
...
@@ -582,7 +582,7 @@ Hint Mode IntoAcc + - ! - - - - - - - : typeclass_instances.
Class
ElimInv
{
PROP
:
bi
}
{
X
:
Type
}
(
φ
:
Prop
)
(
Pinv
Pin
:
PROP
)
(
Pout
:
X
→
PROP
)
(
mPclose
:
option
(
X
→
PROP
))
(
Q
:
PROP
)
(
Q'
:
X
→
PROP
)
:
=
elim_inv
:
φ
→
Pinv
∗
Pin
∗
(
∀
x
,
Pout
x
∗
(
default
(
λ
_
,
emp
)
mPclose
id
)
x
-
∗
Q'
x
)
⊢
Q
.
elim_inv
:
φ
→
Pinv
∗
Pin
∗
(
∀
x
,
Pout
x
∗
(
from_option
id
(
λ
_
,
emp
)
mPclose
)
x
-
∗
Q'
x
)
⊢
Q
.
Arguments
ElimInv
{
_
}
{
_
}
_
_
%
I
_
%
I
_
%
I
_
%
I
_
%
I
_
%
I
:
simpl
never
.
Arguments
elim_inv
{
_
}
{
_
}
_
_
%
I
_
%
I
_
%
I
_
%
I
_
%
I
_
%
I
{
_
}.
Hint
Mode
ElimInv
+
-
-
!
-
-
!
!
-
:
typeclass_instances
.
...
...
theories/proofmode/coq_tactics.v
View file @
3bed085d
...
...
@@ -445,7 +445,7 @@ Proof.
Qed
.
Lemma
maybe_wand_sound
(
mP
:
option
PROP
)
Q
:
maybe_wand
mP
Q
⊣
⊢
(
default
emp
mP
id
-
∗
Q
).
maybe_wand
mP
Q
⊣
⊢
(
from_option
id
emp
mP
-
∗
Q
).
Proof
.
destruct
mP
;
simpl
;
first
done
.
rewrite
emp_wand
//.
Qed
.
Global
Instance
envs_Forall2_refl
(
R
:
relation
PROP
)
:
...
...
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