Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Iris
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Gaëtan Gilbert
Iris
Commits
27426fec
Commit
27426fec
authored
5 years ago
by
Jonas Kastberg
Committed by
Robbert Krebbers
5 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Added a stronger version of cinv_open_strong
parent
1bb62ee3
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
CHANGELOG.md
+2
-0
2 additions, 0 deletions
CHANGELOG.md
theories/base_logic/lib/cancelable_invariants.v
+21
-11
21 additions, 11 deletions
theories/base_logic/lib/cancelable_invariants.v
with
23 additions
and
11 deletions
CHANGELOG.md
+
2
−
0
View file @
27426fec
...
...
@@ -9,6 +9,8 @@ Coq development, but not every API-breaking change is listed. Changes marked
*
[#] Redefine invariants as "semantic invariants" so that they support
splitting and other forms of weakening.
*
Updated the strong variant of the opening lemma for cancellable invariants
to match that of regular invariants, where you can pick the mask at a later time.
**Changes in Coq:**
...
...
This diff is collapsed.
Click to expand it.
theories/base_logic/lib/cancelable_invariants.v
+
21
−
11
View file @
27426fec
...
...
@@ -81,17 +81,24 @@ Section proofs.
Lemma
cinv_open_strong
E
N
γ
p
P
:
↑
N
⊆
E
→
cinv
N
γ
P
-∗
cinv_own
γ
p
=
{
E
,
E
∖↑
N
}
=∗
▷
P
∗
cinv_own
γ
p
∗
(
▷
P
∨
cinv_own
γ
1
=
{
E
∖↑
N
,
E
}
=∗
True
)
.
cinv
N
γ
P
-∗
(
cinv_own
γ
p
=
{
E
,
E
∖↑
N
}
=∗
▷
P
∗
cinv_own
γ
p
∗
(
∀
E'
:
coPset
,
▷
P
∨
cinv_own
γ
1
=
{
E
'
,
↑
N
∪
E'
}
=∗
True
)
)
.
Proof
.
iIntros
(?)
"#Hinv Hγ"
.
iDestruct
"Hinv"
as
(
P'
)
"[#HP' Hinv]"
.
iInv
N
as
"[HP | >Hγ']"
"Hclose"
.
-
iIntros
"!> {$Hγ}"
.
iSplitL
"HP"
.
+
iNext
.
iApply
"HP'"
.
done
.
+
iIntros
"[HP|Hγ]"
.
*
iApply
"Hclose"
.
iLeft
.
iNext
.
by
iApply
"HP'"
.
*
iApply
"Hclose"
.
iRight
.
by
iNext
.
-
iDestruct
(
cinv_own_1_l
with
"Hγ' Hγ"
)
as
%
[]
.
iIntros
(?)
"Hinv Hown"
.
unfold
cinv
.
iDestruct
"Hinv"
as
(
P'
)
"[#HP' Hinv]"
.
iPoseProof
(
inv_open
(
↑
N
)
N
(
P
∨
cinv_own
γ
1
)
with
"[Hinv]"
)
as
"H"
;
first
done
.
{
iApply
inv_iff
=>
//.
iModIntro
.
iModIntro
.
iSplit
;
iIntros
"[H | $]"
;
iDestruct
(
"HP'"
with
"H"
)
as
"$"
.
}
rewrite
difference_diag_L
.
iPoseProof
(
fupd_mask_frame_r
_
_
(
E
∖
↑
N
)
with
"H"
)
as
"H"
;
first
set_solver
.
rewrite
left_id_L
-
union_difference_L
//.
iMod
"H"
as
"[[$ | >HP] H]"
.
-
iFrame
"Hown"
.
iModIntro
.
iIntros
(
E'
)
"HP"
.
iPoseProof
(
fupd_mask_frame_r
_
_
E'
with
"(H [HP])"
)
as
"H"
;
first
set_solver
.
{
iDestruct
"HP"
as
"[HP | Hown]"
;
eauto
.
}
by
rewrite
left_id_L
.
-
iDestruct
(
cinv_own_1_l
with
"HP Hown"
)
as
%
[]
.
Qed
.
Lemma
cinv_alloc
E
N
P
:
▷
P
=
{
E
}
=∗
∃
γ
,
cinv
N
γ
P
∗
cinv_own
γ
1
.
...
...
@@ -104,6 +111,7 @@ Section proofs.
Proof
.
iIntros
(?)
"#Hinv Hγ"
.
iMod
(
cinv_open_strong
with
"Hinv Hγ"
)
as
"($ & Hγ & H)"
;
first
done
.
rewrite
{
2
}(
union_difference_L
(
↑
N
)
E
)=>
//.
iApply
"H"
.
by
iRight
.
Qed
.
...
...
@@ -113,7 +121,9 @@ Section proofs.
Proof
.
iIntros
(?)
"#Hinv Hγ"
.
iMod
(
cinv_open_strong
with
"Hinv Hγ"
)
as
"($ & $ & H)"
;
first
done
.
iIntros
"!> HP"
.
iApply
"H"
;
auto
.
iIntros
"!> HP"
.
rewrite
{
2
}(
union_difference_L
(
↑
N
)
E
)=>
//.
iApply
"H"
.
by
iLeft
.
Qed
.
Global
Instance
into_inv_cinv
N
γ
P
:
IntoInv
(
cinv
N
γ
P
)
N
:=
{}
.
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment