Hi,

The core of the powerpc-FPU manipulation is okay for me. Some comments below.


> --- a/gcc/testsuite/gfortran.dg/ieee/signaling_2_c.c
> +++ b/gcc/testsuite/gfortran.dg/ieee/signaling_2_c.c
> @@ -1,3 +1,11 @@
> +#ifdef __POWERPC__ // No support for issignaling in math.h on Darwin PPC

Two things:

1. I don’t understand why that needs to be added. The companion test in 
signaling_2.f90 has:

! { dg-require-effective-target issignaling } */
! The companion C source needs access to the issignaling macro.

Therefore, if the issignaling macro is not available, the test should not even 
be run.

2. Maybe this is actually moot. Is the __builtin_issignaling() macro available 
on all targets? The test was written before it was added to the middle-end. If 
the answer to the previous question is yes, we should simply use it in instead 
of the macro.


> +/* There is no consistency re what is to be included in all_invalid.
> +   Apple libm has 0x01f80300, Openlibm/FreeBSD/NetBSD has 0x21f80700
> +   and OpenBSD has 0x01f80700. In particular, FE_INVALID_SOFT and
> +   FE_INVALID are contested. */
> +#define FE_ALL_INVALID  0x01F80700
> +#define FE_NO_INVALID   0xFE07F8FF
> +
> +/* Apple libm has 0xFFF80300 and 0x0007FCFF here. */
> +#define FE_ALL_FLAGS    0xFFF80700
> +#define FE_NO_FLAGS     0x0007F8FF

Since it’s a darwin-only file, why not follow Apple libm conventions?


> There is one test which changes from PASS to FAIL (round_4), however I think 
> this is not a real regression, and the test in its present form is expected 
> to fail.
> See comments in the test code in the source and my post: 
> https://gcc.gnu.org/pipermail/fortran/2024-July/060612.html


I agree that round_4.f90 should be added to the dg-skip-if.
But I’d like to understand better what are the other new failures, and why 
there arise?

FX

Reply via email to