GNU bug report logs - #49368
Guile 3.0.7 test failures on i686-linux, glibc 2.33 [core-updates]

Previous Next

Package: guix;

Reported by: Ludovic Courtès <ludo <at> gnu.org>

Date: Sat, 3 Jul 2021 21:42:01 UTC

Severity: important

Done: Maxime Devos <maximedevos <at> telenet.be>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 49368 in the body.
You can then email your comments to 49368 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guix <at> gnu.org:
bug#49368; Package guix. (Sat, 03 Jul 2021 21:42:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Ludovic Courtès <ludo <at> gnu.org>:
New bug report received and forwarded. Copy sent to bug-guix <at> gnu.org. (Sat, 03 Jul 2021 21:42:01 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: bug-guix <at> gnu.org
Subject: Guile 3.0.7 test failures on i686-linux, glibc 2.33 [core-updates]
Date: Sat, 03 Jul 2021 23:41:26 +0200
On current ‘core-updates’
(ca. 39f1486efd70712416ca784f9014132644b04155), Guile 3.0.7,
specifically (@@ (gnu packages commencement) guile-final) fails tests on
i686-linux:

--8<---------------cut here---------------start------------->8---
Running numbers.test
FAIL: numbers.test: Number-theoretic division: euclidean/: mixed types: (130.0 10/7)
FAIL: numbers.test: Number-theoretic division: euclidean/: mixed types: (130.0 -10/7)
FAIL: numbers.test: Number-theoretic division: floor/: mixed types: (130.0 10/7)
FAIL: numbers.test: Number-theoretic division: floor/: mixed types: (-130.0 -10/7)
FAIL: numbers.test: Number-theoretic division: ceiling/: mixed types: (130.0 -10/7)
FAIL: numbers.test: Number-theoretic division: ceiling/: mixed types: (-130.0 10/7)
FAIL: numbers.test: Number-theoretic division: truncate/: mixed types: (130.0 10/7)
FAIL: numbers.test: Number-theoretic division: truncate/: mixed types: (130.0 -10/7)
FAIL: numbers.test: Number-theoretic division: truncate/: mixed types: (-130.0 10/7)
FAIL: numbers.test: Number-theoretic division: truncate/: mixed types: (-130.0 -10/7)
--8<---------------cut here---------------end--------------->8---

Note that this doesn’t happen on ‘master’ (glibc 3.31).

Ludo’.




Severity set to 'important' from 'normal' Request was from Ludovic Courtès <ludo <at> gnu.org> to control <at> debbugs.gnu.org. (Sat, 03 Jul 2021 21:46:02 GMT) Full text and rfc822 format available.

Information forwarded to bug-guix <at> gnu.org:
bug#49368; Package guix. (Sun, 04 Jul 2021 12:07:01 GMT) Full text and rfc822 format available.

Message #10 received at 49368 <at> debbugs.gnu.org (full text, mbox):

From: Maxime Devos <maximedevos <at> telenet.be>
To: Ludovic Courtès <ludo <at> gnu.org>, 49368 <at> debbugs.gnu.org
Subject: Re: bug#49368: Guile 3.0.7 test failures on i686-linux, glibc 2.33
 [core-updates]
Date: Sun, 04 Jul 2021 14:06:20 +0200
[Message part 1 (text/plain, inline)]
Ludovic Courtès schreef op za 03-07-2021 om 23:41 [+0200]:
> On current ‘core-updates’
> (ca. 39f1486efd70712416ca784f9014132644b04155), Guile 3.0.7,
> specifically (@@ (gnu packages commencement) guile-final) fails tests on
> i686-linux:
> 
> --8<---------------cut here---------------start------------->8---
> Running numbers.test
> FAIL: numbers.test: Number-theoretic division: euclidean/: mixed types: (130.0 10/7)
> FAIL: numbers.test: Number-theoretic division: euclidean/: mixed types: (130.0 -10/7)
> FAIL: numbers.test: Number-theoretic division: floor/: mixed types: (130.0 10/7)
> FAIL: numbers.test: Number-theoretic division: floor/: mixed types: (-130.0 -10/7)
> FAIL: numbers.test: Number-theoretic division: ceiling/: mixed types: (130.0 -10/7)
> FAIL: numbers.test: Number-theoretic division: ceiling/: mixed types: (-130.0 10/7)
> FAIL: numbers.test: Number-theoretic division: truncate/: mixed types: (130.0 10/7)
> FAIL: numbers.test: Number-theoretic division: truncate/: mixed types: (130.0 -10/7)
> FAIL: numbers.test: Number-theoretic division: truncate/: mixed types: (-130.0 10/7)
> FAIL: numbers.test: Number-theoretic division: truncate/: mixed types: (-130.0 -10/7)
> --8<---------------cut here---------------end--------------->8---
> 
> Note that this doesn’t happen on ‘master’ (glibc 3.31).

In a REPL:

(euclidean/ 130.0 10/7)
(euclidean/ 130.0 -10/7)
(floor/ 130.0 10/7)
(floor/ -130.0 -10/7)
(ceiling/ 130.0 -10/7)
(ceiling/ -130.0 10/7)
(truncate/ 130.0 10/7)
(truncate/ 130.0 -10/7)
(truncate/ -130.0 10/7)
(truncate/ -130.0 -10/7)

Output on core-updates (using --keep-failed and ./meta/uninstalled-env guile):

scheme@(guile-user)> (euclidean/ 130.0 10/7)
$1 = 90.0
$2 = 1.4285714285714257
scheme@(guile-user)> (euclidean/ 130.0 -10/7)
$3 = -90.0
$4 = 1.4285714285714257
scheme@(guile-user)> (floor/ 130.0 10/7)
$5 = 90.0
$6 = 1.4285714285714257
scheme@(guile-user)> (floor/ -130.0 -10/7)
$7 = 90.0
$8 = -1.4285714285714257
scheme@(guile-user)> (ceiling/ 130.0 -10/7)
$9 = -90.0
$10 = 1.4285714285714257
scheme@(guile-user)> (ceiling/ -130.0 10/7)
$11 = -90.0
$12 = -1.4285714285714257
scheme@(guile-user)> (truncate/ 130.0 10/7)
$13 = 90.0
$14 = 1.4285714285714257
scheme@(guile-user)> (truncate/ 130.0 -10/7)
$15 = -90.0
$16 = 1.4285714285714257
scheme@(guile-user)> (truncate/ -130.0 10/7)
$17 = -90.0
$18 = -1.4285714285714257
scheme@(guile-user)> (truncate/ -130.0 -10/7)
$19 = 90.0
$20 = -1.4285714285714257

It appears that truncate/, ceiling/ and floor/ give the same output ...
that doesn't seem correct.

Greetings,
Maxime.
[signature.asc (application/pgp-signature, inline)]

Information forwarded to bug-guix <at> gnu.org:
bug#49368; Package guix. (Sun, 04 Jul 2021 12:33:01 GMT) Full text and rfc822 format available.

Message #13 received at 49368 <at> debbugs.gnu.org (full text, mbox):

From: Maxime Devos <maximedevos <at> telenet.be>
To: Ludovic Courtès <ludo <at> gnu.org>, 49368 <at> debbugs.gnu.org
Subject: Re: bug#49368: Guile 3.0.7 test failures on i686-linux, glibc 2.33
 [core-updates]
Date: Sun, 04 Jul 2021 14:31:54 +0200
[Message part 1 (text/plain, inline)]
Ludovic Courtès schreef op za 03-07-2021 om 23:41 [+0200]:
> On current ‘core-updates’
> (ca. 39f1486efd70712416ca784f9014132644b04155), Guile 3.0.7,
> specifically (@@ (gnu packages commencement) guile-final) fails tests on
> i686-linux:
> 
> --8<---------------cut here---------------start------------->8---
> Running numbers.test
> FAIL: numbers.test: Number-theoretic division: euclidean/: mixed types: (130.0 10/7)
> [...]

Curiously, on core-updates, ceiling/ is inconsistent with ceiling-quotient
and ceiling-remainder:

scheme@(guile-user) [1]> (ceiling/ 130.0 -10/7)
$28 = -90.0
$29 = 1.4285714285714257
scheme@(guile-user) [1]> (ceiling-quotient 130.0 -10/7)
$30 = -91.0
scheme@(guile-user) [1]> (ceiling-remainder 130.0 -10/7)
$31 = 0.0

But on 'master', the results are consistent:

scheme@(guile-user)> (ceiling/ 130.0 -10/7)
$1 = -91.0
$2 = 0.0
scheme@(guile-user)> (ceiling-quotient 130.0 -10/7)
$3 = -91.0
scheme@(guile-user)> (ceiling-remainder 130.0 -10/7)
$4 = 0.0

To be investigated ...

Greetings,
Maxime.
> 
[signature.asc (application/pgp-signature, inline)]

Information forwarded to bug-guix <at> gnu.org:
bug#49368; Package guix. (Tue, 06 Jul 2021 13:26:01 GMT) Full text and rfc822 format available.

Message #16 received at 49368 <at> debbugs.gnu.org (full text, mbox):

From: Maxime Devos <maximedevos <at> telenet.be>
To: Ludovic Courtès <ludo <at> gnu.org>, 49368 <at> debbugs.gnu.org
Subject: Re: bug#49368: Guile 3.0.7 test failures on i686-linux, glibc 2.33
 [core-updates]
Date: Tue, 06 Jul 2021 15:24:46 +0200
[Message part 1 (text/plain, inline)]
Ludovic Courtès schreef op za 03-07-2021 om 23:41 [+0200]:
> On current ‘core-updates’
> (ca. 39f1486efd70712416ca784f9014132644b04155), Guile 3.0.7,
> specifically (@@ (gnu packages commencement) guile-final) fails tests on
> i686-linux:
> 
> --8<---------------cut here---------------start------------->8---
> Running numbers.test
> FAIL: numbers.test: Number-theoretic division: euclidean/: mixed types: (130.0 10/7)
> FAIL: numbers.test: Number-theoretic division: euclidean/: mixed types: (130.0 -10/7)
> FAIL: numbers.test: Number-theoretic division: floor/: mixed types: (130.0 10/7)
> FAIL: numbers.test: Number-theoretic division: floor/: mixed types: (-130.0 -10/7)
> FAIL: numbers.test: Number-theoretic division: ceiling/: mixed types: (130.0 -10/7)
> FAIL: numbers.test: Number-theoretic division: ceiling/: mixed types: (-130.0 10/7)
> FAIL: numbers.test: Number-theoretic division: truncate/: mixed types: (130.0 10/7)
> FAIL: numbers.test: Number-theoretic division: truncate/: mixed types: (130.0 -10/7)
> FAIL: numbers.test: Number-theoretic division: truncate/: mixed types: (-130.0 10/7)
> FAIL: numbers.test: Number-theoretic division: truncate/: mixed types: (-130.0 -10/7)
> --8<---------------cut here---------------end--------------->8---
> 
> Note that this doesn’t happen on ‘master’ (glibc 3.31).
> 
> Ludo’.

I wondered if the implementation of the C function 'ceil' is buggy,
so I tried the following (spoiler: 'ceil' doesn't seem to be the issue,
or I need another test case:

Run "guix build --system=i686-linux -e (@@ (gnu packages commencement) guile-final) --keep-failed".
In the build directory, write to a file "test.c":

#include <stdio.h>
#include <math.h>

int
main(void)
{
  double x;
  double y;
  if (scanf("%lf %lf", &x, &y) < 0) /* < 0 is actually incorrect here */
    return 1;
  if (printf("%lf/%lf=%lf\n", x,y, x/y) < 0)
    return 1;
  if (printf("ceil(%lf/%lf)=%lf\n", x,y, ceil(x/y)) < 0)
    return 1;
  return 0;
}

Run ((exact->inexact 10/7) = 1.4285714285714286 on both master and core-updates):

$ gcc -Wall -Wextra -lm test.c -o test
$ echo "130.0 1.4285714285714286" | ./test
130.000000/1.428571=91.000000
ceil(130.000000/1.428571)=91.000000

On master, the output is:
130.000000/1.428571=91.000000
ceil(130.000000/1.428571)=91.000000
(idem)

Greetings,
Maxime.
[signature.asc (application/pgp-signature, inline)]

Reply sent to Maxime Devos <maximedevos <at> telenet.be>:
You have taken responsibility. (Sat, 24 Jul 2021 18:47:02 GMT) Full text and rfc822 format available.

Notification sent to Ludovic Courtès <ludo <at> gnu.org>:
bug acknowledged by developer. (Sat, 24 Jul 2021 18:47:02 GMT) Full text and rfc822 format available.

Message #21 received at 49368-done <at> debbugs.gnu.org (full text, mbox):

From: Maxime Devos <maximedevos <at> telenet.be>
To: 49368-done <at> debbugs.gnu.org
Subject: Re: bug#49368: Guile 3.0.7 test failures on i686-linux, glibc 2.33
 [core-updates]
Date: Sat, 24 Jul 2021 20:46:25 +0200
[Message part 1 (text/plain, inline)]
Ludovic Courtès schreef op za 03-07-2021 om 23:41 [+0200]:
> On current ‘core-updates’
> (ca. 39f1486efd70712416ca784f9014132644b04155), Guile 3.0.7,
> specifically (@@ (gnu packages commencement) guile-final) fails tests on
> i686-linux:
> 
> --8<---------------cut here---------------start------------->8---
> Running numbers.test
> FAIL: numbers.test: Number-theoretic division: euclidean/: mixed types: (130.0 10/7)
> [...]

This has been fixed on core-updates:
<https://git.savannah.gnu.org/cgit/guix.git/commit/?h=core-updates&id=fccc0275091af10a46471c68df525d19f446af9e>

Closing.

Greetings,
Maxime
[signature.asc (application/pgp-signature, inline)]

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sun, 22 Aug 2021 11:24:06 GMT) Full text and rfc822 format available.

This bug report was last modified 2 years and 241 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.