vecir.h: New file with VEC primitives for tree, gimple, and rtl.

gcc/ChangeLog
	* vecir.h: New file with VEC primitives for tree, gimple, and rtl.
	* Makefile.in: Add it.
	Fix all other Makefile dependencies for changes below.
	* tree.h: Include it instead of defining VEC primitives here.
	* gimple.h: Likewise.
	* rtl.h: Likewise.
	* tree-inline.h: Inlclude vecir.h instead of gimple.h.
	* except.h: Include vecir.h, break dependence on tree.h.

	* gimplify.c (append_to_statement_list_1, append_to_statement_list):
	Move from here...
	* tree-iterator.c: ...to here.
	* tree-iterator.h: Fix file introduction comment.  Add extern markers.

	* c-lex.c: Include fixed-value.h instead of rtl.h.  Do not include
	tm_p.h.
	* c-cppbuiltin.c: Explain why debug.h and tm_p.h are included.
	* c-objc-common.h: Do not include tm.h, rtl.h, insn-config.h,
	integrate.h, function.h, toplev.h, tree-inline.h, ggc.h,
	tree-mudflap.h, and target.h.
	* c-semantics.c: Do not include except.h, ggc.h, rtl.h, timevar.h,
	predict.h, tree-inline.h, gimple.h, and langhooks.h.
	* c-decl.c: Do not include expr.h, ggc.h, libfuncs.h, except.h.
	Add FIXME for why gimple.h is still included (should be unnecessary
	since GCC 4.5 gimplification unit-at-a-time).
	* c-typeck.c: Do not include rtl.h, tm_p.h, ggc.h, and gimple.h.
	* c-pragma.c: Add FIXME for why function.h needs to be included just
	for cfun, at front-end level.
	Add note that REGISTER_TARGET_PRAGMAS should probably be a target hook.
	Do not include ggc.h, but include vecprim.h for VEC(char).
	* c-opts.c: Do not include tm.h, tree-inline.h, and tm_p.h.
	Explain why target.h is included.
	* c-omp.h: Do not include tm.h, function.h, and bitmap.h.
	Explain why gimple.h is included.
	* c-ppoutput.c: Do not include tm.h.
	* c-common.c: Do not include gimple.h.  Explain why expr.h is included.
	* c-parses.c: Explain why rtl.h is included, and that this (and only
	this) is also why tm.h must be included.
	Do not include except.h.
	* c-lang.c: Do not include ggc.h.

cp/ChangeLog
	* decl.c: Include tree-iterator.h, as fixup for tree-inline.h changes.
	* Make-lang.in: Fix dependencies accordingly.

From-SVN: r159442
This commit is contained in:
Steven Bosscher 2010-05-15 20:02:11 +00:00
parent 12201e4873
commit f4ce02c5bf
27 changed files with 197 additions and 154 deletions

View File

@ -1,3 +1,46 @@
2010-05-15 Steven Bosscher <steven@gcc.gnu.org>
* vecir.h: New file with VEC primitives for tree, gimple, and rtl.
* Makefile.in: Add it.
Fix all other Makefile dependencies for changes below.
* tree.h: Include it instead of defining VEC primitives here.
* gimple.h: Likewise.
* rtl.h: Likewise.
* tree-inline.h: Inlclude vecir.h instead of gimple.h.
* except.h: Include vecir.h, break dependence on tree.h.
* gimplify.c (append_to_statement_list_1, append_to_statement_list):
Move from here...
* tree-iterator.c: ...to here.
* tree-iterator.h: Fix file introduction comment. Add extern markers.
* c-lex.c: Include fixed-value.h instead of rtl.h. Do not include
tm_p.h.
* c-cppbuiltin.c: Explain why debug.h and tm_p.h are included.
* c-objc-common.h: Do not include tm.h, rtl.h, insn-config.h,
integrate.h, function.h, toplev.h, tree-inline.h, ggc.h,
tree-mudflap.h, and target.h.
* c-semantics.c: Do not include except.h, ggc.h, rtl.h, timevar.h,
predict.h, tree-inline.h, gimple.h, and langhooks.h.
* c-decl.c: Do not include expr.h, ggc.h, libfuncs.h, except.h.
Add FIXME for why gimple.h is still included (should be unnecessary
since GCC 4.5 gimplification unit-at-a-time).
* c-typeck.c: Do not include rtl.h, tm_p.h, ggc.h, and gimple.h.
* c-pragma.c: Add FIXME for why function.h needs to be included just
for cfun, at front-end level.
Add note that REGISTER_TARGET_PRAGMAS should probably be a target hook.
Do not include ggc.h, but include vecprim.h for VEC(char).
* c-opts.c: Do not include tm.h, tree-inline.h, and tm_p.h.
Explain why target.h is included.
* c-omp.h: Do not include tm.h, function.h, and bitmap.h.
Explain why gimple.h is included.
* c-ppoutput.c: Do not include tm.h.
* c-common.c: Do not include gimple.h. Explain why expr.h is included.
* c-parses.c: Explain why rtl.h is included, and that this (and only
this) is also why tm.h must be included.
Do not include except.h.
* c-lang.c: Do not include ggc.h.
2010-05-15 Uros Bizjak <ubizjak@gmail.com>
* targhooks.c (GO_IF_MODE_DEPENDENT_ADDRESS): Use CONST_CAST_RTX.

