aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Metcalf <cmetcalf@ezchip.com>2014-12-29 19:48:43 -0500
committerChris Metcalf <cmetcalf@ezchip.com>2014-12-29 19:48:43 -0500
commitcd2c37c979fa19e93ded9e0ed545787271ec0de2 (patch)
treef0ce8465c4c49e42cad606fb1e9940851ca80227
parente47b8d3bbc9415d5aceaeee3e946c3ab7d985bad (diff)
downloadglibc-cd2c37c979fa19e93ded9e0ed545787271ec0de2.zip
glibc-cd2c37c979fa19e93ded9e0ed545787271ec0de2.tar.gz
glibc-cd2c37c979fa19e93ded9e0ed545787271ec0de2.tar.bz2
tile: prefer inlines to macros in math_private.h.
-rw-r--r--ChangeLog6
-rw-r--r--sysdeps/tile/math_private.h10
2 files changed, 12 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog
index c25991f..3aa137c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,11 @@
2014-12-29 Chris Metcalf <cmetcalf@ezchip.com>
+ * sysdeps/tile/math_private.h (fetestexcept): Add macro to
+ parallel other exception macros.
+ (fegetenv): Convert from macro to extern inline so that it applies
+ retroactively to inline functions already seen by the compiler.
+ (fesetenv, feupdateenv, fegetround, fesetround): Likewise.
+
* posix/Makefile (before-compile): Use $(objpfx) for
posix-conf-vars-def.h.
diff --git a/sysdeps/tile/math_private.h b/sysdeps/tile/math_private.h
index 46b9a91..a58eafa 100644
--- a/sysdeps/tile/math_private.h
+++ b/sysdeps/tile/math_private.h
@@ -27,9 +27,11 @@
#define feraiseexcept(excepts) ({ 0; })
#define feclearexcept(exc) ({ 0; })
-#define fegetenv(env) ({ (void) (env); 0; })
-#define fesetenv(env) ({ (void) (env); 0; })
-#define feupdateenv(env) ({ (void) (env); 0; })
-#define fegetround() ({ FE_TONEAREST; })
+#define fetestexcept(exc) ({ 0; })
+extern inline int fegetenv (fenv_t *__e) { return 0; }
+extern inline int fesetenv (const fenv_t *__e) { return 0; }
+extern inline int feupdateenv (const fenv_t *__e) { return 0; }
+extern inline int fegetround (void) { return FE_TONEAREST; }
+extern inline int fesetround (int __d) { return 0; }
#endif