Commit a5063f60 authored by Robbert Krebbers's avatar Robbert Krebbers
Browse files

Enable primitive projections for bi.interface.

This gives a 25% speedup on some files (e.g. boxes).

This commit contains some hacks to work arround Coq issue #5699.

This commit requires Coq v8.7 together with
parent f506c2fa
......@@ -10,6 +10,6 @@ build: [make "-j%{jobs}%"]
install: [make "install"]
remove: ["rm" "-rf" "%{lib}%/coq/user-contrib/iris"]
depends: [
"coq" { >= "8.7.0" & < "8.8~" }
"coq" { >= "" & < "8.8~" }
"coq-stdpp" { (= "dev.2017-11-12.2") | (= "dev") }
......@@ -324,14 +324,13 @@ Definition unseal_eqs :=
uPred_exist_eq, uPred_internal_eq_eq, uPred_sep_eq, uPred_wand_eq,
uPred_plainly_eq, uPred_persistently_eq, uPred_later_eq, uPred_ownM_eq,
uPred_cmra_valid_eq, uPred_bupd_eq).
Ltac unseal := rewrite
/bi_emp /= /uPred_emp /bi_pure /bi_and /bi_or /bi_impl
/bi_forall /bi_exist /bi_internal_eq /bi_sep /bi_wand /bi_plainly
/bi_persistently /bi_later /=
/sbi_emp /sbi_pure /sbi_and /sbi_or /sbi_impl
/sbi_forall /sbi_exist /sbi_internal_eq /sbi_sep /sbi_wand /sbi_plainly
/sbi_persistently /=
!unseal_eqs /=.
Ltac unseal := (* Coq unfold is used to circumvent bug #5699 in rewrite /foo *)
unfold bi_emp; simpl;
unfold uPred_emp, bi_pure, bi_and, bi_or, bi_impl, bi_forall, bi_exist,
bi_internal_eq, bi_sep, bi_wand, bi_plainly, bi_persistently, bi_later; simpl;
unfold sbi_emp, sbi_pure, sbi_and, sbi_or, sbi_impl, sbi_forall, sbi_exist,
sbi_internal_eq, sbi_sep, sbi_wand, sbi_plainly, sbi_persistently; simpl;
rewrite !unseal_eqs /=.
End uPred_unseal.
Import uPred_unseal.
From iris.algebra Require Export ofe.
Set Primitive Projections.
Reserved Notation "P ⊢ Q" (at level 99, Q at level 200, right associativity).
Reserved Notation "'emp'".
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment