coq-club AT inria.fr
Subject: The Coq mailing list
List archive
- From: András Kovács <puttamalac AT gmail.com>
- To: Stefan Monnier <monnier AT iro.umontreal.ca>
- Cc: Jason Gross <jasongross9 AT gmail.com>, coq-club <coq-club AT inria.fr>, agda-list <agda AT lists.chalmers.se>, Coq Discourse <coq+miscellaneous AT discoursemail.com>, lean-user <lean-user AT googlegroups.com>, cl-isabelle-users AT lists.cam.ac.uk
- Subject: Re: [Coq-Club] [Agda] Prior work on proof assistant performance / optimization
- Date: Tue, 12 May 2020 17:15:17 +0200
- Authentication-results: mail3-smtp-sop.national.inria.fr; spf=None smtp.pra=puttamalac AT gmail.com; spf=Pass smtp.mailfrom=puttamalac AT gmail.com; spf=None smtp.helo=postmaster AT mail-io1-f44.google.com
- Ironport-phdr: 9a23:x571nhPGWRklcMuxPnEl6mtUPXoX/o7sNwtQ0KIMzox0IvX9rarrMEGX3/hxlliBBdydt6sZzbuM+PC6EUU7or+5+EgYd5JNUxJXwe43pCcHRPC/NEvgMfTxZDY7FskRHHVs/nW8LFQHUJ2mPw6arXK99yMdFQviPgRpOOv1BpTSj8Oq3Oyu5pHfeQpFiCe9bL9oKBi6swrdu8oIjYB/Nqs/1xzFr2dSde9L321oP1WTnxj95se04pFu9jlbtuwi+cBdT6j0Zrw0QrNEAjsoNWA1/9DrugLYTQST/HscU34ZnQRODgPY8Rz1RJbxsi/9tupgxCmXOND9QL4oVTi+6apgVQTlgzkbOTEn7G7Xi9RwjKNFrxKnuxx/2JPfbIWMOPZjYq/RYdYWSGxcVchTSiNBGJuxYIQBD+UDPehWoYrzqUYQoxSiHgSjHv/jxyVSi3PqwaE30eIsGhzG0gw6GNIOtWzZocnzNKgPS+CyzrLIxijGYfNRxzf66pTHcgs8qvyLRbJwbNbRyVU1GAPAlFqQrZbqMC+O2+QCtmiU9etgVea1h2E7rAFxpyGiy8ExgYbGmowb0ErL9TllwIkrP924TlZ2bMK4HZZQqyyWKop7TMw/Tmx0tys3y74Lt566cSYF1pkqxwLTZv6FfoWL4h/uUOWcLDdmiH54eb+zmxK//Eq+x+D6S8K63lFKri9fndnNsHAAzxPT6smbSvt940euwiyD2BzU6uFBJ00/iKnVK4Y5z7IuipYetV7PEyz2lUnskaObd0Qp9vKn5unoZLjtu4WSOJVuig7kN6Qjgsy/Dvo8MggJR2Wb/P6z1Lzn/UHgQbVKieA6nrDXsJ3VKskXvKG5AwhS0oYs7xawES2q38gfnXkCNF5FeRSHgJb1O1zWPvz0EfOyj06vnTpr3fzKI7zsD5TXInXMn7rtZbN95FRdyAo3w9Bf/ZVUCrQZLfLrR0/xqMDYAQU8MwOux+boEsly25gRWWKKGKCZMafSvUWU6eIoJumAfJUVtyrlK/g5+/7uimc0lkMafamwxJcYdHS4Hul9LEiCenrtgtIBEX8QsQYkTezqjkeCUT9JaHqoUaI8/GJzNIXzNpvOSImryJmG2iG6E4ceMmVBDFaNHG3Adp+DHeoJbySOOMJolnoPXO7yZZUm0ESHsgPgQqEvDe3KcyYD/cb7ycRp7ujakRg53TNxBsWZlWqKSjcnzSszWzYq0fUn8gRGwVCZ3P092qQATIAB17ZySg4/cKXk4aliEdmrA1DOe96ITBCtRdD0WWhsHOJ0+McHZgNGI/vnjh3H2HD3UboclrjOBZttt6yAgz7+IMFyz3uA364k3QF/E5l/cFa+j6s6zDD9QovAkkGXjaGvLP1O0yvE9WPFxm2L7hhV
Could you elaborate on this "sharing loss from beta-redexes"?
We may have a huge Peano numeral which is represented by a small term, because we can use iteration/recursion to give short descriptions of large numerals. Then, we can beta-reduce from a small term to a large numeral, but we cannot go from a large numeral to a small term. In particular, Peano numerals are incompressible by hash consing. Hash consing only does "delta-contraction", i.e. contracting terms by maximally introducing let-definitions, but it is intractable to invent small terms which beta reduce to a given term (related: Kolmogorov complexity).
Stefan Monnier <monnier AT iro.umontreal.ca> ezt írta (időpont: 2020. máj. 12., K, 16:30):
> You may be interested in my github repos: smalltt
> <https://github.com/AndrasKovacs/smalltt>, normalization-bench
> <https://github.com/AndrasKovacs/normalization-bench>. I haven't yet
> updated the smalltt repo, but there's a simplified implementation
> <https://gist.github.com/AndrasKovacs/a0e0938113b193d6b9c1c0620d853784> of
> its evaluator, which seems to have roughly the same performance but which
> is much simpler to implement.
Very interesting, thank you.
> It is also extremely important to stick to the spirit of Coquand's semantic
> checking algorithm as much as possible. In summary: core syntax should
> support *no* expensive computation: no substitution, shifting, renaming, or
> other ad-hoc term massaging. Core syntax should be viewed as immutable
> machine code, which supports evaluation into various semantic domains, from
> which sometimes we can read syntax back; this also leaves it open to swap
> out the representation of core syntax to efficient alternatives such as
> bytecode or machine code.
[ Hmm... I kind of vaguely understand what that entails, but can't quite
see how that would work in practice. I guess I'll have to dig deeper
into your above Git repositories. ]
> Only after we get the above two basic points right, can we start to think
> about more specific and esoteric optimizations. I am skeptical of proposed
> solutions which do not include these. Hash consing has been brought up many
> times, but it is very unsatisfying compared to non-deterministic NbE,
> because of its large constant costs, implementation complexity, and the
> failure to handle sharing loss from beta-redexes in any meaningful way
> (which is the most important source of sharing loss!).
Could you elaborate on this "sharing loss from beta-redexes"?
Stefan
- [Coq-Club] Prior work on proof assistant performance / optimization, Jason Gross, 05/08/2020
- Re: [Coq-Club] Prior work on proof assistant performance / optimization, Stefan Monnier, 05/08/2020
- Re: [Coq-Club] [Agda] Prior work on proof assistant performance / optimization, András Kovács, 05/08/2020
- Re: [Coq-Club] [Agda] Prior work on proof assistant performance / optimization, Stefan Monnier, 05/12/2020
- Re: [Coq-Club] [Agda] Prior work on proof assistant performance / optimization, András Kovács, 05/12/2020
- Re: [Coq-Club] [Agda] Prior work on proof assistant performance / optimization, Wolfram Kahl, 05/12/2020
- Re: [Coq-Club] [Agda] Prior work on proof assistant performance / optimization, András Kovács, 05/12/2020
- Re: [Coq-Club] [Agda] Prior work on proof assistant performance / optimization, Jason Gross, 05/14/2020
- Re: [Coq-Club] [Agda] Prior work on proof assistant performance / optimization, Stefan Monnier, 05/12/2020
- Re: [Coq-Club] [isabelle] Prior work on proof assistant performance / optimization, Lawrence Paulson, 05/08/2020
- Re: [Coq-Club] [isabelle] Prior work on proof assistant performance / optimization, Konrad Slind, 05/14/2020
Archive powered by MHonArc 2.6.18.