Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Strong monotonicity proofs for the new shallow executor #37

Open
skeuchel opened this issue Oct 18, 2023 · 0 comments
Open

Strong monotonicity proofs for the new shallow executor #37

skeuchel opened this issue Oct 18, 2023 · 0 comments

Comments

@skeuchel
Copy link
Member

The new shallow executor currently only has weak monotonicity proofs like e.g.

Instance exec_aux_monotonic :
Proper (MonotonicCall ==> MonotonicExec) (exec_aux).
Proof.
intros ec1 ec2 ec_mon Γ τ s.
induction s; intros P Q PQ ?; cbn; solve_monotonic.
Qed.

This monotonicity property is not strong enough to finish the soundness proof of the new shallow executor. We loose the (non-persistent) induction hypothesis from the Löb induction when using it

Lemma sound :
ForeignSem -> LemmaSem -> Shallow.ValidContractCEnv ->
⊢ Shallow.ValidContractEnvSem semWP.
Proof.
intros extSem lemSem vcenv.
iLöb as "IH".
iIntros (σs σ f).
specialize (vcenv σs σ f).
destruct (CEnv f) as [[Σe δΔ req res ens]|];[|trivial].
iIntros (ι) "PRE".
specialize (vcenv _ eq_refl).
cbn in vcenv.
rewrite env.Forall_forall in vcenv.
specialize (vcenv ι).
rewrite CPureSpecM.wp_produce in vcenv.
cbn in vcenv.
iPoseProof (vcenv with "[$] PRE") as "vcenv". clear vcenv.
iApply (sound_stm extSem lemSem).
iRevert "vcenv".
iApply CHeapSpecM.exec_aux_monotonic.
Abort.

We can probably make this quite structured like the current monotonicity proofs if we build up respectful, forall_relation, pointwise_relation etc. relation constructors up over separation logic propositions. This can probably hugely benefit from #36

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant