the implementation of /=
as simpl
probably predates cbn
. But is there any reason one might want to switch /=
to be cbn
instead? Or reasons against? Wasn't the goal of cbn
to be a "better simpl"?
Reasons for:
cbn
respects simpl never
cbn
unfolds aliases even when they do not lead to further reduction (I find that desirable but that's just me)cbn
generally has more deterministic performance in my experience but it's been a while since I last tested it. Most of that might well be down to the first point.Reasons against:
cbn
is generally slower than simpl
(unless simpl
tries to do too much, see above)cbn
seems to be complex and bugs that have been fixed have generally been tricky. I don't know that simpl
is that much easier to fix but maybe it just has fewer bugs from being around longer/being used more?OK, would be interesting to know if there's anything MathComp-specific affected by "unfolds aliases even when they do not lead to further reduction".
I've only used cbn a bit, and I think the aliasing stuff turned my context to a mess quite a lot. But idiomatic SSR usually scopes simplification very carefully.
The good thing is that you can add simpl never
to your alias and cbn
will not unfold it any more
good to know, but simpl never
is not very often used in MathComp projects. I only see a few in Analysis and fourcolor
I can't deny that it is annoying, especially when it's the only reason for the entire Arguments
line in the code.
@Karl Palmskog there's an option to make simpl itself use cbn. But nobody has had success with it
I recall @Enrico Tassi considers "cbn is a better simpl" as just wrong. There are also a few issues on the discrepancies. One has even been fixed. But they're extremely confusing... I'm kind of happy I forgot most details :-|.
But you can remap the non-/= relatives of /=, I think ssreflect supports it now?
There is a flag to remap /= to cbn, you can just try.
If I could just find it....
Isn't it Set SimplIsCbn?
https://sympa.inria.fr/sympa/arc/coq-club/2015-06/msg00002.html
https://sympa.inria.fr/sympa/arc/coq-club/2015-06/msg00002.html
ahahah
yes, maybe it disappeared
We still tried it last year, and ssreflect honored it https://gitlab.mpi-sws.org/iris/stdpp/-/issues/74
Quick question: how do I create a finType from a Variant?
Last updated: Feb 08 2023 at 07:02 UTC