View File

@ -858,7 +858,7 @@ REVISION_s := "\"\""
endif
# Shorthand variables for dependency lists.
EXCEPT_H = except.h sbitmap.h vecprim.h
EXCEPT_H = except.h sbitmap.h vecprim.h vecir.h
TOPLEV_H = toplev.h $(INPUT_H) bversion.h
TARGET_H = $(TM_H) target.h insn-modes.h
MACHMODE_H = machmode.h mode-classes.def insn-modes.h
@ -869,19 +869,19 @@ TARGET_DEF_H = target-def.h $(HOOKS_H) targhooks.h
RTL_BASE_H = rtl.h rtl.def $(MACHMODE_H) reg-notes.def insn-notes.def \
$(INPUT_H) $(REAL_H) statistics.h vec.h $(FIXED_VALUE_H) alias.h
FIXED_VALUE_H = fixed-value.h $(MACHMODE_H) double-int.h
RTL_H = $(RTL_BASE_H) genrtl.h
RTL_H = $(RTL_BASE_H) genrtl.h vecir.h
PARAMS_H = params.h params.def
BUILTINS_DEF = builtins.def sync-builtins.def omp-builtins.def
TREE_H = tree.h all-tree.def tree.def c-common.def $(lang_tree_files) \
$(MACHMODE_H) tree-check.h $(BUILTINS_DEF) \
$(INPUT_H) statistics.h vec.h treestruct.def $(HASHTAB_H) \
double-int.h alias.h $(SYMTAB_H) options.h
double-int.h alias.h $(SYMTAB_H) options.h vecir.h
BASIC_BLOCK_H = basic-block.h $(BITMAP_H) sbitmap.h $(PARTITION_H) \
hard-reg-set.h $(PREDICT_H) vec.h $(FUNCTION_H) \
cfghooks.h $(OBSTACK_H)
GIMPLE_H = gimple.h gimple.def gsstruct.def pointer-set.h vec.h \
$(GGC_H) $(BASIC_BLOCK_H) $(TM_H) $(TARGET_H) tree-ssa-operands.h \
tree-ssa-alias.h
tree-ssa-alias.h vecir.h
GCOV_IO_H = gcov-io.h gcov-iov.h auto-host.h
COVERAGE_H = coverage.h $(GCOV_IO_H)
DEMANGLE_H = $(srcdir)/../include/demangle.h
@ -944,7 +944,7 @@ C_PRETTY_PRINT_H = c-pretty-print.h $(PRETTY_PRINT_H) $(C_COMMON_H) $(TREE_H)
SCEV_H = tree-scalar-evolution.h $(GGC_H) tree-chrec.h $(PARAMS_H)
LAMBDA_H = lambda.h $(TREE_H) vec.h $(GGC_H)
TREE_DATA_REF_H = tree-data-ref.h $(LAMBDA_H) omega.h graphds.h $(SCEV_H)
TREE_INLINE_H = tree-inline.h $(GIMPLE_H)
TREE_INLINE_H = tree-inline.h vecir.h
REAL_H = real.h $(MACHMODE_H)
IRA_INT_H = ira.h ira-int.h $(CFGLOOP_H) alloc-pool.h
DBGCNT_H = dbgcnt.h dbgcnt.def
@ -1959,7 +1959,7 @@ c-errors.o: c-errors.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(TREE_H) \
c-parser.o : c-parser.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(TREE_H) \
$(GGC_H) $(TIMEVAR_H) $(C_TREE_H) $(INPUT_H) $(FLAGS_H) $(TOPLEV_H) output.h \
$(CPPLIB_H) gt-c-parser.h $(RTL_H) langhooks.h $(C_COMMON_H) $(C_PRAGMA_H) \
vec.h $(TARGET_H) $(CGRAPH_H) $(PLUGIN_H) $(EXCEPT_H)
vec.h $(TARGET_H) $(CGRAPH_H) $(PLUGIN_H)
srcextra: gcc.srcextra lang.srcextra
@ -1972,39 +1972,36 @@ incpath.o: incpath.c incpath.h $(CONFIG_H) $(SYSTEM_H) $(CPPLIB_H) \
c-decl.o : c-decl.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(TREE_H) \
$(RTL_H) $(C_TREE_H) $(GGC_H) $(TARGET_H) $(FLAGS_H) $(FUNCTION_H) output.h \
$(EXPR_H) debug.h $(TOPLEV_H) intl.h $(TM_P_H) $(TREE_INLINE_H) $(TIMEVAR_H) \
debug.h $(TOPLEV_H) intl.h $(TM_P_H) $(TREE_INLINE_H) $(TIMEVAR_H) \
opts.h $(C_PRAGMA_H) gt-c-decl.h $(CGRAPH_H) $(HASHTAB_H) libfuncs.h \
$(EXCEPT_H) $(LANGHOOKS_DEF_H) $(TREE_DUMP_H) $(C_COMMON_H) $(CPPLIB_H) \
$(DIAGNOSTIC_H) $(INPUT_H) langhooks.h $(GIMPLE_H) tree-mudflap.h \
pointer-set.h $(BASIC_BLOCK_H) $(GIMPLE_H) tree-iterator.h c-lang.h $(PLUGIN_H)
$(DIAGNOSTIC_H) $(INPUT_H) langhooks.h tree-mudflap.h \
pointer-set.h tree-iterator.h c-lang.h $(PLUGIN_H)
c-typeck.o : c-typeck.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) \
$(TREE_H) $(C_TREE_H) $(TARGET_H) $(FLAGS_H) intl.h output.h $(EXPR_H) \
$(RTL_H) $(TOPLEV_H) $(TM_P_H) langhooks.h $(GGC_H) $(TREE_FLOW_H) \
$(GIMPLE_H) tree-iterator.h c-lang.h
$(TOPLEV_H) langhooks.h $(TREE_FLOW_H) tree-iterator.h c-lang.h
c-lang.o : c-lang.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(TREE_H) \
$(C_TREE_H) $(DIAGNOSTIC_H) \
$(GGC_H) langhooks.h $(LANGHOOKS_DEF_H) $(C_COMMON_H) gtype-c.h \
langhooks.h $(LANGHOOKS_DEF_H) $(C_COMMON_H) gtype-c.h \
c-objc-common.h $(C_PRAGMA_H) c-common.def $(TREE_INLINE_H)
stub-objc.o : stub-objc.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TREE_H) \
$(C_COMMON_H)
c-lex.o : c-lex.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(TREE_H) \
$(RTL_H) debug.h $(C_TREE_H) $(C_COMMON_H) $(REAL_H) $(SPLAY_TREE_H) \
$(FIXED_VALUE_H) debug.h $(C_TREE_H) $(C_COMMON_H) $(REAL_H) $(SPLAY_TREE_H) \
$(C_PRAGMA_H) $(INPUT_H) intl.h $(FLAGS_H) $(TOPLEV_H) output.h \
$(CPPLIB_H) $(TARGET_H) $(TIMEVAR_H) $(TM_P_H)
c-ppoutput.o : c-ppoutput.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) \
$(CPPLIB_H) $(TARGET_H) $(TIMEVAR_H)
c-ppoutput.o : c-ppoutput.c $(CONFIG_H) $(SYSTEM_H) coretypes.h \
$(C_COMMON_H) $(TREE_H) $(CPPLIB_H) $(CPP_INTERNAL_H) $(C_PRAGMA_H)
c-objc-common.o : c-objc-common.c $(CONFIG_H) $(SYSTEM_H) coretypes.h \
$(TM_H) $(TREE_H) $(C_TREE_H) $(RTL_H) insn-config.h $(INTEGRATE_H) \
$(FUNCTION_H) $(FLAGS_H) $(TOPLEV_H) $(TREE_INLINE_H) $(DIAGNOSTIC_H) \
langhooks.h $(GGC_H) $(TARGET_H) $(C_PRETTY_PRINT_H) c-objc-common.h \
tree-mudflap.h intl.h
$(TREE_H) $(C_TREE_H) $(FLAGS_H) $(DIAGNOSTIC_H) \
langhooks.h $(GGC_H) $(C_PRETTY_PRINT_H) c-objc-common.h intl.h
c-aux-info.o : c-aux-info.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(TREE_H) \
$(C_TREE_H) $(FLAGS_H) $(TOPLEV_H)
c-convert.o : c-convert.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) \
$(TREE_H) $(FLAGS_H) $(TOPLEV_H) $(C_COMMON_H) convert.h $(C_TREE_H) \
langhooks.h $(TARGET_H)
c-pragma.o: c-pragma.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(RTL_H) \
$(TREE_H) $(FUNCTION_H) $(C_PRAGMA_H) $(TOPLEV_H) output.h $(GGC_H) $(TM_P_H) \
$(TREE_H) $(FUNCTION_H) $(C_PRAGMA_H) $(TOPLEV_H) output.h $(TM_P_H) \
$(C_COMMON_H) $(TARGET_H) gt-c-pragma.h $(CPPLIB_H) $(FLAGS_H) $(DIAGNOSTIC_H) \
opts.h $(PLUGINS_H)
graph.o: graph.c $(SYSTEM_H) coretypes.h $(TM_H) $(TOPLEV_H) $(FLAGS_H) output.h \
@ -2051,17 +2048,16 @@ c-common.o : c-common.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(TREE_H) \
$(TARGET_H) $(C_TREE_H) tree-iterator.h langhooks.h tree-mudflap.h \
intl.h opts.h $(REAL_H) $(CPPLIB_H) $(TREE_INLINE_H) $(HASHTAB_H) \
$(BUILTINS_DEF) $(CGRAPH_H) $(BASIC_BLOCK_H) $(TARGET_DEF_H) \
$(GIMPLE_H) libfuncs.h
libfuncs.h
c-pretty-print.o : c-pretty-print.c $(C_PRETTY_PRINT_H) \
$(C_TREE_H) $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(REAL_H) \
$(DIAGNOSTIC_H) tree-iterator.h fixed-value.h intl.h
c-opts.o : c-opts.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) \
$(TREE_H) $(C_PRAGMA_H) $(FLAGS_H) $(TOPLEV_H) langhooks.h \
$(TREE_INLINE_H) $(DIAGNOSTIC_H) intl.h debug.h $(C_COMMON_H) \
opts.h options.h $(MKDEPS_H) incpath.h cppdefault.h $(TARGET_H) \
$(TM_P_H) $(C_TREE_H)
c-opts.o : c-opts.c $(CONFIG_H) $(SYSTEM_H) coretypes.h \
$(TREE_H) $(C_PRAGMA_H) $(FLAGS_H) $(TOPLEV_H) langhooks.h \
$(DIAGNOSTIC_H) intl.h debug.h $(C_COMMON_H) \
opts.h options.h $(MKDEPS_H) incpath.h cppdefault.h $(C_TREE_H)
$(COMPILER) -c $(ALL_COMPILERFLAGS) $(ALL_CPPFLAGS) \
$< $(OUTPUT_OPTION) @TARGET_SYSTEM_ROOT_DEFINE@
@ -2083,10 +2079,8 @@ c-format.o : c-format.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(TREE_H) la
c-format.h
c-semantics.o : c-semantics.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) \
$(TREE_H) $(FLAGS_H) $(TOPLEV_H) output.h $(RTL_H) $(GGC_H) \
$(PREDICT_H) $(TREE_INLINE_H) $(C_COMMON_H) $(EXCEPT_H) $(FUNCTION_H) \
langhooks.h $(SPLAY_TREE_H) $(TIMEVAR_H) $(GIMPLE_H) \
tree-iterator.h
$(TREE_H) $(FLAGS_H) $(TOPLEV_H) output.h $(C_COMMON_H) $(FUNCTION_H) \
langhooks.h $(SPLAY_TREE_H) $(TIMEVAR_H) tree-iterator.h
c-dump.o : c-dump.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(TREE_H) \
$(C_TREE_H) $(TREE_DUMP_H)
@ -2099,9 +2093,8 @@ c-pch.o : c-pch.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(CPPLIB_H) $(TREE_H) \
-DHOST_MACHINE=\"$(host)\" -DTARGET_MACHINE=\"$(target)\" \
$< $(OUTPUT_OPTION)
c-omp.o : c-omp.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(TREE_H) \
$(FUNCTION_H) $(C_COMMON_H) $(TOPLEV_H) $(GIMPLE_H) $(BITMAP_H) \
langhooks.h
c-omp.o : c-omp.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TREE_H) \
$(C_COMMON_H) $(TOPLEV_H) $(GIMPLE_H) langhooks.h
# Language-independent files.
@ -3585,10 +3578,10 @@ s-constrs-h: $(MD_DEPS) build/genpreds$(build_exeext)
$(STAMP) s-constrs-h
GTFILES = $(CPP_ID_DATA_H) $(srcdir)/input.h $(srcdir)/coretypes.h \
$(srcdir)/vecprim.h $(srcdir)/vecir.h \
$(host_xm_file_list) \
$(tm_file_list) $(HASHTAB_H) $(SPLAY_TREE_H) $(srcdir)/bitmap.h \
$(srcdir)/alias.h $(srcdir)/coverage.c $(srcdir)/rtl.h \
$(srcdir)/vecprim.h \
$(srcdir)/optabs.h $(srcdir)/tree.h $(srcdir)/libfuncs.h $(SYMTAB_H) \
$(srcdir)/real.h $(srcdir)/function.h $(srcdir)/insn-addr.h $(srcdir)/hwint.h \
$(srcdir)/fixed-value.h \

