Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
examples
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
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
Iris
examples
Commits
82d08c14
Commit
82d08c14
authored
5 years ago
by
Ralf Jung
Browse files
Options
Downloads
Patches
Plain Diff
expand comments
parent
b14af24e
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Pipeline
#17399
passed
5 years ago
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
theories/logatom/conditional_increment/cinc.v
+6
-2
6 additions, 2 deletions
theories/logatom/conditional_increment/cinc.v
with
6 additions
and
2 deletions
theories/logatom/conditional_increment/cinc.v
+
6
−
2
View file @
82d08c14
...
@@ -188,8 +188,10 @@ Section conditional_counter.
...
@@ -188,8 +188,10 @@ Section conditional_counter.
Remember that the thread winning the CAS might be just helping. The token
Remember that the thread winning the CAS might be just helping. The token
is owned by the thread whose request this is.
is owned by the thread whose request this is.
In this state, [l_ghost_winner] serves as a token to make sure that
In this state, [l_ghost_winner] serves as a token to make sure that
only the CAS winner can transition to here, and [loc_token l] serves as a
only the CAS winner can transition to here, and owning half of[l] serves as a
"location" token to ensure there is no ABA going on. *)
"location" token to ensure there is no ABA going on. Notice how [counter_inv]
owns *more than* half of its [l], which means we know that the [l] there
and here cannot be the same. *)
Definition
done_state
Q
(
l
l_ghost_winner
:
loc
)
(
γ_t
:
gname
)
:=
Definition
done_state
Q
(
l
l_ghost_winner
:
loc
)
(
γ_t
:
gname
)
:=
((
Q
∨
own_token
γ_t
)
∗
l_ghost_winner
↦
-
∗
l
↦
{
1
/
2
}
-
)
%
I
.
((
Q
∨
own_token
γ_t
)
∗
l_ghost_winner
↦
-
∗
l
↦
{
1
/
2
}
-
)
%
I
.
...
@@ -210,6 +212,8 @@ Section conditional_counter.
...
@@ -210,6 +212,8 @@ Section conditional_counter.
Definition
counter_inv
γ_b
γ_n
f
c
:=
Definition
counter_inv
γ_b
γ_n
f
c
:=
(
∃
(
b
:
bool
)
(
l
:
loc
)
(
q
:
Qp
)
(
s
:
abstract_state
),
(
∃
(
b
:
bool
)
(
l
:
loc
)
(
q
:
Qp
)
(
s
:
abstract_state
),
(* We own *more than* half of [l], which shows that this cannot
be the [l] of any [state] protocol in the [done] state. *)
f
↦
#
b
∗
c
↦
{
1
/
2
}
#
l
∗
l
↦
{
1
/
2
+
q
}
(
state_to_val
s
)
∗
f
↦
#
b
∗
c
↦
{
1
/
2
}
#
l
∗
l
↦
{
1
/
2
+
q
}
(
state_to_val
s
)
∗
own
γ_b
(
●
Excl'
b
)
∗
own
γ_b
(
●
Excl'
b
)
∗
match
s
with
match
s
with
...
...
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