From 1398cbfdee648c91906897a24cbc34d50042406b Mon Sep 17 00:00:00 2001 From: bje Date: Tue, 3 Jan 2006 05:08:19 +0000 Subject: [PATCH] * targhooks.h (default_decimal_float_supported_p): Declare. * targhooks.c (default_decimal_float_supported_p): Define. * target-def.h (TARGET_DECIMAL_FLOAT_SUPPORTED_P): Redefine to `default_decimal_float_supported_p'. * doc/tm.texi (TARGET_DECIMAL_FLOAT_SUPPORTED_P): Update. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@109262 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/ChangeLog | 8 ++++++++ gcc/doc/tm.texi | 1 - gcc/target-def.h | 8 ++++---- gcc/targhooks.c | 8 ++++++++ gcc/targhooks.h | 1 + 5 files changed, 21 insertions(+), 5 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 1be3f95..c451a7e 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,11 @@ +2006-01-03 Ben Elliston + + * targhooks.h (default_decimal_float_supported_p): Declare. + * targhooks.c (default_decimal_float_supported_p): Define. + * target-def.h (TARGET_DECIMAL_FLOAT_SUPPORTED_P): Redefine to + `default_decimal_float_supported_p'. + * doc/tm.texi (TARGET_DECIMAL_FLOAT_SUPPORTED_P): Update. + 2006-01-02 Adam Nemet * combine.c (apply_distributive_law ): Check diff --git a/gcc/doc/tm.texi b/gcc/doc/tm.texi index 4960599..c9e6573 100644 --- a/gcc/doc/tm.texi +++ b/gcc/doc/tm.texi @@ -1423,7 +1423,6 @@ may affect its placement. @deftypefn {Target Hook} {bool} TARGET_DECIMAL_FLOAT_SUPPORTED_P (void) Returns true if the target supports decimal floating point. -The default version of this hook always returns false. @end deftypefn @deftypefn {Target Hook} {const char *} TARGET_MANGLE_FUNDAMENTAL_TYPE (tree @var{type}) diff --git a/gcc/target-def.h b/gcc/target-def.h index de0f19b..5848868 100644 --- a/gcc/target-def.h +++ b/gcc/target-def.h @@ -339,6 +339,10 @@ Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. #define TARGET_SCALAR_MODE_SUPPORTED_P default_scalar_mode_supported_p #endif +#ifndef TARGET_DECIMAL_FLOAT_SUPPORTED_P +#define TARGET_DECIMAL_FLOAT_SUPPORTED_P default_decimal_float_supported_p +#endif + #ifndef TARGET_VECTOR_MODE_SUPPORTED_P #define TARGET_VECTOR_MODE_SUPPORTED_P hook_bool_mode_false #endif @@ -366,10 +370,6 @@ Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. #define TARGET_MANGLE_FUNDAMENTAL_TYPE hook_constcharptr_tree_null #define TARGET_ALLOCATE_INITIAL_VALUE NULL -#ifndef TARGET_DECIMAL_FLOAT_SUPPORTED_P -#define TARGET_DECIMAL_FLOAT_SUPPORTED_P hook_bool_void_false -#endif - #ifndef TARGET_INIT_LIBFUNCS #define TARGET_INIT_LIBFUNCS hook_void_void #endif diff --git a/gcc/targhooks.c b/gcc/targhooks.c index 5ef2369..2ff2b9b 100644 --- a/gcc/targhooks.c +++ b/gcc/targhooks.c @@ -270,6 +270,14 @@ default_scalar_mode_supported_p (enum machine_mode mode) } } +/* True if the target supports decimal floating point. */ + +bool +default_decimal_float_supported_p (void) +{ + return ENABLE_DECIMAL_FLOAT; +} + /* NULL if INSN insn is valid within a low-overhead loop, otherwise returns an error message. diff --git a/gcc/targhooks.h b/gcc/targhooks.h index 8acccfd..96bff20 100644 --- a/gcc/targhooks.h +++ b/gcc/targhooks.h @@ -49,6 +49,7 @@ extern bool hook_callee_copies_named extern void default_unwind_emit (FILE *, rtx); extern bool default_scalar_mode_supported_p (enum machine_mode); +extern bool default_decimal_float_supported_p (void); extern const char * default_invalid_within_doloop (rtx); -- 2.7.4