View File

@ -30,7 +30,7 @@ along with GCC; see the file COPYING3. If not see
#include "c-pragma.h"
#include "rtl.h"
#include "ggc.h"
#include "expr.h"
#include "expr.h" /* For vector_mode_valid_p */
#include "c-common.h"
#include "tm_p.h"
#include "obstack.h"
@ -48,7 +48,6 @@ along with GCC; see the file COPYING3. If not see
#include "real.h"
#include "cgraph.h"
#include "target-def.h"
#include "gimple.h"
#include "fixed-value.h"
#include "libfuncs.h"

View File

@ -30,9 +30,9 @@ along with GCC; see the file COPYING3. If not see
#include "c-pragma.h"
#include "output.h"
#include "except.h" /* For USING_SJLJ_EXCEPTIONS. */
#include "debug.h" /* For dwarf2out_do_frame. */
#include "debug.h" /* For dwarf2out_do_cfi_asm. */
#include "toplev.h"
#include "tm_p.h" /* Target prototypes. */
#include "tm_p.h" /* For TARGET_CPU_CPP_BUILTINS & friends. */
#include "target.h"
#ifndef TARGET_OS_CPP_BUILTINS

View File

@ -38,10 +38,8 @@ along with GCC; see the file COPYING3. If not see
#include "flags.h"
#include "function.h"
#include "output.h"
#include "expr.h"
#include "c-tree.h"
#include "toplev.h"
#include "ggc.h"
#include "tm_p.h"
#include "cpplib.h"
#include "target.h"
@ -53,17 +51,14 @@ along with GCC; see the file COPYING3. If not see
#include "c-lang.h"
#include "langhooks.h"
#include "tree-mudflap.h"
#include "gimple.h"
#include "gimple.h" /* FIXME: For gimple_set_body and gimple_body, but why? */
#include "tree-iterator.h"
#include "diagnostic.h"
#include "tree-dump.h"
#include "cgraph.h"
#include "hashtab.h"
#include "libfuncs.h"
#include "except.h"
#include "langhooks-def.h"
#include "pointer-set.h"
#include "gimple.h"
#include "plugin.h"
/* In grokdeclarator, distinguish syntactic contexts of declarators. */

