Subject: Re: bin/33295: ieeefp/except regression test fails on soft-float
To: None <gnats-admin@netbsd.org, netbsd-bugs@netbsd.org,>
From: Matthias Drochner <M.Drochner@fz-juelich.de>
List: netbsd-bugs
Date: 04/20/2006 11:45:07
The following reply was made to PR bin/33295; it has been noted by GNATS.

From: Matthias Drochner <M.Drochner@fz-juelich.de>
To: gnats-bugs@netbsd.org
Cc: gnats-admin@netbsd.org, netbsd-bugs@netbsd.org
Subject: Re: bin/33295: ieeefp/except regression test fails on soft-float 
 userlands
Date: Thu, 20 Apr 2006 13:41:50 +0200

 This is a multipart MIME message.
 
 --==_Exmh_54691082924720
 Content-Type: text/plain; charset=us-ascii
 
 
 simonb@wasabisystems.com said:
 > the softfloat library uses raise(3) to send SIGFPE
 
 How about the appended patch?
 best regards
 Matthias
 
 
 
 --==_Exmh_54691082924720
 Content-Type: text/plain ; name="fpexc.txt"; charset=us-ascii
 Content-Description: fpexc.txt
 Content-Disposition: attachment; filename="fpexc.txt"
 
 Index: Makefile
 ===================================================================
 RCS file: /cvsroot/src/regress/lib/libc/ieeefp/except/Makefile,v
 retrieving revision 1.5
 diff -u -r1.5 Makefile
 --- Makefile	18 Sep 2002 05:41:38 -0000	1.5
 +++ Makefile	20 Apr 2006 11:37:31 -0000
 @@ -4,6 +4,11 @@
  
  PROG=		except
  
 +.include <bsd.own.mk>
 +.if defined(MKSOFTFLOAT) && (${MKSOFTFLOAT} != "no")
 +CPPFLAGS+=	-DSOFTFLOAT
 +.endif
 +
  regress: ${PROG}
  	./${PROG}
  
 Index: except.c
 ===================================================================
 RCS file: /cvsroot/src/regress/lib/libc/ieeefp/except/except.c,v
 retrieving revision 1.9
 diff -u -r1.9 except.c
 --- except.c	25 Mar 2004 15:12:42 -0000	1.9
 +++ except.c	20 Apr 2006 11:37:31 -0000
 @@ -161,7 +161,11 @@
  			BARRIER();
  		}
  		assert(signal_caught == 1);
 -		assert(sicode == ops[i].sicode);
 +		assert(sicode == ops[i].sicode
 +#ifdef SOFTFLOAT /* sent by raise(3) */
 +			|| sicode == SI_USER
 +#endif
 +		);
  		signal_caught = 0;
  	}
  
 
 --==_Exmh_54691082924720--