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
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
Daniël Louwrink
lambda-rust
Commits
d3d87675
Commit
d3d87675
authored
5 years ago
by
Daniël Louwrink
Browse files
Options
Downloads
Patches
Plain Diff
prove logical popping lemma
parent
afaf93f3
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
theories/lang/stbor/stbor_sim.v
+43
-2
43 additions, 2 deletions
theories/lang/stbor/stbor_sim.v
with
43 additions
and
2 deletions
theories/lang/stbor/stbor_sim.v
+
43
−
2
View file @
d3d87675
...
...
@@ -446,7 +446,7 @@ Lemma stack_sub_tail_no_sharedro stklog stkparsed :
stack_sub_tail
stklog
stkparsed
→
¬
∃
tgs
stklog'
,
stklog
=
ItSharedRO
tgs
::
stklog'
.
Proof
.
intros
Hsub
.
induction
Hsub
as
[|?
?
?
?
?
IH
|?
?
?
?
?
Hsubit
|
z
w
x
y
p
]
.
induction
Hsub
as
[|?
?
?
?
?
IH
|?
?
?
?
?
Hsubit
|]
.
-
intros
(?
&
?
&
Heq
)
.
inversion
Heq
.
-
apply
IH
.
-
intros
(?
&
?
&
Heq
)
.
inversion
Hsubit
;
subst
;
inversion
Heq
.
...
...
@@ -481,10 +481,51 @@ Qed.
(** * Retagging (SharedRW) extend *)
(** * Logical popping *)
Lemma
pop_prefix_preserve_tail
stkparsed
stklog1
stklog2
:
stklog2
`
suffix_of
`
stklog1
→
stack_sub_tail
stklog1
stkparsed
→
stack_sub_tail
stklog2
stkparsed
.
Proof
.
intros
(
stkdead
&
Hsuffix
)
Hsub
.
generalize
dependent
stkdead
.
induction
Hsub
as
[|?
?
?
?
?
IH
|?
?
?
?
?
?
?
IH
|?
?
?
?
?
?
?
?
?
IH
];
intros
stkdead
Hsuffix
.
-
symmetry
in
Hsuffix
.
apply
app_eq_nil
in
Hsuffix
as
[
->
->
]
.
apply
stack_sub_tail_empty
.
-
apply
stack_sub_tail_drop_both
.
eapply
IH
.
eassumption
.
-
destruct
stkdead
as
[|
itdead
stkdead
]
.
+
simpl
in
Hsuffix
.
rewrite
-
Hsuffix
.
by
apply
stack_sub_tail_drop_one
.
+
rewrite
-
app_comm_cons
in
Hsuffix
.
inversion
Hsuffix
.
apply
stack_sub_tail_drop_both
.
eapply
IH
.
eassumption
.
-
destruct
stkdead
as
[|
itdead1
[|
itdead2
stkdead
]]
.
+
simpl
in
Hsuffix
.
rewrite
-
Hsuffix
.
by
apply
stack_sub_tail_keep
.
+
inversion
Hsuffix
.
by
apply
stack_sub_tail_drop_one
.
+
inversion
Hsuffix
.
apply
stack_sub_tail_drop_both
.
eapply
IH
.
eassumption
.
Qed
.
Lemma
pop_prefix_preserve
stkphys
stklog1
stklog2
:
stklog2
`
suffix_of
`
stklog1
→
stack_rel_stack
stkphys
stklog1
→
stack_rel_stack
stkphys
stklog2
.
Proof
.
Admitted
.
Proof
.
intros
(
stkdead
&
Hsuffix
)
(
stkparsed
&
Hparse
&
Hsub
)
.
destruct
Hsub
.
-
destruct
stkdead
as
[|
itdead
stkdead
]
.
+
simpl
in
Hsuffix
.
rewrite
-
Hsuffix
.
eexists
;
split
;
first
apply
Hparse
.
by
apply
stack_sub_keep_shared
.
+
rewrite
-
app_comm_cons
in
Hsuffix
.
inversion
Hsuffix
.
eexists
;
split
;
first
apply
Hparse
.
apply
stack_sub_drop_shared
.
eapply
pop_prefix_preserve_tail
;
last
eassumption
.
by
exists
stkdead
.
-
eexists
;
split
;
first
apply
Hparse
.
apply
stack_sub_drop_shared
.
eapply
pop_prefix_preserve_tail
;
last
eassumption
.
by
exists
stkdead
.
Qed
.
(** * Logical disabling *)
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