Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
I
Iris
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
Abel Nieto
Iris
Commits
d30b8add
Commit
d30b8add
authored
6 years ago
by
Robbert Krebbers
Committed by
Jacques-Henri Jourdan
6 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Automate proofs of `Atomic` instances.
parent
9646293e
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
theories/heap_lang/tactics.v
+14
-55
14 additions, 55 deletions
theories/heap_lang/tactics.v
with
14 additions
and
55 deletions
theories/heap_lang/tactics.v
+
14
−
55
View file @
d30b8add
...
@@ -7,70 +7,29 @@ Proof. done. Qed.
...
@@ -7,70 +7,29 @@ Proof. done. Qed.
Instance
as_val_val
v
:
AsVal
(
Val
v
)
.
Instance
as_val_val
v
:
AsVal
(
Val
v
)
.
Proof
.
by
eexists
.
Qed
.
Proof
.
by
eexists
.
Qed
.
Local
Ltac
solve_atomic
:=
apply
strongly_atomic_atomic
,
ectx_language_atomic
;
[
inversion
1
;
naive_solver
|
apply
ectxi_language_sub_redexes_are_values
;
intros
[]
**
;
naive_solver
]
.
Instance
alloc_atomic
s
v
:
Atomic
s
(
Alloc
(
Val
v
))
.
Instance
alloc_atomic
s
v
:
Atomic
s
(
Alloc
(
Val
v
))
.
Proof
.
Proof
.
solve_atomic
.
Qed
.
apply
strongly_atomic_atomic
,
ectx_language_atomic
.
-
intros
σ
e
σ'
ef
obs
Hstep
;
simpl
in
*.
inversion
Hstep
;
simplify_eq
.
eauto
.
-
apply
ectxi_language_sub_redexes_are_values
=>
/=
Ki
e'
Hfill
.
destruct
Ki
;
simplify_eq
/=.
eauto
.
Qed
.
Instance
load_atomic
s
v
:
Atomic
s
(
Load
(
Val
v
))
.
Instance
load_atomic
s
v
:
Atomic
s
(
Load
(
Val
v
))
.
Proof
.
Proof
.
solve_atomic
.
Qed
.
apply
strongly_atomic_atomic
,
ectx_language_atomic
.
-
intros
σ
e
σ'
ef
obs
Hstep
;
simpl
in
*.
inversion
Hstep
;
simplify_eq
.
eauto
.
-
apply
ectxi_language_sub_redexes_are_values
=>
/=
Ki
e'
Hfill
.
destruct
Ki
;
simplify_eq
/=.
eauto
.
Qed
.
Instance
store_atomic
s
v1
v2
:
Atomic
s
(
Store
(
Val
v1
)
(
Val
v2
))
.
Instance
store_atomic
s
v1
v2
:
Atomic
s
(
Store
(
Val
v1
)
(
Val
v2
))
.
Proof
.
Proof
.
solve_atomic
.
Qed
.
apply
strongly_atomic_atomic
,
ectx_language_atomic
.
-
intros
σ
e
σ'
ef
obs
Hstep
;
simpl
in
*.
inversion
Hstep
;
simplify_eq
.
eauto
.
-
apply
ectxi_language_sub_redexes_are_values
=>
/=
Ki
e'
Hfill
.
destruct
Ki
;
simplify_eq
/=
;
eauto
.
Qed
.
Instance
cas_atomic
s
v0
v1
v2
:
Atomic
s
(
CAS
(
Val
v0
)
(
Val
v1
)
(
Val
v2
))
.
Instance
cas_atomic
s
v0
v1
v2
:
Atomic
s
(
CAS
(
Val
v0
)
(
Val
v1
)
(
Val
v2
))
.
Proof
.
Proof
.
solve_atomic
.
Qed
.
apply
strongly_atomic_atomic
,
ectx_language_atomic
.
-
intros
σ
e
σ'
ef
obs
Hstep
;
simpl
in
*.
inversion
Hstep
;
simplify_eq
;
eauto
.
-
apply
ectxi_language_sub_redexes_are_values
=>
/=
Ki
e'
Hfill
.
destruct
Ki
;
simplify_eq
/=
;
eauto
.
Qed
.
Instance
faa_atomic
s
v1
v2
:
Atomic
s
(
FAA
(
Val
v1
)
(
Val
v2
))
.
Instance
faa_atomic
s
v1
v2
:
Atomic
s
(
FAA
(
Val
v1
)
(
Val
v2
))
.
Proof
.
Proof
.
solve_atomic
.
Qed
.
apply
strongly_atomic_atomic
,
ectx_language_atomic
.
-
intros
σ
e
σ'
ef
obs
Hstep
;
simpl
in
*.
inversion
Hstep
;
simplify_eq
;
eauto
.
-
apply
ectxi_language_sub_redexes_are_values
=>
/=
Ki
e'
Hfill
.
destruct
Ki
;
simplify_eq
/=
;
eauto
.
Qed
.
Instance
fork_atomic
s
e
:
Atomic
s
(
Fork
e
)
.
Instance
fork_atomic
s
e
:
Atomic
s
(
Fork
e
)
.
Proof
.
Proof
.
solve_atomic
.
Qed
.
apply
strongly_atomic_atomic
,
ectx_language_atomic
.
-
intros
σ
e'
σ'
ef
obs
Hstep
;
simpl
in
*.
inversion
Hstep
;
simplify_eq
;
eauto
.
-
apply
ectxi_language_sub_redexes_are_values
=>
/=
Ki
e'
Hfill
.
destruct
Ki
;
simplify_eq
/=
;
eauto
.
Qed
.
Instance
skip_atomic
s
:
Atomic
s
Skip
.
Instance
skip_atomic
s
:
Atomic
s
Skip
.
Proof
.
Proof
.
solve_atomic
.
Qed
.
apply
strongly_atomic_atomic
,
ectx_language_atomic
.
-
intros
σ
e'
σ'
ef
obs
Hstep
;
simpl
in
*.
inversion
Hstep
;
simplify_eq
;
eauto
.
-
apply
ectxi_language_sub_redexes_are_values
=>
/=
Ki
e'
Hfill
.
destruct
Ki
;
simplify_eq
/=
;
eauto
.
Qed
.
Instance
new_proph_atomic
s
:
Atomic
s
NewProph
.
Instance
new_proph_atomic
s
:
Atomic
s
NewProph
.
Proof
.
Proof
.
solve_atomic
.
Qed
.
apply
strongly_atomic_atomic
,
ectx_language_atomic
.
-
intros
σ
e'
σ'
ef
obs
Hstep
;
simpl
in
*.
inversion
Hstep
;
simplify_eq
;
eauto
.
-
apply
ectxi_language_sub_redexes_are_values
=>
/=
Ki
e'
Hfill
.
destruct
Ki
;
simplify_eq
/=
;
eauto
.
Qed
.
Instance
resolve_proph_atomic
s
v1
v2
:
Atomic
s
(
ResolveProph
(
Val
v1
)
(
Val
v2
))
.
Instance
resolve_proph_atomic
s
v1
v2
:
Atomic
s
(
ResolveProph
(
Val
v1
)
(
Val
v2
))
.
Proof
.
Proof
.
solve_atomic
.
Qed
.
apply
strongly_atomic_atomic
,
ectx_language_atomic
.
-
intros
σ
e
σ'
ef
obs
Hstep
;
simpl
in
*.
inversion
Hstep
;
simplify_eq
.
eauto
.
-
apply
ectxi_language_sub_redexes_are_values
=>
/=
Ki
e'
Hfill
.
destruct
Ki
;
simplify_eq
/=
;
eauto
.
Qed
.
(** The tactic [reshape_expr e tac] decomposes the expression [e] into an
(** The tactic [reshape_expr e tac] decomposes the expression [e] into an
evaluation context [K] and a subexpression [e']. It calls the tactic [tac K e']
evaluation context [K] and a subexpression [e']. It calls the tactic [tac K e']
...
...
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