View File

@ -27,7 +27,6 @@ along with GCC; see the file COPYING3. If not see
#include "tree.h"
#include "c-tree.h"
#include "c-common.h"
#include "ggc.h"
#include "langhooks.h"
#include "langhooks-def.h"
#include "tree-inline.h"

View File

@ -25,7 +25,7 @@ along with GCC; see the file COPYING3. If not see
#include "tm.h"
#include "real.h"
#include "rtl.h"
#include "fixed-value.h"
#include "tree.h"
#include "input.h"
#include "output.h"
@ -37,7 +37,6 @@ along with GCC; see the file COPYING3. If not see
#include "c-pragma.h"
#include "toplev.h"
#include "intl.h"
#include "tm_p.h"
#include "splay-tree.h"
#include "debug.h"
#include "target.h"

View File

@ -21,23 +21,13 @@ along with GCC; see the file COPYING3. If not see
#include "config.h"
#include "system.h"
#include "coretypes.h"
#include "tm.h"
#include "tree.h"
#include "rtl.h"
#include "insn-config.h"
#include "integrate.h"
#include "c-tree.h"
#include "intl.h"
#include "c-pretty-print.h"
#include "function.h"
#include "flags.h"
#include "toplev.h"
#include "diagnostic.h"
#include "tree-inline.h"
#include "ggc.h"
#include "langhooks.h"
#include "tree-mudflap.h"
#include "target.h"
#include "c-objc-common.h"
static bool c_tree_printer (pretty_printer *, text_info *, const char *,

View File

@ -24,13 +24,10 @@ along with GCC; see the file COPYING3. If not see
#include "config.h"
#include "system.h"
#include "coretypes.h"
#include "tm.h"
#include "tree.h"
#include "function.h"
#include "c-common.h"
#include "toplev.h"
#include "gimple.h"
#include "bitmap.h"
#include "gimple.h" /* For create_tmp_var_raw. */
#include "langhooks.h"

View File

@ -22,14 +22,12 @@ along with GCC; see the file COPYING3. If not see
#include "config.h"
#include "system.h"
#include "coretypes.h"
#include "tm.h"
#include "tree.h"
#include "c-common.h"
#include "c-pragma.h"
#include "flags.h"
#include "toplev.h"
#include "langhooks.h"
#include "tree-inline.h"
#include "diagnostic.h"
#include "intl.h"
#include "cppdefault.h"
@ -38,8 +36,7 @@ along with GCC; see the file COPYING3. If not see
#include "opts.h"
#include "options.h"
#include "mkdeps.h"
#include "target.h"
#include "tm_p.h"
#include "target.h" /* For gcc_targetcm. */
#include "c-tree.h" /* For c_cpp_error. */
#ifndef DOLLARS_IN_IDENTIFIERS

View File

@ -40,9 +40,9 @@ along with GCC; see the file COPYING3. If not see
#include "config.h"
#include "system.h"
#include "coretypes.h"
#include "tm.h"
#include "tm.h" /* For rtl.h: needs enum reg_class. */
#include "tree.h"
#include "rtl.h"
#include "rtl.h" /* For decl_default_tls_model. */
#include "langhooks.h"
#include "input.h"
#include "cpplib.h"
@ -58,7 +58,6 @@ along with GCC; see the file COPYING3. If not see
#include "target.h"
#include "cgraph.h"
#include "plugin.h"
#include "except.h"
/* Initialization routine for this file. */

View File

@ -20,7 +20,6 @@
#include "config.h"
#include "system.h"
#include "coretypes.h"
#include "tm.h"
#include "cpplib.h"
#include "../libcpp/internal.h"
#include "tree.h"

View File

@ -24,16 +24,19 @@ along with GCC; see the file COPYING3. If not see
#include "tm.h"
#include "rtl.h"
#include "tree.h"
#include "function.h"
#include "function.h" /* For cfun. FIXME: Does the parser know
when it is inside a function, so that
we don't have to look at cfun? */
#include "cpplib.h"
#include "c-pragma.h"
#include "flags.h"
#include "toplev.h"
#include "ggc.h"
#include "c-common.h"
#include "output.h"
#include "tm_p.h"
#include "tm_p.h" /* For REGISTER_TARGET_PRAGMAS (why is
this not a target hook?). */
#include "vec.h"
#include "vecprim.h"
#include "target.h"
#include "diagnostic.h"
#include "opts.h"

