Tested on hppa64-hp-hpux11.11.  Committed to trunk.

Dave
---

XFAIL default_format_2.f90 and default_format_denormal_2.f90 on hppa*-*-hpux*

On hppa*-*-hpux*, snprintf only provides 33 digits of decimal
precision for long doubles.  This is insufficient to uniquely
identify long double values.  As a result, these tests fail.

2026-08-05  John David Anglin  <[email protected]>

gcc/testsuite/ChangeLog:

        * gfortran.dg/default_format_2.f90: XFAIL on hppa*-*-hpux*.
        * gfortran.dg/default_format_denormal_2.f90: Likewise.

diff --git a/gcc/testsuite/gfortran.dg/default_format_2.f90 
b/gcc/testsuite/gfortran.dg/default_format_2.f90
index dd04d3aae98..35c23412099 100644
--- a/gcc/testsuite/gfortran.dg/default_format_2.f90
+++ b/gcc/testsuite/gfortran.dg/default_format_2.f90
@@ -1,7 +1,10 @@
-! { dg-do run { xfail long_double_is_ibm128 } }
+! { dg-do run { xfail { long_double_is_ibm128 || hppa*-*-hpux* } } }
 ! { dg-require-effective-target fortran_large_real }
 ! Test XFAILed on these platforms because the system's printf() lacks
 ! proper support for denormalized long doubles. See PR24685
+! On hppa*-*-hpux*, snprintf only provides 33 digits of decimal
+! precision for long doubles.  This is insufficient to uniquely
+! identify long double values.
 !
 ! This tests that the default formats for formatted I/O of reals are
 ! wide enough and have enough precision, by checking that values can
diff --git a/gcc/testsuite/gfortran.dg/default_format_denormal_2.f90 
b/gcc/testsuite/gfortran.dg/default_format_denormal_2.f90
index ae056d506a2..37d62bbfb65 100644
--- a/gcc/testsuite/gfortran.dg/default_format_denormal_2.f90
+++ b/gcc/testsuite/gfortran.dg/default_format_denormal_2.f90
@@ -1,7 +1,10 @@
-! { dg-do run { xfail long_double_is_ibm128 } }
+! { dg-do run { xfail { long_double_is_ibm128 || hppa*-*-hpux* } } }
 ! { dg-require-effective-target fortran_large_real }
 ! Test XFAILed on this platform because the system's printf() lacks
 ! proper support for denormalized long doubles. See PR24685
+! On hppa*-*-hpux*, snprintf only provides 33 digits of decimal
+! precision for long doubles.  This is insufficient to uniquely
+! identify long double values.
 !
 ! This tests that the default formats for formatted I/O of reals are
 ! wide enough and have enough precision, by checking that values can

Attachment: signature.asc
Description: PGP signature

Reply via email to