Makefile.in (stor-layout.o): Depend on ggc.h.
* Makefile.in (stor-layout.o): Depend on ggc.h. (expr.o): Depend on ggc.h. (profile.o): Depend on ggc.h. (stor-layout.o): Depend on ggc.h. * emit-rtl.c (init_emit_once): Add gc roots. * expr.c: Include ggc.h. (emit_block_move): Add gc roots. (clear_storage): Likewise. * expr.h (init_stor_layout_once): New function. * profile.c: Include ggc.h. (init_arc_profiler): profiler_label is a root. * scan.c (make_sstring_space): Trust xrealloc to function correctly with first parameter NULL. * stor-layout.c: Include ggc.h. (set_sizetype): Add gc root. (init_stor_layout_once): New function. * toplev.c (compile_file): Call it. Co-Authored-By: Bernd Schmidt <bernds@cygnus.co.uk> Co-Authored-By: Mark Mitchell <mark@codesourcery.com> From-SVN: r29122
This commit is contained in:
parent
b224278904
commit
d7db664650
|
@ -1,3 +1,25 @@
|
|||
Sat Sep 4 20:40:19 1999 Richard Henderson <rth@cygnus.com>
|
||||
Bernd Schmidt <bernds@cygnus.co.uk>
|
||||
Mark Mitchell <mark@codesourcery.com>
|
||||
|
||||
* Makefile.in (stor-layout.o): Depend on ggc.h.
|
||||
(expr.o): Depend on ggc.h.
|
||||
(profile.o): Depend on ggc.h.
|
||||
(stor-layout.o): Depend on ggc.h.
|
||||
* emit-rtl.c (init_emit_once): Add gc roots.
|
||||
* expr.c: Include ggc.h.
|
||||
(emit_block_move): Add gc roots.
|
||||
(clear_storage): Likewise.
|
||||
* expr.h (init_stor_layout_once): New function.
|
||||
* profile.c: Include ggc.h.
|
||||
(init_arc_profiler): profiler_label is a root.
|
||||
* scan.c (make_sstring_space): Trust xrealloc to function
|
||||
correctly with first parameter NULL.
|
||||
* stor-layout.c: Include ggc.h.
|
||||
(set_sizetype): Add gc root.
|
||||
(init_stor_layout_once): New function.
|
||||
* toplev.c (compile_file): Call it.
|
||||
|
||||
Sat Sep 4 19:26:25 1999 Richard Henderson <rth@cygnus.com>
|
||||
Bernd Schmidt <bernds@cygnus.co.uk>
|
||||
Mark Mitchell <mark@codesourcery.com>
|
||||
|
|
|
@ -1454,7 +1454,7 @@ tree.o : tree.c $(CONFIG_H) system.h $(TREE_H) flags.h function.h toplev.h \
|
|||
ggc.h
|
||||
print-tree.o : print-tree.c $(CONFIG_H) system.h $(TREE_H)
|
||||
stor-layout.o : stor-layout.c $(CONFIG_H) system.h $(TREE_H) flags.h \
|
||||
function.h $(EXPR_H) $(RTL_H) toplev.h
|
||||
function.h $(EXPR_H) $(RTL_H) toplev.h ggc.h
|
||||
fold-const.o : fold-const.c $(CONFIG_H) system.h $(TREE_H) flags.h toplev.h \
|
||||
$(RTL_H)
|
||||
toplev.o : toplev.c $(CONFIG_H) system.h $(TREE_H) $(RTL_H) function.h \
|
||||
|
@ -1486,7 +1486,8 @@ except.o : except.c $(CONFIG_H) system.h $(RTL_H) $(TREE_H) flags.h \
|
|||
insn-config.h $(RECOG_H) output.h except.h toplev.h intl.h ggc.h
|
||||
expr.o : expr.c $(CONFIG_H) system.h $(RTL_H) $(TREE_H) flags.h function.h \
|
||||
$(REGS_H) insn-flags.h insn-codes.h $(EXPR_H) insn-config.h $(RECOG_H) \
|
||||
output.h typeclass.h hard-reg-set.h toplev.h hard-reg-set.h except.h
|
||||
output.h typeclass.h hard-reg-set.h toplev.h hard-reg-set.h except.h \
|
||||
ggc.h
|
||||
builtins.o : builtins.c $(CONFIG_H) system.h $(RTL_H) $(TREE_H) flags.h \
|
||||
function.h $(REGS_H) insn-flags.h insn-codes.h $(EXPR_H) insn-config.h \
|
||||
$(RECOG_H) output.h typeclass.h hard-reg-set.h toplev.h hard-reg-set.h \
|
||||
|
@ -1541,7 +1542,8 @@ resource.o : resource.c $(CONFIG_H) $(RTL_H) hard-reg-set.h system.h \
|
|||
lcm.o : lcm.c $(CONFIG_H) system.h $(RTL_H) $(REGS_H) hard-reg-set.h flags.h \
|
||||
real.h insn-config.h $(RECOG_H) $(EXPR_H) $(BASIC_BLOCK_H)
|
||||
profile.o : profile.c $(CONFIG_H) system.h $(RTL_H) flags.h insn-flags.h \
|
||||
gcov-io.h $(TREE_H) output.h $(REGS_H) toplev.h function.h insn-config.h
|
||||
gcov-io.h $(TREE_H) output.h $(REGS_H) toplev.h function.h insn-config.h \
|
||||
ggc.h
|
||||
loop.o : loop.c $(CONFIG_H) system.h $(RTL_H) flags.h loop.h insn-config.h \
|
||||
insn-flags.h $(REGS_H) hard-reg-set.h $(RECOG_H) $(EXPR_H) real.h \
|
||||
function.h toplev.h varray.h
|
||||
|
|
|
@ -3685,6 +3685,15 @@ init_emit_once (line_numbers)
|
|||
init_function_start. */
|
||||
INIT_EXPANDERS;
|
||||
#endif
|
||||
|
||||
ggc_add_rtx_root (&const_tiny_rtx[0][0], sizeof(const_tiny_rtx)/sizeof(rtx));
|
||||
|
||||
ggc_add_rtx_root (&pic_offset_table_rtx, 1);
|
||||
ggc_add_rtx_root (&struct_value_rtx, 1);
|
||||
ggc_add_rtx_root (&struct_value_incoming_rtx, 1);
|
||||
ggc_add_rtx_root (&static_chain_rtx, 1);
|
||||
ggc_add_rtx_root (&static_chain_incoming_rtx, 1);
|
||||
ggc_add_rtx_root (&return_address_pointer_rtx, 1);
|
||||
}
|
||||
|
||||
/* Query and clear/ restore no_line_numbers. This is used by the
|
||||
|
|
|
@ -40,6 +40,7 @@ Boston, MA 02111-1307, USA. */
|
|||
#include "typeclass.h"
|
||||
#include "defaults.h"
|
||||
#include "toplev.h"
|
||||
#include "ggc.h"
|
||||
|
||||
#define CEIL(x,y) (((x) + (y) - 1) / (y))
|
||||
|
||||
|
@ -1677,6 +1678,7 @@ emit_block_move (x, y, size, align)
|
|||
fntype = build_pointer_type (void_type_node);
|
||||
fntype = build_function_type (fntype, NULL_TREE);
|
||||
fn = build_decl (FUNCTION_DECL, fn, fntype);
|
||||
ggc_add_tree_root (&fn, 1);
|
||||
DECL_EXTERNAL (fn) = 1;
|
||||
TREE_PUBLIC (fn) = 1;
|
||||
DECL_ARTIFICIAL (fn) = 1;
|
||||
|
@ -2451,6 +2453,7 @@ clear_storage (object, size, align)
|
|||
fntype = build_pointer_type (void_type_node);
|
||||
fntype = build_function_type (fntype, NULL_TREE);
|
||||
fn = build_decl (FUNCTION_DECL, fn, fntype);
|
||||
ggc_add_tree_root (&fn, 1);
|
||||
DECL_EXTERNAL (fn) = 1;
|
||||
TREE_PUBLIC (fn) = 1;
|
||||
DECL_ARTIFICIAL (fn) = 1;
|
||||
|
|
|
@ -878,6 +878,10 @@ extern void init_expr_once PROTO((void));
|
|||
/* This is run at the start of compiling a function. */
|
||||
extern void init_expr PROTO((void));
|
||||
|
||||
/* This function is run once to initialize stor-layout.c. */
|
||||
|
||||
extern void init_stor_layout_once PROTO((void));
|
||||
|
||||
/* This is run at the end of compiling a function. */
|
||||
extern void finish_expr_for_function PROTO((void));
|
||||
|
||||
|
|
|
@ -54,6 +54,7 @@ Boston, MA 02111-1307, USA. */
|
|||
#include "output.h"
|
||||
#include "gcov-io.h"
|
||||
#include "toplev.h"
|
||||
#include "ggc.h"
|
||||
|
||||
/* One of these is dynamically created whenever we identify an arc in the
|
||||
function. */
|
||||
|
@ -1544,6 +1545,7 @@ init_arc_profiler ()
|
|||
char *name = xmalloc (20);
|
||||
ASM_GENERATE_INTERNAL_LABEL (name, "LPBX", 2);
|
||||
profiler_label = gen_rtx_SYMBOL_REF (Pmode, name);
|
||||
ggc_add_rtx_root (&profiler_label, 1);
|
||||
}
|
||||
|
||||
/* Output instructions as RTL to increment the arc execution count. */
|
||||
|
|
|
@ -35,10 +35,7 @@ make_sstring_space (str, count)
|
|||
if (new_size <= cur_size)
|
||||
return;
|
||||
|
||||
if (str->base == NULL)
|
||||
str->base = xmalloc (new_size);
|
||||
else
|
||||
str->base = xrealloc (str->base, new_size);
|
||||
str->base = xrealloc (str->base, new_size);
|
||||
str->ptr = str->base + cur_size;
|
||||
str->limit = str->base + new_size;
|
||||
}
|
||||
|
|
|
@ -28,6 +28,7 @@ Boston, MA 02111-1307, USA. */
|
|||
#include "function.h"
|
||||
#include "expr.h"
|
||||
#include "toplev.h"
|
||||
#include "ggc.h"
|
||||
|
||||
#define CEIL(x,y) (((x) + (y) - 1) / (y))
|
||||
|
||||
|
@ -1256,6 +1257,8 @@ set_sizetype (type)
|
|||
usizetype = make_unsigned_type (oprecision);
|
||||
ubitsizetype = make_unsigned_type (precision);
|
||||
}
|
||||
|
||||
ggc_add_tree_root ((tree*) &sizetype_tab, sizeof(sizetype_tab)/sizeof(tree));
|
||||
}
|
||||
|
||||
/* Set the extreme values of TYPE based on its precision in bits,
|
||||
|
@ -1387,3 +1390,11 @@ get_best_mode (bitsize, bitpos, align, largest_mode, volatilep)
|
|||
|
||||
return mode;
|
||||
}
|
||||
|
||||
/* This function is run once to initialize stor-layout.c. */
|
||||
|
||||
void
|
||||
init_stor_layout_once ()
|
||||
{
|
||||
ggc_add_tree_root (&pending_sizes, 1);
|
||||
}
|
||||
|
|
|
@ -2936,6 +2936,7 @@ compile_file (name)
|
|||
init_reload ();
|
||||
init_alias_once ();
|
||||
init_function_once ();
|
||||
init_stor_layout_once ();
|
||||
|
||||
/* The following initialization functions need to generate rtl, so
|
||||
provide a dummy function context for them. */
|
||||
|
|
Loading…
Reference in New Issue