Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
lambda-rust
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
Model registry
Operate
Environments
Monitor
Service Desk
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
Iris
lambda-rust
Commits
4bb7220e
There was a problem fetching the pipeline summary.
Commit
4bb7220e
authored
6 years ago
by
Hai Dang
Browse files
Options
Downloads
Patches
Plain Diff
fix build
parent
29ca2ad4
No related branches found
No related tags found
No related merge requests found
Pipeline
#
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
_CoqProject
+0
-3
0 additions, 3 deletions
_CoqProject
theories/lang/lock.v
+5
-3
5 additions, 3 deletions
theories/lang/lock.v
with
5 additions
and
6 deletions
_CoqProject
+
0
−
3
View file @
4bb7220e
...
...
@@ -63,9 +63,6 @@ theories/typing/lib/refcell/ref_code.v
theories/typing/lib/refcell/refmut_code.v
theories/typing/lib/refcell/refmut.v
theories/typing/lib/refcell/ref.v
theories/typing/lib/rwlock/rwlock.v
theories/typing/lib/rwlock/rwlockreadguard.v
theories/typing/lib/rwlock/rwlockwriteguard.v
theories/typing/examples/get_x.v
theories/typing/examples/rebor.v
theories/typing/examples/unbox.v
...
...
This diff is collapsed.
Click to expand it.
theories/lang/lock.v
+
5
−
3
View file @
4bb7220e
...
...
@@ -7,7 +7,9 @@ Set Default Proof Using "Type".
Definition
mklock_unlocked
:
val
:=
λ
:
[
"l"
],
"l"
<-
#
false
.
Definition
mklock_locked
:
val
:=
λ
:
[
"l"
],
"l"
<-
#
true
.
Definition
try_acquire
:
val
:=
λ
:
[
"l"
],
CAS
"l"
#
false
#
true
AcqRel
Relaxed
.
(* If the CAS fails, it's a relaxed-read.
If the CAS succeeds, it's a acq-read and relaxed-write *)
Definition
try_acquire
:
val
:=
λ
:
[
"l"
],
CAS
"l"
#
false
#
true
Relaxed
AcqRel
Relaxed
.
Definition
acquire
:
val
:=
rec
:
"acquire"
[
"l"
]
:=
if
:
try_acquire
[
"l"
]
then
#☠
else
"acquire"
[
"l"
]
.
Definition
release
:
val
:=
λ
:
[
"l"
],
"l"
<-
ʳᵉˡ
#
false
.
...
...
@@ -135,9 +137,9 @@ Section proof.
wp_rec
.
iMod
(
"Hproto"
with
"HP"
)
as
(
γ
R0
Vb
)
"(#[Eq lc] & inv & Hclose)"
.
iDestruct
"lc"
as
(?)
"lc"
.
iMod
(
rel_True_intro
True
%
I
tid
with
"[//]"
)
as
"rTrue"
.
iApply
(
GPS_PPRaw_CAS_simple
(
lock_interp
R0
)
_
_
_
_
iApply
(
GPS_PPRaw_CAS_
int_
simple
(
lock_interp
R0
)
_
_
_
_
_
(
Z_of_bool
false
)
#
true
()
(
λ
_,
R0
)
%
I
(
λ
_
_,
True
)
%
I
with
"[$lc $inv rTrue]"
);
[
done
|
by
right
|
by
left
|..]
.
with
"[$lc $inv rTrue]"
);[
done
|
by
left
|
done
|
by
right
|
by
left
|..]
.
{
iSplitL
""
;
[|
iSplitL
""
];
[
iNext
;
iModIntro
..|]
.
-
iIntros
(??
_)
.
by
iApply
lock_interp_comparable
.
-
by
iIntros
(??)
"_ #$"
.
...
...
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