View File

@ -27,22 +27,14 @@ along with GCC; see the file COPYING3. If not see
#include "function.h"
#include "splay-tree.h"
#include "c-common.h"
#include "except.h"
/* In order for the format checking to accept the C frontend
diagnostic framework extensions, you must define this token before
including toplev.h. */
#define GCC_DIAG_STYLE __gcc_cdiag__
#include "toplev.h"
#include "flags.h"
#include "ggc.h"
#include "rtl.h"
#include "output.h"
#include "timevar.h"
#include "predict.h"
#include "tree-inline.h"
#include "gimple.h"
#include "tree-iterator.h"
#include "langhooks.h"
/* Create an empty statement tree rooted at T. */

View File

@ -29,21 +29,17 @@ along with GCC; see the file COPYING3. If not see
#include "system.h"
#include "coretypes.h"
#include "tm.h"
#include "rtl.h"
#include "tree.h"
#include "langhooks.h"
#include "c-tree.h"
#include "c-lang.h"
#include "tm_p.h"
#include "flags.h"
#include "output.h"
#include "expr.h"
#include "toplev.h"
#include "intl.h"
#include "ggc.h"
#include "target.h"
#include "tree-iterator.h"
#include "gimple.h"
#include "tree-flow.h"
/* Possible cases of implicit bad conversions. Used to select

View File

@ -1,3 +1,8 @@
2010-05-15 Steven Bosscher <steven@gcc.gnu.org>
* decl.c: Include tree-iterator.h, as fixup for tree-inline.h changes.
* Make-lang.in: Fix dependencies accordingly.
2010-05-14 Jason Merrill <jason@redhat.com>
C++ DR 475

View File

@ -256,7 +256,7 @@ cp/decl.o: cp/decl.c $(CXX_TREE_H) $(TM_H) $(FLAGS_H) cp/decl.h \
output.h $(EXPR_H) except.h toplev.h $(HASHTAB_H) $(RTL_H) \
cp/operators.def $(TM_P_H) $(TREE_INLINE_H) $(DIAGNOSTIC_H) $(C_PRAGMA_H) \
debug.h gt-cp-decl.h $(TIMEVAR_H) $(TREE_FLOW_H) $(TARGET_H) $(PLUGIN_H) \
intl.h
intl.h tree-iterator.h
cp/decl2.o: cp/decl2.c $(CXX_TREE_H) $(TM_H) $(FLAGS_H) cp/decl.h $(EXPR_H) \
output.h except.h toplev.h $(RTL_H) $(C_COMMON_H) gt-cp-decl2.h $(CGRAPH_H) \
$(C_PRAGMA_H) $(TREE_DUMP_H) intl.h $(TARGET_H) $(GIMPLE_H) $(POINTER_SET_H)

View File

@ -37,6 +37,7 @@ along with GCC; see the file COPYING3. If not see
#include "expr.h"
#include "flags.h"
#include "cp-tree.h"
#include "tree-iterator.h"
#include "tree-inline.h"
#include "decl.h"
#include "intl.h"

View File

@ -21,6 +21,7 @@ along with GCC; see the file COPYING3. If not see
#include "sbitmap.h"
#include "vecprim.h"
#include "vecir.h"
struct function;
struct eh_region_d;

View File

@ -24,6 +24,8 @@ along with GCC; see the file COPYING3. If not see
#include "pointer-set.h"
#include "vec.h"
#include "vecprim.h"
#include "vecir.h"
#include "ggc.h"
#include "tm.h"
#include "hard-reg-set.h"
@ -31,18 +33,6 @@ along with GCC; see the file COPYING3. If not see
#include "tree-ssa-operands.h"
#include "tree-ssa-alias.h"
DEF_VEC_P(gimple);
DEF_VEC_ALLOC_P(gimple,heap);
DEF_VEC_ALLOC_P(gimple,gc);
typedef gimple *gimple_p;
DEF_VEC_P(gimple_p);
DEF_VEC_ALLOC_P(gimple_p,heap);
DEF_VEC_P(gimple_seq);
DEF_VEC_ALLOC_P(gimple_seq,gc);
DEF_VEC_ALLOC_P(gimple_seq,heap);
/* For each block, the PHI nodes that need to be rewritten are stored into
these vectors. */
typedef VEC(gimple, heap) *gimple_vec;
@ -1048,8 +1038,6 @@ extern gimple gimple_current_bind_expr (void);
extern VEC(gimple, heap) *gimple_bind_expr_stack (void);
extern tree voidify_wrapper_expr (tree, tree);
extern tree build_and_jump (tree *);
extern tree alloc_stmt_list (void);
extern void free_stmt_list (tree);
extern tree force_labels_r (tree *, int *, void *);
extern enum gimplify_status gimplify_va_arg_expr (tree *, gimple_seq *,
gimple_seq *);

