public inbox for libc-ports@sourceware.org
 help / color / mirror / Atom feed
From: Richard Henderson <rth@twiddle.net>
To: libc-ports@sourceware.org
Subject: [PATCH] alpha: Define FP_TRAPPING_EXCEPTIONS
Date: Fri, 15 Jun 2012 21:28:00 -0000	[thread overview]
Message-ID: <1339795684-27777-1-git-send-email-rth@twiddle.net> (raw)

---
 ChangeLog.alpha                     |    2 ++
 sysdeps/alpha/soft-fp/sfp-machine.h |    5 ++++-
 2 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/ChangeLog.alpha b/ChangeLog.alpha
index 5ec3634..062b4f2 100644
--- a/ChangeLog.alpha
+++ b/ChangeLog.alpha
@@ -1,5 +1,7 @@
 2012-06-15  Richard Henderson  <rth@twiddle.net>
 
+	* sysdeps/alpha/soft-fp/sfp-machine.h (FP_TRAPPING_EXCEPTIONS): New.
+
 	* sysdeps/alpha/fpu/s_rint.c (__rint): Handle inexact regardless
 	of -mieee-with-inexact.
 	* sysdeps/alpha/fpu/s_rintf.c (__rintf): Likewise.
diff --git a/sysdeps/alpha/soft-fp/sfp-machine.h b/sysdeps/alpha/soft-fp/sfp-machine.h
index ef6e957..202f736 100644
--- a/sysdeps/alpha/soft-fp/sfp-machine.h
+++ b/sysdeps/alpha/soft-fp/sfp-machine.h
@@ -1,6 +1,6 @@
 /* Machine-dependent software floating-point definitions.
    Alpha userland IEEE 128-bit version.
-   Copyright (C) 2004 Free Software Foundation, Inc.
+   Copyright (C) 2004-2012 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Richard Henderson (rth@cygnus.com),
 		  Jakub Jelinek (jj@ultra.linux.cz) and
@@ -91,3 +91,6 @@ do {								\
       __ieee_set_fp_control (t | _fex);				\
     }								\
 } while (0)
+
+#define FP_TRAPPING_EXCEPTIONS					\
+  ((__ieee_get_fp_control () & SWCR_ENABLE_MASK) << SWCR_ENABLE_SHIFT)
-- 
1.7.7.6

                 reply	other threads:[~2012-06-15 21:28 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1339795684-27777-1-git-send-email-rth@twiddle.net \
    --to=rth@twiddle.net \
    --cc=libc-ports@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).