[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Floating-point constant folding in Emacs byte compiler
From: |
Paul Eggert |
Subject: |
Re: Floating-point constant folding in Emacs byte compiler |
Date: |
Mon, 26 Mar 2018 17:28:07 -0700 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 |
On 03/26/2018 11:23 AM, Pip Cet wrote:
if I understand things correctly, large integers in decimal notation
are automatically converted to floats, while large hex constants
signal an overflow error. I believe the former case applies to the
read syntax for byte-compiled functions.
Yes, that's right. This thread got started, though, partly because I'm
thinking of changing the behavior for plain integers to be more like
that of other radixes, because the automatic-float conversion causes too
many problems in practice. This is still work in progress. For a recent
discussion please see:
https://debbugs.gnu.org/30408
is this really a problem for any actual code? Good code shouldn't
depend on more than the 30 bits Emacs guarantees,
It is a real issue, I'm afraid.(I suppose this means the code isn't
good....) See these recent fixes in the master branch:
https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=f92c6dd6cd09991c2ab4c0612574064ca061d927
https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=011186279c1041e790b81af72981547d623d9b29
https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=cae9e0fa0358d6323b57a288b5661dc72d36356d
Better treatment of large integers at compile-time will help catch these
gotchas.
- Re: Floating-point constant folding in Emacs byte compiler, (continued)
- Re: Floating-point constant folding in Emacs byte compiler, Pip Cet, 2018/03/23
- Re: Floating-point constant folding in Emacs byte compiler, Eli Zaretskii, 2018/03/24
- Re: Floating-point constant folding in Emacs byte compiler, Robert Pluim, 2018/03/26
- Re: Floating-point constant folding in Emacs byte compiler, Eli Zaretskii, 2018/03/26
- Re: Floating-point constant folding in Emacs byte compiler, Robert Pluim, 2018/03/26
- Re: Floating-point constant folding in Emacs byte compiler, Eli Zaretskii, 2018/03/26
- Re: Floating-point constant folding in Emacs byte compiler, Pip Cet, 2018/03/26
- Re: Floating-point constant folding in Emacs byte compiler, Eli Zaretskii, 2018/03/26
- Re: Floating-point constant folding in Emacs byte compiler,
Paul Eggert <=
- Re: Floating-point constant folding in Emacs byte compiler, Paul Eggert, 2018/03/27
- Re: Floating-point constant folding in Emacs byte compiler, Pip Cet, 2018/03/30
- Re: Floating-point constant folding in Emacs byte compiler, Noam Postavsky, 2018/03/30
- Re: Floating-point constant folding in Emacs byte compiler, Paul Eggert, 2018/03/30
- Re: Floating-point constant folding in Emacs byte compiler, Stefan Monnier, 2018/03/26
- Re: Floating-point constant folding in Emacs byte compiler, Eli Zaretskii, 2018/03/26
- Re: Floating-point constant folding in Emacs byte compiler, Paul Eggert, 2018/03/26