This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: GTY as attribute(single patch)


Tom Tromey wrote:
"Taras" == Taras Glek <tglek@mozilla.com> writes:

Taras> Resending as a monster patch that I rebased today.


I spot-checked this and it looks reasonable to me.
I also looked at the gengtype-parse.c and gty.texi changes, which also
seem ok.

You still need to split gcc/ChangeLog into parts since the language
subdirs have their own ChangeLogs. Annoying, I know. IMO this is not
a big enough problem to warrant a separate patch submission.
Tom, thanks for the ChangeLog clarification. I split up the changelog some more. I also realized that gengtype wasn't running on architecture-specific config files so I'm sending an updated patch. I've run gengtype on every .c and .h file that contains GTY and it seems that they all conform to the new syntax now.

2008-07-21 Taras Glek <tglek@mozilla.com>
gcc/ChangeLog
* gengtype-lex.l: Removed GTY error check from lexer
* gengtype-parse.c: Changed GTY placement on structs and unions
* doc/gty.texi: Changed GTY placement in examples and mention attributes
* alias.c: Update GTY annotations.
* basic-block.h: Likewise.
* bitmap.h: Likewise.
* c-common.h: Likewise.
* c-decl.c: Likewise.
* c-parser.c: Likewise.
* c-pragma.c: Likewise.
* c-tree.h: Likewise.
* cfgloop.h: Likewise.
* cgraph.h: Likewise.
* config/arm/arm.h: Likewise.
* config/avr/avr.h: Likewise.
* config/ia64/ia64.h: Likewise.
* config/i386/i386.c: Likewise.
* config/i386/i386.h: Likewise.
* config/alpha/alpha.c: Likewise.
* config/bfin/bfin.c: Likewise.
* config/cris/cris.c: Likewise.
* config/darwin.c: Likewise.
* config/frv/frv.c: Likewise.
* config/i386/winnt.c: Likewise.
* config/iq2000/iq2000.c: Likewise.
* config/m32c/m32c.h: Likewise.
* config/mips/mips.c: Likewise.
* config/mmix/mmix.h: Likewise.
* config/pa/pa.c: Likewise.
* config/pa/pa.h: Likewise.
* config/rs6000/rs6000.c: Likewise.
* config/s390/s390.c: Likewise.
* config/sparc/sparc.c: Likewise.
* config/xtensa/xtensa.c: Likewise.
* config/score/score.h: Likewise.
* tree-data-ref.c: Likewise.
* coretypes.h: Likewise.
* cselib.h: Likewise.
* dbxout.c: Likewise.
* dwarf2out.c: Likewise.
* except.c: Likewise.
* except.h: Likewise.
* fixed-value.h: Likewise.
* function.c: Likewise.
* function.h: Likewise.
* integrate.c: Likewise.
* optabs.c: Likewise.
* output.h: Likewise.
* real.h: Likewise.
* rtl.h: Likewise.
* stringpool.c: Likewise.
* tree-flow.h: Likewise.
* tree-scalar-evolution.c: Likewise.
* tree-ssa-address.c: Likewise.
* tree-ssa-operands.h: Likewise.
* tree.c: Likewise.
* tree.h: Likewise.
* varasm.c: Likewise.
* varray.h: Likewise.
* vec.h: Likewise.

gcc/ada/ChangeLog
* ada-tree.h: Update GTY annotations.
* trans.c: Likewise.
* utils.c: Likewise.

gcc/cp/ChangeLog
* cp-tree.h: Update GTY annotations.
* decl.c: Likewise.
* mangle.c: Likewise.
* name-lookup.c: Likewise.
* name-lookup.h: Likewise.
* parser.c: Likewise.
* pt.c: Likewise.
* rtti.c: Likewise.
* semantics.c: Likewise.
* typeck2.c: Likewise.

gcc/fortran/ChangeLog
* f95-lang.c: Update GTY annotations.
* trans-intrinsic.c: Likewise.
* trans-io.c: Likewise.
* trans.h: Likewise.

gcc/java/ChangeLog
* builtins.c: Update GTY annotations.
* decl.c: Likewise.
* java-tree.h: Likewise.
* jcf.h: Likewise.
* lang.c: Likewise.

gcc/objc/ChangeLog
* objc-act.c: Likewise.
* objc-act.h: Likewise.

include/ChangeLog
* hashtab.h: Update GTY annotations.
* splay-tree.h: Likewise.

libcpp/ChangeLog
* include/cpp-id-data.h: Update GTY annotations.
* include/cpplib.h: Likewise.
* include/line-map.h: Likewise.
* include/symtab.h: Likewise.


Cheers, Taras
* * *

diff --git a/gcc/ada/ada-tree.h b/gcc/ada/ada-tree.h
--- a/gcc/ada/ada-tree.h
+++ b/gcc/ada/ada-tree.h
@@ -24,14 +24,14 @@
  ****************************************************************************/
 
 /* Ada uses the lang_decl and lang_type fields to hold a tree.  */
-union lang_tree_node
-  GTY((desc ("0"),
-       chain_next ("(union lang_tree_node *)GENERIC_NEXT (&%h.t)")))
+union  GTY((desc ("0"),
+            chain_next ("(union lang_tree_node *)GENERIC_NEXT (&%h.t)"))) 
+ lang_tree_node
 {
   union tree_node GTY((tag ("0"))) t;
 };
-struct lang_decl GTY(()) {tree t; };
-struct lang_type GTY(()) {tree t; };
+struct GTY(()) lang_decl {tree t; };
+struct GTY(()) lang_type {tree t; };
 
 /* Define macros to get and set the tree in TYPE_ and DECL_LANG_SPECIFIC.  */
 #define GET_TYPE_LANG_SPECIFIC(NODE) \
diff --git a/gcc/ada/trans.c b/gcc/ada/trans.c
--- a/gcc/ada/trans.c
+++ b/gcc/ada/trans.c
@@ -97,7 +97,7 @@ bool type_annotate_only;
 /* When not optimizing, we cache the 'First, 'Last and 'Length attributes
    of unconstrained array IN parameters to avoid emitting a great deal of
    redundant instructions to recompute them each time.  */