View File

@ -340,47 +340,6 @@ delete_omp_context (struct gimplify_omp_ctx *c)
static void omp_add_variable (struct gimplify_omp_ctx *, tree, unsigned int);
static bool omp_notice_variable (struct gimplify_omp_ctx *, tree, bool);
/* A subroutine of append_to_statement_list{,_force}. T is not NULL. */
static void
append_to_statement_list_1 (tree t, tree *list_p)
{
tree list = *list_p;
tree_stmt_iterator i;
if (!list)
{
if (t && TREE_CODE (t) == STATEMENT_LIST)
{
*list_p = t;
return;
}
*list_p = list = alloc_stmt_list ();
}
i = tsi_last (list);
tsi_link_after (&i, t, TSI_CONTINUE_LINKING);
}
/* Add T to the end of the list container pointed to by LIST_P.
If T is an expression with no effects, it is ignored. */
void
append_to_statement_list (tree t, tree *list_p)
{
if (t && TREE_SIDE_EFFECTS (t))
append_to_statement_list_1 (t, list_p);
}
/* Similar, but the statement is always added, regardless of side effects. */
void
append_to_statement_list_force (tree t, tree *list_p)
{
if (t != NULL_TREE)
append_to_statement_list_1 (t, list_p);
}
/* Both gimplify the statement T and append it to *SEQ_P. This function
behaves exactly as gimplify_stmt, but you don't have to pass T as a
reference. */

