aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gcc/ChangeLog38
-rw-r--r--gcc/ada/ChangeLog6
-rw-r--r--gcc/ada/gcc-interface/utils.c49
-rw-r--r--gcc/attribs.c2
-rw-r--r--gcc/c-family/ChangeLog7
-rw-r--r--gcc/c-family/c-common.c119
-rw-r--r--gcc/config/alpha/alpha.c7
-rw-r--r--gcc/config/arc/arc.c8
-rw-r--r--gcc/config/arm/arm.c35
-rw-r--r--gcc/config/avr/avr.c23
-rw-r--r--gcc/config/bfin/bfin.c39
-rw-r--r--gcc/config/crx/crx.c4
-rw-r--r--gcc/config/darwin.h7
-rw-r--r--gcc/config/h8300/h8300.c26
-rw-r--r--gcc/config/i386/cygming.h6
-rw-r--r--gcc/config/i386/i386.c47
-rw-r--r--gcc/config/ia64/ia64.c15
-rw-r--r--gcc/config/m32c/m32c.c11
-rw-r--r--gcc/config/m32r/m32r.c10
-rw-r--r--gcc/config/m68hc11/m68hc11.c20
-rw-r--r--gcc/config/m68k/m68k.c14
-rw-r--r--gcc/config/mcore/mcore.c12
-rw-r--r--gcc/config/mep/mep.c24
-rw-r--r--gcc/config/microblaze/microblaze.c12
-rw-r--r--gcc/config/mips/mips.c23
-rw-r--r--gcc/config/rs6000/rs6000.c20
-rw-r--r--gcc/config/rx/rx.c14
-rw-r--r--gcc/config/sh/sh.c35
-rw-r--r--gcc/config/sol2.h4
-rw-r--r--gcc/config/sparc/sparc.c5
-rw-r--r--gcc/config/spu/spu.c11
-rw-r--r--gcc/config/stormy16/stormy16.c14
-rw-r--r--gcc/config/v850/v850.c20
-rw-r--r--gcc/cp/ChangeLog5
-rw-r--r--gcc/cp/tree.c14
-rw-r--r--gcc/doc/plugins.texi2
-rw-r--r--gcc/java/ChangeLog5
-rw-r--r--gcc/java/lang.c4
-rw-r--r--gcc/lto/ChangeLog5
-rw-r--r--gcc/lto/lto-lang.c34
-rw-r--r--gcc/testsuite/ChangeLog5
-rw-r--r--gcc/testsuite/g++.dg/plugin/attribute_plugin.c2
-rw-r--r--gcc/tree.h2
43 files changed, 484 insertions, 281 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 7d38781..14f4cad 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,41 @@
+2011-03-21 Kai Tietz <ktietz@redhat.com>
+
+ PR target/12171
+ * doc/plugins.texi: Adjust documentation
+ for plugin register_callback.
+ * tree.h (attribute_spec): Add new member
+ affects_type_identity.
+ - Zitierten Text anzeigen -
+ * attribs.c (empty_attribute_table): Adjust
+ attribute_spec initializers.
+ * config/alpha/alpha.c: Likewise.
+ * config/arc/arc.c: Likewise.
+ * config/arm/arm.c: Likewise.
+ * config/avr/avr.c: Likewise.
+ * config/bfin/bfin.c: Likewise.
+ * config/crx/crx.c: Likewise.
+ * config/darwin.h: Likewise.
+ * config/h8300/h8300.c: Likewise.
+ * config/i386/cygming.h: Likewise.
+ * config/i386/i386.c: Likewise.
+ * config/ia64/ia64.c: Likewise.
+ * config/m32c/m32c.c: Likewise.
+ * config/m32r/m32r.c: Likewise.
+ * config/m68hc11/m68hc11.c: Likewise.
+ * config/m68k/m68k.c: Likewise.
+ * config/mcore/mcore.c: Likewise.
+ * config/mep/mep.c: Likewise.
+ * config/microblaze/microblaze.c: Likewise.
+ * config/mips/mips.c: Likewise.
+ * config/rs6000/rs6000.c: Likewise.
+ * config/rx/rx.c: Likewise.
+ * config/sh/sh.c: Likewise.
+ * config/sol2.h: Likewise.
+ * config/sparc/sparc.c: Likewise.
+ * config/spu/spu.c: Likewise.
+ * config/stormy16/stormy16.c: Likewise.
+ * config/v850/v850.c: Likewise.
+
2011-03-21 Chung-Lin Tang <cltang@codesourcery.com>
* simplify-rtx.c (simplify_binary_operation_1): Handle
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog
index fc87a82..46e4e22 100644
--- a/gcc/ada/ChangeLog
+++ b/gcc/ada/ChangeLog
@@ -1,3 +1,9 @@
+2011-03-21 Kai Tietz <ktietz@redhat.com>
+
+ PR target/12171
+ * gcc-interface/utils.c (gnat_internal_attribute_table):
+ Add new element.
+
2011-03-17 Eric Botcazou <ebotcazou@adacore.com>
* gcc-interface/decl.c (elaborate_expression_1): Try harder to find
diff --git a/gcc/ada/gcc-interface/utils.c b/gcc/ada/gcc-interface/utils.c
index 4d40f86..6db6375 100644
--- a/gcc/ada/gcc-interface/utils.c
+++ b/gcc/ada/gcc-interface/utils.c
@@ -104,29 +104,42 @@ static tree fake_attribute_handler (tree *, tree, tree, int, bool *);
this minimal set of attributes to accommodate the needs of builtins. */
const struct attribute_spec gnat_internal_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
- { "const", 0, 0, true, false, false, handle_const_attribute },
- { "nothrow", 0, 0, true, false, false, handle_nothrow_attribute },
- { "pure", 0, 0, true, false, false, handle_pure_attribute },
- { "no vops", 0, 0, true, false, false, handle_novops_attribute },
- { "nonnull", 0, -1, false, true, true, handle_nonnull_attribute },
- { "sentinel", 0, 1, false, true, true, handle_sentinel_attribute },
- { "noreturn", 0, 0, true, false, false, handle_noreturn_attribute },
- { "leaf", 0, 0, true, false, false, handle_leaf_attribute },
- { "malloc", 0, 0, true, false, false, handle_malloc_attribute },
- { "type generic", 0, 0, false, true, true, handle_type_generic_attribute },
-
- { "vector_size", 1, 1, false, true, false, handle_vector_size_attribute },
- { "vector_type", 0, 0, false, true, false, handle_vector_type_attribute },
- { "may_alias", 0, 0, false, true, false, NULL },
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
+ { "const", 0, 0, true, false, false, handle_const_attribute,
+ false },
+ { "nothrow", 0, 0, true, false, false, handle_nothrow_attribute,
+ false },
+ { "pure", 0, 0, true, false, false, handle_pure_attribute,
+ false },
+ { "no vops", 0, 0, true, false, false, handle_novops_attribute,
+ false },
+ { "nonnull", 0, -1, false, true, true, handle_nonnull_attribute,
+ false },
+ { "sentinel", 0, 1, false, true, true, handle_sentinel_attribute,
+ false },
+ { "noreturn", 0, 0, true, false, false, handle_noreturn_attribute,
+ false },
+ { "leaf", 0, 0, true, false, false, handle_leaf_attribute,
+ false },
+ { "malloc", 0, 0, true, false, false, handle_malloc_attribute,
+ false },
+ { "type generic", 0, 0, false, true, true, handle_type_generic_attribute,
+ false },
+
+ { "vector_size", 1, 1, false, true, false, handle_vector_size_attribute,
+ false },
+ { "vector_type", 0, 0, false, true, false, handle_vector_type_attribute,
+ false },
+ { "may_alias", 0, 0, false, true, false, NULL, false },
/* ??? format and format_arg are heavy and not supported, which actually
prevents support for stdio builtins, which we however declare as part
of the common builtins.def contents. */
- { "format", 3, 3, false, true, true, fake_attribute_handler },
- { "format_arg", 1, 1, false, true, true, fake_attribute_handler },
+ { "format", 3, 3, false, true, true, fake_attribute_handler, false },
+ { "format_arg", 1, 1, false, true, true, fake_attribute_handler, false },
- { NULL, 0, 0, false, false, false, NULL }
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Associates a GNAT tree node to a GCC tree node. It is used in
diff --git a/gcc/attribs.c b/gcc/attribs.c
index fee1499..ce977d4 100644
--- a/gcc/attribs.c
+++ b/gcc/attribs.c
@@ -57,7 +57,7 @@ static bool attributes_initialized = false;
static const struct attribute_spec empty_attribute_table[] =
{
- { NULL, 0, 0, false, false, false, NULL }
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Return base name of the attribute. Ie '__attr__' is turned into 'attr'.
diff --git a/gcc/c-family/ChangeLog b/gcc/c-family/ChangeLog
index a97a04e..ad2da89 100644
--- a/gcc/c-family/ChangeLog
+++ b/gcc/c-family/ChangeLog
@@ -1,3 +1,10 @@
+2011-03-17 Kai Tietz
+
+ PR target/12171
+ * c-common.c (c_common_attribute_table):
+ Add new element.
+ (c_common_format_attribute_table): Likewise.
+
2011-03-18 Jason Merrill <jason@redhat.com>
* c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
diff --git a/gcc/c-family/c-common.c b/gcc/c-family/c-common.c
index f8d0c7e..3f1b964 100644
--- a/gcc/c-family/c-common.c
+++ b/gcc/c-family/c-common.c
@@ -583,123 +583,125 @@ const unsigned int num_c_common_reswords =
/* Table of machine-independent attributes common to all C-like languages. */
const struct attribute_spec c_common_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
{ "packed", 0, 0, false, false, false,
- handle_packed_attribute },
+ handle_packed_attribute , false},
{ "nocommon", 0, 0, true, false, false,
- handle_nocommon_attribute },
+ handle_nocommon_attribute, false},
{ "common", 0, 0, true, false, false,
- handle_common_attribute },
+ handle_common_attribute, false },
/* FIXME: logically, noreturn attributes should be listed as
"false, true, true" and apply to function types. But implementing this
would require all the places in the compiler that use TREE_THIS_VOLATILE
on a decl to identify non-returning functions to be located and fixed
to check the function type instead. */
{ "noreturn", 0, 0, true, false, false,
- handle_noreturn_attribute },
+ handle_noreturn_attribute, false },
{ "volatile", 0, 0, true, false, false,
- handle_noreturn_attribute },
+ handle_noreturn_attribute, false },
{ "noinline", 0, 0, true, false, false,
- handle_noinline_attribute },
+ handle_noinline_attribute, false },
{ "noclone", 0, 0, true, false, false,
- handle_noclone_attribute },
+ handle_noclone_attribute, false },
{ "leaf", 0, 0, true, false, false,
- handle_leaf_attribute },
+ handle_leaf_attribute, false },
{ "always_inline", 0, 0, true, false, false,
- handle_always_inline_attribute },
+ handle_always_inline_attribute, false },
{ "gnu_inline", 0, 0, true, false, false,
- handle_gnu_inline_attribute },
+ handle_gnu_inline_attribute, false },
{ "artificial", 0, 0, true, false, false,
- handle_artificial_attribute },
+ handle_artificial_attribute, false },
{ "flatten", 0, 0, true, false, false,
- handle_flatten_attribute },
+ handle_flatten_attribute, false },
{ "used", 0, 0, true, false, false,
- handle_used_attribute },
+ handle_used_attribute, false },
{ "unused", 0, 0, false, false, false,
- handle_unused_attribute },
+ handle_unused_attribute, false },
{ "externally_visible", 0, 0, true, false, false,
- handle_externally_visible_attribute },
+ handle_externally_visible_attribute, false },
/* The same comments as for noreturn attributes apply to const ones. */
{ "const", 0, 0, true, false, false,
- handle_const_attribute },
+ handle_const_attribute, false },
{ "transparent_union", 0, 0, false, false, false,
- handle_transparent_union_attribute },
+ handle_transparent_union_attribute, false },
{ "constructor", 0, 1, true, false, false,
- handle_constructor_attribute },
+ handle_constructor_attribute, false },
{ "destructor", 0, 1, true, false, false,
- handle_destructor_attribute },
+ handle_destructor_attribute, false },
{ "mode", 1, 1, false, true, false,
- handle_mode_attribute },
+ handle_mode_attribute, false },
{ "section", 1, 1, true, false, false,
- handle_section_attribute },
+ handle_section_attribute, false },
{ "aligned", 0, 1, false, false, false,
- handle_aligned_attribute },
+ handle_aligned_attribute, false },
{ "weak", 0, 0, true, false, false,
- handle_weak_attribute },
+ handle_weak_attribute, false },
{ "ifunc", 1, 1, true, false, false,
- handle_ifunc_attribute },
+ handle_ifunc_attribute, false },
{ "alias", 1, 1, true, false, false,
- handle_alias_attribute },
+ handle_alias_attribute, false },
{ "weakref", 0, 1, true, false, false,
- handle_weakref_attribute },
+ handle_weakref_attribute, false },
{ "no_instrument_function", 0, 0, true, false, false,
- handle_no_instrument_function_attribute },
+ handle_no_instrument_function_attribute,
+ false },
{ "malloc", 0, 0, true, false, false,
- handle_malloc_attribute },
+ handle_malloc_attribute, false },
{ "returns_twice", 0, 0, true, false, false,
- handle_returns_twice_attribute },
+ handle_returns_twice_attribute, false },
{ "no_stack_limit", 0, 0, true, false, false,
- handle_no_limit_stack_attribute },
+ handle_no_limit_stack_attribute, false },
{ "pure", 0, 0, true, false, false,
- handle_pure_attribute },
+ handle_pure_attribute, false },
/* For internal use (marking of builtins) only. The name contains space
to prevent its usage in source code. */
{ "no vops", 0, 0, true, false, false,
- handle_novops_attribute },
+ handle_novops_attribute, false },
{ "deprecated", 0, 1, false, false, false,
- handle_deprecated_attribute },
+ handle_deprecated_attribute, false },
{ "vector_size", 1, 1, false, true, false,
- handle_vector_size_attribute },
+ handle_vector_size_attribute, false },
{ "visibility", 1, 1, false, false, false,
- handle_visibility_attribute },
+ handle_visibility_attribute, false },
{ "tls_model", 1, 1, true, false, false,
- handle_tls_model_attribute },
+ handle_tls_model_attribute, false },
{ "nonnull", 0, -1, false, true, true,
- handle_nonnull_attribute },
+ handle_nonnull_attribute, false },
{ "nothrow", 0, 0, true, false, false,
- handle_nothrow_attribute },
- { "may_alias", 0, 0, false, true, false, NULL },
+ handle_nothrow_attribute, false },
+ { "may_alias", 0, 0, false, true, false, NULL, false },
{ "cleanup", 1, 1, true, false, false,
- handle_cleanup_attribute },
+ handle_cleanup_attribute, false },
{ "warn_unused_result", 0, 0, false, true, true,
- handle_warn_unused_result_attribute },
+ handle_warn_unused_result_attribute, false },
{ "sentinel", 0, 1, false, true, true,
- handle_sentinel_attribute },
+ handle_sentinel_attribute, false },
/* For internal use (marking of builtins) only. The name contains space
to prevent its usage in source code. */
{ "type generic", 0, 0, false, true, true,
- handle_type_generic_attribute },
+ handle_type_generic_attribute, false },
{ "alloc_size", 1, 2, false, true, true,
- handle_alloc_size_attribute },
+ handle_alloc_size_attribute, false },
{ "cold", 0, 0, true, false, false,
- handle_cold_attribute },
+ handle_cold_attribute, false },
{ "hot", 0, 0, true, false, false,
- handle_hot_attribute },
+ handle_hot_attribute, false },
{ "warning", 1, 1, true, false, false,
- handle_error_attribute },
+ handle_error_attribute, false },
{ "error", 1, 1, true, false, false,
- handle_error_attribute },
+ handle_error_attribute, false },
{ "target", 1, -1, true, false, false,
- handle_target_attribute },
+ handle_target_attribute, false },
{ "optimize", 1, -1, true, false, false,
- handle_optimize_attribute },
+ handle_optimize_attribute, false },
{ "no_split_stack", 0, 0, true, false, false,
- handle_no_split_stack_attribute },
+ handle_no_split_stack_attribute, false },
/* For internal use (marking of builtins and runtime functions) only.
The name contains space to prevent its usage in source code. */
{ "fn spec", 1, 1, false, true, true,
- handle_fnspec_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ handle_fnspec_attribute, false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Give the specifications for the format attributes, used by C and all
@@ -707,12 +709,13 @@ const struct attribute_spec c_common_attribute_table[] =
const struct attribute_spec c_common_format_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
{ "format", 3, 3, false, true, true,
- handle_format_attribute },
+ handle_format_attribute, false },
{ "format_arg", 1, 1, false, true, true,
- handle_format_arg_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ handle_format_arg_attribute, false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Return identifier for address space AS. */
diff --git a/gcc/config/alpha/alpha.c b/gcc/config/alpha/alpha.c
index 76ab31a..78b4d17 100644
--- a/gcc/config/alpha/alpha.c
+++ b/gcc/config/alpha/alpha.c
@@ -7582,9 +7582,10 @@ common_object_handler (tree *node, tree name ATTRIBUTE_UNUSED,
static const struct attribute_spec vms_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
- { COMMON_OBJECT, 0, 1, true, false, false, common_object_handler },
- { NULL, 0, 0, false, false, false, NULL }
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
+ { COMMON_OBJECT, 0, 1, true, false, false, common_object_handler, false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
void
diff --git a/gcc/config/arc/arc.c b/gcc/config/arc/arc.c
index f1afda2..fa92ccf 100644
--- a/gcc/config/arc/arc.c
+++ b/gcc/config/arc/arc.c
@@ -107,9 +107,11 @@ static void arc_conditional_register_usage (void);
static const struct attribute_spec arc_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
- { "interrupt", 1, 1, true, false, false, arc_handle_interrupt_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
+ { "interrupt", 1, 1, true, false, false, arc_handle_interrupt_attribute,
+ false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Initialize the GCC target structure. */
diff --git a/gcc/config/arm/arm.c b/gcc/config/arm/arm.c
index 4784939..e863e8c 100644
--- a/gcc/config/arm/arm.c
+++ b/gcc/config/arm/arm.c
@@ -255,20 +255,25 @@ static reg_class_t arm_preferred_rename_class (reg_class_t rclass);
/* Table of machine attributes. */
static const struct attribute_spec arm_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
/* Function calls made to this symbol must be done indirectly, because
it may lie outside of the 26 bit addressing range of a normal function
call. */
- { "long_call", 0, 0, false, true, true, NULL },
+ { "long_call", 0, 0, false, true, true, NULL, false },
/* Whereas these functions are always known to reside within the 26 bit
addressing range. */
- { "short_call", 0, 0, false, true, true, NULL },
+ { "short_call", 0, 0, false, true, true, NULL, false },
/* Specify the procedure call conventions for a function. */
- { "pcs", 1, 1, false, true, true, arm_handle_pcs_attribute },
+ { "pcs", 1, 1, false, true, true, arm_handle_pcs_attribute,
+ false },
/* Interrupt Service Routines have special prologue and epilogue requirements. */
- { "isr", 0, 1, false, false, false, arm_handle_isr_attribute },
- { "interrupt", 0, 1, false, false, false, arm_handle_isr_attribute },
- { "naked", 0, 0, true, false, false, arm_handle_fndecl_attribute },
+ { "isr", 0, 1, false, false, false, arm_handle_isr_attribute,
+ false },
+ { "interrupt", 0, 1, false, false, false, arm_handle_isr_attribute,
+ false },
+ { "naked", 0, 0, true, false, false, arm_handle_fndecl_attribute,
+ false },
#ifdef ARM_PE
/* ARM/PE has three new attributes:
interfacearm - ?
@@ -279,15 +284,17 @@ static const struct attribute_spec arm_attribute_table[] =
them with spaces. We do NOT support this. Instead, use __declspec
multiple times.
*/
- { "dllimport", 0, 0, true, false, false, NULL },
- { "dllexport", 0, 0, true, false, false, NULL },
- { "interfacearm", 0, 0, true, false, false, arm_handle_fndecl_attribute },
+ { "dllimport", 0, 0, true, false, false, NULL, false },
+ { "dllexport", 0, 0, true, false, false, NULL, false },
+ { "interfacearm", 0, 0, true, false, false, arm_handle_fndecl_attribute,
+ false },
#elif TARGET_DLLIMPORT_DECL_ATTRIBUTES
- { "dllimport", 0, 0, false, false, false, handle_dll_attribute },
- { "dllexport", 0, 0, false, false, false, handle_dll_attribute },
- { "notshared", 0, 0, false, true, false, arm_handle_notshared_attribute },
+ { "dllimport", 0, 0, false, false, false, handle_dll_attribute, false },
+ { "dllexport", 0, 0, false, false, false, handle_dll_attribute, false },
+ { "notshared", 0, 0, false, true, false, arm_handle_notshared_attribute,
+ false },
#endif
- { NULL, 0, 0, false, false, false, NULL }
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Set default optimization options. */
diff --git a/gcc/config/avr/avr.c b/gcc/config/avr/avr.c
index 6709c36..f921188 100644
--- a/gcc/config/avr/avr.c
+++ b/gcc/config/avr/avr.c
@@ -129,14 +129,21 @@ section *progmem_section;
/* AVR attributes. */
static const struct attribute_spec avr_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
- { "progmem", 0, 0, false, false, false, avr_handle_progmem_attribute },
- { "signal", 0, 0, true, false, false, avr_handle_fndecl_attribute },
- { "interrupt", 0, 0, true, false, false, avr_handle_fndecl_attribute },
- { "naked", 0, 0, false, true, true, avr_handle_fntype_attribute },
- { "OS_task", 0, 0, false, true, true, avr_handle_fntype_attribute },
- { "OS_main", 0, 0, false, true, true, avr_handle_fntype_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
+ { "progmem", 0, 0, false, false, false, avr_handle_progmem_attribute,
+ false },
+ { "signal", 0, 0, true, false, false, avr_handle_fndecl_attribute,
+ false },
+ { "interrupt", 0, 0, true, false, false, avr_handle_fndecl_attribute,
+ false },
+ { "naked", 0, 0, false, true, true, avr_handle_fntype_attribute,
+ false },
+ { "OS_task", 0, 0, false, true, true, avr_handle_fntype_attribute,
+ false },
+ { "OS_main", 0, 0, false, true, true, avr_handle_fntype_attribute,
+ false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Implement TARGET_OPTION_OPTIMIZATION_TABLE. */
diff --git a/gcc/config/bfin/bfin.c b/gcc/config/bfin/bfin.c
index a6f2a38..0e05e72 100644
--- a/gcc/config/bfin/bfin.c
+++ b/gcc/config/bfin/bfin.c
@@ -5765,21 +5765,30 @@ bfin_handle_l2_attribute (tree *node, tree ARG_UNUSED (name),
/* Table of valid machine attributes. */
static const struct attribute_spec bfin_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
- { "interrupt_handler", 0, 0, false, true, true, handle_int_attribute },
- { "exception_handler", 0, 0, false, true, true, handle_int_attribute },
- { "nmi_handler", 0, 0, false, true, true, handle_int_attribute },
- { "nesting", 0, 0, false, true, true, NULL },
- { "kspisusp", 0, 0, false, true, true, NULL },
- { "saveall", 0, 0, false, true, true, NULL },
- { "longcall", 0, 0, false, true, true, bfin_handle_longcall_attribute },
- { "shortcall", 0, 0, false, true, true, bfin_handle_longcall_attribute },
- { "l1_text", 0, 0, true, false, false, bfin_handle_l1_text_attribute },
- { "l1_data", 0, 0, true, false, false, bfin_handle_l1_data_attribute },
- { "l1_data_A", 0, 0, true, false, false, bfin_handle_l1_data_attribute },
- { "l1_data_B", 0, 0, true, false, false, bfin_handle_l1_data_attribute },
- { "l2", 0, 0, true, false, false, bfin_handle_l2_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
+ { "interrupt_handler", 0, 0, false, true, true, handle_int_attribute,
+ false },
+ { "exception_handler", 0, 0, false, true, true, handle_int_attribute,
+ false },
+ { "nmi_handler", 0, 0, false, true, true, handle_int_attribute, false },
+ { "nesting", 0, 0, false, true, true, NULL, false },
+ { "kspisusp", 0, 0, false, true, true, NULL, false },
+ { "saveall", 0, 0, false, true, true, NULL, false },
+ { "longcall", 0, 0, false, true, true, bfin_handle_longcall_attribute,
+ false },
+ { "shortcall", 0, 0, false, true, true, bfin_handle_longcall_attribute,
+ false },
+ { "l1_text", 0, 0, true, false, false, bfin_handle_l1_text_attribute,
+ false },
+ { "l1_data", 0, 0, true, false, false, bfin_handle_l1_data_attribute,
+ false },
+ { "l1_data_A", 0, 0, true, false, false, bfin_handle_l1_data_attribute,
+ false },
+ { "l1_data_B", 0, 0, true, false, false, bfin_handle_l1_data_attribute,
+ false },
+ { "l2", 0, 0, true, false, false, bfin_handle_l2_attribute, false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Implementation of TARGET_ASM_INTEGER. When using FD-PIC, we need to
diff --git a/gcc/config/crx/crx.c b/gcc/config/crx/crx.c
index 79d341c..8f635d5 100644
--- a/gcc/config/crx/crx.c
+++ b/gcc/config/crx/crx.c
@@ -183,8 +183,8 @@ static void crx_function_arg_advance (CUMULATIVE_ARGS *, enum machine_mode,
static const struct attribute_spec crx_attribute_table[] = {
/* ISRs have special prologue and epilogue requirements. */
- {"interrupt", 0, 0, false, true, true, NULL},
- {NULL, 0, 0, false, false, false, NULL}
+ {"interrupt", 0, 0, false, true, true, NULL, false},
+ {NULL, 0, 0, false, false, false, NULL, false}
};
/* Option handling. */
diff --git a/gcc/config/darwin.h b/gcc/config/darwin.h
index 0526d85..e3f6960 100644
--- a/gcc/config/darwin.h
+++ b/gcc/config/darwin.h
@@ -726,11 +726,12 @@ extern GTY(()) section * darwin_sections[NUM_DARWIN_SECTIONS];
/* Extra attributes for Darwin. */
#define SUBTARGET_ATTRIBUTE_TABLE \
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */ \
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler, \
+ affects_type_identity } */ \
{ "apple_kext_compatibility", 0, 0, false, true, false, \
- darwin_handle_kext_attribute }, \
+ darwin_handle_kext_attribute, false }, \
{ "weak_import", 0, 0, true, false, false, \
- darwin_handle_weak_import_attribute }
+ darwin_handle_weak_import_attribute, false }
#undef ASM_GENERATE_INTERNAL_LABEL
#define ASM_GENERATE_INTERNAL_LABEL(LABEL,PREFIX,NUM) \
diff --git a/gcc/config/h8300/h8300.c b/gcc/config/h8300/h8300.c
index 834fc99..774863c 100644
--- a/gcc/config/h8300/h8300.c
+++ b/gcc/config/h8300/h8300.c
@@ -5367,15 +5367,23 @@ h8300_insert_attributes (tree node, tree *attributes)
static const struct attribute_spec h8300_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
- { "interrupt_handler", 0, 0, true, false, false, h8300_handle_fndecl_attribute },
- { "saveall", 0, 0, true, false, false, h8300_handle_fndecl_attribute },
- { "OS_Task", 0, 0, true, false, false, h8300_handle_fndecl_attribute },
- { "monitor", 0, 0, true, false, false, h8300_handle_fndecl_attribute },
- { "function_vector", 0, 0, true, false, false, h8300_handle_fndecl_attribute },
- { "eightbit_data", 0, 0, true, false, false, h8300_handle_eightbit_data_attribute },
- { "tiny_data", 0, 0, true, false, false, h8300_handle_tiny_data_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
+ { "interrupt_handler", 0, 0, true, false, false,
+ h8300_handle_fndecl_attribute, false },
+ { "saveall", 0, 0, true, false, false,
+ h8300_handle_fndecl_attribute, false },
+ { "OS_Task", 0, 0, true, false, false,
+ h8300_handle_fndecl_attribute, false },
+ { "monitor", 0, 0, true, false, false,
+ h8300_handle_fndecl_attribute, false },
+ { "function_vector", 0, 0, true, false, false,
+ h8300_handle_fndecl_attribute, false },
+ { "eightbit_data", 0, 0, true, false, false,
+ h8300_handle_eightbit_data_attribute, false },
+ { "tiny_data", 0, 0, true, false, false,
+ h8300_handle_tiny_data_attribute, false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
diff --git a/gcc/config/i386/cygming.h b/gcc/config/i386/cygming.h
index 9c32dda..41ca799 100644
--- a/gcc/config/i386/cygming.h
+++ b/gcc/config/i386/cygming.h
@@ -454,8 +454,10 @@ do { \
#define TARGET_USE_LOCAL_THUNK_ALIAS_P(DECL) (!DECL_ONE_ONLY (DECL))
#define SUBTARGET_ATTRIBUTE_TABLE \
- { "selectany", 0, 0, true, false, false, ix86_handle_selectany_attribute }
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
+ { "selectany", 0, 0, true, false, false, ix86_handle_selectany_attribute, \
+ false }
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
/* mcount() does not need a counter variable. */
#undef NO_PROFILE_COUNTERS
diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c
index a25ff7e..d158969 100644
--- a/gcc/config/i386/i386.c
+++ b/gcc/config/i386/i386.c
@@ -32723,45 +32723,56 @@ ix86_expand_round (rtx operand0, rtx operand1)
/* Table of valid machine attributes. */
static const struct attribute_spec ix86_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
/* Stdcall attribute says callee is responsible for popping arguments
if they are not variable. */
- { "stdcall", 0, 0, false, true, true, ix86_handle_cconv_attribute },
+ { "stdcall", 0, 0, false, true, true, ix86_handle_cconv_attribute,
+ true },
/* Fastcall attribute says callee is responsible for popping arguments
if they are not variable. */
- { "fastcall", 0, 0, false, true, true, ix86_handle_cconv_attribute },
+ { "fastcall", 0, 0, false, true, true, ix86_handle_cconv_attribute,
+ true },
/* Thiscall attribute says callee is responsible for popping arguments
if they are not variable. */
- { "thiscall", 0, 0, false, true, true, ix86_handle_cconv_attribute },
+ { "thiscall", 0, 0, false, true, true, ix86_handle_cconv_attribute,
+ true },
/* Cdecl attribute says the callee is a normal C declaration */
- { "cdecl", 0, 0, false, true, true, ix86_handle_cconv_attribute },
+ { "cdecl", 0, 0, false, true, true, ix86_handle_cconv_attribute,
+ true },
/* Regparm attribute specifies how many integer arguments are to be
passed in registers. */
- { "regparm", 1, 1, false, true, true, ix86_handle_cconv_attribute },
+ { "regparm", 1, 1, false, true, true, ix86_handle_cconv_attribute,
+ true },
/* Sseregparm attribute says we are using x86_64 calling conventions
for FP arguments. */
- { "sseregparm", 0, 0, false, true, true, ix86_handle_cconv_attribute },
+ { "sseregparm", 0, 0, false, true, true, ix86_handle_cconv_attribute,
+ true },
/* force_align_arg_pointer says this function realigns the stack at entry. */
{ (const char *)&ix86_force_align_arg_pointer_string, 0, 0,
- false, true, true, ix86_handle_cconv_attribute },
+ false, true, true, ix86_handle_cconv_attribute, false },
#if TARGET_DLLIMPORT_DECL_ATTRIBUTES
- { "dllimport", 0, 0, false, false, false, handle_dll_attribute },
- { "dllexport", 0, 0, false, false, false, handle_dll_attribute },
- { "shared", 0, 0, true, false, false, ix86_handle_shared_attribute },
+ { "dllimport", 0, 0, false, false, false, handle_dll_attribute, false },
+ { "dllexport", 0, 0, false, false, false, handle_dll_attribute, false },
+ { "shared", 0, 0, true, false, false, ix86_handle_shared_attribute,
+ false },
#endif
- { "ms_struct", 0, 0, false, false, false, ix86_handle_struct_attribute },
- { "gcc_struct", 0, 0, false, false, false, ix86_handle_struct_attribute },
+ { "ms_struct", 0, 0, false, false, false, ix86_handle_struct_attribute,
+ false },
+ { "gcc_struct", 0, 0, false, false, false, ix86_handle_struct_attribute,
+ false },
#ifdef SUBTARGET_ATTRIBUTE_TABLE
SUBTARGET_ATTRIBUTE_TABLE,
#endif
/* ms_abi and sysv_abi calling convention function attributes. */
- { "ms_abi", 0, 0, false, true, true, ix86_handle_abi_attribute },
- { "sysv_abi", 0, 0, false, true, true, ix86_handle_abi_attribute },
- { "ms_hook_prologue", 0, 0, true, false, false, ix86_handle_fndecl_attribute },
+ { "ms_abi", 0, 0, false, true, true, ix86_handle_abi_attribute, true },
+ { "sysv_abi", 0, 0, false, true, true, ix86_handle_abi_attribute, true },
+ { "ms_hook_prologue", 0, 0, true, false, false, ix86_handle_fndecl_attribute,
+ false },
{ "callee_pop_aggregate_return", 1, 1, false, true, true,
- ix86_handle_callee_pop_aggregate_return },
+ ix86_handle_callee_pop_aggregate_return, true },
/* End element. */
- { NULL, 0, 0, false, false, false, NULL }
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Implement targetm.vectorize.builtin_vectorization_cost. */
diff --git a/gcc/config/ia64/ia64.c b/gcc/config/ia64/ia64.c
index 1d3f8b1..55a55e8 100644
--- a/gcc/config/ia64/ia64.c
+++ b/gcc/config/ia64/ia64.c
@@ -342,15 +342,18 @@ static section * ia64_hpux_function_section (tree, enum node_frequency,
/* Table of valid machine attributes. */
static const struct attribute_spec ia64_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
- { "syscall_linkage", 0, 0, false, true, true, NULL },
- { "model", 1, 1, true, false, false, ia64_handle_model_attribute },
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
+ { "syscall_linkage", 0, 0, false, true, true, NULL, false },
+ { "model", 1, 1, true, false, false, ia64_handle_model_attribute,
+ false },
#if TARGET_ABI_OPEN_VMS
- { "common_object", 1, 1, true, false, false, ia64_vms_common_object_attribute},
+ { "common_object", 1, 1, true, false, false,
+ ia64_vms_common_object_attribute, false },
#endif
{ "version_id", 1, 1, true, false, false,
- ia64_handle_version_id_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ ia64_handle_version_id_attribute, false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Implement overriding of the optimization options. */
diff --git a/gcc/config/m32c/m32c.c b/gcc/config/m32c/m32c.c
index 83bf86c..56f9cf5 100644
--- a/gcc/config/m32c/m32c.c
+++ b/gcc/config/m32c/m32c.c
@@ -3232,11 +3232,12 @@ current_function_special_page_vector (rtx x)
#undef TARGET_ATTRIBUTE_TABLE
#define TARGET_ATTRIBUTE_TABLE m32c_attribute_table
static const struct attribute_spec m32c_attribute_table[] = {
- {"interrupt", 0, 0, false, false, false, interrupt_handler},
- {"bank_switch", 0, 0, false, false, false, interrupt_handler},
- {"fast_interrupt", 0, 0, false, false, false, interrupt_handler},
- {"function_vector", 1, 1, true, false, false, function_vector_handler},
- {0, 0, 0, 0, 0, 0, 0}
+ {"interrupt", 0, 0, false, false, false, interrupt_handler, false},
+ {"bank_switch", 0, 0, false, false, false, interrupt_handler, false},
+ {"fast_interrupt", 0, 0, false, false, false, interrupt_handler, false},
+ {"function_vector", 1, 1, true, false, false, function_vector_handler,
+ false},
+ {0, 0, 0, 0, 0, 0, 0, false}
};
#undef TARGET_COMP_TYPE_ATTRIBUTES
diff --git a/gcc/config/m32r/m32r.c b/gcc/config/m32r/m32r.c
index 444f16e..820aa8d 100644
--- a/gcc/config/m32r/m32r.c
+++ b/gcc/config/m32r/m32r.c
@@ -108,10 +108,12 @@ static void m32r_trampoline_init (rtx, tree, rtx);
static const struct attribute_spec m32r_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
- { "interrupt", 0, 0, true, false, false, NULL },
- { "model", 1, 1, true, false, false, m32r_handle_model_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
+ { "interrupt", 0, 0, true, false, false, NULL, false },
+ { "model", 1, 1, true, false, false, m32r_handle_model_attribute,
+ false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
static const struct default_options m32r_option_optimization_table[] =
diff --git a/gcc/config/m68hc11/m68hc11.c b/gcc/config/m68hc11/m68hc11.c
index f45de3d..1e41410 100644
--- a/gcc/config/m68hc11/m68hc11.c
+++ b/gcc/config/m68hc11/m68hc11.c
@@ -231,13 +231,19 @@ static const struct processor_costs m6812_cost = {
static const struct attribute_spec m68hc11_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
- { "interrupt", 0, 0, false, true, true, m68hc11_handle_fntype_attribute },
- { "trap", 0, 0, false, true, true, m68hc11_handle_fntype_attribute },
- { "far", 0, 0, false, true, true, m68hc11_handle_fntype_attribute },
- { "near", 0, 0, false, true, true, m68hc11_handle_fntype_attribute },
- { "page0", 0, 0, false, false, false, m68hc11_handle_page0_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
+ { "interrupt", 0, 0, false, true, true, m68hc11_handle_fntype_attribute,
+ false },
+ { "trap", 0, 0, false, true, true, m68hc11_handle_fntype_attribute,
+ false },
+ { "far", 0, 0, false, true, true, m68hc11_handle_fntype_attribute,
+ false },
+ { "near", 0, 0, false, true, true, m68hc11_handle_fntype_attribute,
+ false },
+ { "page0", 0, 0, false, false, false, m68hc11_handle_page0_attribute,
+ false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Initialize the GCC target structure. */
diff --git a/gcc/config/m68k/m68k.c b/gcc/config/m68k/m68k.c
index b8e9ff2..5810aa4 100644
--- a/gcc/config/m68k/m68k.c
+++ b/gcc/config/m68k/m68k.c
@@ -298,11 +298,15 @@ const char *m68k_library_id_string = "_current_shared_library_a5_offset_";
static const struct attribute_spec m68k_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
- { "interrupt", 0, 0, true, false, false, m68k_handle_fndecl_attribute },
- { "interrupt_handler", 0, 0, true, false, false, m68k_handle_fndecl_attribute },
- { "interrupt_thread", 0, 0, true, false, false, m68k_handle_fndecl_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
+ { "interrupt", 0, 0, true, false, false, m68k_handle_fndecl_attribute,
+ false },
+ { "interrupt_handler", 0, 0, true, false, false,
+ m68k_handle_fndecl_attribute, false },
+ { "interrupt_thread", 0, 0, true, false, false,
+ m68k_handle_fndecl_attribute, false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
struct gcc_target targetm = TARGET_INITIALIZER;
diff --git a/gcc/config/mcore/mcore.c b/gcc/config/mcore/mcore.c
index 8118276..093ac2f 100644
--- a/gcc/config/mcore/mcore.c
+++ b/gcc/config/mcore/mcore.c
@@ -143,11 +143,13 @@ static void mcore_option_override (void);
static const struct attribute_spec mcore_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
- { "dllexport", 0, 0, true, false, false, NULL },
- { "dllimport", 0, 0, true, false, false, NULL },
- { "naked", 0, 0, true, false, false, mcore_handle_naked_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
+ { "dllexport", 0, 0, true, false, false, NULL, false },
+ { "dllimport", 0, 0, true, false, false, NULL, false },
+ { "naked", 0, 0, true, false, false, mcore_handle_naked_attribute,
+ false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* What options are we going to default to specific settings when
diff --git a/gcc/config/mep/mep.c b/gcc/config/mep/mep.c
index 913a30a..73bb45d 100644
--- a/gcc/config/mep/mep.c
+++ b/gcc/config/mep/mep.c
@@ -4088,17 +4088,19 @@ mep_validate_vliw (tree *node, tree name, tree args ATTRIBUTE_UNUSED,
static const struct attribute_spec mep_attribute_table[11] =
{
- /* name min max decl type func handler */
- { "based", 0, 0, false, false, false, mep_validate_based_tiny },
- { "tiny", 0, 0, false, false, false, mep_validate_based_tiny },
- { "near", 0, 0, false, false, false, mep_validate_near_far },
- { "far", 0, 0, false, false, false, mep_validate_near_far },
- { "disinterrupt", 0, 0, false, false, false, mep_validate_disinterrupt },
- { "interrupt", 0, 0, false, false, false, mep_validate_interrupt },
- { "io", 0, 1, false, false, false, mep_validate_io_cb },
- { "cb", 0, 1, false, false, false, mep_validate_io_cb },
- { "vliw", 0, 0, false, true, false, mep_validate_vliw },
- { NULL, 0, 0, false, false, false, NULL }
+ /* name min max decl type func handler
+ affects_type_identity */
+ { "based", 0, 0, false, false, false, mep_validate_based_tiny, false },
+ { "tiny", 0, 0, false, false, false, mep_validate_based_tiny, false },
+ { "near", 0, 0, false, false, false, mep_validate_near_far, false },
+ { "far", 0, 0, false, false, false, mep_validate_near_far, false },
+ { "disinterrupt", 0, 0, false, false, false, mep_validate_disinterrupt,
+ false },
+ { "interrupt", 0, 0, false, false, false, mep_validate_interrupt, false },
+ { "io", 0, 1, false, false, false, mep_validate_io_cb, false },
+ { "cb", 0, 1, false, false, false, mep_validate_io_cb, false },
+ { "vliw", 0, 0, false, true, false, mep_validate_vliw, false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
static bool
diff --git a/gcc/config/microblaze/microblaze.c b/gcc/config/microblaze/microblaze.c
index b50c794..a38545f 100644
--- a/gcc/config/microblaze/microblaze.c
+++ b/gcc/config/microblaze/microblaze.c
@@ -195,10 +195,14 @@ int interrupt_handler;
int save_volatiles;
const struct attribute_spec microblaze_attribute_table[] = {
- /* name min_len, max_len, decl_req, type_req, fn_type, req_handler */
- {"interrupt_handler", 0, 0, true, false, false, NULL},
- {"save_volatiles" , 0, 0, true, false, false, NULL},
- { NULL, 0, 0, false, false, false, NULL}
+ /* name min_len, max_len, decl_req, type_req, fn_type, req_handler,
+ affects_type_identity */
+ {"interrupt_handler", 0, 0, true, false, false, NULL,
+ false },
+ {"save_volatiles" , 0, 0, true, false, false, NULL,
+ false },
+ { NULL, 0, 0, false, false, false, NULL,
+ false }
};
static int microblaze_interrupt_function_p (tree);
diff --git a/gcc/config/mips/mips.c b/gcc/config/mips/mips.c
index 9de479b..11d8ff0 100644
--- a/gcc/config/mips/mips.c
+++ b/gcc/config/mips/mips.c
@@ -641,22 +641,23 @@ const enum reg_class mips_regno_to_class[FIRST_PSEUDO_REGISTER] = {
/* The value of TARGET_ATTRIBUTE_TABLE. */
static const struct attribute_spec mips_attribute_table[] = {
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
- { "long_call", 0, 0, false, true, true, NULL },
- { "far", 0, 0, false, true, true, NULL },
- { "near", 0, 0, false, true, true, NULL },
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ om_diagnostic } */
+ { "long_call", 0, 0, false, true, true, NULL, false },
+ { "far", 0, 0, false, true, true, NULL, false },
+ { "near", 0, 0, false, true, true, NULL, false },
/* We would really like to treat "mips16" and "nomips16" as type
attributes, but GCC doesn't provide the hooks we need to support
the right conversion rules. As declaration attributes, they affect
code generation but don't carry other semantics. */
- { "mips16", 0, 0, true, false, false, NULL },
- { "nomips16", 0, 0, true, false, false, NULL },
+ { "mips16", 0, 0, true, false, false, NULL, false },
+ { "nomips16", 0, 0, true, false, false, NULL, false },
/* Allow functions to be specified as interrupt handlers */
- { "interrupt", 0, 0, false, true, true, NULL },
- { "use_shadow_register_set", 0, 0, false, true, true, NULL },
- { "keep_interrupts_masked", 0, 0, false, true, true, NULL },
- { "use_debug_exception_return", 0, 0, false, true, true, NULL },
- { NULL, 0, 0, false, false, false, NULL }
+ { "interrupt", 0, 0, false, true, true, NULL, false },
+ { "use_shadow_register_set", 0, 0, false, true, true, NULL, false },
+ { "keep_interrupts_masked", 0, 0, false, true, true, NULL, false },
+ { "use_debug_exception_return", 0, 0, false, true, true, NULL, false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* A table describing all the processors GCC knows about. Names are
diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c
index 0714c8f..eca1b44 100644
--- a/gcc/config/rs6000/rs6000.c
+++ b/gcc/config/rs6000/rs6000.c
@@ -1303,16 +1303,22 @@ static const char alt_reg_names[][8] =
static const struct attribute_spec rs6000_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
- { "altivec", 1, 1, false, true, false, rs6000_handle_altivec_attribute },
- { "longcall", 0, 0, false, true, true, rs6000_handle_longcall_attribute },
- { "shortcall", 0, 0, false, true, true, rs6000_handle_longcall_attribute },
- { "ms_struct", 0, 0, false, false, false, rs6000_handle_struct_attribute },
- { "gcc_struct", 0, 0, false, false, false, rs6000_handle_struct_attribute },
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
+ { "altivec", 1, 1, false, true, false, rs6000_handle_altivec_attribute,
+ false },
+ { "longcall", 0, 0, false, true, true, rs6000_handle_longcall_attribute,
+ false },
+ { "shortcall", 0, 0, false, true, true, rs6000_handle_longcall_attribute,
+ false },
+ { "ms_struct", 0, 0, false, false, false, rs6000_handle_struct_attribute,
+ false },
+ { "gcc_struct", 0, 0, false, false, false, rs6000_handle_struct_attribute,
+ false },
#ifdef SUBTARGET_ATTRIBUTE_TABLE
SUBTARGET_ATTRIBUTE_TABLE,
#endif
- { NULL, 0, 0, false, false, false, NULL }
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Implement TARGET_OPTION_OPTIMIZATION_TABLE. */
diff --git a/gcc/config/rx/rx.c b/gcc/config/rx/rx.c
index 6b179e7..592f311 100644
--- a/gcc/config/rx/rx.c
+++ b/gcc/config/rx/rx.c
@@ -2237,11 +2237,15 @@ rx_handle_func_attribute (tree * node,
/* Table of RX specific attributes. */
const struct attribute_spec rx_attribute_table[] =
{
- /* Name, min_len, max_len, decl_req, type_req, fn_type_req, handler. */
- { "fast_interrupt", 0, 0, true, false, false, rx_handle_func_attribute },
- { "interrupt", 0, 0, true, false, false, rx_handle_func_attribute },
- { "naked", 0, 0, true, false, false, rx_handle_func_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ /* Name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity. */
+ { "fast_interrupt", 0, 0, true, false, false, rx_handle_func_attribute,
+ false },
+ { "interrupt", 0, 0, true, false, false, rx_handle_func_attribute,
+ false },
+ { "naked", 0, 0, true, false, false, rx_handle_func_attribute,
+ false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Extra processing for target specific command line options. */
diff --git a/gcc/config/sh/sh.c b/gcc/config/sh/sh.c
index fc739dd..ee52c32a 100644
--- a/gcc/config/sh/sh.c
+++ b/gcc/config/sh/sh.c
@@ -306,15 +306,24 @@ static void sh_conditional_register_usage (void);
static const struct attribute_spec sh_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
- { "interrupt_handler", 0, 0, true, false, false, sh_handle_interrupt_handler_attribute },
- { "sp_switch", 1, 1, true, false, false, sh_handle_sp_switch_attribute },
- { "trap_exit", 1, 1, true, false, false, sh_handle_trap_exit_attribute },
- { "renesas", 0, 0, false, true, false, sh_handle_renesas_attribute },
- { "trapa_handler", 0, 0, true, false, false, sh_handle_interrupt_handler_attribute },
- { "nosave_low_regs", 0, 0, true, false, false, sh_handle_interrupt_handler_attribute },
- { "resbank", 0, 0, true, false, false, sh_handle_resbank_handler_attribute },
- { "function_vector", 1, 1, true, false, false, sh2a_handle_function_vector_handler_attribute },
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
+ { "interrupt_handler", 0, 0, true, false, false,
+ sh_handle_interrupt_handler_attribute, false },
+ { "sp_switch", 1, 1, true, false, false,
+ sh_handle_sp_switch_attribute, false },
+ { "trap_exit", 1, 1, true, false, false,
+ sh_handle_trap_exit_attribute, false },
+ { "renesas", 0, 0, false, true, false,
+ sh_handle_renesas_attribute, false },
+ { "trapa_handler", 0, 0, true, false, false,
+ sh_handle_interrupt_handler_attribute, false },
+ { "nosave_low_regs", 0, 0, true, false, false,
+ sh_handle_interrupt_handler_attribute, false },
+ { "resbank", 0, 0, true, false, false,
+ sh_handle_resbank_handler_attribute, false },
+ { "function_vector", 1, 1, true, false, false,
+ sh2a_handle_function_vector_handler_attribute, false },
#ifdef SYMBIAN
/* Symbian support adds three new attributes:
dllexport - for exporting a function/variable that will live in a dll
@@ -323,10 +332,12 @@ static const struct attribute_spec sh_attribute_table[] =
Microsoft allows multiple declspecs in one __declspec, separating
them with spaces. We do NOT support this. Instead, use __declspec
multiple times. */
- { "dllimport", 0, 0, true, false, false, sh_symbian_handle_dll_attribute },
- { "dllexport", 0, 0, true, false, false, sh_symbian_handle_dll_attribute },
+ { "dllimport", 0, 0, true, false, false,
+ sh_symbian_handle_dll_attribute, false },
+ { "dllexport", 0, 0, true, false, false,
+ sh_symbian_handle_dll_attribute, false },
#endif
- { NULL, 0, 0, false, false, false, NULL }
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Set default optimization options. */
diff --git a/gcc/config/sol2.h b/gcc/config/sol2.h
index d520dbf..7d081c6 100644
--- a/gcc/config/sol2.h
+++ b/gcc/config/sol2.h
@@ -257,8 +257,8 @@ __enable_execute_stack (void *addr) \
/* #pragma init and #pragma fini are implemented on top of init and
fini attributes. */
#define SOLARIS_ATTRIBUTE_TABLE \
- { "init", 0, 0, true, false, false, NULL }, \
- { "fini", 0, 0, true, false, false, NULL }
+ { "init", 0, 0, true, false, false, NULL, false }, \
+ { "fini", 0, 0, true, false, false, NULL, false }
/* Solaris/x86 as and gas support the common ELF .section/.pushsection
syntax. */
diff --git a/gcc/config/sparc/sparc.c b/gcc/config/sparc/sparc.c
index 2060fa2..03edae5 100644
--- a/gcc/config/sparc/sparc.c
+++ b/gcc/config/sparc/sparc.c
@@ -469,9 +469,10 @@ static enum machine_mode sparc_preferred_simd_mode (enum machine_mode);
/* Table of valid machine attributes. */
static const struct attribute_spec sparc_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ do_diagnostic } */
SUBTARGET_ATTRIBUTE_TABLE,
- { NULL, 0, 0, false, false, false, NULL }
+ { NULL, 0, 0, false, false, false, NULL, false }
};
#endif
diff --git a/gcc/config/spu/spu.c b/gcc/config/spu/spu.c
index d80d86d..46bc586 100644
--- a/gcc/config/spu/spu.c
+++ b/gcc/config/spu/spu.c
@@ -293,10 +293,13 @@ spu_libgcc_shift_count_mode (void);
/* Table of machine attributes. */
static const struct attribute_spec spu_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
- { "naked", 0, 0, true, false, false, spu_handle_fndecl_attribute },
- { "spu_vector", 0, 0, false, true, false, spu_handle_vector_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
+ { "naked", 0, 0, true, false, false, spu_handle_fndecl_attribute,
+ false },
+ { "spu_vector", 0, 0, false, true, false, spu_handle_vector_attribute,
+ false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* TARGET overrides. */
diff --git a/gcc/config/stormy16/stormy16.c b/gcc/config/stormy16/stormy16.c
index 3954d50..052285c 100644
--- a/gcc/config/stormy16/stormy16.c
+++ b/gcc/config/stormy16/stormy16.c
@@ -2170,11 +2170,15 @@ static tree xstormy16_handle_below100_attribute
static const struct attribute_spec xstormy16_attribute_table[] =
{
- /* name, min_len, max_len, decl_req, type_req, fn_type_req, handler. */
- { "interrupt", 0, 0, false, true, true, xstormy16_handle_interrupt_attribute },
- { "BELOW100", 0, 0, false, false, false, xstormy16_handle_below100_attribute },
- { "below100", 0, 0, false, false, false, xstormy16_handle_below100_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ /* name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity. */
+ { "interrupt", 0, 0, false, true, true,
+ xstormy16_handle_interrupt_attribute , false },
+ { "BELOW100", 0, 0, false, false, false,
+ xstormy16_handle_below100_attribute, false },
+ { "below100", 0, 0, false, false, false,
+ xstormy16_handle_below100_attribute, false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Handle an "interrupt" attribute;
diff --git a/gcc/config/v850/v850.c b/gcc/config/v850/v850.c
index 4fbdceb..e3a19ff 100644
--- a/gcc/config/v850/v850.c
+++ b/gcc/config/v850/v850.c
@@ -3118,13 +3118,19 @@ v850_issue_rate (void)
static const struct attribute_spec v850_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
- { "interrupt_handler", 0, 0, true, false, false, v850_handle_interrupt_attribute },
- { "interrupt", 0, 0, true, false, false, v850_handle_interrupt_attribute },
- { "sda", 0, 0, true, false, false, v850_handle_data_area_attribute },
- { "tda", 0, 0, true, false, false, v850_handle_data_area_attribute },
- { "zda", 0, 0, true, false, false, v850_handle_data_area_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
+ { "interrupt_handler", 0, 0, true, false, false,
+ v850_handle_interrupt_attribute, false },
+ { "interrupt", 0, 0, true, false, false,
+ v850_handle_interrupt_attribute, false },
+ { "sda", 0, 0, true, false, false,
+ v850_handle_data_area_attribute, false },
+ { "tda", 0, 0, true, false, false,
+ v850_handle_data_area_attribute, false },
+ { "zda", 0, 0, true, false, false,
+ v850_handle_data_area_attribute, false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Initialize the GCC target structure. */
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index e187dee..37124b4 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,3 +1,8 @@
+2011-03-21 Kai Tietz <ktietz@redhat.com>
+
+ PR target/12171
+ * tree.c (cxx_attribute_table): Adjust table.
+
2011-03-18 Jason Merrill <jason@redhat.com>
PR c++/48162
diff --git a/gcc/cp/tree.c b/gcc/cp/tree.c
index 56639ff..070ba81 100644
--- a/gcc/cp/tree.c
+++ b/gcc/cp/tree.c
@@ -2611,11 +2611,15 @@ zero_init_p (const_tree t)
/* Table of valid C++ attributes. */
const struct attribute_spec cxx_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
- { "java_interface", 0, 0, false, false, false, handle_java_interface_attribute },
- { "com_interface", 0, 0, false, false, false, handle_com_interface_attribute },
- { "init_priority", 1, 1, true, false, false, handle_init_priority_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
+ { "java_interface", 0, 0, false, false, false,
+ handle_java_interface_attribute, false },
+ { "com_interface", 0, 0, false, false, false,
+ handle_com_interface_attribute, false },
+ { "init_priority", 1, 1, true, false, false,
+ handle_init_priority_attribute, false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Handle a "java_interface" attribute; arguments as in
diff --git a/gcc/doc/plugins.texi b/gcc/doc/plugins.texi
index 767cee8..6e878e6 100644
--- a/gcc/doc/plugins.texi
+++ b/gcc/doc/plugins.texi
@@ -331,7 +331,7 @@ handle_user_attribute (tree *node, tree name, tree args,
/* Attribute definition */
static struct attribute_spec user_attr =
- @{ "user", 1, 1, false, false, false, handle_user_attribute @};
+ @{ "user", 1, 1, false, false, false, handle_user_attribute, false @};
/* Plugin callback called during attribute registration.
Registered with register_callback (plugin_name, PLUGIN_ATTRIBUTES, register_attributes, NULL)
diff --git a/gcc/java/ChangeLog b/gcc/java/ChangeLog
index 5b95565..e384294 100644
--- a/gcc/java/ChangeLog
+++ b/gcc/java/ChangeLog
@@ -1,3 +1,8 @@
+2011-03-21 Kai Tietz <ktietz@redhat.com>
+
+ PR target/12171
+ * lang.c (java_attribute_table): Adjust table.
+
2011-02-13 Joseph Myers <joseph@codesourcery.com>
* jvspec.c (jvgenmain_spec): Remove %{a*}.
diff --git a/gcc/java/lang.c b/gcc/java/lang.c
index d26f155..6a117d7 100644
--- a/gcc/java/lang.c
+++ b/gcc/java/lang.c
@@ -75,8 +75,8 @@ static tree java_eh_personality (void);
const struct attribute_spec java_attribute_table[] =
{
{ "nonnull", 0, -1, false, true, true,
- NULL },
- { NULL, 0, 0, false, false, false, NULL }
+ NULL, false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Used to avoid printing error messages with bogus function
diff --git a/gcc/lto/ChangeLog b/gcc/lto/ChangeLog
index b97da6f..124b0e7 100644
--- a/gcc/lto/ChangeLog
+++ b/gcc/lto/ChangeLog
@@ -1,3 +1,8 @@
+2011-03-21 Kai Tietz <ktietz@redhat.com>
+
+ PR target/12171
+ * lto-lang.c (lto_attribute_table): Adjust table.
+
2011-02-18 Jakub Jelinek <jakub@redhat.com>
PR bootstrap/47807
diff --git a/gcc/lto/lto-lang.c b/gcc/lto/lto-lang.c
index 5f157d6..aa928b6 100644
--- a/gcc/lto/lto-lang.c
+++ b/gcc/lto/lto-lang.c
@@ -52,29 +52,30 @@ static tree handle_format_arg_attribute (tree *, tree, tree, int, bool *);
/* Table of machine-independent attributes supported in GIMPLE. */
const struct attribute_spec lto_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ do_diagnostic } */
{ "noreturn", 0, 0, true, false, false,
- handle_noreturn_attribute },
+ handle_noreturn_attribute, false },
{ "leaf", 0, 0, true, false, false,
- handle_leaf_attribute },
+ handle_leaf_attribute, false },
/* The same comments as for noreturn attributes apply to const ones. */
{ "const", 0, 0, true, false, false,
- handle_const_attribute },
+ handle_const_attribute, false },
{ "malloc", 0, 0, true, false, false,
- handle_malloc_attribute },
+ handle_malloc_attribute, false },
{ "pure", 0, 0, true, false, false,
- handle_pure_attribute },
+ handle_pure_attribute, false },
{ "no vops", 0, 0, true, false, false,
- handle_novops_attribute },
+ handle_novops_attribute, false },
{ "nonnull", 0, -1, false, true, true,
- handle_nonnull_attribute },
+ handle_nonnull_attribute, false },
{ "nothrow", 0, 0, true, false, false,
- handle_nothrow_attribute },
+ handle_nothrow_attribute, false },
{ "sentinel", 0, 1, false, true, true,
- handle_sentinel_attribute },
+ handle_sentinel_attribute, false },
{ "type generic", 0, 0, false, true, true,
- handle_type_generic_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ handle_type_generic_attribute, false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
/* Give the specifications for the format attributes, used by C and all
@@ -82,12 +83,13 @@ const struct attribute_spec lto_attribute_table[] =
const struct attribute_spec lto_format_attribute_table[] =
{
- /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
+ /* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler,
+ affects_type_identity } */
{ "format", 3, 3, false, true, true,
- handle_format_attribute },
+ handle_format_attribute, false },
{ "format_arg", 1, 1, false, true, true,
- handle_format_arg_attribute },
- { NULL, 0, 0, false, false, false, NULL }
+ handle_format_arg_attribute, false },
+ { NULL, 0, 0, false, false, false, NULL, false }
};
enum built_in_attribute
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index dbf0e21..acb8524 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2011-03-21 Kai Tietz <ktietz@redhat.com>
+
+ PR target/12171
+ * g++.dg/plugin/attribute_plugin.c: Adjust test.
+
2011-03-21 Chung-Lin Tang <cltang@codesourcery.com>
* gcc.target/arm/xor-and.c: New.
diff --git a/gcc/testsuite/g++.dg/plugin/attribute_plugin.c b/gcc/testsuite/g++.dg/plugin/attribute_plugin.c
index e5b0566..8de5f44 100644
--- a/gcc/testsuite/g++.dg/plugin/attribute_plugin.c
+++ b/gcc/testsuite/g++.dg/plugin/attribute_plugin.c
@@ -26,7 +26,7 @@ handle_user_attribute (tree *node, tree name, tree args,
/* Attribute definition */
static struct attribute_spec user_attr =
- { "user", 1, 1, false, false, false, handle_user_attribute };
+ { "user", 1, 1, false, false, false, handle_user_attribute, false };
/* Plugin callback called during attribute registration */
diff --git a/gcc/tree.h b/gcc/tree.h
index 2a94b3a..eb5e4ca 100644
--- a/gcc/tree.h
+++ b/gcc/tree.h
@@ -4329,6 +4329,8 @@ struct attribute_spec
by the rest of this structure. */
tree (*const handler) (tree *node, tree name, tree args,
int flags, bool *no_add_attrs);
+ /* Specifies if attribute affects type's identity. */
+ const bool affects_type_identity;
};
/* Flags that may be passed in the third argument of decl_attributes, and