-struct parm_attr GTY (())
+struct GTY (()) parm_attr
 {
   int id; /* GTY doesn't like Entity_Id.  */
   int dim;
@@ -111,7 +111,7 @@ DEF_VEC_P(parm_attr);
 DEF_VEC_P(parm_attr);
 DEF_VEC_ALLOC_P(parm_attr,gc);
 
-struct language_function GTY(())
+struct GTY(()) language_function
 {
   VEC(parm_attr,gc) *parm_attr_cache;
 };
@@ -124,7 +124,7 @@ struct language_function GTY(())
    of a IF.  In the case where it represents a lexical scope, we may also
    have a BLOCK node corresponding to it and/or cleanups.  */
 
-struct stmt_group GTY((chain_next ("%h.previous"))) {
+struct GTY((chain_next ("%h.previous"))) stmt_group {
   struct stmt_group *previous;	/* Previous code group.  */
   tree stmt_list;		/* List of statements for this code group. */
   tree block;			/* BLOCK for this code group, if any. */
@@ -141,7 +141,7 @@ static GTY((deletable)) struct stmt_grou
 
    ??? gnat_node should be Node_Id, but gengtype gets confused.  */
 
-struct elab_info GTY((chain_next ("%h.next"))) {
+struct GTY((chain_next ("%h.next"))) elab_info {
   struct elab_info *next;	/* Pointer to next in chain. */
   tree elab_proc;		/* Elaboration procedure.  */
   int gnat_node;		/* The N_Compilation_Unit.  */
diff --git a/gcc/ada/utils.c b/gcc/ada/utils.c
--- a/gcc/ada/utils.c
+++ b/gcc/ada/utils.c
@@ -158,7 +158,7 @@ static GTY(()) tree float_types[NUM_MACH
 /* For each binding contour we allocate a binding_level structure to indicate
    the binding depth.  */
 
-struct gnat_binding_level GTY((chain_next ("%h.chain")))
+struct GTY((chain_next ("%h.chain"))) gnat_binding_level
 {
   /* The binding level containing this one (the enclosing binding level). */
   struct gnat_binding_level *chain;
diff --git a/gcc/alias.c b/gcc/alias.c
--- a/gcc/alias.c
+++ b/gcc/alias.c
@@ -128,7 +128,7 @@ along with GCC; see the file COPYING3.  
    However, this is no actual entry for alias set zero.  It is an
    error to attempt to explicitly construct a subset of zero.  */
 
-struct alias_set_entry GTY(())
+struct GTY(()) alias_set_entry
 {
   /* The alias set number, as stored in MEM_ALIAS_SET.  */
   alias_set_type alias_set;
diff --git a/gcc/basic-block.h b/gcc/basic-block.h
--- a/gcc/basic-block.h
+++ b/gcc/basic-block.h
@@ -114,7 +114,7 @@ typedef HOST_WIDEST_INT gcov_type;
 typedef HOST_WIDEST_INT gcov_type;
 
 /* Control flow edge information.  */
-struct edge_def GTY(())
+struct GTY(()) edge_def
 {
   /* The two blocks at the ends of the edge.  */
   struct basic_block_def *src;
@@ -211,7 +211,7 @@ struct rtl_bb_info;
    basic blocks.  */
 
 /* Basic block information indexed by block number.  */
-struct basic_block_def GTY((chain_next ("%h.next_bb"), chain_prev ("%h.prev_bb")))
+struct GTY((chain_next ("%h.next_bb"), chain_prev ("%h.prev_bb"))) basic_block_def
 {
   /* The edges into and out of the block.  */
   VEC(edge,gc) *preds;
@@ -251,7 +251,7 @@ struct basic_block_def GTY((chain_next (
   int flags;
 };
 
-struct rtl_bb_info GTY(())
+struct GTY(()) rtl_bb_info
 {
   /* The first and last insns of the block.  */
   rtx head_;
@@ -266,7 +266,7 @@ struct rtl_bb_info GTY(())
   int visited;
 };
 
-struct tree_bb_info GTY(())
+struct GTY(()) tree_bb_info
 {
   /* Pointers to the first and last trees of the block.  */
   tree stmt_list;
@@ -363,7 +363,7 @@ enum dom_state
    The x_* prefixing is necessary because otherwise references to the
    fields of this struct are interpreted as the defines for backward
    source compatibility following the definition of this struct.  */
-struct control_flow_graph GTY(())
+struct GTY(()) control_flow_graph
 {
   /* Block pointers for the exit and entry of a function.
      These are always the head and tail of the basic block list.  */
diff --git a/gcc/bitmap.h b/gcc/bitmap.h
--- a/gcc/bitmap.h
+++ b/gcc/bitmap.h
@@ -42,7 +42,7 @@ typedef unsigned long BITMAP_WORD;
 #define BITMAP_ELEMENT_ALL_BITS (BITMAP_ELEMENT_WORDS * BITMAP_WORD_BITS)
 
 /* Obstack for allocating bitmaps and elements from.  */
-typedef struct bitmap_obstack GTY (())
+typedef struct GTY (()) bitmap_obstack
 {
   struct bitmap_element_def *elements;
   struct bitmap_head_def *heads;
@@ -61,7 +61,7 @@ typedef struct bitmap_obstack GTY (())
    bitmap_elt_clear_from to be implemented in unit time rather than
    linear in the number of elements to be freed.  */
 
-typedef struct bitmap_element_def GTY(())
+typedef struct GTY(()) bitmap_element_def
 {
   struct bitmap_element_def *next;		/* Next element.  */
   struct bitmap_element_def *prev;		/* Previous element.  */
@@ -74,7 +74,8 @@ struct bitmap_descriptor;
    statistics we need to add a bitmap descriptor pointer.  As it is
    not collected, we can just GTY((skip)) it.   */
 
-typedef struct bitmap_head_def GTY(()) {
+typedef struct GTY(()) bitmap_head_def
+{
   bitmap_element *first;	/* First element in linked list.  */
   bitmap_element *current;	/* Last element looked at.  */
   unsigned int indx;		/* Index of last element looked at.  */
diff --git a/gcc/c-common.h b/gcc/c-common.h
--- a/gcc/c-common.h
+++ b/gcc/c-common.h
@@ -197,7 +197,7 @@ enum c_tree_index
 
 /* Identifier part common to the C front ends.  Inherits from
    tree_identifier, despite appearances.  */
-struct c_common_identifier GTY(())
+struct GTY(()) c_common_identifier 
 {
   struct tree_common common;
   struct cpp_hashnode node;
@@ -275,7 +275,7 @@ extern GTY(()) tree c_global_trees[CTI_M
 
 /* In a RECORD_TYPE, a sorted array of the fields of the type, not a
    tree for size reasons.  */
-struct sorted_fields_type GTY(())
+struct GTY(()) sorted_fields_type 
 {
   int len;
   tree GTY((length ("%h.len"))) elts[1];
@@ -303,7 +303,7 @@ extern c_language_kind c_language;
 
 /* Information about a statement tree.  */
 
-struct stmt_tree_s GTY(()) {
+struct GTY(()) stmt_tree_s {
   /* The current statement list being collected.  */
   tree x_cur_stmt_list;
 
@@ -329,7 +329,7 @@ typedef struct stmt_tree_s *stmt_tree;
 /* Global state pertinent to the current function.  Some C dialects
    extend this structure with additional fields.  */
 
-struct c_language_function GTY(()) {
+struct GTY(()) c_language_function {
   /* While we are parsing the function, this contains information
      about the statement-tree that we are building.  */
   struct stmt_tree_s x_stmt_tree;
diff --git a/gcc/c-decl.c b/gcc/c-decl.c
--- a/gcc/c-decl.c
+++ b/gcc/c-decl.c
@@ -195,7 +195,7 @@ bool c_override_global_bindings_to_false
    in all such cases, the binding in the outer scope will have its
    invisible bit true.  */
 
-struct c_binding GTY((chain_next ("%h.prev")))
+struct GTY((chain_next ("%h.prev"))) c_binding
 {
   tree decl;			/* the decl bound */
   tree type;			/* the type in this scope */
@@ -232,7 +232,7 @@ struct c_binding GTY((chain_next ("%h.pr
    These describe the values of the identifier in the three different
    namespaces defined by the language.  */
 
-struct lang_identifier GTY(())
+struct GTY(()) lang_identifier
 {
   struct c_common_identifier common_id;
   struct c_binding *symbol_binding; /* vars, funcs, constants, typedefs */
@@ -246,9 +246,9 @@ extern char C_SIZEOF_STRUCT_LANG_IDENTIF
 
 /* The resulting tree type.  */
 
-union lang_tree_node
-  GTY((desc ("TREE_CODE (&%h.generic) == IDENTIFIER_NODE"),
-       chain_next ("TREE_CODE (&%h.generic) == INTEGER_TYPE ? (union lang_tree_node *) TYPE_NEXT_VARIANT (&%h.generic) : ((union lang_tree_node *) GENERIC_NEXT (&%h.generic))")))
+union GTY((desc ("TREE_CODE (&%h.generic) == IDENTIFIER_NODE"),
+           chain_next ("TREE_CODE (&%h.generic) == INTEGER_TYPE ? (union lang_tree_node *) TYPE_NEXT_VARIANT (&%h.generic) : ((union lang_tree_node *) GENERIC_NEXT (&%h.generic))")))
+ lang_tree_node
 {
   union tree_node GTY ((tag ("0"),
 			desc ("tree_node_structure (&%h)")))
@@ -301,7 +301,7 @@ union lang_tree_node
    pop_scope relies on this.  */
 
 
-struct c_scope GTY((chain_next ("%h.outer")))
+struct GTY((chain_next ("%h.outer"))) c_scope
 {
   /* The scope containing this one.  */
   struct c_scope *outer;
diff --git a/gcc/c-parser.c b/gcc/c-parser.c
--- a/gcc/c-parser.c
+++ b/gcc/c-parser.c
@@ -136,7 +136,7 @@ typedef enum c_id_kind {
 
 /* A single C token after string literal concatenation and conversion
    of preprocessing tokens to tokens.  */
-typedef struct c_token GTY (())
+typedef struct GTY (()) c_token
 {
   /* The kind of token.  */
   ENUM_BITFIELD (cpp_ttype) type : 8;
@@ -158,7 +158,7 @@ typedef struct c_token GTY (())
 /* A parser structure recording information about the state and
    context of parsing.  Includes lexer information with up to two
    tokens of look-ahead; more are not needed for C.  */
-typedef struct c_parser GTY(())
+typedef struct GTY(()) c_parser
 {
   /* The look-ahead tokens.  */
   c_token tokens[2];
diff --git a/gcc/c-pragma.c b/gcc/c-pragma.c
--- a/gcc/c-pragma.c
+++ b/gcc/c-pragma.c
@@ -43,7 +43,7 @@ along with GCC; see the file COPYING3.  
 #define GCC_BAD2(gmsgid, arg) \
   do { warning (OPT_Wpragmas, gmsgid, arg); return; } while (0)
 
-typedef struct align_stack GTY(())
+typedef struct GTY(()) align_stack
 {
   int		       alignment;
   tree		       id;
@@ -244,13 +244,13 @@ handle_pragma_pack (cpp_reader * ARG_UNU
 }
 #endif  /* HANDLE_PRAGMA_PACK */
 
-struct def_pragma_macro_value GTY(())
+struct GTY(()) def_pragma_macro_value
 {
   struct def_pragma_macro_value *prev;
   cpp_macro *value;
 };
 
-struct def_pragma_macro GTY(())
+struct GTY(()) def_pragma_macro
 {
   hashval_t hash;
   const char *name;
diff --git a/gcc/c-tree.h b/gcc/c-tree.h
--- a/gcc/c-tree.h
+++ b/gcc/c-tree.h
@@ -32,7 +32,7 @@ along with GCC; see the file COPYING3.  
 
 /* Language-specific declaration information.  */
 
-struct lang_decl GTY(())
+struct GTY(()) lang_decl
 {
   char dummy;
 };
@@ -56,7 +56,7 @@ struct lang_decl GTY(())
    and C_RID_YYCODE is the token number wanted by Yacc.  */
 #define C_IS_RESERVED_WORD(ID) TREE_LANG_FLAG_0 (ID)
 
-struct lang_type GTY(())
+struct GTY(()) lang_type
 {
   /* In a RECORD_TYPE, a sorted array of the fields of the type.  */
   struct sorted_fields_type * GTY ((reorder ("resort_sorted_fields"))) s;
@@ -377,7 +377,7 @@ struct c_parm {
    that keep track of the progress of compilation of the current function.
    Used for nested functions.  */
 
-struct language_function GTY(())
+struct GTY(()) language_function
 {
   struct c_language_function base;
   tree x_break_label;
diff --git a/gcc/cfgloop.h b/gcc/cfgloop.h
--- a/gcc/cfgloop.h
+++ b/gcc/cfgloop.h
@@ -38,7 +38,7 @@ enum lpt_dec
   LPT_UNROLL_STUPID
 };
 
-struct lpt_decision GTY (())
+struct GTY (()) lpt_decision
 {
   enum lpt_dec decision;
   unsigned times;
@@ -46,7 +46,7 @@ struct lpt_decision GTY (())
 
 /* The structure describing a bound on number of iterations of a loop.  */
 
-struct nb_iter_bound GTY ((chain_next ("%h.next")))
+struct GTY ((chain_next ("%h.next"))) nb_iter_bound
 {
   /* The statement STMT is executed at most ...  */
   tree stmt;
@@ -71,7 +71,7 @@ struct nb_iter_bound GTY ((chain_next ("
 
 /* Description of the loop exit.  */
 
-struct loop_exit GTY (())
+struct GTY (()) loop_exit
 {
   /* The exit edge.  */
   struct edge_def *e;
@@ -100,7 +100,7 @@ enum loop_estimation
 };
 
 /* Structure to hold information for each natural loop.  */
-struct loop GTY ((chain_next ("%h.next")))
+struct GTY ((chain_next ("%h.next"))) loop
 {
   /* Index into loops array.  */
   int num;
@@ -179,7 +179,7 @@ enum
 #define AVOID_CFG_MODIFICATIONS (LOOPS_MAY_HAVE_MULTIPLE_LATCHES)
 
 /* Structure to hold CFG information about natural loops within a function.  */
-struct loops GTY (())
+struct GTY (()) loops
 {
   /* State of loops.  */
   int state;
diff --git a/gcc/cgraph.h b/gcc/cgraph.h
--- a/gcc/cgraph.h
+++ b/gcc/cgraph.h
@@ -51,7 +51,7 @@ extern const char * const cgraph_availab
 /* Information about the function collected locally.
    Available after function is analyzed.  */
 
-struct cgraph_local_info GTY(())
+struct GTY(()) cgraph_local_info
 {
   struct inline_summary {
     /* Estimated stack frame consumption by the function.  */
@@ -93,7 +93,7 @@ struct cgraph_local_info GTY(())
 /* Information about the function that needs to be computed globally
    once compilation is finished.  Available only with -funit-at-time.  */
 
-struct cgraph_global_info GTY(())
+struct GTY(()) cgraph_global_info
 {
   /* Estimated stack frame consumption by the function.  */
   HOST_WIDE_INT estimated_stack_size;
@@ -116,7 +116,7 @@ struct cgraph_global_info GTY(())
 /* Information about the function that is propagated by the RTL backend.
    Available only for functions that has been already assembled.  */
 
-struct cgraph_rtl_info GTY(())
+struct GTY(()) cgraph_rtl_info
 {
    unsigned int preferred_incoming_stack_boundary;
 };
@@ -124,7 +124,7 @@ struct cgraph_rtl_info GTY(())
 /* The cgraph data structure.
    Each function decl has assigned cgraph_node listing callees and callers.  */
 
-struct cgraph_node GTY((chain_next ("%h.next"), chain_prev ("%h.previous")))
+struct GTY((chain_next ("%h.next"), chain_prev ("%h.previous"))) cgraph_node
 {
   tree decl;
   struct cgraph_edge *callees;
@@ -188,7 +188,7 @@ struct cgraph_node GTY((chain_next ("%h.
   int pid;
 };
 
-struct cgraph_edge GTY((chain_next ("%h.next_caller"), chain_prev ("%h.prev_caller")))
+struct GTY((chain_next ("%h.next_caller"), chain_prev ("%h.prev_caller"))) cgraph_edge
 {
   struct cgraph_node *caller;
   struct cgraph_node *callee;
@@ -224,7 +224,7 @@ DEF_VEC_ALLOC_P(cgraph_edge_p,heap);
 /* The varpool data structure.
    Each static variable decl has assigned varpool_node.  */
 
-struct varpool_node GTY((chain_next ("%h.next")))
+struct GTY((chain_next ("%h.next"))) varpool_node
 {
   tree decl;
   /* Pointer to the next function in varpool_nodes.  */
@@ -255,7 +255,7 @@ struct varpool_node GTY((chain_next ("%h
 
 /* Every top level asm statement is put into a cgraph_asm_node.  */
 
-struct cgraph_asm_node GTY(())
+struct GTY(()) cgraph_asm_node
 {
   /* Next asm node.  */
   struct cgraph_asm_node *next;
diff --git a/gcc/config/alpha/alpha.c b/gcc/config/alpha/alpha.c
--- a/gcc/config/alpha/alpha.c
+++ b/gcc/config/alpha/alpha.c
@@ -2842,7 +2842,7 @@ alpha_split_conditional_move (enum rtx_c
 /* Look up the function X_floating library function name for the
    given operation.  */
 
-struct xfloating_op GTY(())
+struct GTY(()) xfloating_op
 {
   const enum rtx_code code;
   const char *const GTY((skip)) osf_func;
@@ -4730,7 +4730,7 @@ alpha_multipass_dfa_lookahead (void)
 
 /* Machine-specific function data.  */
 
-struct machine_function GTY(())
+struct GTY(()) machine_function
 {
   /* For unicosmk.  */
   /* List of call information words for calls from this function.  */
@@ -9363,7 +9363,7 @@ enum links_kind {KIND_UNUSED, KIND_LOCAL
 enum links_kind {KIND_UNUSED, KIND_LOCAL, KIND_EXTERN};
 enum reloc_kind {KIND_LINKAGE, KIND_CODEADDR};
 
-struct alpha_links GTY(())
+struct GTY(()) alpha_links
 {
   int num;
   rtx linkage;
@@ -9371,7 +9371,7 @@ struct alpha_links GTY(())
   enum reloc_kind rkind;
 };
 
-struct alpha_funcs GTY(())
+struct GTY(()) alpha_funcs
 {
   int num;
   splay_tree GTY ((param1_is (char *), param2_is (struct alpha_links *)))
diff --git a/gcc/config/arm/arm.h b/gcc/config/arm/arm.h
--- a/gcc/config/arm/arm.h
+++ b/gcc/config/arm/arm.h
@@ -1525,7 +1525,7 @@ do {									      \
    in the direction of stack growth.
    Only soft_frame is used in thumb mode.  */
 
-typedef struct arm_stack_offsets GTY(())
+typedef struct GTY(()) arm_stack_offsets
 {
   int saved_args;	/* ARG_POINTER_REGNUM.  */
   int frame;		/* ARM_HARD_FRAME_POINTER_REGNUM.  */
@@ -1539,7 +1539,7 @@ arm_stack_offsets;
 
 /* A C structure for machine-specific, per-function data.
    This is added to the cfun structure.  */
-typedef struct machine_function GTY(())
+typedef struct GTY(()) machine_function
 {
   /* Additional stack adjustment in __builtin_eh_throw.  */
   rtx eh_epilogue_sp_ofs;
diff --git a/gcc/config/avr/avr.h b/gcc/config/avr/avr.h
--- a/gcc/config/avr/avr.h
+++ b/gcc/config/avr/avr.h
@@ -1045,7 +1045,7 @@ mmcu=*:-mmcu=%*}"
 
 /* A C structure for machine-specific, per-function data.
    This is added to the cfun structure.  */
-struct machine_function GTY(())
+struct GTY(()) machine_function
 {
   /* 'true' - if the current function is a leaf function.  */
   int is_leaf;
diff --git a/gcc/config/bfin/bfin.c b/gcc/config/bfin/bfin.c
--- a/gcc/config/bfin/bfin.c
+++ b/gcc/config/bfin/bfin.c
@@ -58,7 +58,7 @@
 
 /* A C structure for machine-specific, per-function data.
    This is added to the cfun structure.  */
-struct machine_function GTY(())
+struct GTY(()) machine_function
 {
   int has_hardware_loops;
 };
@@ -3451,7 +3451,7 @@ DEF_VEC_ALLOC_P (loop_info,heap);
 
 /* Information about a loop we have found (or are in the process of
    finding).  */
-struct loop_info GTY (())
+struct GTY (()) loop_info
 {
   /* loop number, for dumps */
   int loop_no;
diff --git a/gcc/config/cris/cris.c b/gcc/config/cris/cris.c
--- a/gcc/config/cris/cris.c
+++ b/gcc/config/cris/cris.c
@@ -63,7 +63,7 @@ enum cris_retinsn_type
  { CRIS_RETINSN_UNKNOWN = 0, CRIS_RETINSN_RET, CRIS_RETINSN_JUMP };
 
 /* Per-function machine data.  */
-struct machine_function GTY(())
+struct GTY(()) machine_function
  {
    int needs_return_address_on_stack;
 
diff --git a/gcc/config/darwin.c b/gcc/config/darwin.c
--- a/gcc/config/darwin.c
+++ b/gcc/config/darwin.c
@@ -332,7 +332,7 @@ machopic_output_function_base_name (FILE
 /* The suffix attached to stub symbols.  */
 #define STUB_SUFFIX "$stub"
 
-typedef struct machopic_indirection GTY (())
+typedef struct GTY (()) machopic_indirection
 {
   /* The SYMBOL_REF for the entity referenced.  */
   rtx symbol;
diff --git a/gcc/config/frv/frv.c b/gcc/config/frv/frv.c
--- a/gcc/config/frv/frv.c
+++ b/gcc/config/frv/frv.c
@@ -139,7 +139,7 @@ struct frv_io {
        REG++)
 
 /* This structure contains machine specific function data.  */
-struct machine_function GTY(())
+struct GTY(()) machine_function
 {
   /* True if we have created an rtx that relies on the stack frame.  */
   int frame_needed;
diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c
--- a/gcc/config/i386/i386.c
+++ b/gcc/config/i386/i386.c
@@ -1628,7 +1628,7 @@ rtx ix86_compare_emitted = NULL_RTX;
 
 /* Define the structure for the machine field in struct function.  */
 
-struct stack_local_entry GTY(())
+struct GTY(()) stack_local_entry
 {
   unsigned short mode;
   unsigned short n;
diff --git a/gcc/config/i386/i386.h b/gcc/config/i386/i386.h
--- a/gcc/config/i386/i386.h
+++ b/gcc/config/i386/i386.h
@@ -2487,7 +2487,7 @@ enum ix86_stack_slot
 
 #define FASTCALL_PREFIX '@'
 
-struct machine_function GTY(())
+struct GTY(()) machine_function 
 {
   struct stack_local_entry *stack_locals;
   const char *some_ld_name;
diff --git a/gcc/config/i386/winnt.c b/gcc/config/i386/winnt.c
--- a/gcc/config/i386/winnt.c
+++ b/gcc/config/i386/winnt.c
@@ -546,7 +546,7 @@ i386_pe_declare_function_type (FILE *fil
 
 /* Keep a list of external functions.  */
 
-struct extern_list GTY(())
+struct GTY(()) extern_list
 {
   struct extern_list *next;
   tree decl;
@@ -575,7 +575,7 @@ i386_pe_record_external_function (tree d
 
 /* Keep a list of exported symbols.  */
 
-struct export_list GTY(())
+struct GTY(()) export_list
 {
   struct export_list *next;
   const char *name;
diff --git a/gcc/config/ia64/ia64.h b/gcc/config/ia64/ia64.h
--- a/gcc/config/ia64/ia64.h
+++ b/gcc/config/ia64/ia64.h
@@ -1925,7 +1925,7 @@ extern int ia64_final_schedule;
 #define EH_RETURN_DATA_REGNO(N) ((N) < 4 ? (N) + 15 : INVALID_REGNUM)
 
 /* This function contains machine specific function data.  */
-struct machine_function GTY(())
+struct GTY(()) machine_function
 {
   /* The new stack pointer when unwinding from EH.  */
   rtx ia64_eh_epilogue_sp;
diff --git a/gcc/config/iq2000/iq2000.c b/gcc/config/iq2000/iq2000.c
--- a/gcc/config/iq2000/iq2000.c
+++ b/gcc/config/iq2000/iq2000.c
@@ -88,7 +88,7 @@ struct iq2000_frame_info
   int  num_gp;			/* Number of gp registers saved.  */
 } iq2000_frame_info;
 
-struct machine_function GTY(())
+struct GTY(()) machine_function
 {
   /* Current frame information, calculated by compute_frame_size.  */
   long total_size;		/* # bytes that the entire frame takes up.  */
diff --git a/gcc/config/m32c/m32c.h b/gcc/config/m32c/m32c.h
--- a/gcc/config/m32c/m32c.h
+++ b/gcc/config/m32c/m32c.h
@@ -100,7 +100,7 @@ extern int target_memregs;
 
 /* Defining data structures for per-function information */
 
-typedef struct machine_function GTY (())
+typedef struct GTY (()) machine_function
 {
   /* How much we adjust the stack when returning from an exception
      handler.  */
diff --git a/gcc/config/mips/mips.c b/gcc/config/mips/mips.c
--- a/gcc/config/mips/mips.c
+++ b/gcc/config/mips/mips.c
@@ -234,7 +234,7 @@ static const char *const mips_fp_conditi
 };
 
 /* Information about a function's frame layout.  */
-struct mips_frame_info GTY(()) {
+struct GTY(()) mips_frame_info {
   /* The size of the frame in bytes.  */
   HOST_WIDE_INT total_size;
 
@@ -274,7 +274,7 @@ struct mips_frame_info GTY(()) {
   HOST_WIDE_INT hard_frame_pointer_offset;
 };
 
-struct machine_function GTY(()) {
+struct GTY(()) machine_function {
   /* The register returned by mips16_gp_pseudo_reg; see there for details.  */
   rtx mips16_gp_pseudo_rtx;
 
@@ -1036,7 +1036,7 @@ static const struct mips_rtx_cost_data m
 
 /* This hash table keeps track of implicit "mips16" and "nomips16" attributes
    for -mflip_mips16.  It maps decl names onto a boolean mode setting.  */
-struct mflip_mips16_entry GTY (()) {
+struct GTY (()) mflip_mips16_entry {
   const char *name;
   bool mips16_p;
 };
diff --git a/gcc/config/mmix/mmix.h b/gcc/config/mmix/mmix.h
--- a/gcc/config/mmix/mmix.h
+++ b/gcc/config/mmix/mmix.h
@@ -88,7 +88,7 @@ extern GTY(()) rtx mmix_compare_op1;
 /* Per-function machine data.  This is normally an opaque type just
    defined and used in the tm.c file, but we need to see the definition in
    mmix.md too.  */
-struct machine_function GTY(())
+struct GTY(()) machine_function
  {
    int has_landing_pad;
    int highest_saved_stack_register;
diff --git a/gcc/config/pa/pa.c b/gcc/config/pa/pa.c
--- a/gcc/config/pa/pa.c
+++ b/gcc/config/pa/pa.c
@@ -195,7 +195,7 @@ static int last_address;
 
 /* Variables to handle plabels that we discover are necessary at assembly
    output time.  They are output after the current function.  */
-struct deferred_plabel GTY(())
+struct GTY(()) deferred_plabel
 {
   rtx internal_label;
   rtx symbol;
@@ -9594,7 +9594,7 @@ pa_return_in_memory (const_tree type, co
    at the end of the file if and only if SYMBOL_REF_REFERENCED_P is true.
    This avoids putting out names that are never really used.  */
 
-typedef struct extern_symbol GTY(())
+typedef struct GTY(()) extern_symbol
 {
   tree decl;
   const char *name;
diff --git a/gcc/config/pa/pa.h b/gcc/config/pa/pa.h
--- a/gcc/config/pa/pa.h
+++ b/gcc/config/pa/pa.h
@@ -249,7 +249,7 @@ do {								\
 #define CAN_DEBUG_WITHOUT_FP
 
 /* target machine storage layout */
-typedef struct machine_function GTY(())
+typedef struct GTY(()) machine_function
 {
   /* Flag indicating that a .NSUBSPA directive has been output for
      this function.  */
diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c
--- a/gcc/config/rs6000/rs6000.c
+++ b/gcc/config/rs6000/rs6000.c
@@ -113,7 +113,7 @@ typedef struct rs6000_stack {
 
 /* A C structure for machine-specific, per-function data.
    This is added to the cfun structure.  */
-typedef struct machine_function GTY(())
+typedef struct GTY(()) machine_function
 {
   /* Flags if __builtin_return_address (n) with n >= 1 was used.  */
   int ra_needs_full_frame;
@@ -975,7 +975,7 @@ static enum machine_mode rs6000_eh_retur
 
 /* Hash table stuff for keeping track of TOC entries.  */
 
-struct toc_hash_struct GTY(())
+struct GTY(()) toc_hash_struct
 {
   /* `key' will satisfy CONSTANT_P; in fact, it will satisfy
      ASM_OUTPUT_SPECIAL_POOL_ENTRY_P.  */
diff --git a/gcc/config/s390/s390.c b/gcc/config/s390/s390.c
--- a/gcc/config/s390/s390.c
+++ b/gcc/config/s390/s390.c
@@ -263,7 +263,7 @@ HOST_WIDE_INT s390_stack_guard = 0;
 /* The following structure is embedded in the machine 
    specific part of struct function.  */
 
-struct s390_frame_layout GTY (())
+struct GTY (()) s390_frame_layout
 {
   /* Offset within stack frame.  */
   HOST_WIDE_INT gprs_offset;
@@ -306,7 +306,7 @@ struct s390_frame_layout GTY (())
 
 /* Define the structure for the machine field in struct function.  */
 
-struct machine_function GTY(())
+struct GTY(()) machine_function
 {
   struct s390_frame_layout frame_layout;
 
diff --git a/gcc/config/score/score.h b/gcc/config/score/score.h
--- a/gcc/config/score/score.h
+++ b/gcc/config/score/score.h
@@ -1087,7 +1087,7 @@ typedef struct score_args
    for 32-bit targets.  */
 #define FUNCTION_MODE                   Pmode
 
-struct extern_list GTY ((chain_next ("%h.next")))
+struct GTY ((chain_next ("%h.next"))) extern_list
 {
   struct extern_list *next;             /* next external  */
   const char *name;                     /* name of the external  */
diff --git a/gcc/config/sparc/sparc.c b/gcc/config/sparc/sparc.c
--- a/gcc/config/sparc/sparc.c
+++ b/gcc/config/sparc/sparc.c
@@ -321,7 +321,7 @@ char sparc_leaf_regs[] =
   1, 1, 1, 1, 1, 1, 1, 1,
   1, 1, 1, 1, 1};
 
-struct machine_function GTY(())
+struct GTY(()) machine_function
 {
   /* Some local-dynamic TLS symbol name.  */
   const char *some_ld_name;
diff --git a/gcc/config/xtensa/xtensa.c b/gcc/config/xtensa/xtensa.c
--- a/gcc/config/xtensa/xtensa.c
+++ b/gcc/config/xtensa/xtensa.c
@@ -89,7 +89,7 @@ unsigned xtensa_current_frame_size;
 #define LARGEST_MOVE_RATIO 15
 
 /* Define the structure for the machine field in struct function.  */
-struct machine_function GTY(())
+struct GTY(()) machine_function
 {
   int accesses_prev_frame;
   bool need_a7_copy;
diff --git a/gcc/coretypes.h b/gcc/coretypes.h
--- a/gcc/coretypes.h
+++ b/gcc/coretypes.h
@@ -32,7 +32,10 @@ along with GCC; see the file COPYING3.  
 #ifndef GCC_CORETYPES_H
 #define GCC_CORETYPES_H
 
+/* Allow GTY to be overridden as an attribute */
+#ifndef GTY
 #define GTY(x)  /* nothing - marker for gengtype */
+#endif
 
 #ifndef USED_FOR_TARGET
 
diff --git a/gcc/cp/cp-tree.h b/gcc/cp/cp-tree.h
--- a/gcc/cp/cp-tree.h
+++ b/gcc/cp/cp-tree.h
@@ -203,7 +203,7 @@ struct diagnostic_info;
 
 /* Language-dependent contents of an identifier.  */
 
-struct lang_identifier GTY(())
+struct GTY(()) lang_identifier 
 {
   struct c_common_identifier c_common;
   cxx_binding *namespace_bindings;
@@ -221,7 +221,7 @@ struct lang_identifier GTY(())
 #define LANG_IDENTIFIER_CAST(NODE) \
 	((struct lang_identifier*)IDENTIFIER_NODE_CHECK (NODE))
 
-struct template_parm_index_s GTY(())
+struct GTY(()) template_parm_index_s 
 {
   struct tree_common common;
   int index;
@@ -231,7 +231,7 @@ struct template_parm_index_s GTY(())
 };
 typedef struct template_parm_index_s template_parm_index;
 
-struct ptrmem_cst GTY(())
+struct GTY(()) ptrmem_cst 
 {
   struct tree_common common;
   /* This isn't used, but the middle-end expects all constants to have
@@ -315,7 +315,7 @@ typedef struct ptrmem_cst * ptrmem_cst_t
    is not important for this node.  */
 #define OVL_USED(NODE)		TREE_USED (NODE)
 
-struct tree_overload GTY(())
+struct GTY(()) tree_overload 
 {
   struct tree_common common;
   tree function;
@@ -347,7 +347,7 @@ struct tree_overload GTY(())
 #define BASELINK_QUALIFIED_P(NODE) \
   TREE_LANG_FLAG_0 (BASELINK_CHECK (NODE))
 
-struct tree_baselink GTY(())
+struct GTY(()) tree_baselink 
 {
   struct tree_common common;
   tree binfo;
@@ -437,7 +437,7 @@ typedef enum cp_id_kind
 #define DEFARG_INSTANTIATIONS(NODE) \
   (((struct tree_default_arg *)DEFAULT_ARG_CHECK (NODE))->instantiations)
 
-struct tree_default_arg GTY (())
+struct GTY (()) tree_default_arg 
 {
   struct tree_common common;
   struct cp_token_cache *tokens;
@@ -459,7 +459,7 @@ struct tree_default_arg GTY (())
 #define STATIC_ASSERT_SOURCE_LOCATION(NODE) \
   (((struct tree_static_assert *)STATIC_ASSERT_CHECK (NODE))->location)
 
-struct tree_static_assert GTY (())
+struct GTY (()) tree_static_assert 
 {
   struct tree_common common;
   tree condition;
@@ -467,7 +467,7 @@ struct tree_static_assert GTY (())
   location_t location;
 };
 
-struct tree_argument_pack_select GTY (())
+struct GTY (()) tree_argument_pack_select 
 {
   struct tree_common common;
   tree argument_pack;
@@ -508,7 +508,7 @@ typedef enum cp_trait_kind
 #define TRAIT_EXPR_KIND(NODE) \
   (((struct tree_trait_expr *)TRAIT_EXPR_CHECK (NODE))->kind)
 
-struct tree_trait_expr GTY (())
+struct GTY (()) tree_trait_expr 
 {
   struct tree_common common;
   tree type1;
@@ -533,8 +533,9 @@ enum cp_tree_node_structure_enum {
 };
 
 /* The resulting tree type.  */
-union lang_tree_node GTY((desc ("cp_tree_node_structure (&%h)"),
-       chain_next ("(union lang_tree_node *)GENERIC_NEXT (&%h.generic)")))
+union GTY((desc ("cp_tree_node_structure (&%h)"), 
+           chain_next ("(union lang_tree_node *)GENERIC_NEXT (&%h.generic)")))
+ lang_tree_node 
 {
   union tree_node GTY ((tag ("TS_CP_GENERIC"),
 			desc ("tree_node_structure (&%h)"))) generic;
@@ -731,7 +732,7 @@ extern GTY(()) tree cp_global_trees[CPTI
 
 /* Global state.  */
 
-struct saved_scope GTY(())
+struct GTY(()) saved_scope 
 {
   VEC(cxx_saved_binding,gc) *old_bindings;
   tree old_namespace;
@@ -810,7 +811,7 @@ struct saved_scope GTY(())
 
 extern GTY(()) struct saved_scope *scope_chain;
 
-struct cxx_int_tree_map GTY(())
+struct GTY(()) cxx_int_tree_map 
 {
   unsigned int uid;
   tree to;
@@ -821,7 +822,7 @@ extern int cxx_int_tree_map_eq (const vo
 
 /* Global state pertinent to the current function.  */
 
-struct language_function GTY(())
+struct GTY(()) language_function 
 {
   struct c_language_function base;
 
@@ -1045,7 +1046,7 @@ enum languages { lang_c, lang_cplusplus,
 #define CLASSTYPE_VISIBILITY_SPECIFIED(TYPE)	\
 	DECL_VISIBILITY_SPECIFIED (TYPE_NAME (TYPE))
 
-typedef struct tree_pair_s GTY (())
+typedef struct GTY (()) tree_pair_s 
 {
   tree purpose;
   tree value;
@@ -1057,7 +1058,7 @@ DEF_VEC_ALLOC_O (tree_pair_s,gc);
 /* This is a few header flags for 'struct lang_type'.  Actually,
    all but the first are used only for lang_type_class; they
    are put in this structure to save space.  */
-struct lang_type_header GTY(())
+struct GTY(()) lang_type_header 
 {
   BOOL_BITFIELD is_lang_type_class : 1;
 
@@ -1084,7 +1085,7 @@ struct lang_type_header GTY(())
    many (i.e., thousands) of classes can easily be generated.
    Therefore, we should endeavor to keep the size of this structure to
    a minimum.  */
-struct lang_type_class GTY(())
+struct GTY(()) lang_type_class 
 {
   struct lang_type_header h;
 
@@ -1160,13 +1161,13 @@ struct lang_type_class GTY(())
   tree objc_info;
 };
 
-struct lang_type_ptrmem GTY(())
+struct GTY(()) lang_type_ptrmem 
 {
   struct lang_type_header h;
   tree record;
 };
 
-struct lang_type GTY(())
+struct GTY(()) lang_type 
 {
   union lang_type_u
   {
@@ -1577,7 +1578,7 @@ struct lang_type GTY(())
      || TREE_CODE (NODE) == CONST_DECL			\
      || TREE_CODE (NODE) == USING_DECL))
 
-struct lang_decl_flags GTY(())
+struct GTY(()) lang_decl_flags 
 {
   ENUM_BITFIELD(languages) language : 4;
   unsigned global_ctor_p : 1;
@@ -1637,7 +1638,7 @@ struct lang_decl_flags GTY(())
 /* sorted_fields is sorted based on a pointer, so we need to be able
    to resort it if pointers get rearranged.  */
 
-struct lang_decl GTY(())
+struct GTY(()) lang_decl 
 {
   struct lang_decl_flags decl_flags;
 
@@ -2497,7 +2498,7 @@ extern void decl_shadowed_for_var_insert
 /* Abstract iterators for AGGR_INIT_EXPRs.  */
 
 /* Structure containing iterator state.  */
-typedef struct aggr_init_expr_arg_iterator_d GTY (())
+typedef struct GTY (()) aggr_init_expr_arg_iterator_d 
 {
   tree t;	/* the aggr_init_expr */
   int n;	/* argument count */
@@ -3859,7 +3860,7 @@ extern void init_reswords (void);
    opname_tab[(int) MINUS_EXPR] == "-".  */
 extern const char **opname_tab, **assignop_tab;
 
-typedef struct operator_name_info_t GTY(())
+typedef struct GTY(()) operator_name_info_t 
 {
   /* The IDENTIFIER_NODE for the operator.  */
   tree identifier;
@@ -4047,7 +4048,7 @@ struct cp_declarator {
 };
 
 /* A level of template instantiation.  */
-struct tinst_level GTY(())
+struct GTY(()) tinst_level 
 {
   /* The immediately deeper level in the chain.  */
   struct tinst_level *next;
@@ -4556,7 +4557,7 @@ extern int shared_member_p			(tree);
 
 /* The representation of a deferred access check.  */
 
-typedef struct deferred_access_check GTY(())
+typedef struct GTY(()) deferred_access_check 
 {
   /* The base class in which the declaration is referenced. */
   tree binfo;
diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c
--- a/gcc/cp/decl.c
+++ b/gcc/cp/decl.c
@@ -170,7 +170,7 @@ tree integer_two_node, integer_three_nod
 /* Used only for jumps to as-yet undefined labels, since jumps to
    defined labels can have their validity checked immediately.  */
 
-struct named_label_use_entry GTY(())
+struct GTY(()) named_label_use_entry
 {
   struct named_label_use_entry *next;
   /* The binding level to which this entry is *currently* attached.
@@ -193,7 +193,7 @@ struct named_label_use_entry GTY(())
    we can clear out their names' definitions at the end of the
    function, and so we can check the validity of jumps to these labels.  */
 
-struct named_label_entry GTY(())
+struct GTY(()) named_label_entry
 {
   /* The decl itself.  */
   tree label_decl;
diff --git a/gcc/cp/mangle.c b/gcc/cp/mangle.c
--- a/gcc/cp/mangle.c
+++ b/gcc/cp/mangle.c
@@ -90,7 +90,7 @@ along with GCC; see the file COPYING3.  
 	   && (PRIMARY_TEMPLATE_P (CLASSTYPE_TI_TEMPLATE (NODE))))))
 
 /* Things we only need one of.  This module is not reentrant.  */
-typedef struct globals GTY(())
+typedef struct GTY(()) globals
 {
   /* An array of the current substitution candidates, in the order
      we've seen them.  */
diff --git a/gcc/cp/name-lookup.c b/gcc/cp/name-lookup.c
--- a/gcc/cp/name-lookup.c
+++ b/gcc/cp/name-lookup.c
@@ -125,7 +125,7 @@ binding_entry_free (binding_entry entry)
 
 /* The datatype used to implement the mapping from names to types at
    a given scope.  */
-struct binding_table_s GTY(())
+struct GTY(()) binding_table_s
 {
   /* Array of chains of "binding_entry"s  */
   binding_entry * GTY((length ("%h.chain_count"))) chain;
diff --git a/gcc/cp/name-lookup.h b/gcc/cp/name-lookup.h
--- a/gcc/cp/name-lookup.h
+++ b/gcc/cp/name-lookup.h
@@ -31,7 +31,7 @@ typedef struct binding_entry_s *binding_
 /* The type of a routine repeatedly called by binding_table_foreach.  */
 typedef void (*bt_foreach_proc) (binding_entry, void *);
 
-struct binding_entry_s GTY(())
+struct GTY(()) binding_entry_s 
 {
   binding_entry chain;
   tree name;
@@ -63,7 +63,7 @@ typedef struct cp_binding_level cxx_scop
    currently being defined.  */
 #define INHERITED_VALUE_BINDING_P(NODE) ((NODE)->value_is_inherited)
 
-struct cxx_binding GTY(())
+struct GTY(()) cxx_binding 
 {
   /* Link to chain together various bindings for this name.  */
   cxx_binding *previous;
@@ -79,7 +79,7 @@ struct cxx_binding GTY(())
 
 /* Datatype used to temporarily save C++ bindings (for implicit
    instantiations purposes and like).  Implemented in decl.c.  */
-typedef struct cxx_saved_binding GTY(())
+typedef struct GTY(()) cxx_saved_binding 
 {
   /* The name of the current binding.  */
   tree identifier;
@@ -139,7 +139,7 @@ typedef enum tag_scope {
 					   and [class.friend]/9.  */
 } tag_scope;
 
-typedef struct cp_class_binding GTY(())
+typedef struct GTY(()) cp_class_binding 
 {
   cxx_binding base;
   /* The bound name.  */
@@ -173,7 +173,7 @@ DEF_VEC_ALLOC_O(cp_class_binding,gc);
 /* Note that the information in the `names' component of the global contour
    is duplicated in the IDENTIFIER_GLOBAL_VALUEs of all identifiers.  */
 
-struct cp_binding_level GTY(())
+struct GTY(()) cp_binding_level 
   {
     /* A chain of _DECL nodes for all variables, constants, functions,
        and typedef types.  These are in the reverse of the order
diff --git a/gcc/cp/parser.c b/gcc/cp/parser.c
--- a/gcc/cp/parser.c
+++ b/gcc/cp/parser.c
@@ -47,7 +47,7 @@ along with GCC; see the file COPYING3.  
 /* A token's value and its associated deferred access checks and
    qualifying scope.  */
 
-struct tree_check GTY(())
+struct GTY(()) tree_check
 {
   /* The value associated with the token.  */
   tree value;
@@ -60,7 +60,7 @@ struct tree_check GTY(())
 
 /* A C++ token.  */
 
-typedef struct cp_token GTY (())
+typedef struct GTY (()) cp_token
 {
   /* The kind of token.  */
   ENUM_BITFIELD (cpp_ttype) type : 8;
@@ -104,7 +104,7 @@ static cp_token eof_token =
    it to the parser.  Tokens are never added to the cp_lexer after
    it is created.  */
 
-typedef struct cp_lexer GTY (())
+typedef struct GTY (()) cp_lexer
 {
   /* The memory allocated for the buffer.  NULL if this lexer does not
      own the token buffer.  */
@@ -144,7 +144,7 @@ typedef struct cp_lexer GTY (())
    a cp_token_cache, since everything in here is referenced through
    a lexer.  */
 
-typedef struct cp_token_cache GTY(())
+typedef struct GTY(()) cp_token_cache
 {
   /* The beginning of the token range.  */
   cp_token * GTY((skip)) first;
@@ -1281,7 +1281,7 @@ typedef struct cp_parser_expression_stac
   cp_parser_expression_stack[NUM_PREC_VALUES];
 
 /* Context that is saved and restored when parsing tentatively.  */
-typedef struct cp_parser_context GTY (())
+typedef struct GTY (()) cp_parser_context
 {
   /* If this is a tentative parsing context, the status of the
      tentative parse.  */
@@ -1388,7 +1388,7 @@ cp_parser_context_new (cp_parser_context
 
 /* The cp_parser structure represents the C++ parser.  */
 
-typedef struct cp_parser GTY(())
+typedef struct GTY(()) cp_parser
 {
   /* The lexer from which we are obtaining tokens.  */
   cp_lexer *lexer;
diff --git a/gcc/cp/pt.c b/gcc/cp/pt.c
--- a/gcc/cp/pt.c
+++ b/gcc/cp/pt.c
@@ -53,7 +53,7 @@ typedef int (*tree_fn_t) (tree, void*);
 /* The PENDING_TEMPLATES is a TREE_LIST of templates whose
    instantiations have been deferred, either because their definitions
    were not yet available, or because we were putting off doing the work.  */
-struct pending_template GTY (()) {
+struct GTY (()) pending_template {
   struct pending_template *next;
   struct tinst_level *tinst;
 };
diff --git a/gcc/cp/rtti.c b/gcc/cp/rtti.c
--- a/gcc/cp/rtti.c
+++ b/gcc/cp/rtti.c
@@ -64,7 +64,7 @@ along with GCC; see the file COPYING3.  
    translation, when we are emitting the type info objects.  */
 
 /* Auxiliary data we hold for each type_info derived object we need.  */
-typedef struct tinfo_s GTY (())
+typedef struct GTY (()) tinfo_s
 {
   tree type;  /* The RECORD_TYPE for this type_info object */
 
diff --git a/gcc/cp/semantics.c b/gcc/cp/semantics.c
--- a/gcc/cp/semantics.c
+++ b/gcc/cp/semantics.c
@@ -108,7 +108,7 @@ static tree finalize_nrv_r (tree *, int 
       In case of parsing error, we simply call `pop_deferring_access_checks'
       without `perform_deferred_access_checks'.  */
 
-typedef struct deferred_access GTY(())
+typedef struct GTY(()) deferred_access
 {
   /* A VEC representing name-lookups for which we have deferred
      checking access controls.  We cannot check the accessibility of
diff --git a/gcc/cp/typeck2.c b/gcc/cp/typeck2.c
--- a/gcc/cp/typeck2.c
+++ b/gcc/cp/typeck2.c
@@ -112,7 +112,7 @@ readonly_error (tree arg, const char* st
 /* Structure that holds information about declarations whose type was
    incomplete and we could not check whether it was abstract or not.  */
 
-struct pending_abstract_type GTY((chain_next ("%h.next")))
+struct GTY((chain_next ("%h.next"))) pending_abstract_type
 {
   /* Declaration which we are checking for abstractness. It is either
      a DECL node, or an IDENTIFIER_NODE if we do not have a full
diff --git a/gcc/cselib.h b/gcc/cselib.h
--- a/gcc/cselib.h
+++ b/gcc/cselib.h
@@ -19,7 +19,7 @@ along with GCC; see the file COPYING3.  
 <http://www.gnu.org/licenses/>.  */
 
 /* Describe a value.  */
-typedef struct cselib_val_struct GTY(())
+typedef struct GTY(()) cselib_val_struct
 {
   /* The hash value.  */
   unsigned int value;
@@ -39,7 +39,7 @@ typedef struct cselib_val_struct GTY(())
 } cselib_val;
 
 /* A list of rtl expressions that hold the same value.  */
-struct elt_loc_list GTY(())
+struct GTY(()) elt_loc_list
 {
   /* Next element in the list.  */
   struct elt_loc_list *next;
@@ -50,7 +50,7 @@ struct elt_loc_list GTY(())
 };
 
 /* A list of cselib_val structures.  */
-struct elt_list GTY(())
+struct GTY(()) elt_list
 {
   struct elt_list *next;
   cselib_val *elt;
diff --git a/gcc/dbxout.c b/gcc/dbxout.c
--- a/gcc/dbxout.c
+++ b/gcc/dbxout.c
@@ -171,7 +171,7 @@ enum typestatus {TYPE_UNSEEN, TYPE_XREF,
    The file_number and type_number elements are used if DBX_USE_BINCL
    is defined.  */
 
-struct typeinfo GTY(())
+struct GTY(()) typeinfo
 {
   enum typestatus status;
   int file_number;
diff --git a/gcc/doc/gty.texi b/gcc/doc/gty.texi
--- a/gcc/doc/gty.texi
+++ b/gcc/doc/gty.texi
@@ -46,12 +46,12 @@ Here are some examples of marking simple
 Here are some examples of marking simple data structures and globals.
 
 @smallexample
-struct @var{tag} GTY(())
+struct GTY(()) @var{tag}
 @{
   @var{fields}@dots{}
 @};
 
-typedef struct @var{tag} GTY(())
+typedef struct GTY(()) @var{tag}
 @{
   @var{fields}@dots{}
 @} *@var{typename};
@@ -69,6 +69,7 @@ These don't need to be marked.
 * GTY Options::         What goes inside a @code{GTY(())}.
 * GGC Roots::           Making global variables GGC roots.
 * Files::               How the generated files work.
+* Attributes::          GTY annotations and attributes.
 @end menu
 
 @node GTY Options
@@ -135,7 +136,7 @@ the length of an array.  The first case 
 the length of an array.  The first case is when a structure ends in a
 variable-length array, like this:
 @smallexample
-struct rtvec_def GTY(()) @{
+struct GTY(()) rtvec_def @{
   int num_elem;         /* @r{number of elements} */
   rtx GTY ((length ("%h.num_elem"))) elem[1];
 @};
@@ -193,7 +194,7 @@ constant.
 
 For example,
 @smallexample
-struct tree_binding GTY(())
+struct GTY(()) tree_binding
 @{
   struct tree_common common;
   union tree_binding_u @{
@@ -448,3 +449,11 @@ For language frontends, there is another
 For language frontends, there is another file that needs to be included
 somewhere.  It will be called @file{gtype-@var{lang}.h}, where
 @var{lang} is the name of the subdirectory the language is contained in.
+
+@node Attributes
+@section GTY Annotations as Attributes
+
+GTY annotations follow the same conventions as GCC attributes, one
+can turn them into GNU attributes with the following macro:
+
+@code{#define GTY(x) __attribute__((user (("gty:"#x))))}
diff --git a/gcc/dwarf2out.c b/gcc/dwarf2out.c
--- a/gcc/dwarf2out.c
+++ b/gcc/dwarf2out.c
@@ -187,7 +187,7 @@ enum dw_cfi_oprnd_type {
   dw_cfi_oprnd_loc
 };
 
-typedef union dw_cfi_oprnd_struct GTY(())
+typedef union GTY(()) dw_cfi_oprnd_struct
 {
   unsigned int GTY ((tag ("dw_cfi_oprnd_reg_num"))) dw_cfi_reg_num;
   HOST_WIDE_INT GTY ((tag ("dw_cfi_oprnd_offset"))) dw_cfi_offset;
@@ -196,7 +196,7 @@ typedef union dw_cfi_oprnd_struct GTY(()
 }
 dw_cfi_oprnd;
 
-typedef struct dw_cfi_struct GTY(())
+typedef struct GTY(()) dw_cfi_struct
 {
   dw_cfi_ref dw_cfi_next;
   enum dwarf_call_frame_info dw_cfi_opc;
@@ -212,7 +212,7 @@ dw_cfi_node;
    It can now be either REG + CFA_OFFSET or *(REG + BASE_OFFSET) + CFA_OFFSET.
    Instead of passing around REG and OFFSET, we pass a copy
    of this structure.  */
-typedef struct cfa_loc GTY(())
+typedef struct GTY(()) cfa_loc
 {
   HOST_WIDE_INT offset;
   HOST_WIDE_INT base_offset;
@@ -226,7 +226,7 @@ typedef struct cfa_loc GTY(())
    CIE obviates the need to keep track of multiple CIE's
    in the DWARF generation routines below.  */
 
-typedef struct dw_fde_struct GTY(())
+typedef struct GTY(()) dw_fde_struct
 {
   tree decl;
   const char *dw_fde_begin;
@@ -334,7 +334,7 @@ static unsigned current_funcdef_fde;
 static unsigned current_funcdef_fde;
 #endif
 
-struct indirect_string_node GTY(())
+struct GTY(()) indirect_string_node
 {
   const char *str;
   unsigned int refcount;
@@ -1208,7 +1208,7 @@ dwarf2out_stack_adjust (rtx insn, bool a
    of the prologue or (b) the register is clobbered.  This clusters
    register saves so that there are fewer pc advances.  */
 
-struct queued_reg_save GTY(())
+struct GTY(()) queued_reg_save
 {
   struct queued_reg_save *next;
   rtx reg;
@@ -1219,7 +1219,7 @@ static GTY(()) struct queued_reg_save *q
 static GTY(()) struct queued_reg_save *queued_reg_saves;
 
 /* The caller's ORIG_REG is saved in SAVED_IN_REG.  */
-struct reg_saved_in_data GTY(()) {
+struct GTY(()) reg_saved_in_data {
   rtx orig_reg;
   rtx saved_in_reg;
 };
@@ -2799,7 +2799,7 @@ dwarf2out_switch_text_section (void)
    for emitting location expressions.  */
 
 /* Data about a single source file.  */
-struct dwarf_file_data GTY(())
+struct GTY(()) dwarf_file_data
 {
   const char * filename;
   int emitted_number;
@@ -2844,7 +2844,7 @@ enum dw_val_class
 /* Describe a double word constant value.  */
 /* ??? Every instance of long_long in the code really means CONST_DOUBLE.  */
 
-typedef struct dw_long_long_struct GTY(())
+typedef struct GTY(()) dw_long_long_struct
 {
   unsigned long hi;
   unsigned long low;
@@ -2853,7 +2853,7 @@ dw_long_long_const;
 
 /* Describe a floating point constant value, or a vector constant value.  */
 
-typedef struct dw_vec_struct GTY(())
+typedef struct GTY(()) dw_vec_struct
 {
   unsigned char * GTY((length ("%h.length"))) array;
   unsigned length;
@@ -2864,7 +2864,7 @@ dw_vec_const;
 /* The dw_val_node describes an attribute's value, as it is
    represented internally.  */
 
-typedef struct dw_val_struct GTY(())
+typedef struct GTY(()) dw_val_struct
 {
   enum dw_val_class val_class;
   union dw_val_struct_union
@@ -2895,7 +2895,7 @@ dw_val_node;
 /* Locations in memory are described using a sequence of stack machine
    operations.  */
 
-typedef struct dw_loc_descr_struct GTY(())
+typedef struct GTY(()) dw_loc_descr_struct
 {
   dw_loc_descr_ref dw_loc_next;
   enum dwarf_location_atom dw_loc_opc;
@@ -2908,7 +2908,7 @@ dw_loc_descr_node;
 /* Location lists are ranges + location descriptions for that range,
    so you can track variables that are in different places over
    their entire life.  */
-typedef struct dw_loc_list_struct GTY(())
+typedef struct GTY(()) dw_loc_list_struct
 {
   dw_loc_list_ref dw_loc_next;
   const char *begin; /* Label for begin address of range */
@@ -3836,7 +3836,7 @@ typedef struct dw_ranges_by_label_struct
    entry.  The label gives the PC value associated with
    the line number entry.  */
 
-typedef struct dw_line_info_struct GTY(())
+typedef struct GTY(()) dw_line_info_struct
 {
   unsigned long dw_file_num;
   unsigned long dw_line_num;
@@ -3845,7 +3845,7 @@ dw_line_info_entry;
 
 /* Line information for functions in separate sections; each one gets its
    own sequence.  */
-typedef struct dw_separate_line_info_struct GTY(())
+typedef struct GTY(()) dw_separate_line_info_struct
 {
   unsigned long dw_file_num;
   unsigned long dw_line_num;
@@ -3857,7 +3857,7 @@ dw_separate_line_info_entry;
    a link to the next attribute in the chain, and an attribute value.
    Attributes are typically linked below the DIE they modify.  */
 
-typedef struct dw_attr_struct GTY(())
+typedef struct GTY(()) dw_attr_struct
 {
   enum dwarf_attribute dw_attr;
   dw_val_node dw_attr_val;
@@ -3871,7 +3871,7 @@ DEF_VEC_ALLOC_O(dw_attr_node,gc);
    The children of each node form a circular list linked by
    die_sib.  die_child points to the node *before* the "first" child node.  */
 
-typedef struct die_struct GTY((chain_circular ("%h.die_sib")))
+typedef struct GTY((chain_circular ("%h.die_sib"))) die_struct
 {
   enum dwarf_tag die_tag;
   char *die_symbol;
@@ -3900,7 +3900,7 @@ die_node;
 
 /* The pubname structure */
 
-typedef struct pubname_struct GTY(())
+typedef struct GTY(()) pubname_struct
 {
   dw_die_ref die;
   const char *name;
@@ -3910,21 +3910,21 @@ DEF_VEC_O(pubname_entry);
 DEF_VEC_O(pubname_entry);
 DEF_VEC_ALLOC_O(pubname_entry, gc);
 
-struct dw_ranges_struct GTY(())
+struct GTY(()) dw_ranges_struct
 {
   /* If this is positive, it's a block number, otherwise it's a
      bitwise-negated index into dw_ranges_by_label.  */
   int num;
 };
 
-struct dw_ranges_by_label_struct GTY(())
+struct GTY(()) dw_ranges_by_label_struct
 {
   const char *begin;
   const char *end;
 };
 
 /* The limbo die list structure.  */
-typedef struct limbo_die_struct GTY(())
+typedef struct GTY(()) limbo_die_struct
 {
   dw_die_ref die;
   tree created_for;
@@ -4026,7 +4026,7 @@ static GTY ((param_is (struct die_struct
 static GTY ((param_is (struct die_struct))) htab_t decl_die_table;
 
 /* Node of the variable location list.  */
-struct var_loc_node GTY ((chain_next ("%h.next")))
+struct GTY ((chain_next ("%h.next"))) var_loc_node
 {
   rtx GTY (()) var_loc_note;
   const char * GTY (()) label;
@@ -4035,7 +4035,7 @@ struct var_loc_node GTY ((chain_next ("%
 };
 
 /* Variable location list.  */
-struct var_loc_list_def GTY (())
+struct GTY (()) var_loc_list_def
 {
   struct var_loc_node * GTY (()) first;
 
diff --git a/gcc/except.c b/gcc/except.c
--- a/gcc/except.c
+++ b/gcc/except.c
@@ -96,7 +96,7 @@ tree (*lang_eh_runtime_type) (tree);
 
 /* A hash table of label to region number.  */
 
-struct ehl_map_entry GTY(())
+struct GTY(()) ehl_map_entry
 {
   rtx label;
   struct eh_region *region;
@@ -115,7 +115,7 @@ static int sjlj_fc_jbuf_ofs;
 static int sjlj_fc_jbuf_ofs;
 
 /* Describes one exception region.  */
-struct eh_region GTY(())
+struct GTY(()) eh_region
 {
   /* The immediately surrounding region.  */
   struct eh_region *outer;
@@ -200,7 +200,7 @@ struct eh_region GTY(())
 
 typedef struct eh_region *eh_region;
 
-struct call_site_record GTY(())
+struct GTY(()) call_site_record
 {
   rtx landing_pad;
   int action;
@@ -210,7 +210,7 @@ DEF_VEC_ALLOC_P(eh_region, gc);
 DEF_VEC_ALLOC_P(eh_region, gc);
 
 /* Used to save exception status for each function.  */
-struct eh_status GTY(())
+struct GTY(()) eh_status
 {
   /* The tree of all regions for this function.  */
   struct eh_region *region_tree;
@@ -1131,7 +1131,7 @@ lookup_type_for_runtime (tree type)
 
 /* Represent an entry in @TTypes for either catch actions
    or exception filter actions.  */
-struct ttypes_filter GTY(())
+struct GTY(()) ttypes_filter
 {
   tree t;
   int filter;
diff --git a/gcc/except.h b/gcc/except.h
--- a/gcc/except.h
+++ b/gcc/except.h
@@ -173,7 +173,7 @@ extern tree (*lang_eh_runtime_type) (tre
 # define USING_SJLJ_EXCEPTIONS		MUST_USE_SJLJ_EXCEPTIONS
 #endif
 
-struct throw_stmt_node GTY(())
+struct GTY(()) throw_stmt_node
 {
   tree stmt;
   int region_nr;
diff --git a/gcc/fixed-value.h b/gcc/fixed-value.h
--- a/gcc/fixed-value.h
+++ b/gcc/fixed-value.h
@@ -24,7 +24,7 @@ along with GCC; see the file COPYING3.  
 #include "real.h"
 #include "double-int.h"
 
-struct fixed_value GTY(())
+struct GTY(()) fixed_value
 {
   double_int data;	/* Store data up to 2 wide integers.  */
   unsigned int mode;	/* Use machine mode to know IBIT and FBIT.  */
diff --git a/gcc/fortran/f95-lang.c b/gcc/fortran/f95-lang.c
--- a/gcc/fortran/f95-lang.c
+++ b/gcc/fortran/f95-lang.c
@@ -52,18 +52,16 @@ along with GCC; see the file COPYING3.  
 
 /* Language-dependent contents of an identifier.  */
 
-struct lang_identifier
-GTY(())
+struct GTY(()) lang_identifier
 {
   struct tree_identifier common;
 };
 
 /* The resulting tree type.  */
 
-union lang_tree_node
-GTY((desc ("TREE_CODE (&%h.generic) == IDENTIFIER_NODE"),
-     chain_next ("(union lang_tree_node *)GENERIC_NEXT (&%h.generic)")))
-
+union GTY((desc ("TREE_CODE (&%h.generic) == IDENTIFIER_NODE"),
+           chain_next ("(union lang_tree_node *)GENERIC_NEXT (&%h.generic)")))
+ lang_tree_node
 {
   union tree_node GTY((tag ("0"),
 		       desc ("tree_node_structure (&%h)"))) generic;
@@ -74,8 +72,7 @@ GTY((desc ("TREE_CODE (&%h.generic) == I
    that keep track of the progress of compilation of the current function.
    Used for nested functions.  */
 
-struct language_function
-GTY(())
+struct GTY(()) language_function
 {
   /* struct gfc_language_function base; */
   struct binding_level *binding_level;
@@ -306,8 +303,7 @@ gfc_print_identifier (FILE * file ATTRIB
 
    Binding contours are used to create GCC tree BLOCK nodes.  */
 
-struct binding_level
-GTY(())
+struct GTY(()) binding_level
 {
   /* A chain of ..._DECL nodes for all variables, constants, functions,
      parameters and type declarations.  These ..._DECL nodes are chained
diff --git a/gcc/fortran/trans-intrinsic.c b/gcc/fortran/trans-intrinsic.c
--- a/gcc/fortran/trans-intrinsic.c
+++ b/gcc/fortran/trans-intrinsic.c
@@ -45,7 +45,7 @@ along with GCC; see the file COPYING3.  
 
 /* This maps fortran intrinsic math functions to external library or GCC
    builtin functions.  */
-typedef struct gfc_intrinsic_map_t	GTY(())
+typedef struct GTY(()) gfc_intrinsic_map_t
 {
   /* The explicit enum is required to work around inadequacies in the
      garbage collection/gengtype parsing mechanism.  */
diff --git a/gcc/fortran/trans-io.c b/gcc/fortran/trans-io.c
--- a/gcc/fortran/trans-io.c
+++ b/gcc/fortran/trans-io.c
@@ -64,7 +64,7 @@ enum iofield_type
   IOPARM_type_num
 };
 
-typedef struct gfc_st_parameter_field GTY(())
+typedef struct GTY(()) gfc_st_parameter_field
 {
   const char *name;
   unsigned int mask;
@@ -75,7 +75,7 @@ typedef struct gfc_st_parameter_field GT
 }
 gfc_st_parameter_field;
 
-typedef struct gfc_st_parameter GTY(())
+typedef struct GTY(()) gfc_st_parameter
 {
   const char *name;
   tree type;
diff --git a/gcc/fortran/trans.h b/gcc/fortran/trans.h
--- a/gcc/fortran/trans.h
+++ b/gcc/fortran/trans.h
@@ -524,7 +524,7 @@ extern GTY(()) tree gfor_fndecl_associat
 /* Math functions.  Many other math functions are handled in
    trans-intrinsic.c.  */
 
-typedef struct gfc_powdecl_list GTY(())
+typedef struct GTY(()) gfc_powdecl_list
 {
   tree integer;
   tree real;
@@ -596,7 +596,7 @@ enum gfc_array_kind
 };
 
 /* Array types only.  */
-struct lang_type		GTY(())
+struct GTY(()) lang_type	
 {
   int rank;
   enum gfc_array_kind akind;
@@ -609,7 +609,7 @@ struct lang_type		GTY(())
   tree dataptr_type;
 };
 
-struct lang_decl		GTY(())
+struct GTY(()) lang_decl	
 {
   /* Dummy variables.  */
   tree saved_descriptor;
diff --git a/gcc/function.c b/gcc/function.c
--- a/gcc/function.c
+++ b/gcc/function.c
@@ -150,7 +150,7 @@ static VEC(int,heap) *sibcall_epilogue;
    level where they are defined.  They are marked a "kept" so that
    free_temp_slots will not free them.  */
 
-struct temp_slot GTY(())
+struct GTY(()) temp_slot
 {
   /* Points to next temporary slot.  */
   struct temp_slot *next;
diff --git a/gcc/function.h b/gcc/function.h
--- a/gcc/function.h
+++ b/gcc/function.h
@@ -31,7 +31,7 @@ along with GCC; see the file COPYING3.  
    The main insn-chain is saved in the last element of the chain,
    unless the chain is empty.  */
 
-struct sequence_stack GTY(())
+struct GTY(()) sequence_stack 
 {
   /* First and last insns in the chain of the saved sequence.  */
   rtx first;
@@ -39,7 +39,7 @@ struct sequence_stack GTY(())
   struct sequence_stack *next;
 };
 
-struct emit_status GTY(())
+struct GTY(()) emit_status 
 {
   /* This is reset to LAST_VIRTUAL_REGISTER + 1 at the start of each function.
      After rtl generation, it is 1 plus the largest register number used.  */
@@ -96,7 +96,7 @@ extern GTY ((length ("crtl->emit.x_reg_r
 
 #define REGNO_POINTER_ALIGN(REGNO) (crtl->emit.regno_pointer_align[REGNO])
 
-struct expr_status GTY(())
+struct GTY(()) expr_status 
 {
   /* Number of units that we should eventually pop off the stack.
      These are the arguments to function calls that have already returned.  */
@@ -142,7 +142,7 @@ DEF_VEC_ALLOC_P(call_site_record, gc);
 DEF_VEC_ALLOC_P(call_site_record, gc);
 
 /* RTL representation of exception handling.  */
-struct rtl_eh GTY(())
+struct GTY(()) rtl_eh
 {
   rtx filter;
   rtx exc_ptr;
@@ -196,7 +196,7 @@ enum function_frequency {
   FUNCTION_FREQUENCY_HOT
 };
 
-struct varasm_status GTY(())
+struct GTY(()) varasm_status
 {
   /* If we're using a per-function constant pool, this is it.  */
   struct rtx_constant_pool *pool;
@@ -207,7 +207,7 @@ struct varasm_status GTY(())
 };
 
 /* Information mainlined about RTL representation of incoming arguments.  */
-struct incoming_args GTY(())
+struct GTY(()) incoming_args
 {
   /* Number of bytes of args popped by function being compiled on its return.
      Zero if no bytes are to be popped.
@@ -237,7 +237,7 @@ struct incoming_args GTY(())
 };
 
 /* Data for function partitioning.  */
-struct function_subsections GTY(())
+struct GTY(()) function_subsections
 {
   /* Assembly labels for the hot and cold text sections, to
      be used by debugger functions for determining the size of text
@@ -255,7 +255,7 @@ struct function_subsections GTY(())
 };
 
 /* Datastructures maintained for currently processed function in RTL form.  */
-struct rtl_data GTY(())
+struct GTY(()) rtl_data
 {
   struct expr_status expr;
   struct emit_status emit;
@@ -422,7 +422,7 @@ extern GTY(()) struct rtl_data x_rtl;
 /* This structure can save all the important global and static variables
    describing the status of the current function.  */
 
-struct function GTY(())
+struct GTY(()) function 
 {
   struct eh_status *eh;
 
diff --git a/gcc/gengtype-lex.l b/gcc/gengtype-lex.l
--- a/gcc/gengtype-lex.l
+++ b/gcc/gengtype-lex.l
@@ -187,9 +187,6 @@ EOID	[^[:alnum:]_]
 }
 
 ^{HWS}"#"{HWS}"define"{WS}"GTY(" /* do nothing */
-{WS}"GTY"{WS}?"("	{
-  error_at_line (&lexer_line, "stray GTY marker");
-}
 
 %%
 
diff --git a/gcc/gengtype-parse.c b/gcc/gengtype-parse.c
--- a/gcc/gengtype-parse.c
+++ b/gcc/gengtype-parse.c
@@ -677,7 +677,6 @@ type (options_p *optsp, bool nested)
 type (options_p *optsp, bool nested)
 {
   const char *s;
-  bool is_union;
   *optsp = 0;
   switch (token ())
     {
@@ -694,14 +693,16 @@ type (options_p *optsp, bool nested)
     case UNION:
       {
 	options_p opts = 0;
-
-	is_union = (token() == UNION);
+    /* GTY annotations follow attribute syntax 
+       GTY_BEFORE_ID is for union/struct declarations
+       GTY_AFTER_ID is for variable declarations */
+    enum {
+        NO_GTY,
+        GTY_BEFORE_ID,
+        GTY_AFTER_ID
+    } is_gty = NO_GTY;
+    bool is_union = (token() == UNION);
 	advance ();
-
-	if (token () == ID)
-	  s = advance ();
-	else
-	  s = xasprintf ("anonymous:%s:%d", lexer_line.file, lexer_line.line);
 
 	/* Top-level structures that are not explicitly tagged GTY(())
 	   are treated as mere forward declarations.  This is because
@@ -710,18 +711,40 @@ type (options_p *optsp, bool nested)
 	   that we can't handle.  */
 	if (nested || token () == GTY_TOKEN)
 	  {
-	    opts = gtymarker_opt ();
-	    if (token () == '{')
-	      {
-		pair_p fields;
-		advance ();
-		fields = struct_field_seq ();
-		require ('}');
-		return new_structure (s, is_union, &lexer_line, fields, opts);
-	      }
+        is_gty = GTY_BEFORE_ID;
+        opts = gtymarker_opt ();
 	  }
-	else if (token () == '{')
-	  consume_balanced ('{', '}');
+
+	if (token () == ID)
+	  s = advance ();
+	else
+	  s = xasprintf ("anonymous:%s:%d", lexer_line.file, lexer_line.line);
+
+        /* Unfortunately above GTY_TOKEN check does not capture the
+           typedef struct_type GTY case */
+	if (token () == GTY_TOKEN)
+	  {
+        is_gty = GTY_AFTER_ID;
+        opts = gtymarker_opt ();
+	  }
+        
+    if (is_gty) 
+      {
+        if (token () == '{')
+          {
+            if (is_gty == GTY_AFTER_ID) 
+              {
+                parse_error ("GTY must be specified before identifier\n");
+              }
+            pair_p fields;
+            advance ();
+            fields = struct_field_seq ();
+            require ('}');
+            return new_structure (s, is_union, &lexer_line, fields, opts);
+          }
+      } 
+    else if (token () == '{')
+      consume_balanced ('{', '}');
 	if (opts)
 	  *optsp = opts;
 	return find_structure (s, is_union);
diff --git a/gcc/integrate.c b/gcc/integrate.c
--- a/gcc/integrate.c
+++ b/gcc/integrate.c
@@ -52,11 +52,11 @@ along with GCC; see the file COPYING3.  
 
 
 /* Private type used by {get/has}_hard_reg_initial_val.  */
-typedef struct initial_value_pair GTY(()) {
+typedef struct GTY(()) initial_value_pair {
   rtx hard_reg;
   rtx pseudo;
 } initial_value_pair;
-typedef struct initial_value_struct GTY(()) {
+typedef struct GTY(()) initial_value_struct {
   int num_entries;
   int max_entries;
   initial_value_pair * GTY ((length ("%h.num_entries"))) entries;
diff --git a/gcc/java/builtins.c b/gcc/java/builtins.c
--- a/gcc/java/builtins.c
+++ b/gcc/java/builtins.c
@@ -65,14 +65,14 @@ typedef tree builtin_creator_function (t
 
 /* Hold a char*, before initialization, or a tree, after
    initialization.  */
-union string_or_tree GTY(())
+union GTY(()) string_or_tree
 {
   const char * GTY ((tag ("0"))) s;
   tree GTY ((tag ("1"))) t;
 };
 
 /* Used to hold a single builtin record.  */
-struct builtin_record GTY(())
+struct GTY(()) builtin_record
 {
   union string_or_tree GTY ((desc ("1"))) class_name;
   union string_or_tree GTY ((desc ("1"))) method_name;
diff --git a/gcc/java/decl.c b/gcc/java/decl.c
--- a/gcc/java/decl.c
+++ b/gcc/java/decl.c
@@ -350,7 +350,7 @@ find_stack_slot (int index, tree type)
 			      type, -1);
 }
 
-struct binding_level GTY(())
+struct GTY(()) binding_level
   {
     /* A chain of _DECL nodes for all variables, constants, functions,
      * and typedef types.  These are in the reverse of the order supplied.
diff --git a/gcc/java/java-tree.h b/gcc/java/java-tree.h
--- a/gcc/java/java-tree.h
+++ b/gcc/java/java-tree.h
@@ -635,7 +635,7 @@ extern GTY(()) tree java_global_trees[JT
 /* The decl for "_Jv_ResolvePoolEntry".  */
 extern GTY(()) tree soft_resolvepoolentry_node;
 
-struct lang_identifier GTY(())
+struct GTY(()) lang_identifier
 {
   struct tree_identifier ignore;
   tree global_value;
@@ -647,10 +647,9 @@ struct lang_identifier GTY(())
 };
 
 /* The resulting tree type.  */
-union lang_tree_node 
-  GTY((desc ("TREE_CODE (&%h.generic) == IDENTIFIER_NODE"),
-       chain_next ("(union lang_tree_node *)GENERIC_NEXT (&%h.generic)")))
-
+union GTY((desc ("TREE_CODE (&%h.generic) == IDENTIFIER_NODE"),
+           chain_next ("(union lang_tree_node *)GENERIC_NEXT (&%h.generic)")))
+ lang_tree_node
 {
   union tree_node GTY ((tag ("0"), 
 			desc ("tree_node_structure (&%h)"))) 
@@ -772,7 +771,7 @@ union lang_tree_node
    || TREE_CODE (NODE) == REAL_CST)
 
 /* DECL_LANG_SPECIFIC for FUNCTION_DECLs. */
-struct lang_decl_func GTY(())
+struct GTY(()) lang_decl_func
 {
   /*  tree chain; not yet used. */
   long code_offset;
@@ -803,7 +802,7 @@ struct lang_decl_func GTY(())
   unsigned int varargs : 1;	/* Varargs method.  */
 };
 
-struct treetreehash_entry GTY(())
+struct GTY(()) treetreehash_entry
 {
   tree key;
   tree value;
@@ -840,7 +839,7 @@ typedef enum
   JV_ANNOTATION_DEFAULT_KIND
 } jv_attr_kind;
 
-typedef struct type_assertion GTY(())
+typedef struct GTY(()) type_assertion
 {
   int assertion_code; /* 'opcode' for the type of this assertion. */
   tree op1;           /* First operand. */
@@ -853,7 +852,7 @@ extern htab_t java_treetreehash_create (
 
 /* DECL_LANG_SPECIFIC for VAR_DECL, PARM_DECL and sometimes FIELD_DECL
    (access methods on outer class fields) and final fields. */
-struct lang_decl_var GTY(())
+struct GTY(()) lang_decl_var
 {
   int slot_number;
   int start_pc;
@@ -871,7 +870,7 @@ struct lang_decl_var GTY(())
 
 enum lang_decl_desc {LANG_DECL_FUNC, LANG_DECL_VAR};
 
-struct lang_decl GTY(())
+struct GTY(()) lang_decl
 {
   enum lang_decl_desc desc;
   union lang_decl_u
@@ -927,7 +926,7 @@ struct lang_decl GTY(())
 #define TYPE_REFLECTION_DATASIZE(T)					\
 				(TYPE_LANG_SPECIFIC (T)->reflection_datasize)
 
-struct lang_type GTY(())
+struct GTY(()) lang_type
 {
   tree signature;
   struct JCF *jcf;
diff --git a/gcc/java/jcf.h b/gcc/java/jcf.h
--- a/gcc/java/jcf.h
+++ b/gcc/java/jcf.h
@@ -66,7 +66,7 @@ struct JCF;
 struct JCF;
 typedef int (*jcf_filbuf_t) (struct JCF*, int needed);
 
-union cpool_entry GTY(()) {
+union GTY(()) cpool_entry {
   jword GTY ((tag ("0"))) w;
   tree GTY ((tag ("1"))) t;
 };
@@ -74,7 +74,7 @@ union cpool_entry GTY(()) {
 #define cpool_entry_is_tree(tag) \
   (tag & CONSTANT_ResolvedFlag) || tag == CONSTANT_Utf8
 
-typedef struct CPool GTY(()) {
+typedef struct GTY(()) CPool {
   /* Available number of elements in the constants array, before it
      must be re-allocated. */
   int capacity;
@@ -92,7 +92,7 @@ struct ZipDirectory;
 
 /* JCF encapsulates the state of reading a Java Class File. */
 
-typedef struct JCF GTY(()) {
+typedef struct GTY(()) JCF {
   unsigned char * GTY ((skip)) buffer;
   unsigned char * GTY ((skip)) buffer_end;
   unsigned char * GTY ((skip)) read_ptr;
diff --git a/gcc/java/lang.c b/gcc/java/lang.c
--- a/gcc/java/lang.c
+++ b/gcc/java/lang.c
@@ -112,7 +112,7 @@ static int dependency_tracking = 0;
 #define DEPEND_TARGET_SET 4
 #define DEPEND_FILE_ALREADY_SET 8
 
-struct language_function GTY(())
+struct GTY(()) language_function
 {
   int unused;
 };
diff --git a/gcc/objc/objc-act.c b/gcc/objc/objc-act.c
--- a/gcc/objc/objc-act.c
+++ b/gcc/objc/objc-act.c
@@ -385,7 +385,7 @@ static int flag_typed_selectors;
 /* Store all constructed constant strings in a hash table so that
    they get uniqued properly.  */
 
-struct string_descriptor GTY(())
+struct GTY(()) string_descriptor
 {
   /* The literal argument .  */
   tree literal;
@@ -397,7 +397,7 @@ static GTY((param_is (struct string_desc
 static GTY((param_is (struct string_descriptor))) htab_t string_htab;
 
 /* Store the EH-volatilized types in a hash table, for easy retrieval.  */
-struct volatilized_type GTY(())
+struct GTY(()) volatilized_type
 {
   tree type;
 };
@@ -3275,7 +3275,7 @@ objc_generate_write_barrier (tree lhs, e
   return result;
 }
 
-struct interface_tuple GTY(())
+struct GTY(()) interface_tuple
 {
   tree id;
   tree class_name;
diff --git a/gcc/objc/objc-act.h b/gcc/objc/objc-act.h
--- a/gcc/objc/objc-act.h
+++ b/gcc/objc/objc-act.h
@@ -127,12 +127,12 @@ typedef struct hashed_entry	*hash;
 typedef struct hashed_entry	*hash;
 typedef struct hashed_attribute	*attr;
 
-struct hashed_attribute GTY(())
+struct GTY(()) hashed_attribute
 {
   attr next;
   tree value;
 };
-struct hashed_entry GTY(())
+struct GTY(()) hashed_entry
 {
   attr list;
   hash next;
@@ -146,7 +146,7 @@ extern GTY ((length ("SIZEHASHTABLE"))) 
 
 /* Objective-C/Objective-C++ @implementation list.  */
 
-struct imp_entry GTY(())
+struct GTY(()) imp_entry
 {
   struct imp_entry *next;
   tree imp_context;
diff --git a/gcc/optabs.c b/gcc/optabs.c
--- a/gcc/optabs.c
+++ b/gcc/optabs.c
@@ -132,7 +132,7 @@ void debug_optab_libfuncs (void);
 
 /* Info about libfunc.  We use same hashtable for normal optabs and conversion
    optab.  In the first case mode2 is unused.  */
-struct libfunc_entry GTY(())
+struct GTY(()) libfunc_entry
 {
   size_t optab;
   enum machine_mode mode1, mode2;
diff --git a/gcc/output.h b/gcc/output.h
--- a/gcc/output.h
+++ b/gcc/output.h
@@ -467,13 +467,13 @@ enum section_category
 };
 
 /* Information that is provided by all instances of the section type.  */
-struct section_common GTY(()) {
+struct GTY(()) section_common {
   /* The set of SECTION_* flags that apply to this section.  */
   unsigned int flags;
 };
 
 /* Information about a SECTION_NAMED section.  */
-struct named_section GTY(()) {
+struct GTY(()) named_section {
   struct section_common common;
 
   /* The name of the section.  */
@@ -489,7 +489,7 @@ typedef void (*unnamed_section_callback)
 typedef void (*unnamed_section_callback) (const void *);
 
 /* Information about a SECTION_UNNAMED section.  */
-struct unnamed_section GTY(()) {
+struct GTY(()) unnamed_section {
   struct section_common common;
 
   /* The callback used to switch to the section, and the data that
@@ -515,7 +515,7 @@ typedef bool (*noswitch_section_callback
 					   unsigned HOST_WIDE_INT rounded);
 
 /* Information about a SECTION_NOSWITCH section.  */
-struct noswitch_section GTY(()) {
+struct GTY(()) noswitch_section {
   struct section_common common;
 
   /* The callback used to assemble decls in this section.  */
@@ -523,7 +523,7 @@ struct noswitch_section GTY(()) {
 };
 
 /* Information about a section, which may be named or unnamed.  */
-union section GTY ((desc ("SECTION_STYLE (&(%h))")))
+union GTY((desc ("SECTION_STYLE (&(%h))"))) section
 {
   struct section_common GTY ((skip)) common;
   struct named_section GTY ((tag ("SECTION_NAMED"))) named;
diff --git a/gcc/real.h b/gcc/real.h
--- a/gcc/real.h
+++ b/gcc/real.h
@@ -43,7 +43,7 @@ enum real_value_class {
 #define SIGSZ			(SIGNIFICAND_BITS / HOST_BITS_PER_LONG)
 #define SIG_MSB			((unsigned long)1 << (HOST_BITS_PER_LONG - 1))
 
-struct real_value GTY(())
+struct GTY(()) real_value
 {
   /* Use the same underlying type for all bit-fields, so as to make
      sure they're packed together, otherwise REAL_VALUE_TYPE_SIZE will
diff --git a/gcc/rtl.h b/gcc/rtl.h
--- a/gcc/rtl.h
+++ b/gcc/rtl.h
@@ -139,7 +139,7 @@ typedef struct
 /* ALIGN and SIZE are the alignment and size of the MEM itself,
    while EXPR can describe a larger underlying object, which might have a
    stricter alignment; OFFSET is the offset of the MEM within that object.  */
-typedef struct mem_attrs GTY(())
+typedef struct GTY(()) mem_attrs
 {
   alias_set_type alias;		/* Memory alias set.  */
   tree expr;			/* expr corresponding to MEM.  */
@@ -155,7 +155,7 @@ typedef struct mem_attrs GTY(())
    object in the low part of a 4-byte register, the OFFSET field
    will be -3 rather than 0.  */
 
-typedef struct reg_attrs GTY(())
+typedef struct GTY(()) reg_attrs
 {
   tree decl;			/* decl corresponding to REG.  */
   HOST_WIDE_INT offset;		/* Offset from start of DECL.  */
@@ -185,7 +185,7 @@ typedef union rtunion_def rtunion;
 /* This structure remembers the position of a SYMBOL_REF within an
    object_block structure.  A SYMBOL_REF only provides this information
    if SYMBOL_REF_HAS_BLOCK_INFO_P is true.  */
-struct block_symbol GTY(()) {
+struct GTY(()) block_symbol {
   /* The usual SYMBOL_REF fields.  */
   rtunion GTY ((skip)) fld[3];
 
@@ -203,7 +203,7 @@ DEF_VEC_ALLOC_P(rtx,gc);
 
 /* Describes a group of objects that are to be placed together in such
    a way that their relative positions are known.  */
-struct object_block GTY(())
+struct GTY(()) object_block
 {
   /* The section in which these objects should be placed.  */
   section *sect;
@@ -237,8 +237,8 @@ struct object_block GTY(())
 
 /* RTL expression ("rtx").  */
 
-struct rtx_def GTY((chain_next ("RTX_NEXT (&%h)"),
-		    chain_prev ("RTX_PREV (&%h)")))
+struct GTY((chain_next ("RTX_NEXT (&%h)"), 
+            chain_prev ("RTX_PREV (&%h)"))) rtx_def
 {
   /* The kind of expression this is.  */
   ENUM_BITFIELD(rtx_code) code: 16;
@@ -357,7 +357,7 @@ struct rtx_def GTY((chain_next ("RTX_NEX
    for a variable number of things.  The principle use is inside
    PARALLEL expressions.  */
 
-struct rtvec_def GTY(()) {
+struct GTY(()) rtvec_def {
   int num_elem;		/* number of elements */
   rtx GTY ((length ("%h.num_elem"))) elem[1];
 };
diff --git a/gcc/stringpool.c b/gcc/stringpool.c
--- a/gcc/stringpool.c
+++ b/gcc/stringpool.c
@@ -216,7 +216,7 @@ gt_pch_n_S (const void *x)
 /* SPD is saved in the PCH file and holds the information needed
    to restore the string pool.  */
 
-struct string_pool_data GTY(())
+struct GTY(()) string_pool_data
 {
   struct ht_identifier * * 
     GTY((length ("%h.nslots"),
diff --git a/gcc/tree-data-ref.c b/gcc/tree-data-ref.c
--- a/gcc/tree-data-ref.c
+++ b/gcc/tree-data-ref.c
@@ -4577,7 +4577,7 @@ dot_rdg (struct graph *rdg)
 /* This structure is used for recording the mapping statement index in
    the RDG.  */
 
-struct rdg_vertex_info GTY(())
+struct GTY(()) rdg_vertex_info
 {
   tree stmt;
   int index;
diff --git a/gcc/tree-flow.h b/gcc/tree-flow.h
--- a/gcc/tree-flow.h
+++ b/gcc/tree-flow.h
@@ -61,7 +61,7 @@ enum escape_type
 
 /* Memory reference statistics for individual memory symbols,
    collected during alias analysis.  */
-struct mem_sym_stats_d GTY(())
+struct GTY(()) mem_sym_stats_d
 {
   /* Memory symbol.  */
   tree var;
@@ -107,7 +107,7 @@ DEF_VEC_ALLOC_P(mem_sym_stats_t, heap);
 DEF_VEC_ALLOC_P(mem_sym_stats_t, heap);
 
 /* Memory reference statistics collected during alias analysis.  */
-struct mem_ref_stats_d GTY(())
+struct GTY(()) mem_ref_stats_d
 {
   /* Number of statements that make memory references.  */
   long num_mem_stmts;
@@ -136,7 +136,7 @@ struct mem_ref_stats_d GTY(())
 /* Gimple dataflow datastructure. All publicly available fields shall have
    gimple_ accessor defined in tree-flow-inline.h, all publicly modifiable
    fields should have gimple_set accessor.  */
-struct gimple_df GTY(())
+struct GTY(()) gimple_df
 {
   /* Array of all variables referenced in the function.  */
   htab_t GTY((param_is (union tree_node))) referenced_vars;
@@ -229,7 +229,7 @@ typedef struct
 ---------------------------------------------------------------------------*/
 
 /* Aliasing information for SSA_NAMEs representing pointer variables.  */
-struct ptr_info_def GTY(())
+struct GTY(()) ptr_info_def
 {
   /* Mask of reasons this pointer's value escapes the function.  */
   ENUM_BITFIELD (escape_type) escape_mask : 9;
@@ -270,7 +270,7 @@ struct ptr_info_def GTY(())
 ---------------------------------------------------------------------------*/
 enum tree_ann_type { TREE_ANN_COMMON, VAR_ANN, FUNCTION_ANN, STMT_ANN };
 
-struct tree_ann_common_d GTY(())
+struct GTY(()) tree_ann_common_d
 {
   /* Annotation type.  */
   enum tree_ann_type type;
@@ -331,7 +331,7 @@ enum noalias_state {
 };
 
 
-struct var_ann_d GTY(())
+struct GTY(()) var_ann_d
 {
   struct tree_ann_common_d common;
 
@@ -401,13 +401,13 @@ struct var_ann_d GTY(())
 
 /* Container for variable annotation used by hashtable for annotations for
    static variables.  */
-struct static_var_ann_d GTY(())
+struct GTY(()) static_var_ann_d
 {
   struct var_ann_d ann;
   unsigned int uid;
 };
 
-struct function_ann_d GTY(())
+struct GTY(()) function_ann_d
 {
   struct tree_ann_common_d common;
 
@@ -476,7 +476,7 @@ typedef struct immediate_use_iterator_d
 
 
 
-struct stmt_ann_d GTY(())
+struct GTY(()) stmt_ann_d
 {
   struct tree_ann_common_d common;
 
@@ -508,7 +508,7 @@ struct stmt_ann_d GTY(())
   unsigned has_volatile_ops : 1;
 };
 
-union tree_ann_d GTY((desc ("ann_type ((tree_ann_t)&%h)")))
+union GTY((desc ("ann_type ((tree_ann_t)&%h)"))) tree_ann_d
 {
   struct tree_ann_common_d GTY((tag ("TREE_ANN_COMMON"))) common;
   struct var_ann_d GTY((tag ("VAR_ANN"))) vdecl;
@@ -544,7 +544,7 @@ static inline bitmap addresses_taken (tr
 /*---------------------------------------------------------------------------
                   Structure representing predictions in tree level.
 ---------------------------------------------------------------------------*/
-struct edge_prediction GTY((chain_next ("%h.ep_next")))
+struct GTY((chain_next ("%h.ep_next"))) edge_prediction
 {
   struct edge_prediction *ep_next;
   edge ep_edge;
@@ -559,7 +559,7 @@ static inline void set_phi_nodes (basic_
 /*---------------------------------------------------------------------------
 			      Global declarations
 ---------------------------------------------------------------------------*/
-struct int_tree_map GTY(())
+struct GTY(()) int_tree_map
 {
   
   unsigned int uid;
@@ -890,7 +890,7 @@ extern void strict_aliasing_warning_back
 /* In tree-ssa.c  */
 
 /* Mapping for redirected edges.  */
-struct _edge_var_map GTY(())
+struct GTY(()) _edge_var_map
 {
   tree result;			/* PHI result.  */
   tree def;			/* PHI arg definition.  */
diff --git a/gcc/tree-scalar-evolution.c b/gcc/tree-scalar-evolution.c
--- a/gcc/tree-scalar-evolution.c
+++ b/gcc/tree-scalar-evolution.c
@@ -281,7 +281,7 @@ static tree analyze_scalar_evolution_1 (
 /* The cached information about a ssa name VAR, claiming that inside LOOP,
    the value of VAR can be expressed as CHREC.  */
 
-struct scev_info_str GTY(())
+struct GTY(()) scev_info_str
 {
   tree var;
   tree chrec;
diff --git a/gcc/tree-ssa-address.c b/gcc/tree-ssa-address.c
--- a/gcc/tree-ssa-address.c
+++ b/gcc/tree-ssa-address.c
@@ -70,7 +70,7 @@ along with GCC; see the file COPYING3.  
 /* A "template" for memory address, used to determine whether the address is
    valid for mode.  */
 
-struct mem_addr_template GTY (())
+struct GTY (()) mem_addr_template
 {
   rtx ref;			/* The template.  */
   rtx * GTY ((skip)) step_p;	/* The point in template where the step should be
diff --git a/gcc/tree-ssa-operands.h b/gcc/tree-ssa-operands.h
--- a/gcc/tree-ssa-operands.h
+++ b/gcc/tree-ssa-operands.h
@@ -110,7 +110,7 @@ typedef struct voptype_d *voptype_p;
    operand memory manager.  Operands are suballocated out of this block.  The
    MEM array varies in size.  */
    
-struct ssa_operand_memory_d GTY((chain_next("%h.next")))
+struct GTY((chain_next("%h.next"))) ssa_operand_memory_d
 {
   struct ssa_operand_memory_d *next;
   char mem[1];
@@ -120,7 +120,7 @@ struct ssa_operand_memory_d GTY((chain_n
 #define NUM_VOP_FREE_BUCKETS		29
 
 /* Per-function operand caches.  */
-struct ssa_operands GTY(()) {
+struct GTY(()) ssa_operands {
    struct ssa_operand_memory_d *operand_memory;
    unsigned operand_memory_index;
    /* Current size of the operand memory buffer.  */
diff --git a/gcc/tree.c b/gcc/tree.c
--- a/gcc/tree.c
+++ b/gcc/tree.c
@@ -151,7 +151,7 @@ static GTY(()) int next_type_uid = 1;
 /* Since we cannot rehash a type after it is in the table, we have to
    keep the hash code.  */
 
-struct type_hash GTY(())
+struct GTY(()) type_hash
 {
   unsigned long hash;
   tree type;
diff --git a/gcc/tree.h b/gcc/tree.h
--- a/gcc/tree.h
+++ b/gcc/tree.h
@@ -372,7 +372,7 @@ enum omp_clause_code
    fields.  */
 union tree_ann_d;
 
-struct tree_base GTY(())
+struct GTY(()) tree_base 
 {
   ENUM_BITFIELD(tree_code) code : 16;
 
@@ -411,7 +411,7 @@ struct tree_base GTY(())
   union tree_ann_d *ann;
 };
 
-struct tree_common GTY(())
+struct GTY(()) tree_common 
 {
   struct tree_base base;
   tree chain;
@@ -419,7 +419,7 @@ struct tree_common GTY(())
 };
 
 /* GIMPLE_MODIFY_STMT */
-struct gimple_stmt GTY(())
+struct GTY(()) gimple_stmt 
 {
   struct tree_base base;
   location_t locus;
@@ -1471,7 +1471,7 @@ extern void omp_clause_range_check_faile
 	== (unsigned HOST_WIDE_INT) TREE_INT_CST_HIGH (B))	\
        && TREE_INT_CST_LOW (A) < TREE_INT_CST_LOW (B)))
 
-struct tree_int_cst GTY(())
+struct GTY(()) tree_int_cst 
 {
   struct tree_common common;
   double_int int_cst;
@@ -1485,7 +1485,7 @@ struct real_value;
 #define TREE_REAL_CST_PTR(NODE) (REAL_CST_CHECK (NODE)->real_cst.real_cst_ptr)
 #define TREE_REAL_CST(NODE) (*TREE_REAL_CST_PTR (NODE))
 
-struct tree_real_cst GTY(())
+struct GTY(()) tree_real_cst 
 {
   struct tree_common common;
   struct real_value * real_cst_ptr;
@@ -1497,7 +1497,7 @@ struct fixed_value;
 #define TREE_FIXED_CST_PTR(NODE) (FIXED_CST_CHECK (NODE)->fixed_cst.fixed_cst_ptr)
 #define TREE_FIXED_CST(NODE) (*TREE_FIXED_CST_PTR (NODE))
 
-struct tree_fixed_cst GTY(())
+struct GTY(()) tree_fixed_cst 
 {
   struct tree_common common;
   struct fixed_value * fixed_cst_ptr;
@@ -1508,7 +1508,7 @@ struct tree_fixed_cst GTY(())
 #define TREE_STRING_POINTER(NODE) \
   ((const char *)(STRING_CST_CHECK (NODE)->string.str))
 
-struct tree_string GTY(())
+struct GTY(()) tree_string 
 {
   struct tree_common common;
   int length;
@@ -1519,7 +1519,7 @@ struct tree_string GTY(())
 #define TREE_REALPART(NODE) (COMPLEX_CST_CHECK (NODE)->complex.real)
 #define TREE_IMAGPART(NODE) (COMPLEX_CST_CHECK (NODE)->complex.imag)
 
-struct tree_complex GTY(())
+struct GTY(()) tree_complex 
 {
   struct tree_common common;
   tree real;
@@ -1529,7 +1529,7 @@ struct tree_complex GTY(())
 /* In a VECTOR_CST node.  */
 #define TREE_VECTOR_CST_ELTS(NODE) (VECTOR_CST_CHECK (NODE)->vector.elements)
 
-struct tree_vector GTY(())
+struct GTY(()) tree_vector 
 {
   struct tree_common common;
   tree elements;
@@ -1553,7 +1553,7 @@ struct tree_vector GTY(())
   ((tree) ((char *) (NODE) - sizeof (struct tree_common)))
 #define GCC_IDENT_TO_HT_IDENT(NODE) (&((struct tree_identifier *) (NODE))->id)
 
-struct tree_identifier GTY(())
+struct GTY(()) tree_identifier 
 {
   struct tree_common common;
   struct ht_identifier id;
@@ -1563,7 +1563,7 @@ struct tree_identifier GTY(())
 #define TREE_PURPOSE(NODE) (TREE_LIST_CHECK (NODE)->list.purpose)
 #define TREE_VALUE(NODE) (TREE_LIST_CHECK (NODE)->list.value)
 
-struct tree_list GTY(())
+struct GTY(()) tree_list 
 {
   struct tree_common common;
   tree purpose;
@@ -1577,7 +1577,7 @@ struct tree_list GTY(())
 
 #define TREE_VEC_ELT(NODE,I) TREE_VEC_ELT_CHECK (NODE, I)
 
-struct tree_vec GTY(())
+struct GTY(()) tree_vec 
 {
   struct tree_common common;
   int length;
@@ -1623,7 +1623,7 @@ struct tree_vec GTY(())
    element. INDEX can optionally design the position of VALUE: in arrays,
    it is the index where VALUE has to be placed; in structures, it is the
    FIELD_DECL of the member.  */
-typedef struct constructor_elt_d GTY(())
+typedef struct GTY(()) constructor_elt_d 
 {
   tree index;
   tree value;
@@ -1632,7 +1632,7 @@ DEF_VEC_O(constructor_elt);
 DEF_VEC_O(constructor_elt);
 DEF_VEC_ALLOC_O(constructor_elt,gc);
 
-struct tree_constructor GTY(())
+struct GTY(()) tree_constructor 
 {
   struct tree_common common;
   VEC(constructor_elt,gc) *elts;
@@ -1934,7 +1934,7 @@ enum omp_clause_default_kind
 #define OMP_CLAUSE_DEFAULT_KIND(NODE) \
   (OMP_CLAUSE_SUBCODE_CHECK (NODE, OMP_CLAUSE_DEFAULT)->omp_clause.subcode.default_kind)
 
-struct tree_exp GTY(())
+struct GTY(()) tree_exp
 {
   struct tree_common common;
   location_t locus;
@@ -1995,7 +1995,7 @@ struct ptr_info_def;
 
 /* Immediate use linking structure.  This structure is used for maintaining
    a doubly linked list of uses of an SSA_NAME.  */
-typedef struct ssa_use_operand_d GTY(())
+typedef struct GTY(()) ssa_use_operand_d 
 {
   struct ssa_use_operand_d* GTY((skip(""))) prev;
   struct ssa_use_operand_d* GTY((skip(""))) next;
@@ -2006,7 +2006,7 @@ typedef struct ssa_use_operand_d GTY(())
 /* Return the immediate_use information for an SSA_NAME. */
 #define SSA_NAME_IMM_USE_NODE(NODE) SSA_NAME_CHECK (NODE)->ssa_name.imm_uses
 
-struct tree_ssa_name GTY(())
+struct GTY(()) tree_ssa_name 
 {
   struct tree_common common;
 
@@ -2053,7 +2053,7 @@ struct tree_ssa_name GTY(())
 #define PHI_BB(NODE)			PHI_NODE_CHECK (NODE)->phi.bb
 #define PHI_ARG_IMM_USE_NODE(NODE, I)	PHI_NODE_ELT_CHECK (NODE, I).imm_use
 
-struct phi_arg_d GTY(())
+struct GTY(()) phi_arg_d 
 {
   /* imm_use MUST be the first element in struct because we do some
      pointer arithmetic with it.  See phi_arg_index_from_use.  */
@@ -2061,7 +2061,7 @@ struct phi_arg_d GTY(())
   tree def;
 };
 
-struct tree_phi_node GTY(())
+struct GTY(()) tree_phi_node 
 {
   struct tree_base common;
   tree chain;
@@ -2090,7 +2090,7 @@ struct tree_phi_node GTY(())
 #define OMP_CLAUSE_OPERAND(NODE, I)				\
 	OMP_CLAUSE_ELT_CHECK (NODE, I)
 
-struct tree_omp_clause GTY(())
+struct GTY(()) tree_omp_clause 
 {
   struct tree_common common;
   enum omp_clause_code code;
@@ -2156,7 +2156,7 @@ struct varray_head_tag;
 
 #define BLOCK_SOURCE_LOCATION(NODE) (BLOCK_CHECK (NODE)->block.locus)
 
-struct tree_block GTY(())
+struct GTY(()) tree_block 
 {
   struct tree_common common;
 
@@ -2389,7 +2389,7 @@ struct tree_block GTY(())
 
 struct die_struct;
 
-struct tree_type GTY(())
+struct GTY(()) tree_type 
 {
   struct tree_common common;
   tree values;
@@ -2543,7 +2543,7 @@ struct tree_type GTY(())
 #define BINFO_INHERITANCE_CHAIN(NODE) \
 	(TREE_BINFO_CHECK(NODE)->binfo.inheritance)
 
-struct tree_binfo GTY (())
+struct GTY (()) tree_binfo 
 {
   struct tree_common common;
 
@@ -2619,7 +2619,7 @@ struct function;
     scope".  */
 #define DECL_CONTEXT(NODE) (DECL_MINIMAL_CHECK (NODE)->decl_minimal.context)
 #define DECL_FIELD_CONTEXT(NODE) (FIELD_DECL_CHECK (NODE)->decl_minimal.context)
-struct tree_decl_minimal GTY(())
+struct GTY(()) tree_decl_minimal 
 {
   struct tree_common common;
   location_t locus;
@@ -2645,7 +2645,7 @@ struct tree_decl_minimal GTY(())
    In general, given a pointer P with a symbol tag SMT, the alias set
    of SMT should be the union of all the alias sets of the NMTs of
    every SSA_NAME for P.  */
-struct tree_memory_tag GTY(())
+struct GTY(()) tree_memory_tag 
 {
   struct tree_decl_minimal common;
 
@@ -2661,7 +2661,7 @@ struct tree_memory_tag GTY(())
 /* Memory Partition Tags (MPTs) group memory symbols under one
    common name for the purposes of placing memory PHI nodes.  */
 
-struct tree_memory_partition_tag GTY(())
+struct GTY(()) tree_memory_partition_tag 
 {
   struct tree_memory_tag common;
   
@@ -2817,7 +2817,7 @@ struct tree_memory_partition_tag GTY(())
 #define DECL_NO_TBAA_P(DECL) \
   DECL_COMMON_CHECK (DECL)->decl_common.no_tbaa_flag
 
-struct tree_decl_common GTY(())
+struct GTY(()) tree_decl_common 
 {
   struct tree_decl_minimal common;
   tree size;
@@ -2918,7 +2918,7 @@ extern void decl_value_expr_insert (tree
 /* In VAR_DECL and PARM_DECL nodes, nonzero means declared `register'.  */
 #define DECL_REGISTER(NODE) (DECL_WRTL_CHECK (NODE)->decl_common.decl_flag_0)
 
-struct tree_decl_with_rtl GTY(())
+struct GTY(()) tree_decl_with_rtl 
 {
   struct tree_decl_common common;
   rtx rtl;
@@ -2987,7 +2987,7 @@ struct tree_decl_with_rtl GTY(())
 #define DECL_NONADDRESSABLE_P(NODE) \
   (FIELD_DECL_CHECK (NODE)->decl_common.decl_flag_3)
 
-struct tree_field_decl GTY(())
+struct GTY(()) tree_field_decl 
 {
   struct tree_decl_common common;
 
@@ -3009,17 +3009,17 @@ struct tree_field_decl GTY(())
    jumping into such a binding contour has been printed for this label.  */
 #define DECL_ERROR_ISSUED(NODE) (LABEL_DECL_CHECK (NODE)->decl_common.decl_flag_0)
 
-struct tree_label_decl GTY(())
+struct GTY(()) tree_label_decl 
 {
   struct tree_decl_with_rtl common;
 };
 
-struct tree_result_decl GTY(())
+struct GTY(()) tree_result_decl 
 {
   struct tree_decl_with_rtl common;
 };
 
-struct tree_const_decl GTY(())
+struct GTY(()) tree_const_decl 
 {
   struct tree_decl_with_rtl common;
 };
@@ -3032,7 +3032,7 @@ struct tree_const_decl GTY(())
    where the data was actually passed.  */
 #define DECL_INCOMING_RTL(NODE) (PARM_DECL_CHECK (NODE)->parm_decl.incoming_rtl)
 
-struct tree_parm_decl GTY(())
+struct GTY(()) tree_parm_decl 
 {
   struct tree_decl_with_rtl common;
   rtx incoming_rtl;
@@ -3160,7 +3160,7 @@ extern void decl_restrict_base_insert (t
    multiple translation units should be merged.  */
 #define DECL_ONE_ONLY(NODE) (DECL_WITH_VIS_CHECK (NODE)->decl_with_vis.one_only)
 
-struct tree_decl_with_vis GTY(())
+struct GTY(()) tree_decl_with_vis 
 {
  struct tree_decl_with_rtl common;
  tree assembler_name;
@@ -3266,7 +3266,7 @@ extern void decl_fini_priority_insert (t
 #define DECL_THREAD_LOCAL_P(NODE) \
   (VAR_DECL_CHECK (NODE)->decl_with_vis.tls_model >= TLS_MODEL_REAL)
 
-struct tree_var_decl GTY(())
+struct GTY(()) tree_var_decl 
 {
   struct tree_decl_with_vis common;
 };
@@ -3286,7 +3286,7 @@ struct tree_var_decl GTY(())
    C++ also uses this field in namespaces, hence the DECL_NON_COMMON_CHECK.  */
 #define DECL_VINDEX(NODE) (DECL_NON_COMMON_CHECK (NODE)->decl_non_common.vindex)
 
-struct tree_decl_non_common GTY(())
+struct GTY(()) tree_decl_non_common 
 
 {
   struct tree_decl_with_vis common;
@@ -3413,7 +3413,7 @@ struct tree_decl_non_common GTY(())
    FUNCTION_DECL from non_common, or inherit non_common from FUNCTION_DECL,
    which seemed a bit strange.  */
 
-struct tree_function_decl GTY(())
+struct GTY(()) tree_function_decl 
 {
   struct tree_decl_non_common common;
 
@@ -3458,7 +3458,7 @@ struct tree_function_decl GTY(())
 #define TYPE_DECL_SUPPRESS_DEBUG(NODE) \
   (TYPE_DECL_CHECK (NODE)->decl_common.decl_flag_2)
 
-struct tree_type_decl GTY(())
+struct GTY(()) tree_type_decl 
 {
   struct tree_decl_non_common common;
 
@@ -3475,16 +3475,15 @@ struct tree_type_decl GTY(())
 #define STATEMENT_LIST_TAIL(NODE) \
   (STATEMENT_LIST_CHECK (NODE)->stmt_list.tail)
 
-struct tree_statement_list_node
-  GTY ((chain_next ("%h.next"), chain_prev ("%h.prev")))
+struct GTY((chain_next ("%h.next"), chain_prev ("%h.prev")))
+  tree_statement_list_node
 {
   struct tree_statement_list_node *prev;
   struct tree_statement_list_node *next;
   tree stmt;
 };
 
-struct tree_statement_list
-  GTY(())
+struct GTY(()) tree_statement_list
 {
   struct tree_common common;
   struct tree_statement_list_node *head;
@@ -3496,8 +3495,9 @@ struct tree_statement_list
    It may be any of the structures declared above
    for various types of node.  */
 
-union tree_node GTY ((ptr_alias (union lang_tree_node),
-		      desc ("tree_node_structure (&%h)")))
+union 
+  GTY ((ptr_alias (union lang_tree_node), desc ("tree_node_structure (&%h)")))
+  tree_node 
 {
   struct tree_base GTY ((tag ("TS_BASE"))) base;
   struct tree_common GTY ((tag ("TS_COMMON"))) common;
@@ -5236,7 +5236,7 @@ extern void vect_set_verbosity_level (co
 
 /* In tree.c.  */
 
-struct tree_map_base GTY(())
+struct GTY(()) tree_map_base 
 {
   tree from;
 };
@@ -5247,7 +5247,7 @@ extern int tree_map_base_marked_p (const
 
 /* Map from a tree to another tree.  */
 
-struct tree_map GTY(())
+struct GTY(()) tree_map 
 {
   struct tree_map_base base;
   unsigned int hash;
@@ -5260,7 +5260,7 @@ extern unsigned int tree_map_hash (const
 
 /* Map from a tree to an int.  */
 
-struct tree_int_map GTY(())
+struct GTY(()) tree_int_map 
 {
   struct tree_map_base base;
   unsigned int to;
@@ -5272,7 +5272,7 @@ struct tree_int_map GTY(())
 
 /* Map from a tree to initialization/finalization priorities.  */
 
-struct tree_priority_map GTY(())
+struct GTY(()) tree_priority_map 
 {
   struct tree_map_base base;
   priority_type init;
@@ -5320,14 +5320,14 @@ tree_operand_length (const_tree node)
    defined by this point.  */
 
 /* Structure containing iterator state.  */
-typedef struct call_expr_arg_iterator_d GTY (())
+typedef struct GTY (()) call_expr_arg_iterator_d 
 {
   tree t;	/* the call_expr */
   int n;	/* argument count */
   int i;	/* next argument index */
 } call_expr_arg_iterator;
 
-typedef struct const_call_expr_arg_iterator_d GTY (())
+typedef struct GTY (()) const_call_expr_arg_iterator_d 
 {
   const_tree t;	/* the call_expr */
   int n;	/* argument count */
diff --git a/gcc/varasm.c b/gcc/varasm.c
--- a/gcc/varasm.c
+++ b/gcc/varasm.c
@@ -2690,7 +2690,7 @@ assemble_real (REAL_VALUE_TYPE d, enum m
    Store them both in the structure *VALUE.
    EXP must be reducible.  */
 
-struct addr_const GTY(())
+struct GTY(()) addr_const
 {
   rtx base;
   HOST_WIDE_INT offset;
@@ -2759,7 +2759,7 @@ decode_addr_const (tree exp, struct addr
    Each constant in memory thus far output is recorded
    in `const_desc_table'.  */
 
-struct constant_descriptor_tree GTY(())
+struct GTY(()) constant_descriptor_tree
 {
   /* A MEM for the constant.  */
   rtx rtl;
@@ -3345,7 +3345,7 @@ lookup_constant_def (tree exp)
    can use one per-file pool.  Should add a targetm bit to tell the
    difference.  */
 
-struct rtx_constant_pool GTY(())
+struct GTY(()) rtx_constant_pool
 {
   /* Pointers to first and last constant in pool, as ordered by offset.  */
   struct constant_descriptor_rtx *first;
@@ -3362,7 +3362,7 @@ struct rtx_constant_pool GTY(())
   HOST_WIDE_INT offset;
 };
 
-struct constant_descriptor_rtx GTY((chain_next ("%h.next")))
+struct GTY((chain_next ("%h.next"))) constant_descriptor_rtx
 {
   struct constant_descriptor_rtx *next;
   rtx mem;
@@ -5120,7 +5120,7 @@ globalize_decl (tree decl)
    of an alias.  This requires that the decl have been defined.  Aliases
    that precede their definition have to be queued for later processing.  */
 
-typedef struct alias_pair GTY(())
+typedef struct GTY(()) alias_pair
 {
   tree decl;
   tree target;
diff --git a/gcc/varray.h b/gcc/varray.h
--- a/gcc/varray.h
+++ b/gcc/varray.h
@@ -62,7 +62,7 @@ enum varray_data_enum {
 };
 
 /* Union of various array types that are used.  */
-typedef union varray_data_tag GTY (()) {
+typedef union  GTY (()) varray_data_tag {
   char			  GTY ((length ("%0.num_elements"),
 				tag ("VARRAY_DATA_C")))		vdt_c[1];
   unsigned char		  GTY ((length ("%0.num_elements"),
@@ -110,7 +110,7 @@ typedef union varray_data_tag GTY (()) {
 } varray_data;
 
 /* Virtual array of pointers header.  */
-struct varray_head_tag GTY(()) {
+struct GTY(()) varray_head_tag {
   size_t	num_elements;	/* Maximum element number allocated.  */
   size_t        elements_used;  /* The number of elements used, if
 				   using VARRAY_PUSH/VARRAY_POP.  */
diff --git a/gcc/vec.h b/gcc/vec.h
--- a/gcc/vec.h
+++ b/gcc/vec.h
@@ -466,7 +466,7 @@ typedef struct VEC(T,B) 				 		  \
 } VEC(T,B)
 
 #define VEC_T_GTY(T,B)							  \
-typedef struct VEC(T,B) GTY(())				 		  \
+typedef struct GTY(()) VEC(T,B)                     	 		  \
 {									  \
   unsigned num;								  \
   unsigned alloc;							  \
@@ -475,7 +475,7 @@ typedef struct VEC(T,B) GTY(())				 		  
 
 /* Derived vector type, user visible.  */
 #define VEC_TA_GTY(T,B,A,GTY)						  \
-typedef struct VEC(T,A) GTY						  \
+typedef struct GTY VEC(T,A)						  \
 {									  \
   VEC(T,B) base;							  \
 } VEC(T,A)
diff --git a/include/hashtab.h b/include/hashtab.h
--- a/include/hashtab.h
+++ b/include/hashtab.h
@@ -96,7 +96,7 @@ typedef void (*htab_free_with_arg) (void
    functions mentioned below.  The size of this structure is subject to
    change.  */
 
-struct htab GTY(())
+struct GTY(()) htab
 {
   /* Pointer to hash function.  */
   htab_hash hash_f;
diff --git a/include/splay-tree.h b/include/splay-tree.h
--- a/include/splay-tree.h
+++ b/include/splay-tree.h
@@ -86,7 +86,7 @@ typedef void (*splay_tree_deallocate_fn)
 typedef void (*splay_tree_deallocate_fn) (void *, void *);
 
 /* The nodes in the splay tree.  */
-struct splay_tree_node_s GTY(())
+struct GTY(()) splay_tree_node_s 
 {
   /* The key.  */
   splay_tree_key GTY ((use_param1)) key;
@@ -100,7 +100,7 @@ struct splay_tree_node_s GTY(())
 };
 
 /* The splay tree itself.  */
-struct splay_tree_s GTY(())
+struct GTY(()) splay_tree_s 
 {
   /* The root of the tree.  */
   splay_tree_node GTY ((use_params)) root;
diff --git a/libcpp/include/cpp-id-data.h b/libcpp/include/cpp-id-data.h
--- a/libcpp/include/cpp-id-data.h
+++ b/libcpp/include/cpp-id-data.h
@@ -25,7 +25,7 @@ typedef unsigned char uchar;
 #define UC (const unsigned char *)  /* Intended use: UC"string" */
 
 /* Chained list of answers to an assertion.  */
-struct answer GTY(())
+struct GTY(()) answer
 {
   struct answer *next;
   unsigned int count;
@@ -34,7 +34,7 @@ struct answer GTY(())
 
 /* Each macro definition is recorded in a cpp_macro structure.
    Variadic macros cannot occur with traditional cpp.  */
-struct cpp_macro GTY(())
+struct GTY(()) cpp_macro
 {
   /* Parameters, if any.  */
   cpp_hashnode ** GTY ((nested_ptr (union tree_node,
diff --git a/libcpp/include/cpplib.h b/libcpp/include/cpplib.h
--- a/libcpp/include/cpplib.h
+++ b/libcpp/include/cpplib.h
@@ -162,7 +162,7 @@ enum c_lang {CLK_GNUC89 = 0, CLK_GNUC99,
 	     CLK_GNUCXX, CLK_CXX98, CLK_GNUCXX0X, CLK_CXX0X, CLK_ASM};
 
 /* Payload of a NUMBER, STRING, CHAR or COMMENT token.  */
-struct cpp_string GTY(())
+struct GTY(()) cpp_string 
 {
   unsigned int len;
   const unsigned char *text;
@@ -192,7 +192,7 @@ enum cpp_token_fld_kind {
 
 /* A preprocessing token.  This has been carefully packed and should
    occupy 16 bytes on 32-bit hosts and 24 bytes on 64-bit hosts.  */
-struct cpp_token GTY(())
+struct GTY(()) cpp_token 
 {
   source_location src_loc;	/* Location of first char of token.  */
   ENUM_BITFIELD(cpp_ttype) type : CHAR_BIT;  /* token type */
@@ -614,7 +614,7 @@ enum {
    ends.  Also used to store CPP identifiers, which are a superset of
    identifiers in the grammatical sense.  */
 
-union _cpp_hashnode_value GTY(())
+union GTY(()) _cpp_hashnode_value
 {
   /* If a macro.  */
   cpp_macro * GTY((tag ("NTV_MACRO"))) macro;
@@ -626,7 +626,7 @@ union _cpp_hashnode_value GTY(())
   unsigned short GTY ((tag ("NTV_ARGUMENT"))) arg_index;
 };
 
-struct cpp_hashnode GTY(())
+struct GTY(()) cpp_hashnode 
 {
   struct ht_identifier ident;
   unsigned int is_directive : 1;
diff --git a/libcpp/include/line-map.h b/libcpp/include/line-map.h
--- a/libcpp/include/line-map.h
+++ b/libcpp/include/line-map.h
@@ -57,7 +57,7 @@ typedef void *(*line_map_realloc) (void 
    creation of this line map, SYSP is one for a system header, two for
    a C system header file that therefore needs to be extern "C"
    protected in C++, and zero otherwise.  */
-struct line_map GTY(())
+struct GTY(()) line_map 
 {
   const char *to_file;
   linenum_type to_line;
@@ -71,7 +71,7 @@ struct line_map GTY(())
 };
 
 /* A set of chronological line_map structures.  */
-struct line_maps GTY(())
+struct GTY(()) line_maps 
 {
   struct line_map * GTY ((length ("%h.used"))) maps;
   unsigned int allocated;
diff --git a/libcpp/include/symtab.h b/libcpp/include/symtab.h
--- a/libcpp/include/symtab.h
+++ b/libcpp/include/symtab.h
@@ -26,7 +26,7 @@ Foundation, 51 Franklin Street, Fifth Fl
 /* This is what each hash table entry points to.  It may be embedded
    deeply within another object.  */
 typedef struct ht_identifier ht_identifier;
-struct ht_identifier GTY(())
+struct GTY(()) ht_identifier 
 {
   const unsigned char *str;
   unsigned int len;

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]