View File

@ -27,6 +27,7 @@ along with GCC; see the file COPYING3. If not see
#include "input.h"
#include "real.h"
#include "vec.h"
#include "vecir.h"
#include "fixed-value.h"
#include "alias.h"
@ -197,10 +198,6 @@ struct GTY(()) block_symbol {
HOST_WIDE_INT offset;
};
DEF_VEC_P(rtx);
DEF_VEC_ALLOC_P(rtx,heap);
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 GTY(()) object_block {

View File

@ -22,7 +22,7 @@ along with GCC; see the file COPYING3. If not see
#ifndef GCC_TREE_INLINE_H
#define GCC_TREE_INLINE_H
#include "gimple.h"
#include "vecir.h" /* For VEC(gimple,heap). */
struct cgraph_edge;

View File

@ -61,6 +61,47 @@ free_stmt_list (tree t)
stmt_list_cache = t;
}
/* A subroutine of append_to_statement_list{,_force}. T is not NULL. */
static void
append_to_statement_list_1 (tree t, tree *list_p)
{
tree list = *list_p;
tree_stmt_iterator i;
if (!list)
{
if (t && TREE_CODE (t) == STATEMENT_LIST)
{
*list_p = t;
return;
}
*list_p = list = alloc_stmt_list ();
}
i = tsi_last (list);
tsi_link_after (&i, t, TSI_CONTINUE_LINKING);
}
/* Add T to the end of the list container pointed to by LIST_P.
If T is an expression with no effects, it is ignored. */
void
append_to_statement_list (tree t, tree *list_p)
{
if (t && TREE_SIDE_EFFECTS (t))
append_to_statement_list_1 (t, list_p);
}
/* Similar, but the statement is always added, regardless of side effects. */
void
append_to_statement_list_force (tree t, tree *list_p)
{
if (t != NULL_TREE)
append_to_statement_list_1 (t, list_p);
}
/* Links a statement, or a chain of statements, before the current stmt. */
void

