This is the mail archive of the 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]

[Committed] Fix gt-dwarf2out.h bootstrap failure

Many thanks to Andrew Pinski for correctly identifying the source of
the current boostrap failure on Tru64 in GeoffK's recent dwarf patch.
The problem is that the new GC'd variable file_table_last_lookup is
declared inside #ifdef DWARF2_DEBUGGING_INFO which fools our GC
machinery to producing a gt-dwarf2out.h with an invalid (non-constant)
initializer.  Fixed by moving the declaration inside the source file.
I've also added a comment describing what file_table_last_lookup does.

Tested on alphaev67-dec-osf5.1 by getting past stage 1.
Committed to mainline as revision 116903.  Thanks Andrew.

2006-09-12  Andrew Pinski  <>
	    Roger Sayle  <>

	* dwarf2out.c (file_table_last_lookup): Move this GC'd declaration
	outside of #ifdef DWARF2_DEBUGGING_INFO to fix bootstrap failure
	on platforms that don't use dwarf for debug info.

Index: dwarf2out.c
*** dwarf2out.c	(revision 116898)
--- dwarf2out.c	(working copy)
*************** static GTY(()) struct dwarf_file_data *
*** 3998,4003 ****
--- 3998,4006 ----
  /* Number of internal labels generated by gen_internal_sym().  */
  static GTY(()) int label_num;

+ /* Cached result of previous call to lookup_filename.  */
+ static GTY(()) struct dwarf_file_data * file_table_last_lookup;

  /* Offset from the "steady-state frame pointer" to the frame base,
*************** file_table_hash (const void *p_p)
*** 13521,13528 ****
     available unique index number.  In order to speed up searches, we remember
     the index of the filename was looked up last.  This handles the majority of
     all searches.  */
- static GTY(()) struct dwarf_file_data * file_table_last_lookup;

  static struct dwarf_file_data *
  lookup_filename (const char *file_name)
--- 13524,13529 ----


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