* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
@ 2012-07-11 17:53 Rob Browning
2012-07-11 19:16 ` Glenn Morris
2012-07-17 2:59 ` Paul Eggert
0 siblings, 2 replies; 24+ messages in thread
From: Rob Browning @ 2012-07-11 17:53 UTC (permalink / raw)
To: 11913
At the moment, Emacs 24.1 repeatedly fails to build on a Debian i386
build daemon, murphy, which is an actual i386 machine. However, the
build finishes without a problem on biber which is an amd64 machine,
building in an i386 chroot.
I was hoping that the error might be familiar to someone; it looks like
this (for both Debian 24.1+1-1 and 24.1+1-2):
cal-hebrew.el:815:1:Warning: global/dynamic var `entry' lacks a prefix
cal-hebrew.el:819:56:Error: Arithmetic error: "abs", 8.0
make[4]: *** [calendar/cal-hebrew.elc] Error 1
make[4]: *** Waiting for unfinished jobs....
I have attempted to reproduce the problem a number of different ways,
without success:
- local i386 chroot on another amd64 host
- local i386 wheezy kvm vm
- local i386 squeeze kvm vm using a wheezy chroot (more similar to murphy)
- local i386 host (thanks to Moritz)
I'm also asking about the possibility of shell access to murphy.
You can find the full build log for one of the failures here:
https://buildd.debian.org/status/fetch.php?pkg=emacs24&arch=i386&ver=24.1%2B1-2&stamp=1341453696
and the overall build summary here:
https://buildd.debian.org/status/package.php?p=emacs24
Thanks
--
Rob Browning
rlb @defaultvalue.org and @debian.org
GPG as of 2002-11-03 14DD 432F AE39 534D B592 F9A0 25C8 D377 8C7E 73A4
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-11 17:53 bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine Rob Browning
@ 2012-07-11 19:16 ` Glenn Morris
2012-07-11 21:52 ` Rob Browning
2012-07-17 2:59 ` Paul Eggert
1 sibling, 1 reply; 24+ messages in thread
From: Glenn Morris @ 2012-07-11 19:16 UTC (permalink / raw)
To: Rob Browning; +Cc: 11913
No help whatsoever, but deja vu in March 2008 on two different
distributions, then apparently never again until now:
http://lists.gnu.org/archive/html/emacs-devel/2008-03/msg00508.html
http://lists.gnu.org/archive/html/emacs-devel/2008-03/msg00769.html
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-11 19:16 ` Glenn Morris
@ 2012-07-11 21:52 ` Rob Browning
2012-07-13 17:47 ` Rob Browning
0 siblings, 1 reply; 24+ messages in thread
From: Rob Browning @ 2012-07-11 21:52 UTC (permalink / raw)
To: Glenn Morris; +Cc: 11913
Glenn Morris <rgm@gnu.org> writes:
> No help whatsoever, but deja vu in March 2008 on two different
> distributions, then apparently never again until now:
>
> http://lists.gnu.org/archive/html/emacs-devel/2008-03/msg00508.html
> http://lists.gnu.org/archive/html/emacs-devel/2008-03/msg00769.html
OK, thanks -- I'm going to see if I can have access to murphy. If so,
any suggestions with respect to tracking down the problem?
--
Rob Browning
rlb @defaultvalue.org and @debian.org
GPG as of 2002-11-03 14DD 432F AE39 534D B592 F9A0 25C8 D377 8C7E 73A4
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-11 21:52 ` Rob Browning
@ 2012-07-13 17:47 ` Rob Browning
2012-07-13 17:51 ` Glenn Morris
0 siblings, 1 reply; 24+ messages in thread
From: Rob Browning @ 2012-07-13 17:47 UTC (permalink / raw)
To: Glenn Morris; +Cc: 11913
Rob Browning <rlb@defaultvalue.org> writes:
> OK, thanks -- I'm going to see if I can have access to murphy. If so,
> any suggestions with respect to tracking down the problem?
So it looks like I won't have direct access to murphy, but I can submit
requests to run tests. Do you have any thoughts about what might be
most effective?
This was the original error:
cal-hebrew.el:819:56:Error: Arithmetic error: "abs", 8.0
and I can easily ask them to run a build with an annotated version of
emacs.
Thanks
--
Rob Browning
rlb @defaultvalue.org and @debian.org
GPG as of 2002-11-03 14DD 432F AE39 534D B592 F9A0 25C8 D377 8C7E 73A4
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-13 17:47 ` Rob Browning
@ 2012-07-13 17:51 ` Glenn Morris
2012-07-13 18:40 ` Eli Zaretskii
0 siblings, 1 reply; 24+ messages in thread
From: Glenn Morris @ 2012-07-13 17:51 UTC (permalink / raw)
To: Rob Browning; +Cc: 11913
Rob Browning wrote:
> This was the original error:
>
> cal-hebrew.el:819:56:Error: Arithmetic error: "abs", 8.0
I'm sorry, personally I have no idea what to do about this.
Hopefully someone else on this list does...
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-13 17:51 ` Glenn Morris
@ 2012-07-13 18:40 ` Eli Zaretskii
2012-07-13 19:02 ` Andreas Schwab
` (2 more replies)
0 siblings, 3 replies; 24+ messages in thread
From: Eli Zaretskii @ 2012-07-13 18:40 UTC (permalink / raw)
To: Glenn Morris; +Cc: 11913, rlb
> From: Glenn Morris <rgm@gnu.org>
> Date: Fri, 13 Jul 2012 13:51:29 -0400
> Cc: 11913@debbugs.gnu.org
>
> Rob Browning wrote:
>
> > This was the original error:
> >
> > cal-hebrew.el:819:56:Error: Arithmetic error: "abs", 8.0
>
> I'm sorry, personally I have no idea what to do about this.
> Hopefully someone else on this list does...
Do we even understand how this error happens? There's nothing even
close to a reference to 'abs' on that line of cal-hebrew.el in my copy
of Emacs 24.1.
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-13 18:40 ` Eli Zaretskii
@ 2012-07-13 19:02 ` Andreas Schwab
2012-07-13 19:02 ` Rob Browning
2012-07-13 19:04 ` Glenn Morris
2 siblings, 0 replies; 24+ messages in thread
From: Andreas Schwab @ 2012-07-13 19:02 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: 11913, rlb
Eli Zaretskii <eliz@gnu.org> writes:
>> From: Glenn Morris <rgm@gnu.org>
>> Date: Fri, 13 Jul 2012 13:51:29 -0400
>> Cc: 11913@debbugs.gnu.org
>>
>> Rob Browning wrote:
>>
>> > This was the original error:
>> >
>> > cal-hebrew.el:819:56:Error: Arithmetic error: "abs", 8.0
>>
>> I'm sorry, personally I have no idea what to do about this.
>> Hopefully someone else on this list does...
>
> Do we even understand how this error happens? There's nothing even
> close to a reference to 'abs' on that line of cal-hebrew.el in my copy
> of Emacs 24.1.
Let alone why should (abs 8.0) raise an arithmetic error. That looks
much like a bug in the system library. It would be nice to know the
actual errno value.
Andreas.
--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-13 18:40 ` Eli Zaretskii
2012-07-13 19:02 ` Andreas Schwab
@ 2012-07-13 19:02 ` Rob Browning
2012-07-13 19:17 ` Eli Zaretskii
2012-07-13 19:04 ` Glenn Morris
2 siblings, 1 reply; 24+ messages in thread
From: Rob Browning @ 2012-07-13 19:02 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: 11913
Eli Zaretskii <eliz@gnu.org> writes:
> Do we even understand how this error happens? There's nothing even
> close to a reference to 'abs' on that line of cal-hebrew.el in my copy
> of Emacs 24.1.
Right. While I'm not extremely knowledgeable about the process, since
that string is associated with Qarith_error (in data.c), I assumed it
was probably some code deeper down raising the exception (from either
data.c or floatfns.c). Given the fact that it only happens on i386, I
also wondered if x87 issues might be involved -- but the fact that it
only happens on *this* i386 machine (and a couple of others) suggests
the software versions matter.
In any case, if we can come up with some suitable diagnostic process, I
can ask the buildd maintainers to attempt it, but since I'm sure there
time is a limited resource, I wanted to consult all of you in an attempt
to test more efficiently.
Thanks
--
Rob Browning
rlb @defaultvalue.org and @debian.org
GPG as of 2002-11-03 14DD 432F AE39 534D B592 F9A0 25C8 D377 8C7E 73A4
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-13 19:02 ` Rob Browning
@ 2012-07-13 19:17 ` Eli Zaretskii
2012-07-13 19:29 ` Andreas Schwab
2012-07-13 19:50 ` Rob Browning
0 siblings, 2 replies; 24+ messages in thread
From: Eli Zaretskii @ 2012-07-13 19:17 UTC (permalink / raw)
To: Rob Browning; +Cc: 11913
> From: Rob Browning <rlb@defaultvalue.org>
> Cc: Glenn Morris <rgm@gnu.org>, 11913@debbugs.gnu.org
> Date: Fri, 13 Jul 2012 14:02:16 -0500
>
> Eli Zaretskii <eliz@gnu.org> writes:
>
> > Do we even understand how this error happens? There's nothing even
> > close to a reference to 'abs' on that line of cal-hebrew.el in my copy
> > of Emacs 24.1.
>
> Right. While I'm not extremely knowledgeable about the process, since
> that string is associated with Qarith_error (in data.c), I assumed it
> was probably some code deeper down raising the exception (from either
> data.c or floatfns.c). Given the fact that it only happens on i386, I
> also wondered if x87 issues might be involved -- but the fact that it
> only happens on *this* i386 machine (and a couple of others) suggests
> the software versions matter.
Does that 386 machine have an x87 co-processor? If not, what provides
the floating-point emulation -- the kernel?
If you compile a trivial C program that calls 'fabs' on that machine,
does it work as expected, or does it bomb?
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-13 19:17 ` Eli Zaretskii
@ 2012-07-13 19:29 ` Andreas Schwab
2012-07-13 19:35 ` Eli Zaretskii
2012-07-13 19:50 ` Rob Browning
1 sibling, 1 reply; 24+ messages in thread
From: Andreas Schwab @ 2012-07-13 19:29 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: 11913, Rob Browning
Eli Zaretskii <eliz@gnu.org> writes:
> If you compile a trivial C program that calls 'fabs' on that machine,
> does it work as expected, or does it bomb?
It will not bomb, it will just set errno spuriously.
Andreas.
--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-13 19:29 ` Andreas Schwab
@ 2012-07-13 19:35 ` Eli Zaretskii
2012-07-13 19:51 ` Andreas Schwab
0 siblings, 1 reply; 24+ messages in thread
From: Eli Zaretskii @ 2012-07-13 19:35 UTC (permalink / raw)
To: Andreas Schwab; +Cc: 11913, rlb
> From: Andreas Schwab <schwab@linux-m68k.org>
> Cc: Rob Browning <rlb@defaultvalue.org>, 11913@debbugs.gnu.org
> Date: Fri, 13 Jul 2012 21:29:52 +0200
>
> Eli Zaretskii <eliz@gnu.org> writes:
>
> > If you compile a trivial C program that calls 'fabs' on that machine,
> > does it work as expected, or does it bomb?
>
> It will not bomb, it will just set errno spuriously.
Doesn't it trigger SIGILL or SIGFPE?
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-13 19:35 ` Eli Zaretskii
@ 2012-07-13 19:51 ` Andreas Schwab
2012-07-14 6:23 ` Eli Zaretskii
0 siblings, 1 reply; 24+ messages in thread
From: Andreas Schwab @ 2012-07-13 19:51 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: 11913, rlb
Eli Zaretskii <eliz@gnu.org> writes:
> Doesn't it trigger SIGILL or SIGFPE?
That wouldn't tell us about abs and 8.0.
Andreas.
--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-13 19:51 ` Andreas Schwab
@ 2012-07-14 6:23 ` Eli Zaretskii
2012-07-14 8:09 ` Andreas Schwab
0 siblings, 1 reply; 24+ messages in thread
From: Eli Zaretskii @ 2012-07-14 6:23 UTC (permalink / raw)
To: Andreas Schwab; +Cc: 11913, rlb
> From: Andreas Schwab <schwab@linux-m68k.org>
> Cc: rlb@defaultvalue.org, 11913@debbugs.gnu.org
> Date: Fri, 13 Jul 2012 21:51:24 +0200
>
> Eli Zaretskii <eliz@gnu.org> writes:
>
> > Doesn't it trigger SIGILL or SIGFPE?
>
> That wouldn't tell us about abs and 8.0.
Right, but it should cause the program to crash.
However, since the CPU is a P4, I don't think my suggestion is a good
idea. There cannot be any hardware problem with FP instructions on a
P4.
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-14 6:23 ` Eli Zaretskii
@ 2012-07-14 8:09 ` Andreas Schwab
0 siblings, 0 replies; 24+ messages in thread
From: Andreas Schwab @ 2012-07-14 8:09 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: 11913, rlb
Eli Zaretskii <eliz@gnu.org> writes:
>> From: Andreas Schwab <schwab@linux-m68k.org>
>> Cc: rlb@defaultvalue.org, 11913@debbugs.gnu.org
>> Date: Fri, 13 Jul 2012 21:51:24 +0200
>>
>> Eli Zaretskii <eliz@gnu.org> writes:
>>
>> > Doesn't it trigger SIGILL or SIGFPE?
>>
>> That wouldn't tell us about abs and 8.0.
>
> Right, but it should cause the program to crash.
But it won't happen.
Andreas.
--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-13 19:17 ` Eli Zaretskii
2012-07-13 19:29 ` Andreas Schwab
@ 2012-07-13 19:50 ` Rob Browning
2012-07-14 6:21 ` Eli Zaretskii
1 sibling, 1 reply; 24+ messages in thread
From: Rob Browning @ 2012-07-13 19:50 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: 11913
Eli Zaretskii <eliz@gnu.org> writes:
> Does that 386 machine have an x87 co-processor? If not, what provides
> the floating-point emulation -- the kernel?
It's a P4 Xeon, so it should have x87 support:
http://db.debian.org/machines.cgi?host=murphy
> If you compile a trivial C program that calls 'fabs' on that machine,
> does it work as expected, or does it bomb?
For reference, I'd be a bit surprised if there was a really blatant
problem with murphy since that buildd is probably used to build a lot of
other Debian packages. Though probably not as many as other buildds,
since until recently most developers probably uploaded i386 binaries
themselves.
That said, I'm happy to ask the maintainers to attempt whatever seems
most appropriate.
--
Rob Browning
rlb @defaultvalue.org and @debian.org
GPG as of 2002-11-03 14DD 432F AE39 534D B592 F9A0 25C8 D377 8C7E 73A4
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-13 19:50 ` Rob Browning
@ 2012-07-14 6:21 ` Eli Zaretskii
0 siblings, 0 replies; 24+ messages in thread
From: Eli Zaretskii @ 2012-07-14 6:21 UTC (permalink / raw)
To: Rob Browning; +Cc: 11913
> From: Rob Browning <rlb@defaultvalue.org>
> Cc: rgm@gnu.org, 11913@debbugs.gnu.org
> Date: Fri, 13 Jul 2012 14:50:38 -0500
>
> Eli Zaretskii <eliz@gnu.org> writes:
>
> > Does that 386 machine have an x87 co-processor? If not, what provides
> > the floating-point emulation -- the kernel?
>
> It's a P4 Xeon, so it should have x87 support:
Yes, of course. You said "386", so I somehow thought it was a _real_
i386.
Then I think the only thing that will help is run this under a
debugger.
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-13 18:40 ` Eli Zaretskii
2012-07-13 19:02 ` Andreas Schwab
2012-07-13 19:02 ` Rob Browning
@ 2012-07-13 19:04 ` Glenn Morris
2012-07-13 19:15 ` Eli Zaretskii
2012-07-14 21:45 ` Rob Browning
2 siblings, 2 replies; 24+ messages in thread
From: Glenn Morris @ 2012-07-13 19:04 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: 11913, rlb
Eli Zaretskii wrote:
>> > cal-hebrew.el:819:56:Error: Arithmetic error: "abs", 8.0
[...]
> Do we even understand how this error happens? There's nothing even
> close to a reference to 'abs' on that line of cal-hebrew.el in my copy
> of Emacs 24.1.
Line 819 of cal-hebrew.el in Emacs 24 is diary-hebrew-birthday.
This calls calendar-absolute-from-gregorian, which uses the `abs'
function. I assume it's something to do with that, but I have no idea
why that function should even be called during the building of Emacs.
There are few calendar callers of the `abs' function.
Another is calendar-dst-find-data. This is actually called when cal-dst
is loaded, so an error from there during building would make slightly
more sense.
But why does (abs 8.0) return an arithmetic error at all...?
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-13 19:04 ` Glenn Morris
@ 2012-07-13 19:15 ` Eli Zaretskii
2012-07-13 19:19 ` Glenn Morris
2012-07-14 21:45 ` Rob Browning
1 sibling, 1 reply; 24+ messages in thread
From: Eli Zaretskii @ 2012-07-13 19:15 UTC (permalink / raw)
To: Glenn Morris; +Cc: 11913, rlb
> From: Glenn Morris <rgm@gnu.org>
> Cc: rlb@defaultvalue.org, 11913@debbugs.gnu.org
> Date: Fri, 13 Jul 2012 15:04:25 -0400
>
> Eli Zaretskii wrote:
>
> >> > cal-hebrew.el:819:56:Error: Arithmetic error: "abs", 8.0
> [...]
> > Do we even understand how this error happens? There's nothing even
> > close to a reference to 'abs' on that line of cal-hebrew.el in my copy
> > of Emacs 24.1.
>
> Line 819 of cal-hebrew.el in Emacs 24 is diary-hebrew-birthday.
> This calls calendar-absolute-from-gregorian, which uses the `abs'
> function.
No, line 819 is this:
(defun diary-hebrew-birthday (month day year &optional after-sunset)
This doesn't call anything. So this is still mystery in my eyes.
Btw, column 56, assuming it is 1-based, is 'a' in after-sunset. Huh??
> But why does (abs 8.0) return an arithmetic error at all...?
Hardware problem or some kernel issue are the only things that come to
mind. Running under a debugger should bring more info.
And I still don't see how 'abs' could be called from that line and
that column.
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-13 19:15 ` Eli Zaretskii
@ 2012-07-13 19:19 ` Glenn Morris
2012-07-13 19:37 ` Eli Zaretskii
0 siblings, 1 reply; 24+ messages in thread
From: Glenn Morris @ 2012-07-13 19:19 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: 11913, rlb
Eli Zaretskii wrote:
> No, line 819 is this:
>
> (defun diary-hebrew-birthday (month day year &optional after-sunset)
I put less trust in the precise line number reported by the Emacs byte
compiler. :)
(I don't think debugging the Lisp level is likely to be useful anyway.)
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-13 19:19 ` Glenn Morris
@ 2012-07-13 19:37 ` Eli Zaretskii
2012-07-13 19:47 ` Andreas Schwab
0 siblings, 1 reply; 24+ messages in thread
From: Eli Zaretskii @ 2012-07-13 19:37 UTC (permalink / raw)
To: Glenn Morris; +Cc: 11913, rlb
> From: Glenn Morris <rgm@gnu.org>
> Cc: rlb@defaultvalue.org, 11913@debbugs.gnu.org
> Date: Fri, 13 Jul 2012 15:19:58 -0400
>
> Eli Zaretskii wrote:
>
> > No, line 819 is this:
> >
> > (defun diary-hebrew-birthday (month day year &optional after-sunset)
>
> I put less trust in the precise line number reported by the Emacs byte
> compiler. :)
This is a slippery slope: if we don't trust that (in a released
version!), then why do we trust the rest of that error message?
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-13 19:37 ` Eli Zaretskii
@ 2012-07-13 19:47 ` Andreas Schwab
0 siblings, 0 replies; 24+ messages in thread
From: Andreas Schwab @ 2012-07-13 19:47 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: 11913, rlb
Eli Zaretskii <eliz@gnu.org> writes:
> This is a slippery slope: if we don't trust that (in a released
> version!), then why do we trust the rest of that error message?
Because line numbers are much harder to get right.
Andreas.
--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-13 19:04 ` Glenn Morris
2012-07-13 19:15 ` Eli Zaretskii
@ 2012-07-14 21:45 ` Rob Browning
2012-07-17 2:33 ` Rob Browning
1 sibling, 1 reply; 24+ messages in thread
From: Rob Browning @ 2012-07-14 21:45 UTC (permalink / raw)
To: Glenn Morris; +Cc: 11913
Glenn Morris <rgm@gnu.org> writes:
> But why does (abs 8.0) return an arithmetic error at all...?
OK, at the moment, I believe the short answer is because fabs() is
changing errno which triggers the default clause in IN_FLOAT() here:
default: arith_error (float_error_fn_name, float_error_arg);
I've been told that this should be considered an Emacs bug because the
effect of fabs() on errno is strictly undefined, and so fabs() is within
its rights to do whatever it wants to the value.
Hope this helps.
--
Rob Browning
rlb @defaultvalue.org and @debian.org
GPG as of 2002-11-03 14DD 432F AE39 534D B592 F9A0 25C8 D377 8C7E 73A4
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-14 21:45 ` Rob Browning
@ 2012-07-17 2:33 ` Rob Browning
0 siblings, 0 replies; 24+ messages in thread
From: Rob Browning @ 2012-07-17 2:33 UTC (permalink / raw)
To: Glenn Morris; +Cc: 11913
Rob Browning <rlb@defaultvalue.org> writes:
> Glenn Morris <rgm@gnu.org> writes:
>
>> But why does (abs 8.0) return an arithmetic error at all...?
>
> OK, at the moment, I believe the short answer is because fabs() is
> changing errno which triggers the default clause in IN_FLOAT() here:
>
> default: arith_error (float_error_fn_name, float_error_arg);
>
> I've been told that this should be considered an Emacs bug because the
> effect of fabs() on errno is strictly undefined, and so fabs() is within
> its rights to do whatever it wants to the value.
For now, I'm going to deploy a patch in the Debian package that just
adds a DEB_IN_FLOAT_NOERRNO() that omits the errno checking, and then
uses that macro for the fabs() call.
Doing something with a similar result would probably be advisable.
Thanks for the help.
--
Rob Browning
rlb @defaultvalue.org and @debian.org
GPG as of 2002-11-03 14DD 432F AE39 534D B592 F9A0 25C8 D377 8C7E 73A4
^ permalink raw reply [flat|nested] 24+ messages in thread
* bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine
2012-07-11 17:53 bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine Rob Browning
2012-07-11 19:16 ` Glenn Morris
@ 2012-07-17 2:59 ` Paul Eggert
1 sibling, 0 replies; 24+ messages in thread
From: Paul Eggert @ 2012-07-17 2:59 UTC (permalink / raw)
To: Rob Browning, 11913-done
Thanks for that bug report. It's definitely an Emacs bug.
I applied the obvious fix as trunk bzr 109108
and am marking this as done.
^ permalink raw reply [flat|nested] 24+ messages in thread
end of thread, other threads:[~2012-07-17 2:59 UTC | newest]
Thread overview: 24+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-07-11 17:53 bug#11913: Unusual Emacs 24.1 arithmetic error (abs) on i386 machine Rob Browning
2012-07-11 19:16 ` Glenn Morris
2012-07-11 21:52 ` Rob Browning
2012-07-13 17:47 ` Rob Browning
2012-07-13 17:51 ` Glenn Morris
2012-07-13 18:40 ` Eli Zaretskii
2012-07-13 19:02 ` Andreas Schwab
2012-07-13 19:02 ` Rob Browning
2012-07-13 19:17 ` Eli Zaretskii
2012-07-13 19:29 ` Andreas Schwab
2012-07-13 19:35 ` Eli Zaretskii
2012-07-13 19:51 ` Andreas Schwab
2012-07-14 6:23 ` Eli Zaretskii
2012-07-14 8:09 ` Andreas Schwab
2012-07-13 19:50 ` Rob Browning
2012-07-14 6:21 ` Eli Zaretskii
2012-07-13 19:04 ` Glenn Morris
2012-07-13 19:15 ` Eli Zaretskii
2012-07-13 19:19 ` Glenn Morris
2012-07-13 19:37 ` Eli Zaretskii
2012-07-13 19:47 ` Andreas Schwab
2012-07-14 21:45 ` Rob Browning
2012-07-17 2:33 ` Rob Browning
2012-07-17 2:59 ` Paul Eggert
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.