View File

@ -1,4 +1,4 @@
/* Iterator routines for manipulating GENERIC and GIMPLE tree statements.
/* Iterator routines for manipulating GENERIC tree statement list.
Copyright (C) 2003, 2004, 2007 Free Software Foundation, Inc.
Contributed by Andrew MacLeod <amacleod@redhat.com>
@ -111,9 +111,11 @@ extern void tsi_link_before (tree_stmt_iterator *, tree,
extern void tsi_link_after (tree_stmt_iterator *, tree,
enum tsi_iterator_update);
void tsi_delink (tree_stmt_iterator *);
extern void tsi_delink (tree_stmt_iterator *);
void append_to_statement_list (tree, tree *);
void append_to_statement_list_force (tree, tree *);
extern tree alloc_stmt_list (void);
extern void free_stmt_list (tree);
extern void append_to_statement_list (tree, tree *);
extern void append_to_statement_list_force (tree, tree *);
#endif /* GCC_TREE_ITERATOR_H */

View File

@ -27,6 +27,7 @@ along with GCC; see the file COPYING3. If not see
#include "input.h"
#include "statistics.h"
#include "vec.h"
#include "vecir.h"
#include "double-int.h"
#include "alias.h"
#include "options.h"
@ -178,11 +179,6 @@ extern const unsigned char tree_code_length[];
extern const char *const tree_code_name[];
/* A vectors of trees. */
DEF_VEC_P(tree);
DEF_VEC_ALLOC_P(tree,gc);
DEF_VEC_ALLOC_P(tree,heap);
/* We have to be able to tell cgraph about the needed-ness of the target
of an alias. This requires that the decl have been defined. Aliases
that precede their definition have to be queued for later processing. */

52
gcc/vecir.h Normal file
View File

@ -0,0 +1,52 @@
/* VEC types for basic types of the intermediate representations.
Copyright (C) 2010 Free Software Foundation, Inc.
This file is part of GCC.
GCC is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free
Software Foundation; either version 3, or (at your option) any later
version.
GCC is distributed in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
for more details.
You should have received a copy of the GNU General Public License
along with GCC; see the file COPYING3. If not see
<http://www.gnu.org/licenses/>. */
#ifndef GCC_VECIR_H
#define GCC_VECIR_H
#ifndef GCC_CORETYPES_H
#error "vecir.h must be included after coretypes.h"
#endif
/* A varray of trees. */
DEF_VEC_P(tree);
DEF_VEC_ALLOC_P(tree,gc);
DEF_VEC_ALLOC_P(tree,heap);
/* A varray of gimple statements. */
DEF_VEC_P(gimple);
DEF_VEC_ALLOC_P(gimple,heap);
DEF_VEC_ALLOC_P(gimple,gc);
/* A varray of pointers to gimple statements. */
typedef gimple *gimple_p;
DEF_VEC_P(gimple_p);
DEF_VEC_ALLOC_P(gimple_p,heap);
/* A varray gimple statement sequences. */
DEF_VEC_P(gimple_seq);
DEF_VEC_ALLOC_P(gimple_seq,gc);
DEF_VEC_ALLOC_P(gimple_seq,heap);
/* A varray of RTX objects. */
DEF_VEC_P(rtx);
DEF_VEC_ALLOC_P(rtx,heap);
DEF_VEC_ALLOC_P(rtx,gc);
#endif /* GCC_VECIR_H */