bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

fenv-*: Port to Minix


From: Bruno Haible
Subject: fenv-*: Port to Minix
Date: Sun, 05 Nov 2023 23:26:59 +0100

On Minix 3.3, I see these test failures:


FAIL: test-fenv-except-state-1
==============================

../../gltests/test-fenv-except-state-1.c:62: assertion 'fetestexcept 
(FE_OVERFLOW) == FE_OVERFLOW' failed
FAIL test-fenv-except-state-1 (exit status: 134)

FAIL: test-fenv-except-tracking-4
=================================

../../gltests/test-fenv-except-tracking-4.c:45: assertion 'fetestexcept 
(FE_ALL_EXCEPT) == FE_INVALID' failed
FAIL test-fenv-except-tracking-4 (exit status: 134)

FAIL: test-fenv-except-trapping-2.sh
====================================

...
Failed (got no trap): ./test-fenv-except-trapping-2 4 p f
Failed (got no trap): ./test-fenv-except-trapping-2 4 p d
Failed (got no trap): ./test-fenv-except-trapping-2 4 p l
Failed (got no trap): ./test-fenv-except-trapping-2 4 q f
Failed (got no trap): ./test-fenv-except-trapping-2 4 q d
Failed (got no trap): ./test-fenv-except-trapping-2 4 q l
Failed (got no trap): ./test-fenv-except-trapping-2 4 r f
Failed (got no trap): ./test-fenv-except-trapping-2 4 r d
Failed (got no trap): ./test-fenv-except-trapping-2 4 r l
...

The latter failure is easy to work around. Then, regarding the first two:

* Forcing
    REPLACE_FETESTEXCEPT=1
    REPLACE_FECLEAREXCEPT=1
    REPLACE_FERAISEEXCEPT=1
  the tests succeed.

* Forcing only
    REPLACE_FETESTEXCEPT=1
    REPLACE_FECLEAREXCEPT=1
  the tests still succeed.

* Forcing only
    REPLACE_FETESTEXCEPT=1
  the test failures are:

    ../../gltests/test-fenv-except-state-1.c:69: assertion 'fetestexcept 
(FE_INVALID) == 0' failed
    FAIL test-fenv-except-state-1 (exit status: 134)

    ../../gltests/test-fenv-except-tracking-4.c:45: assertion 'fetestexcept 
(FE_ALL_EXCEPT) == FE_INVALID' failed
    FAIL test-fenv-except-tracking-4 (exit status: 134)

    ../../gltests/test-fenv-except-tracking-1.c:50: assertion 'fetestexcept 
(FE_ALL_EXCEPT) == 0' failed
    FAIL test-fenv-except-tracking-1 (exit status: 134)

  which clearly indicates a problem with the feclearexcept() function.

* Forcing only
    REPLACE_FECLEAREXCEPT=1
  the test failures are:

    ../../gltests/test-fenv-except-state-1.c:62: assertion 'fetestexcept 
(FE_OVERFLOW) == FE_OVERFLOW' failed
    FAIL test-fenv-except-state-1 (exit status: 134)

    ../../gltests/test-fenv-except-tracking-4.c:45: assertion 'fetestexcept 
(FE_ALL_EXCEPT) == FE_INVALID' failed
    FAIL test-fenv-except-tracking-4 (exit status: 134)

So, clearly both functions need to be overridden.


2023-11-05  Bruno Haible  <bruno@clisp.org>

        fenv-exceptions-trapping: Avoid test failure on Minix.
        * tests/test-fenv-except-trapping-2.c (main): Skip the '4' tests also on
        Minix.

        fenv-exceptions-tracking-c99: Fix test failures on Minix.
        * m4/fenv-exceptions-tracking.m4 (gl_FENV_EXCEPTIONS_TRACKING): On
        Minix, set REPLACE_FECLEAREXCEPT and REPLACE_FETESTEXCEPT to 1.
        * doc/posix-functions/feclearexcept.texi: Mention the Minix bug.
        * doc/posix-functions/fetestexcept.texi: Likewise.


Attachment: 0001-fenv-exceptions-tracking-c99-Fix-test-failures-on-Mi.patch
Description: Text Data

Attachment: 0002-fenv-exceptions-trapping-Avoid-test-failure-on-Minix.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]