Commit 006339cd by Richard Guenther Committed by Richard Biener

tm.texi (TARGET_HAS_SINCOS): Document new target macro.

2007-01-19  Richard Guenther  <rguenther@suse.de>

	* doc/tm.texi (TARGET_HAS_SINCOS): Document new target macro.
	* defaults.h (TARGET_HAS_SINCOS): Default to off.
	* config/linux.h (TARGET_HAS_SINCOS): Set to on if we have glibc.
	* config/alpha/linux.h (TARGET_HAS_SINCOS): Likewise.
	* config/sparc/linux.h (TARGET_HAS_SINCOS): Likewise.
	* config/sparc/linux64.h (TARGET_HAS_SINCOS): Likewise.
	* config/rs6000/linux.h (TARGET_HAS_SINCOS): Likewise.
	* config/rs6000/linux64.h (TARGET_HAS_SINCOS): Likewise.

From-SVN: r120952
parent 8ef4f42c
2007-01-19 Richard Guenther <rguenther@suse.de>
* doc/tm.texi (TARGET_HAS_SINCOS): Document new target macro.
* defaults.h (TARGET_HAS_SINCOS): Default to off.
* config/linux.h (TARGET_HAS_SINCOS): Set to on if we have glibc.
* config/alpha/linux.h (TARGET_HAS_SINCOS): Likewise.
* config/sparc/linux.h (TARGET_HAS_SINCOS): Likewise.
* config/sparc/linux64.h (TARGET_HAS_SINCOS): Likewise.
* config/rs6000/linux.h (TARGET_HAS_SINCOS): Likewise.
* config/rs6000/linux64.h (TARGET_HAS_SINCOS): Likewise.
2007-01-19 Uros Bizjak <ubizjak@gmail.com> 2007-01-19 Uros Bizjak <ubizjak@gmail.com>
* config/i386/i386.md (*fpatanxf3_i387, fpatan_extend<mode>xf3_i387): * config/i386/i386.md (*fpatanxf3_i387, fpatan_extend<mode>xf3_i387):
......
...@@ -66,6 +66,9 @@ Boston, MA 02110-1301, USA. */ ...@@ -66,6 +66,9 @@ Boston, MA 02110-1301, USA. */
runtime library. */ runtime library. */
#define TARGET_C99_FUNCTIONS (OPTION_GLIBC) #define TARGET_C99_FUNCTIONS (OPTION_GLIBC)
/* Whether we have sincos that follows the GNU extension. */
#define TARGET_HAS_SINCOS (OPTION_GLIBC)
#define TARGET_POSIX_IO #define TARGET_POSIX_IO
#define LINK_GCC_C_SEQUENCE_SPEC \ #define LINK_GCC_C_SEQUENCE_SPEC \
......
...@@ -126,4 +126,7 @@ Boston, MA 02110-1301, USA. */ ...@@ -126,4 +126,7 @@ Boston, MA 02110-1301, USA. */
is present in the runtime library. */ is present in the runtime library. */
#define TARGET_C99_FUNCTIONS (OPTION_GLIBC) #define TARGET_C99_FUNCTIONS (OPTION_GLIBC)
/* Whether we have sincos that follows the GNU extension. */
#define TARGET_HAS_SINCOS (OPTION_GLIBC)
#define TARGET_POSIX_IO #define TARGET_POSIX_IO
...@@ -35,6 +35,10 @@ ...@@ -35,6 +35,10 @@
#undef TARGET_C99_FUNCTIONS #undef TARGET_C99_FUNCTIONS
#define TARGET_C99_FUNCTIONS (OPTION_GLIBC) #define TARGET_C99_FUNCTIONS (OPTION_GLIBC)
/* Whether we have sincos that follows the GNU extension. */
#undef TARGET_HAS_SINCOS
#define TARGET_HAS_SINCOS (OPTION_GLIBC)
#undef TARGET_OS_CPP_BUILTINS #undef TARGET_OS_CPP_BUILTINS
#define TARGET_OS_CPP_BUILTINS() \ #define TARGET_OS_CPP_BUILTINS() \
do \ do \
......
...@@ -285,6 +285,10 @@ extern int dot_symbols; ...@@ -285,6 +285,10 @@ extern int dot_symbols;
#undef TARGET_C99_FUNCTIONS #undef TARGET_C99_FUNCTIONS
#define TARGET_C99_FUNCTIONS (OPTION_GLIBC) #define TARGET_C99_FUNCTIONS (OPTION_GLIBC)
/* Whether we have sincos that follows the GNU extension. */
#undef TARGET_HAS_SINCOS
#define TARGET_HAS_SINCOS (OPTION_GLIBC)
#undef TARGET_OS_CPP_BUILTINS #undef TARGET_OS_CPP_BUILTINS
#define TARGET_OS_CPP_BUILTINS() \ #define TARGET_OS_CPP_BUILTINS() \
do \ do \
......
...@@ -215,6 +215,9 @@ do { \ ...@@ -215,6 +215,9 @@ do { \
runtime library. */ runtime library. */
#define TARGET_C99_FUNCTIONS (OPTION_GLIBC) #define TARGET_C99_FUNCTIONS (OPTION_GLIBC)
/* Whether we have sincos that follows the GNU extension. */
#define TARGET_HAS_SINCOS (OPTION_GLIBC)
#define TARGET_POSIX_IO #define TARGET_POSIX_IO
#undef LINK_GCC_C_SEQUENCE_SPEC #undef LINK_GCC_C_SEQUENCE_SPEC
......
...@@ -347,6 +347,9 @@ do { \ ...@@ -347,6 +347,9 @@ do { \
runtime library. */ runtime library. */
#define TARGET_C99_FUNCTIONS (OPTION_GLIBC) #define TARGET_C99_FUNCTIONS (OPTION_GLIBC)
/* Whether we have sincos that follows the GNU extension. */
#define TARGET_HAS_SINCOS (OPTION_GLIBC)
#define TARGET_POSIX_IO #define TARGET_POSIX_IO
#undef LINK_GCC_C_SEQUENCE_SPEC #undef LINK_GCC_C_SEQUENCE_SPEC
......
...@@ -796,6 +796,12 @@ Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA ...@@ -796,6 +796,12 @@ Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA
#define TARGET_C99_FUNCTIONS 0 #define TARGET_C99_FUNCTIONS 0
#endif #endif
/* Determine whether the target runtime library has
a sincos implementation following the GNU extension. */
#ifndef TARGET_HAS_SINCOS
#define TARGET_HAS_SINCOS 0
#endif
/* Indicate that CLZ and CTZ are undefined at zero. */ /* Indicate that CLZ and CTZ are undefined at zero. */
#ifndef CLZ_DEFINED_VALUE_AT_ZERO #ifndef CLZ_DEFINED_VALUE_AT_ZERO
#define CLZ_DEFINED_VALUE_AT_ZERO(MODE, VALUE) 0 #define CLZ_DEFINED_VALUE_AT_ZERO(MODE, VALUE) 0
......
...@@ -5061,6 +5061,18 @@ number of existing systems lacks support for these functions in the runtime so ...@@ -5061,6 +5061,18 @@ number of existing systems lacks support for these functions in the runtime so
they needs this macro to be redefined to 0. they needs this macro to be redefined to 0.
@end defmac @end defmac
@cindex sincos math function, implicit usage
@defmac TARGET_HAS_SINCOS
When this macro is nonzero, GCC will implicitly optimize calls to @code{sin}
and @code{cos} with the same argument to a call to @code{sincos}. The
default is zero. The target has to provide the following functions:
@smallexample
void sincos(double x, double *sin, double *cos);
void sincosf(float x, float *sin, float *cos);
void sincosl(long double x, long double *sin, long double *cos);
@end smallexample
@end defmac
@defmac NEXT_OBJC_RUNTIME @defmac NEXT_OBJC_RUNTIME
Define this macro to generate code for Objective-C message sending using Define this macro to generate code for Objective-C message sending using
the calling convention of the NeXT system. This calling convention the calling convention of the NeXT system. This calling convention
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment