Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
I
iris
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Tej Chajed
iris
Commits
d2b00f17
Commit
d2b00f17
authored
May 31, 2016
by
Ralf Jung
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
auth: strong allocation and some more proper lemmas
parent
e24c006e
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
4 deletions
+18
-4
program_logic/auth.v
program_logic/auth.v
+18
-4
No files found.
program_logic/auth.v
View file @
d2b00f17
...
...
@@ -30,6 +30,12 @@ Section definitions.
Proof
.
solve_proper
.
Qed
.
Global
Instance
auth_own_timeless
a
:
TimelessP
(
auth_own
a
).
Proof
.
apply
_
.
Qed
.
Global
Instance
auth_inv_ne
n
:
Proper
(
pointwise_relation
A
(
dist
n
)
==>
dist
n
)
(
auth_inv
).
Proof
.
solve_proper
.
Qed
.
Global
Instance
auth_ctx_ne
n
N
:
Proper
(
pointwise_relation
A
(
dist
n
)
==>
dist
n
)
(
auth_ctx
N
).
Proof
.
solve_proper
.
Qed
.
Global
Instance
auth_ctx_persistent
N
φ
:
PersistentP
(
auth_ctx
N
φ
).
Proof
.
apply
_
.
Qed
.
End
definitions
.
...
...
@@ -53,16 +59,24 @@ Section auth.
Lemma
auth_own_valid
γ
a
:
auth_own
γ
a
⊢
✓
a
.
Proof
.
by
rewrite
/
auth_own
own_valid
auth_validI
.
Qed
.
Lemma
auth_alloc
N
E
a
:
Lemma
auth_alloc
_strong
N
E
a
(
G
:
gset
gname
)
:
✓
a
→
nclose
N
⊆
E
→
▷
φ
a
={
E
}=>
∃
γ
,
auth_ctx
γ
N
φ
∧
auth_own
γ
a
.
▷
φ
a
={
E
}=>
∃
γ
,
■
(
γ
∉
G
)
∧
auth_ctx
γ
N
φ
∧
auth_own
γ
a
.
Proof
.
iIntros
{??}
"Hφ"
.
rewrite
/
auth_own
/
auth_ctx
.
iPvs
(
own_alloc
(
Auth
(
Excl'
a
)
a
))
as
{
γ
}
"Hγ
"
;
first
done
.
iPvs
(
own_alloc
_strong
(
Auth
(
Excl'
a
)
a
)
_
G
)
as
{
γ
}
"[% Hγ]
"
;
first
done
.
iRevert
"Hγ"
;
rewrite
auth_both_op
;
iIntros
"[Hγ Hγ']"
.
iPvs
(
inv_alloc
N
_
(
auth_inv
γ
φ
)
with
"[-Hγ']"
)
;
first
done
.
{
iNext
.
iExists
a
.
by
iFrame
"Hφ"
.
}
iPvsIntro
;
iExists
γ
;
by
iFrame
"Hγ'"
.
iPvsIntro
;
iExists
γ
.
iSplit
;
first
by
iPureIntro
.
by
iFrame
"Hγ'"
.
Qed
.
Lemma
auth_alloc
N
E
a
:
✓
a
→
nclose
N
⊆
E
→
▷
φ
a
={
E
}=>
∃
γ
,
auth_ctx
γ
N
φ
∧
auth_own
γ
a
.
Proof
.
iIntros
{??}
"Hφ"
.
iPvs
(
auth_alloc_strong
N
E
a
∅
with
"Hφ"
)
as
{
γ
}
"[_ ?]"
;
[
done
..|].
by
iExists
γ
.
Qed
.
Lemma
auth_empty
γ
E
:
True
={
E
}=>
auth_own
γ
∅
.
...
...
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