aboutsummaryrefslogtreecommitdiff
path: root/gcc/targhooks.c
diff options
context:
space:
mode:
authorUlrich Weigand <uweigand@de.ibm.com>2008-06-18 20:49:12 +0000
committerUlrich Weigand <uweigand@gcc.gnu.org>2008-06-18 20:49:12 +0000
commit7b0518e33c7818cbaa640257226e13513e86671e (patch)
treecdc7fc54ba1d87f25a40abeb7252e518dc5a4f8a /gcc/targhooks.c
parentaa5d99391813f31c6ded568a345701fc935f2d83 (diff)
downloadgcc-7b0518e33c7818cbaa640257226e13513e86671e.zip
gcc-7b0518e33c7818cbaa640257226e13513e86671e.tar.gz
gcc-7b0518e33c7818cbaa640257226e13513e86671e.tar.bz2
targhooks.h (struct gcc_target): New member unwind_word_mode.
* targhooks.h (struct gcc_target): New member unwind_word_mode. (default_unwind_word_mode): Add prototype. * targhooks.c (default_unwind_word_mode): New function. (default_eh_return_filter_mode): Return targetm.unwind_word_mode () instead of word_mode. * target-def.h (TARGET_UNWIND_WORD_MODE): New macro. (TARGET_INITIALIZER): Use it. * c-common.c (handle_mode_attribute): Support "unwind_word" mode attribute. * unwind-generic.h (_Unwind_Word, _Unwind_Sword): Use it. * except.c (init_eh): Use targetm.unwind_word_mode () instead of word_mode to access SjLj_Function_Context member "data". (sjlj_emit_dispatch_table): Likewise. Also, perform type conversion from targetm.eh_return_filter_mode () to targetm.unwind_word_mode () if they differ. * builtin-types.def (BT_UNWINDWORD): New primitive type. (BT_FN_UNWINDWORD_PTR): New function type. (BT_FN_WORD_PTR): Remove. * builtins.def (BUILT_IN_EXTEND_POINTER): Use BT_FN_UNWINDWORD_PTR. * except.c (expand_builtin_extend_pointer): Convert pointer to targetm.unwind_word_mode () instead of word_mode. * config/spu/spu-protos.h (spu_eh_return_filter_mode): Remove. * config/spu/spu.c (spu_eh_return_filter_mode): Remove. (spu_unwind_word_mode): New function. (TARGET_EH_RETURN_FILTER_MODE): Do not define. (TARGET_UNWIND_WORD_MODE): Define. * config/spu/t-spu-elf (TARGET_LIBGCC2_CFLAGS): Remove -D__word__=SI. From-SVN: r136912
Diffstat (limited to 'gcc/targhooks.c')
-rw-r--r--gcc/targhooks.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/gcc/targhooks.c b/gcc/targhooks.c
index d719f5f..7e931c5 100644
--- a/gcc/targhooks.c
+++ b/gcc/targhooks.c
@@ -152,7 +152,7 @@ default_pretend_outgoing_varargs_named (CUMULATIVE_ARGS *ca ATTRIBUTE_UNUSED)
enum machine_mode
default_eh_return_filter_mode (void)
{
- return word_mode;
+ return targetm.unwind_word_mode ();
}
enum machine_mode
@@ -167,6 +167,12 @@ default_libgcc_shift_count_mode (void)
return word_mode;
}
+enum machine_mode
+default_unwind_word_mode (void)
+{
+ return word_mode;
+}
+
/* The default implementation of TARGET_SHIFT_TRUNCATION_MASK. */
unsigned HOST_WIDE_INT