aboutsummaryrefslogtreecommitdiff
path: root/gcc/sdbout.c
diff options
context:
space:
mode:
authorsteven <steven@138bc75d-0d04-0410-961f-82ee72b054a4>2010-04-30 14:58:54 +0000
committersteven <steven@138bc75d-0d04-0410-961f-82ee72b054a4>2010-04-30 14:58:54 +0000
commit67076d6d021ccc8692cdda5c1cb37cc937068e5d (patch)
tree1fcd11c88845a3c74b2d60744c3b29ea233813f8 /gcc/sdbout.c
parentda67d82629fa5e769cbce16569de9a07212445b1 (diff)
* sdbout.c: Include vec.h, do not include varray.h.
(deferred_global_decls, sdbout_global_decl, sdbout_finish, sdbout_init): Use VEC instead of VARRAY. * toplev.c: Do not include varray.h. (dump_memory_report): Do not dump VARRAY statistics. * gengtype.c (open_base_file): Ignore varray.h. * Makefile.in: Update for abovementioned changes. Remove all traces of varray.c and varray.h. * varray.c: Remove file. * varray.h: Remove file. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158939 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/sdbout.c')
-rw-r--r--gcc/sdbout.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/gcc/sdbout.c b/gcc/sdbout.c
index f4541ea0763..87a00b4a61e 100644
--- a/gcc/sdbout.c
+++ b/gcc/sdbout.c
@@ -48,7 +48,7 @@ AT&T C compiler. From the example below I would conclude the following:
#include "debug.h"
#include "tree.h"
#include "ggc.h"
-#include "varray.h"
+#include "vec.h"
static GTY(()) tree anonymous_types;
@@ -58,7 +58,7 @@ static GTY(()) int unnamed_struct_number;
/* Declarations whose debug info was deferred till end of compilation. */
-static GTY(()) varray_type deferred_global_decls;
+static GTY(()) VEC(tree,gc) *deferred_global_decls;
/* The C front end may call sdbout_symbol before sdbout_init runs.
We save all such decls in this list and output them when we get
@@ -1464,7 +1464,7 @@ sdbout_global_decl (tree decl)
if (!DECL_INITIAL (decl) || !TREE_PUBLIC (decl))
sdbout_symbol (decl, 0);
else
- VARRAY_PUSH_TREE (deferred_global_decls, decl);
+ VEC_safe_push (tree, gc, deferred_global_decls, decl);
/* Output COFF information for non-global file-scope initialized
variables. */
@@ -1480,9 +1480,10 @@ static void
sdbout_finish (const char *main_filename ATTRIBUTE_UNUSED)
{
size_t i;
+ tree decl;
- for (i = 0; i < VARRAY_ACTIVE_SIZE (deferred_global_decls); i++)
- sdbout_symbol (VARRAY_TREE (deferred_global_decls, i), 0);
+ for (i = 0; VEC_iterate (tree, deferred_global_decls, i, decl); i++)
+ sdbout_symbol (decl, 0);
}
/* Describe the beginning of an internal block within a function.
@@ -1689,7 +1690,7 @@ sdbout_init (const char *input_file_name ATTRIBUTE_UNUSED)
current_file->name = input_file_name;
#endif
- VARRAY_TREE_INIT (deferred_global_decls, 12, "deferred_global_decls");
+ deferred_global_decls = VEC_alloc (tree, gc, 12);
/* Emit debug information which was queued by sdbout_symbol before
we got here. */