aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog12
-rw-r--r--gcc/Makefile.in22
-rw-r--r--gcc/cfglayout.c4
-rw-r--r--gcc/df-problems.c4
-rw-r--r--gcc/function.c4
-rw-r--r--gcc/genextract.c5
-rw-r--r--gcc/global.c4
-rw-r--r--gcc/lambda-code.c4
-rw-r--r--gcc/reg-stack.c4
-rw-r--r--gcc/tree-into-ssa.c7
-rw-r--r--gcc/tree-outof-ssa.c4
-rw-r--r--gcc/tree-ssa-alias.c4
-rw-r--r--gcc/tree-ssa-live.c4
-rw-r--r--gcc/vecprim.h30
14 files changed, 64 insertions, 48 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 0acc7c9..923be6c 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,15 @@
+2006-04-10 Kazu Hirata <kazu@codesourcery.com>
+
+ * Makefile.in (tree-into-ssa.o, tree-outof-ssa.o,
+ tree-ssa-live.o, tree-ssa-alias.o, function.o, df-problems.o,
+ global.o, cfglayout.o, lambda-code.o, reg-stack.o,
+ build/genextract.o): Depend on vecprim.h.
+ * cfglayout.c, df-problems.c, function.c, genextract.c,
+ global.c, lambda-code.c, reg-stack.c, tree-into-ssa.c,
+ tree-outof-ssa.c, tree-ssa-alias.c, tree-ssa-live.c: Include
+ vecprim.h.
+ * vecprim.h: New.
+
2006-04-10 Geoffrey Keating <geoffk@apple.com>
* dwarf2out.c (struct dw_attr_struct): Remove dw_attr_next.
diff --git a/gcc/Makefile.in b/gcc/Makefile.in
index 77033f2..25559e4 100644
--- a/gcc/Makefile.in
+++ b/gcc/Makefile.in
@@ -1823,13 +1823,13 @@ tree-into-ssa.o : tree-into-ssa.c $(TREE_FLOW_H) $(CONFIG_H) $(SYSTEM_H) \
$(FUNCTION_H) $(TIMEVAR_H) $(TM_H) coretypes.h $(TREE_DUMP_H) \
langhooks.h domwalk.h tree-pass.h $(GGC_H) $(PARAMS_H) $(BASIC_BLOCK_H) \
bitmap.h $(CFGLOOP_H) $(FLAGS_H) hard-reg-set.h $(HASHTAB_H) \
- $(TREE_GIMPLE_H) $(TREE_INLINE_H) $(VARRAY_H)
+ $(TREE_GIMPLE_H) $(TREE_INLINE_H) $(VARRAY_H) vecprim.h
tree-outof-ssa.o : tree-outof-ssa.c $(TREE_FLOW_H) $(CONFIG_H) $(SYSTEM_H) \
$(RTL_H) $(TREE_H) $(TM_P_H) $(EXPR_H) output.h $(DIAGNOSTIC_H) \
$(FUNCTION_H) $(TIMEVAR_H) $(TM_H) coretypes.h $(TREE_DUMP_H) \
langhooks.h tree-pass.h $(TREE_SSA_LIVE_H) $(BASIC_BLOCK_H) bitmap.h \
$(FLAGS_H) $(GGC_H) hard-reg-set.h $(HASHTAB_H) $(TREE_GIMPLE_H) \
- $(TREE_INLINE_H) $(VARRAY_H) toplev.h
+ $(TREE_INLINE_H) $(VARRAY_H) toplev.h vecprim.h
tree-ssa-dse.o : tree-ssa-dse.c $(CONFIG_H) $(SYSTEM_H) coretypes.h \
$(TM_H) $(GGC_H) $(TREE_H) $(RTL_H) $(TM_P_H) $(BASIC_BLOCK_H) \
$(TREE_FLOW_H) tree-pass.h $(TREE_DUMP_H) domwalk.h $(FLAGS_H) \
@@ -1884,7 +1884,7 @@ tree-ssa-live.o : tree-ssa-live.c $(TREE_FLOW_H) $(CONFIG_H) $(SYSTEM_H) \
$(TREE_H) $(DIAGNOSTIC_H) $(FUNCTION_H) $(TIMEVAR_H) \
$(TM_H) coretypes.h $(TREE_DUMP_H) $(TREE_SSA_LIVE_H) $(BASIC_BLOCK_H) \
bitmap.h $(FLAGS_H) $(HASHTAB_H) $(TREE_GIMPLE_H) $(TREE_INLINE_H) \
- $(VARRAY_H) toplev.h
+ $(VARRAY_H) toplev.h vecprim.h
tree-ssa-copyrename.o : tree-ssa-copyrename.c $(TREE_FLOW_H) $(CONFIG_H) \
$(SYSTEM_H) $(TREE_H) $(DIAGNOSTIC_H) $(FUNCTION_H) $(TIMEVAR_H) tree-pass.h \
$(TM_H) coretypes.h $(TREE_DUMP_H) $(TREE_SSA_LIVE_H) $(BASIC_BLOCK_H) \
@@ -2009,7 +2009,7 @@ tree-ssa-alias.o : tree-ssa-alias.c $(TREE_FLOW_H) $(CONFIG_H) $(SYSTEM_H) \
$(FUNCTION_H) $(TIMEVAR_H) convert.h $(TM_H) coretypes.h langhooks.h \
$(TREE_DUMP_H) tree-pass.h $(PARAMS_H) $(BASIC_BLOCK_H) $(DIAGNOSTIC_H) \
hard-reg-set.h $(TREE_GIMPLE_H) vec.h tree-ssa-structalias.h \
- $(IPA_TYPE_ESCAPE_H)
+ $(IPA_TYPE_ESCAPE_H) vecprim.h
tree-ssa-reassoc.o : tree-ssa-reassoc.c $(TREE_FLOW_H) $(CONFIG_H) \
$(SYSTEM_H) $(TREE_H) $(GGC_H) $(DIAGNOSTIC_H) errors.h $(TIMEVAR_H) \
$(TM_H) coretypes.h $(TREE_DUMP_H) tree-pass.h $(FLAGS_H) tree-iterator.h\
@@ -2166,7 +2166,7 @@ function.o : function.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(RTL_H) \
$(OPTABS_H) libfuncs.h $(REGS_H) hard-reg-set.h insn-config.h $(RECOG_H) \
output.h toplev.h except.h $(HASHTAB_H) $(GGC_H) $(TM_P_H) langhooks.h \
gt-function.h $(TARGET_H) $(BASIC_BLOCK_H) $(INTEGRATE_H) $(PREDICT_H) \
- tree-pass.h
+ tree-pass.h vecprim.h
stmt.o : stmt.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(RTL_H) \
$(TREE_H) $(FLAGS_H) $(FUNCTION_H) insn-config.h hard-reg-set.h $(EXPR_H) \
libfuncs.h except.h $(RECOG_H) toplev.h output.h $(GGC_H) $(TM_P_H) \
@@ -2352,7 +2352,7 @@ df-core.o : df-core.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(RTL_H) \
df-problems.o : df-problems.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) \
$(RTL_H) insn-config.h $(RECOG_H) $(FUNCTION_H) $(REGS_H) alloc-pool.h \
hard-reg-set.h $(BASIC_BLOCK_H) $(DF_H) bitmap.h sbitmap.h $(TM_P_H) \
- $(FLAGS_H) output.h
+ $(FLAGS_H) output.h vecprim.h
df-scan.o : df-scan.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(RTL_H) \
insn-config.h $(RECOG_H) $(FUNCTION_H) $(REGS_H) alloc-pool.h \
hard-reg-set.h $(BASIC_BLOCK_H) $(DF_H) bitmap.h sbitmap.h $(TM_P_H) \
@@ -2460,7 +2460,7 @@ bitmap.o : bitmap.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(RTL_H) \
global.o : global.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(RTL_H) \
$(FLAGS_H) reload.h $(FUNCTION_H) $(RECOG_H) $(REGS_H) hard-reg-set.h \
insn-config.h output.h toplev.h $(TM_P_H) $(MACHMODE_H) tree-pass.h \
- timevar.h
+ timevar.h vecprim.h
varray.o : varray.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(GGC_H) \
$(HASHTAB_H) $(BCONFIG_H) $(VARRAY_H) toplev.h
vec.o : vec.c $(CONFIG_H) $(SYSTEM_H) $(TREE_H) coretypes.h vec.h $(GGC_H) \
@@ -2549,7 +2549,7 @@ reg-stack.o : reg-stack.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) \
$(RTL_H) $(TREE_H) $(RECOG_H) $(REGS_H) hard-reg-set.h $(FLAGS_H) \
insn-config.h toplev.h reload.h $(FUNCTION_H) $(TM_P_H) $(GGC_H) \
$(BASIC_BLOCK_H) output.h $(VARRAY_H) timevar.h tree-pass.h \
- target.h
+ target.h vecprim.h
sreal.o: sreal.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) sreal.h
predict.o: predict.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(RTL_H) \
$(TREE_H) $(FLAGS_H) insn-config.h $(BASIC_BLOCK_H) $(REGS_H) \
@@ -2570,7 +2570,7 @@ tracer.o : tracer.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(RTL_H) \
cfglayout.o : cfglayout.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) \
$(RTL_H) $(TREE_H) insn-config.h $(BASIC_BLOCK_H) hard-reg-set.h output.h \
$(FUNCTION_H) $(CFGLAYOUT_H) $(CFGLOOP_H) $(TARGET_H) gt-cfglayout.h \
- $(GGC_H) alloc-pool.h $(FLAGS_H) $(OBSTACK_H) tree-pass.h
+ $(GGC_H) alloc-pool.h $(FLAGS_H) $(OBSTACK_H) tree-pass.h vecprim.h
timevar.o : timevar.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) \
$(TIMEVAR_H) $(FLAGS_H) intl.h toplev.h $(RTL_H) timevar.def
regrename.o : regrename.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) \
@@ -2589,7 +2589,7 @@ lambda-code.o: lambda-code.c $(LAMBDA_H) $(GGC_H) $(SYSTEM_H) $(CONFIG_H) \
$(TM_H) $(OPTABS_H) $(TREE_H) $(RTL_H) $(BASIC_BLOCK_H) \
$(DIAGNOSTIC_H) $(TREE_FLOW_H) $(TREE_DUMP_H) $(TIMEVAR_H) $(CFGLOOP_H) \
$(TREE_DATA_REF_H) $(SCEV_H) $(EXPR_H) coretypes.h $(TARGET_H) \
- tree-chrec.h tree-pass.h vec.h
+ tree-chrec.h tree-pass.h vec.h vecprim.h
params.o : params.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(PARAMS_H) toplev.h
pointer-set.o: pointer-set.c pointer-set.h $(CONFIG_H) $(SYSTEM_H)
hooks.o: hooks.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) $(HOOKS_H)
@@ -2949,7 +2949,7 @@ build/genconstants.o : genconstants.c $(RTL_BASE_H) $(BCONFIG_H) \
build/genemit.o : genemit.c $(RTL_BASE_H) $(BCONFIG_H) $(SYSTEM_H) \
coretypes.h $(GTM_H) errors.h gensupport.h
build/genextract.o : genextract.c $(RTL_BASE_H) $(BCONFIG_H) \
- $(SYSTEM_H) coretypes.h $(GTM_H) errors.h gensupport.h
+ $(SYSTEM_H) coretypes.h $(GTM_H) errors.h gensupport.h vecprim.h
build/genflags.o : genflags.c $(RTL_BASE_H) $(OBSTACK_H) $(BCONFIG_H) \
$(SYSTEM_H) coretypes.h $(GTM_H) errors.h gensupport.h
build/gengenrtl.o : gengenrtl.c $(BCONFIG_H) $(SYSTEM_H) rtl.def
diff --git a/gcc/cfglayout.c b/gcc/cfglayout.c
index f427a2b..841f2a8 100644
--- a/gcc/cfglayout.c
+++ b/gcc/cfglayout.c
@@ -37,6 +37,7 @@ Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA
#include "alloc-pool.h"
#include "flags.h"
#include "tree-pass.h"
+#include "vecprim.h"
/* Holds the interesting trailing notes for the function. */
rtx cfg_layout_function_footer, cfg_layout_function_header;
@@ -221,9 +222,6 @@ record_effective_endpoints (void)
cfg_layout_function_footer = unlink_insn_chain (cfg_layout_function_footer, get_last_insn ());
}
-DEF_VEC_I(int);
-DEF_VEC_ALLOC_I(int,heap);
-
/* Data structures representing mapping of INSN_LOCATOR into scope blocks, line
numbers and files. In order to be GGC friendly we need to use separate
varrays. This also slightly improve the memory locality in binary search.
diff --git a/gcc/df-problems.c b/gcc/df-problems.c
index a0422f8..8dd3446 100644
--- a/gcc/df-problems.c
+++ b/gcc/df-problems.c
@@ -42,6 +42,7 @@ Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA
#include "bitmap.h"
#include "timevar.h"
#include "df.h"
+#include "vecprim.h"
#define DF_SPARSE_THRESHOLD 32
@@ -2208,9 +2209,6 @@ df_urec_mark_reg_change (rtx reg, rtx setter, void *data)
/* Classes of registers which could be early clobbered in the current
insn. */
-DEF_VEC_I(int);
-DEF_VEC_ALLOC_I(int,heap);
-
static VEC(int,heap) *earlyclobber_regclass;
/* This function finds and stores register classes that could be early
diff --git a/gcc/function.c b/gcc/function.c
index 3becef3..fd5eeb9 100644
--- a/gcc/function.c
+++ b/gcc/function.c
@@ -63,6 +63,7 @@ Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA
#include "tree-gimple.h"
#include "tree-pass.h"
#include "predict.h"
+#include "vecprim.h"
#ifndef LOCAL_ALIGNMENT
#define LOCAL_ALIGNMENT(TYPE, ALIGNMENT) ALIGNMENT
@@ -123,9 +124,6 @@ struct machine_function * (*init_machine_status) (void);
/* The currently compiled function. */
struct function *cfun = 0;
-DEF_VEC_I(int);
-DEF_VEC_ALLOC_I(int,heap);
-
/* These arrays record the INSN_UIDs of the prologue and epilogue insns. */
static VEC(int,heap) *prologue;
static VEC(int,heap) *epilogue;
diff --git a/gcc/genextract.c b/gcc/genextract.c
index 06ed44a..591a697 100644
--- a/gcc/genextract.c
+++ b/gcc/genextract.c
@@ -29,6 +29,7 @@ Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA
#include "errors.h"
#include "gensupport.h"
#include "vec.h"
+#include "vecprim.h"
/* This structure contains all the information needed to describe one
set of extractions methods. Each method may be used by more than
@@ -69,11 +70,7 @@ static struct code_ptr *peepholes;
/* This structure is used by gen_insn and walk_rtx to accumulate the
data that will be used to produce an extractions structure. */
-DEF_VEC_I(int);
-DEF_VEC_I(char);
DEF_VEC_P(locstr);
-DEF_VEC_ALLOC_I(int,heap);
-DEF_VEC_ALLOC_I(char,heap);
DEF_VEC_ALLOC_P(locstr,heap);
struct accum_extract
diff --git a/gcc/global.c b/gcc/global.c
index 0642a70..b3c13ed 100644
--- a/gcc/global.c
+++ b/gcc/global.c
@@ -38,6 +38,7 @@ Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA
#include "toplev.h"
#include "tree-pass.h"
#include "timevar.h"
+#include "vecprim.h"
/* This pass of the compiler performs global register allocation.
It assigns hard register numbers to all the pseudo registers
@@ -2124,9 +2125,6 @@ mark_reg_change (rtx reg, rtx setter, void *data)
/* Classes of registers which could be early clobbered in the current
insn. */
-DEF_VEC_I(int);
-DEF_VEC_ALLOC_I(int,heap);
-
static VEC(int,heap) *earlyclobber_regclass;
/* This function finds and stores register classes that could be early
diff --git a/gcc/lambda-code.c b/gcc/lambda-code.c
index 8c8b1e5..bf00c05 100644
--- a/gcc/lambda-code.c
+++ b/gcc/lambda-code.c
@@ -41,6 +41,7 @@
#include "tree-scalar-evolution.h"
#include "vec.h"
#include "lambda.h"
+#include "vecprim.h"
/* This loop nest code generation is based on non-singular matrix
math.
@@ -114,9 +115,6 @@
Fourier-Motzkin elimination is used to compute the bounds of the base space
of the lattice. */
-DEF_VEC_I(int);
-DEF_VEC_ALLOC_I(int,heap);
-
static bool perfect_nestify (struct loops *,
struct loop *, VEC(tree,heap) *,
VEC(tree,heap) *, VEC(int,heap) *,
diff --git a/gcc/reg-stack.c b/gcc/reg-stack.c
index 09f74b4..4ed7204 100644
--- a/gcc/reg-stack.c
+++ b/gcc/reg-stack.c
@@ -173,9 +173,7 @@
#include "timevar.h"
#include "tree-pass.h"
#include "target.h"
-
-DEF_VEC_I(char);
-DEF_VEC_ALLOC_I(char,heap);
+#include "vecprim.h"
#ifdef STACK_REGS
diff --git a/gcc/tree-into-ssa.c b/gcc/tree-into-ssa.c
index e0b6e6e..29ad2fc 100644
--- a/gcc/tree-into-ssa.c
+++ b/gcc/tree-into-ssa.c
@@ -47,6 +47,7 @@ Boston, MA 02110-1301, USA. */
#include "domwalk.h"
#include "ggc.h"
#include "params.h"
+#include "vecprim.h"
/* This file builds the SSA form for a function as described in:
R. Cytron, J. Ferrante, B. Rosen, M. Wegman, and K. Zadeck. Efficiently
@@ -103,12 +104,6 @@ static htab_t def_blocks;
associated with the current block. */
static VEC(tree,heap) *block_defs_stack;
-/* Basic block vectors used in this file ought to be allocated in the
- heap. We use pointer vector, because ints can be easily passed by
- value. */
-DEF_VEC_I(int);
-DEF_VEC_ALLOC_I(int,heap);
-
/* Set of existing SSA names being replaced by update_ssa. */
static sbitmap old_ssa_names;
diff --git a/gcc/tree-outof-ssa.c b/gcc/tree-outof-ssa.c
index f2841ae..32f3544 100644
--- a/gcc/tree-outof-ssa.c
+++ b/gcc/tree-outof-ssa.c
@@ -46,6 +46,7 @@ Boston, MA 02110-1301, USA. */
#include "tree-ssa-live.h"
#include "tree-pass.h"
#include "toplev.h"
+#include "vecprim.h"
/* Flags to pass to remove_ssa_form. */
@@ -53,9 +54,6 @@ Boston, MA 02110-1301, USA. */
#define SSANORM_COMBINE_TEMPS 0x2
#define SSANORM_COALESCE_PARTITIONS 0x4
-DEF_VEC_I(int);
-DEF_VEC_ALLOC_I(int,heap);
-
/* Used to hold all the components required to do SSA PHI elimination.
The node and pred/succ list is a simple linear list of nodes and
edges represented as pairs of nodes.
diff --git a/gcc/tree-ssa-alias.c b/gcc/tree-ssa-alias.c
index a151c8c..cc652e7 100644
--- a/gcc/tree-ssa-alias.c
+++ b/gcc/tree-ssa-alias.c
@@ -46,6 +46,7 @@ Boston, MA 02110-1301, USA. */
#include "ipa-type-escape.h"
#include "vec.h"
#include "bitmap.h"
+#include "vecprim.h"
/* Obstack used to hold grouping bitmaps and other temporary bitmaps used by
aliasing */
@@ -135,9 +136,6 @@ bitmap addressable_vars;
having to keep track of too many V_MAY_DEF expressions at call sites. */
tree global_var;
-DEF_VEC_I(int);
-DEF_VEC_ALLOC_I(int,heap);
-
/* qsort comparison function to sort type/name tags by DECL_UID. */
static int
diff --git a/gcc/tree-ssa-live.c b/gcc/tree-ssa-live.c
index 5b9ead1..84abc96 100644
--- a/gcc/tree-ssa-live.c
+++ b/gcc/tree-ssa-live.c
@@ -38,6 +38,7 @@ Boston, MA 02110-1301, USA. */
#include "tree-dump.h"
#include "tree-ssa-live.h"
#include "toplev.h"
+#include "vecprim.h"
static void live_worklist (tree_live_info_p, int *, int);
static tree_live_info_p new_tree_live_info (var_map);
@@ -1385,9 +1386,6 @@ add_conflicts_if_valid (tpa_p tpa, conflict_graph graph,
}
}
-DEF_VEC_I(int);
-DEF_VEC_ALLOC_I(int,heap);
-
/* Return a conflict graph for the information contained in LIVE_INFO. Only
conflicts between items in the same TPA list are added. If optional
coalesce list CL is passed in, any copies encountered are added. */
diff --git a/gcc/vecprim.h b/gcc/vecprim.h
new file mode 100644
index 0000000..f27e44a
--- /dev/null
+++ b/gcc/vecprim.h
@@ -0,0 +1,30 @@
+/* VEC types for primitive types
+ Copyright (C) 2006 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 2, 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 COPYING. If not, write to the Free
+Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301, USA. */
+
+#ifndef GCC_VECPRIM_H
+#define GCC_VECPRIM_H
+
+DEF_VEC_I(char);
+DEF_VEC_ALLOC_I(char,heap);
+
+DEF_VEC_I(int);
+DEF_VEC_ALLOC_I(int,heap);
+
+#endif /* GCC_VECPRIM_H */