public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* RFA: Enable DFP/BID on  i?86-pc-mingw32 target
@ 2007-07-21 10:15 Danny Smith
  2007-07-21 10:57 ` Paolo Bonzini
  2007-07-21 19:56 ` Ben Elliston
  0 siblings, 2 replies; 4+ messages in thread
From: Danny Smith @ 2007-07-21 10:15 UTC (permalink / raw)
  To: GCC-patches; +Cc: bje

Hello,

With following patch libbid builds and passes all supported tests in
gcc.dg/dfp 

make -k check-gcc RUNSTESTFLAGS="dfp.exp"

		=== gcc Summary ===

# of expected passes		591
# of unsupported tests		1
/develop/svn/trunk/build/gcc/xgcc  version 4.3.0 200707158
(experimental)

I have also tried on cygwin target, but the build fails because of lack
of fenv.h,
included from libdecnumber/dec/Except.[ch].

Is this OK for mainline? 

2007-07-19  Danny Smith  <dannysmith@users.sourceforge.net>

gcc
	* configure.ac (i?86*-*-mingw*): Default enable_decimal_float to
bid.
	* configure: Regenerate
	
libgcc
	* config/t-dfprules: New file, copied from gcc/config.
	* config.host (i?86*-*-mingw*): Adds t-dfprules to tmake_file.


Index: gcc/configure.ac
===================================================================
--- gcc/configure.ac	(revision 126718)
+++ gcc/configure.ac	(working copy)
@@ -592,6 +592,9 @@
     powerpc*-*-linux* | i?86*-*-linux* | x86_64*-*-linux*)
       enable_decimal_float=yes
       ;;
+    i?86*-*-mingw*)
+      enable_decimal_float=yes
+      ;;
     *)
       AC_MSG_WARN(decimal float is not supported for this target,
ignored)
       enable_decimal_float=no
@@ -610,6 +613,9 @@
       i?86*-*-linux* | x86_64*-*-linux*)
 	enable_decimal_float=bid
 	;;
+      i?86*-*-mingw*)
+        enable_decimal_float=bid
+        ;;
       *)
 	enable_decimal_float=dpd
 	;;
Index: libgcc/config.host
===================================================================
--- libgcc/config.host	(revision 126718)
+++ libgcc/config.host	(working copy)
@@ -369,10 +369,14 @@
 	;;
 i[34567]86-*-pe)
 	;;
-i[34567]86-*-cygwin* | i[34567]86-*-mingw*)
+i[34567]86-*-cygwin*)
 	extra_parts="crtbegin.o crtend.o crtfastmath.o"
 	tmake_file="i386/t-cygming i386/t-crtfm"
 	;;
+i[34567]86-*-mingw*)
+	extra_parts="crtbegin.o crtend.o crtfastmath.o"
+	tmake_file="i386/t-cygming i386/t-crtfm t-dfprules"
+	;;
 x86_64-*-mingw*)
 	;;
 i[34567]86-*-uwin*)
Index: libgcc/config/t-dfprules
===================================================================
--- libgcc/config/t-dfprules	(revision 0)
+++ libgcc/config/t-dfprules	(revision 0)
@@ -0,0 +1,10 @@
+# Use DFP_ENABLE to build decimal floating point support routines for
+# all decimal floating point types (32-bit, 64-bit and 128-bit). We
+# use `true' for clarity, but any value will do.
+#
+DFP_ENABLE = true
+
+# DFP_CFLAGS can be used to pass target-specific CFLAGS when compiling
+# dfp-bit.c.  This is useful for overriding the definition of macros.
+#
+# DFP_CFLAGS = -DFOO=bar

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: RFA: Enable DFP/BID on  i?86-pc-mingw32 target
  2007-07-21 10:15 RFA: Enable DFP/BID on i?86-pc-mingw32 target Danny Smith
@ 2007-07-21 10:57 ` Paolo Bonzini
  2007-07-21 19:56 ` Ben Elliston
  1 sibling, 0 replies; 4+ messages in thread
From: Paolo Bonzini @ 2007-07-21 10:57 UTC (permalink / raw)
  To: Danny Smith; +Cc: GCC-patches, bje


> 	* configure.ac (i?86*-*-mingw*): Default enable_decimal_float to
> bid.
> 	* configure: Regenerate
> 	
> libgcc
> 	* config/t-dfprules: New file, copied from gcc/config.
> 	* config.host (i?86*-*-mingw*): Adds t-dfprules to tmake_file.

You could approve this yourself, ok anyway.

Paolo

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: RFA: Enable DFP/BID on  i?86-pc-mingw32 target
  2007-07-21 10:15 RFA: Enable DFP/BID on i?86-pc-mingw32 target Danny Smith
  2007-07-21 10:57 ` Paolo Bonzini
@ 2007-07-21 19:56 ` Ben Elliston
  2007-07-22 10:23   ` Danny Smith
  1 sibling, 1 reply; 4+ messages in thread
From: Ben Elliston @ 2007-07-21 19:56 UTC (permalink / raw)
  To: Danny Smith; +Cc: GCC-patches

On Sat, 2007-07-21 at 21:28 +1200, Danny Smith wrote:

> Is this OK for mainline? 

This patch doesn't really cover my maintenance area (it's just
configury), but I wanted to throw a point in: I assume that MinGW
conforms to the MS ABI?  If so, you're making an ABI extension here
because of the way that the x86 backend passes decimal float parameters,
etc.

Do you intend to just make that an undocumented extension for the time
being?  What if you wish to later conform to the MS ABI?  You'll break
your current ABI.

Cheers, Ben


^ permalink raw reply	[flat|nested] 4+ messages in thread

* RE: RFA: Enable DFP/BID on  i?86-pc-mingw32 target
  2007-07-21 19:56 ` Ben Elliston
@ 2007-07-22 10:23   ` Danny Smith
  0 siblings, 0 replies; 4+ messages in thread
From: Danny Smith @ 2007-07-22 10:23 UTC (permalink / raw)
  To: 'Ben Elliston'; +Cc: 'GCC-patches'

 Ben Elliston
 Sunday, 22 July 2007 6:01 a.m.
> 
> On Sat, 2007-07-21 at 21:28 +1200, Danny Smith wrote:
> 
> > Is this OK for mainline? 
> 
> This patch doesn't really cover my maintenance area (it's just
> configury), but I wanted to throw a point in: I assume that MinGW
> conforms to the MS ABI?  If so, you're making an ABI extension here
> because of the way that the x86 backend passes decimal float 
> parameters,
> etc.
> 
> Do you intend to just make that an undocumented extension for the time
> being?  What if you wish to later conform to the MS ABI?  You'll break
> your current ABI.

You got me.  I need to do more research.
Thanks for the comments.
Danny

> 
> Cheers, Ben
> 

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2007-07-22  3:27 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-07-21 10:15 RFA: Enable DFP/BID on i?86-pc-mingw32 target Danny Smith
2007-07-21 10:57 ` Paolo Bonzini
2007-07-21 19:56 ` Ben Elliston
2007-07-22 10:23   ` Danny Smith

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).