Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

one test fails for 2.5.1 release building with gcc 11/10 on i686-linux #2796

Closed
jollm opened this issue Jan 12, 2024 · 3 comments
Closed

one test fails for 2.5.1 release building with gcc 11/10 on i686-linux #2796

jollm opened this issue Jan 12, 2024 · 3 comments
Labels
Building and Packaging Issues affecting build/packaging scripts and utilities

Comments

@jollm
Copy link

jollm commented Jan 12, 2024

Describe the bug
The REQUIRE_THAT( generated, Catch::Matchers::RangeEquals( uniform_fp_test_params<TestType>::expected ) ) test fails when building with gcc on i686-linux. (for type float?)

Expected behavior
The test should pass as long as a supported compiler is used. (It does pass when building with clang++-10)

Reproduction steps
Build either with gcc 11.3 or gcc 10 targeting i686-linux.

Flags used:

-DCATCH_DEVELOPMENT_BUILD=ON
-DCATCH_ENABLE_WERROR=OFF
-DBUILD_SHARED_LIBS=ON

Platform information:

  • OS: Linux
  • Compiler+version: GCC v11.3.0
  • Catch version: v2.5.1

Additional context
See https://gitlab.com/nonguix/nonguix/-/issues/307 for downstream discovery and discussion.

@horenmar
Copy link
Member

Looks like I underestimated how many people still build 32 bit packages without SSE2 for floats.

Those tests will fail when compiled for the old x86 fpu.

@podiki
Copy link

podiki commented Jan 13, 2024

Thanks for the info on the core reason. This was found on Guix as we don't usually enable any extra architecture features by default. So at least for Guix I've enabled SSE2 so things build/test on i686 (see https://issues.guix.gnu.org/68429).

Millak pushed a commit to Millak/guix that referenced this issue Jan 14, 2024
Reported upstream to <catchorg/Catch2#2796>.  It is
expected that SSE2 is enabled for i686 builds or tests fail.

* gnu/packages/check.scm (check2)[arguments]: Enable SSE2 for x86_64-linux and
i686-linux in configure-flags.

Co-authored-by: Richard Sent <richard@freakingpenguin.com>
Co-authored-by: Jo Gay <@jane.lx.gay>
Change-Id: I99205f92b66ab3d10affbfb58918f37069ba82ec
@jollm
Copy link
Author

jollm commented Jan 15, 2024

Thanks for the explanation!, Feel free to close this for my part

@horenmar horenmar added the Building and Packaging Issues affecting build/packaging scripts and utilities label Feb 10, 2024
horenmar added a commit that referenced this issue Feb 10, 2024
Without SSE2 enabled, x86 targets will use x87 FPU, which breaks
the tests checking for reproducible results from our random
floating point number generators. The output is still reproducible,
at least between binaries targetting x87, but the tests hardcode
results for the whole pipeline being done in 32/64bit precision.

Closes #2796
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Building and Packaging Issues affecting build/packaging scripts and utilities
Projects
None yet
Development

No branches or pull requests

3 participants