Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 948043 - =sys-devel/gcc-14.2.1_p20241221: possible miscompilation of sci-libs/qd on riscv
Summary: =sys-devel/gcc-14.2.1_p20241221: possible miscompilation of sci-libs/qd on riscv
Status: CONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: riscv Linux
: Normal normal
Assignee: Gentoo Toolchain Maintainers
URL:
Whiteboard:
Keywords: TESTFAILURE
Depends on:
Blocks: 915000
  Show dependency tree
 
Reported: 2025-01-13 15:58 UTC by Michael Orlitzky
Modified: 2025-01-19 09:24 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Orlitzky gentoo-dev 2025-01-13 15:58:21 UTC
I'm not terribly worried about this, but in case it's something that upstream would want to backport into the gcc-14.x branch:

The test suite for sci-libs/qd-2.3.24 fails on riscv, but only when compiled with gcc-14 and optimization enabled (-O2 or higher). Lower optimization levels are OK, and so are gcc-15 and clang-19 at -O3. So whatever the problem is, it was likely fixed in gcc-15 already.

FWIW my gcc-15 is currently Gentoo Hardened 15.0.0_pre20241208-r1 p31).

It's fairly easy to reproduce outside of portage as well:

$ ./configure --disable-static --enable-ieee-add --disable-sloppy-mul --disable-sloppy-div --enable-inline --disable-fortran
$ make check

The one test failure that arises is for the exponential function (exp) within qd_test:

Test 7.  (Sanity check for exp).
Test FAILED.
Comment 1 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2025-01-13 16:07:58 UTC
@riscv people: I'm happy to give advice on how to look at it and reduce it and so on but I'm unlikely to run it down myself.
Comment 2 Michael Orlitzky gentoo-dev 2025-01-13 16:32:09 UTC
Time has been flying and ~riscv is unstable, so I'm content to just wait for gcc-15 in ~arch. No one is clamoring for this to be keyworded -- it was only on my list as an optional dependency of a dependency of SageMath.
Comment 3 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2025-01-13 16:34:58 UTC
Yeah, normally, I'd want to run it down for my own peace of mind out of correctness, but riscv moves soooo quickly upstream too that I wouldn't be surprised if it ended up being fixed by some large change.