summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gcc/ChangeLog14
-rw-r--r--gcc/cfgloop.h21
-rw-r--r--gcc/cp/ChangeLog5
-rw-r--r--gcc/cp/parser.c7
-rw-r--r--gcc/df-scan.c6
-rw-r--r--gcc/df.h24
-rw-r--r--gcc/dse.c18
-rw-r--r--gcc/function.c4
-rw-r--r--gcc/ira-int.h24
-rw-r--r--gcc/ira.c10
-rw-r--r--gcc/matrix-reorg.c10
-rw-r--r--gcc/rtl.h2
-rw-r--r--gcc/tree-data-ref.h24
-rw-r--r--gcc/tree-ssa-loop-ivopts.c20
-rw-r--r--libcpp/ChangeLog4
-rw-r--r--libcpp/include/cpplib.h16
16 files changed, 117 insertions, 92 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index e18131d3d2d..c192bd61a48 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,17 @@
+2009-03-18 Jakub Jelinek <jakub@redhat.com>
+
+ * dse.c (struct group_info): Reorder fields for 64-bit hosts.
+ * matrix-reorg.c (struct matrix_info): Likewise.
+ * tree-ssa-loop-ivopts.c (struct ivopts_data): Likewise.
+ * rtl.h (struct mem_attrs): Likewise.
+ * df.h (struct df): Likewise.
+ * tree-data-ref.h (struct data_dependence_relation): Likewise.
+ * ira-int.h (struct ira_allocno): Likewise.
+ * df-scan.c (struct df_collection_rec): Likewise.
+ * ira.c (struct equivalence): Likewise.
+ * function.c (struct temp_slot): Likewise.
+ * cfgloop.h (struct loop): Likewise.
+
2009-03-18 Sebastian Pop <sebastian.pop@amd.com>
PR middle-end/39447
diff --git a/gcc/cfgloop.h b/gcc/cfgloop.h
index 8f5ba8dce49..0af5be02d76 100644
--- a/gcc/cfgloop.h
+++ b/gcc/cfgloop.h
@@ -1,6 +1,6 @@
/* Natural loop functions
Copyright (C) 1987, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
- 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+ 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
This file is part of GCC.
@@ -105,6 +105,9 @@ struct loop GTY ((chain_next ("%h.next")))
/* Index into loops array. */
int num;
+ /* Number of loop insns. */
+ unsigned ninsns;
+
/* Basic block of loop header. */
struct basic_block_def *header;
@@ -114,9 +117,6 @@ struct loop GTY ((chain_next ("%h.next")))
/* For loop unrolling/peeling decision. */
struct lpt_decision lpt_decision;
- /* Number of loop insns. */
- unsigned ninsns;
-
/* Average number of executed insns per iteration. */
unsigned av_ninsns;
@@ -142,19 +142,20 @@ struct loop GTY ((chain_next ("%h.next")))
information in this field. */
tree nb_iterations;
- /* An integer estimation of the number of iterations. Estimate_state
- describes what is the state of the estimation. */
- enum loop_estimation estimate_state;
-
/* An integer guaranteed to bound the number of iterations of the loop
from above. */
- bool any_upper_bound;
double_int nb_iterations_upper_bound;
/* An integer giving the expected number of iterations of the loop. */
- bool any_estimate;
double_int nb_iterations_estimate;
+ bool any_upper_bound;
+ bool any_estimate;
+
+ /* An integer estimation of the number of iterations. Estimate_state
+ describes what is the state of the estimation. */
+ enum loop_estimation estimate_state;
+
/* Upper bound on number of iterations of a loop. */
struct nb_iter_bound *bounds;
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index ecf1bc634ce..8553a198f92 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,3 +1,8 @@
+2009-03-18 Jakub Jelinek <jakub@redhat.com>
+
+ * parser.c (struct cp_token): Reorder fields for 64-bit hosts.
+ (eof_token): Adjust.
+
2009-03-18 H.J. Lu <hongjiu.lu@intel.com>
PR c++/39425
diff --git a/gcc/cp/parser.c b/gcc/cp/parser.c
index 7206af2e4a4..4e79e1f9126 100644
--- a/gcc/cp/parser.c
+++ b/gcc/cp/parser.c
@@ -77,6 +77,8 @@ typedef struct cp_token GTY (())
KEYWORD is RID_MAX) iff this name was looked up and found to be
ambiguous. An error has already been reported. */
BOOL_BITFIELD ambiguous_p : 1;
+ /* The location at which this token was found. */
+ location_t location;
/* The value associated with this token, if any. */
union cp_token_value {
/* Used for CPP_NESTED_NAME_SPECIFIER and CPP_TEMPLATE_ID. */
@@ -84,8 +86,6 @@ typedef struct cp_token GTY (())
/* Use for all other tokens. */
tree GTY((tag ("0"))) value;
} GTY((desc ("(%1.type == CPP_TEMPLATE_ID) || (%1.type == CPP_NESTED_NAME_SPECIFIER)"))) u;
- /* The location at which this token was found. */
- location_t location;
} cp_token;
/* We use a stack of token pointer for saving token sets. */
@@ -95,8 +95,7 @@ DEF_VEC_ALLOC_P (cp_token_position,heap);
static cp_token eof_token =
{
- CPP_EOF, RID_MAX, 0, PRAGMA_NONE, false, 0, { NULL },
- 0
+ CPP_EOF, RID_MAX, 0, PRAGMA_NONE, false, 0, 0, { NULL }
};
/* The cp_lexer structure represents the C++ lexer. It is responsible
diff --git a/gcc/df-scan.c b/gcc/df-scan.c
index 6888fb42ee3..d8ad4a06698 100644
--- a/gcc/df-scan.c
+++ b/gcc/df-scan.c
@@ -1,6 +1,6 @@
/* Scanning of rtl for dataflow analysis.
Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
- 2008 Free Software Foundation, Inc.
+ 2008, 2009 Free Software Foundation, Inc.
Originally contributed by Michael P. Hayes
(m.hayes@elec.canterbury.ac.nz, mhayes@redhat.com)
Major rewrite contributed by Danny Berlin (dberlin@dberlin.org)
@@ -85,12 +85,12 @@ static HARD_REG_SET elim_reg_set;
struct df_collection_rec
{
df_ref * def_vec;
- unsigned int next_def;
df_ref * use_vec;
+ unsigned int next_def;
unsigned int next_use;
df_ref * eq_use_vec;
- unsigned int next_eq_use;
struct df_mw_hardreg **mw_vec;
+ unsigned int next_eq_use;
unsigned int next_mw;
};
diff --git a/gcc/df.h b/gcc/df.h
index dd00d9284d1..639c52157b4 100644
--- a/gcc/df.h
+++ b/gcc/df.h
@@ -1,6 +1,6 @@
/* Form lists of pseudo register references for autoinc optimization
for GNU compiler. This is part of flow optimization.
- Copyright (C) 1999, 2000, 2001, 2003, 2004, 2005, 2006, 2007, 2008
+ Copyright (C) 1999, 2000, 2001, 2003, 2004, 2005, 2006, 2007, 2008, 2009
Free Software Foundation, Inc.
Originally contributed by Michael P. Hayes
(m.hayes@elec.canterbury.ac.nz, mhayes@redhat.com)
@@ -535,7 +535,6 @@ struct df
struct dataflow *problems_in_order[DF_LAST_PROBLEM_PLUS1];
struct dataflow *problems_by_index[DF_LAST_PROBLEM_PLUS1];
- int num_problems_defined;
/* If not NULL, this subset of blocks of the program to be
considered for analysis. At certain times, this will contain all
@@ -543,14 +542,6 @@ struct df
of if we are analyzing a subset. See analyze_subset. */
bitmap blocks_to_analyze;
- /* If this is true, then only a subset of the blocks of the program
- is considered to compute the solutions of dataflow problems. */
- bool analyze_subset;
-
- /* True if someone added or deleted something from regs_ever_live so
- that the entry and exit blocks need be reprocessed. */
- bool redo_entry_and_exit;
-
/* The following information is really the problem data for the
scanning instance but it is used too often by the other problems
to keep getting it from there. */
@@ -568,6 +559,9 @@ struct df
struct df_insn_info **insns; /* Insn table, indexed by insn UID. */
unsigned int insns_size; /* Size of insn table. */
+
+ int num_problems_defined;
+
bitmap hardware_regs_used; /* The set of hardware registers used. */
/* The set of hard regs that are in the artificial uses at the end
of a regular basic block. */
@@ -609,7 +603,15 @@ struct df
unsigned int ref_order;
/* Problem specific control information. */
- enum df_changeable_flags changeable_flags;
+ ENUM_BITFIELD (df_changeable_flags) changeable_flags : 8;
+
+ /* If this is true, then only a subset of the blocks of the program
+ is considered to compute the solutions of dataflow problems. */
+ bool analyze_subset;
+
+ /* True if someone added or deleted something from regs_ever_live so
+ that the entry and exit blocks need be reprocessed. */
+ bool redo_entry_and_exit;
};
#define DF_SCAN_BB_INFO(BB) (df_scan_get_bb_info((BB)->index))
diff --git a/gcc/dse.c b/gcc/dse.c
index 666a2f00164..a35f07bb113 100644
--- a/gcc/dse.c
+++ b/gcc/dse.c
@@ -1,5 +1,5 @@
/* RTL dead store elimination.
- Copyright (C) 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+ Copyright (C) 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
Contributed by Richard Sandiford <rsandifor@codesourcery.com>
and Kenneth Zadeck <zadeck@naturalbridge.com>
@@ -464,6 +464,14 @@ struct group_info
canonical ordering of these that is not based on addresses. */
int id;
+ /* True if there are any positions that are to be processed
+ globally. */
+ bool process_globally;
+
+ /* True if the base of this group is either the frame_pointer or
+ hard_frame_pointer. */
+ bool frame_related;
+
/* A mem wrapped around the base pointer for the group in order to
do read dependency. */
rtx base_mem;
@@ -494,14 +502,6 @@ struct group_info
the positions that are occupied by stores for this group. */
bitmap group_kill;
- /* True if there are any positions that are to be processed
- globally. */
- bool process_globally;
-
- /* True if the base of this group is either the frame_pointer or
- hard_frame_pointer. */
- bool frame_related;
-
/* The offset_map is used to map the offsets from this base into
positions in the global bitmaps. It is only created after all of
the all of stores have been scanned and we know which ones we
diff --git a/gcc/function.c b/gcc/function.c
index 0cbcbd3e054..76d48347d48 100644
--- a/gcc/function.c
+++ b/gcc/function.c
@@ -458,8 +458,6 @@ struct temp_slot GTY(())
struct temp_slot *prev;
/* The rtx to used to reference the slot. */
rtx slot;
- /* The alignment (in bits) of the slot. */
- unsigned int align;
/* The size, in units, of the slot. */
HOST_WIDE_INT size;
/* The type of the object in the slot, or zero if it doesn't correspond
@@ -467,6 +465,8 @@ struct temp_slot GTY(())
It can be reused if objects of the type of the new slot will always
conflict with objects of the type of the old slot. */
tree type;
+ /* The alignment (in bits) of the slot. */
+ unsigned int align;
/* Nonzero if this temporary is currently in use. */
char in_use;
/* Nonzero if this temporary has its address taken. */
diff --git a/gcc/ira-int.h b/gcc/ira-int.h
index 87ba7b0700a..4cb3928564c 100644
--- a/gcc/ira-int.h
+++ b/gcc/ira-int.h
@@ -240,8 +240,6 @@ struct ira_allocno
/* Mode of the allocno which is the mode of the corresponding
pseudo-register. */
enum machine_mode mode;
- /* Final rtx representation of the allocno. */
- rtx reg;
/* Hard register assigned to given allocno. Negative value means
that memory was allocated to the allocno. During the reload,
spilled allocno has value equal to the corresponding stack slot
@@ -249,6 +247,8 @@ struct ira_allocno
reload (at this point pseudo-register has only one allocno) which
did not get stack slot yet. */
int hard_regno;
+ /* Final rtx representation of the allocno. */
+ rtx reg;
/* Allocnos with the same regno are linked by the following member.
Allocnos corresponding to inner loops are first in the list (it
corresponds to depth-first traverse of the loops). */
@@ -312,33 +312,29 @@ struct ira_allocno
correspondingly minimal and maximal conflict ids of allocnos with
which given allocno can conflict. */
int min, max;
- /* The unique member value represents given allocno in conflict bit
- vectors. */
- int conflict_id;
/* Vector of accumulated conflicting allocnos with NULL end marker
(if CONFLICT_VEC_P is true) or conflict bit vector otherwise.
Only allocnos with the same cover class are in the vector or in
the bit vector. */
void *conflict_allocno_array;
+ /* The unique member value represents given allocno in conflict bit
+ vectors. */
+ int conflict_id;
/* Allocated size of the previous array. */
unsigned int conflict_allocno_array_size;
- /* Number of accumulated conflicts in the vector of conflicting
- allocnos. */
- int conflict_allocnos_num;
/* Initial and accumulated hard registers conflicting with this
allocno and as a consequences can not be assigned to the allocno.
All non-allocatable hard regs and hard regs of cover classes
different from given allocno one are included in the sets. */
HARD_REG_SET conflict_hard_regs, total_conflict_hard_regs;
+ /* Number of accumulated conflicts in the vector of conflicting
+ allocnos. */
+ int conflict_allocnos_num;
/* Accumulated frequency of calls which given allocno
intersects. */
int call_freq;
/* Accumulated number of the intersected calls. */
int calls_crossed_num;
- /* Non NULL if we remove restoring value from given allocno to
- MEM_OPTIMIZED_DEST at loop exit (see ira-emit.c) because the
- allocno value is not changed inside the loop. */
- ira_allocno_t mem_optimized_dest;
/* TRUE if the allocno assigned to memory was a destination of
removed move (see ira-emit.c) at loop exit because the value of
the corresponding pseudo-register is not changed inside the
@@ -383,6 +379,10 @@ struct ira_allocno
vector where a bit with given index represents allocno with the
same number. */
unsigned int conflict_vec_p : 1;
+ /* Non NULL if we remove restoring value from given allocno to
+ MEM_OPTIMIZED_DEST at loop exit (see ira-emit.c) because the
+ allocno value is not changed inside the loop. */
+ ira_allocno_t mem_optimized_dest;
/* Array of usage costs (accumulated and the one updated during
coloring) for each hard register of the allocno cover class. The
member value can be NULL if all costs are the same and equal to
diff --git a/gcc/ira.c b/gcc/ira.c
index 8eb11254720..3742f0f35c1 100644
--- a/gcc/ira.c
+++ b/gcc/ira.c
@@ -1864,21 +1864,21 @@ mark_elimination (int from, int to)
struct equivalence
{
- /* Set when an attempt should be made to replace a register
- with the associated src_p entry. */
- char replace;
/* Set when a REG_EQUIV note is found or created. Use to
keep track of what memory accesses might be created later,
e.g. by reload. */
rtx replacement;
rtx *src_p;
+ /* The list of each instruction which initializes this register. */
+ rtx init_insns;
/* Loop depth is used to recognize equivalences which appear
to be present within the same loop (or in an inner loop). */
int loop_depth;
- /* The list of each instruction which initializes this register. */
- rtx init_insns;
/* Nonzero if this had a preexisting REG_EQUIV note. */
int is_arg_equivalence;
+ /* Set when an attempt should be made to replace a register
+ with the associated src_p entry. */
+ char replace;
};
/* reg_equiv[N] (where N is a pseudo reg number) is the equivalence
diff --git a/gcc/matrix-reorg.c b/gcc/matrix-reorg.c
index 7ea185ced20..d916f70266c 100644
--- a/gcc/matrix-reorg.c
+++ b/gcc/matrix-reorg.c
@@ -1,5 +1,5 @@
/* Matrix layout transformations.
- Copyright (C) 2006, 2007, 2008 Free Software Foundation, Inc.
+ Copyright (C) 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
Contributed by Razya Ladelsky <razya@il.ibm.com>
Originally written by Revital Eres and Mustafa Hagog.
@@ -261,9 +261,6 @@ struct matrix_info
gimple min_indirect_level_escape_stmt;
- /* Is the matrix transposed. */
- bool is_transposed_p;
-
/* Hold the allocation site for each level (dimension).
We can use NUM_DIMS as the upper bound and allocate the array
once with this number of elements and no need to use realloc and
@@ -272,6 +269,9 @@ struct matrix_info
int max_malloced_level;
+ /* Is the matrix transposed. */
+ bool is_transposed_p;
+
/* The location of the allocation sites (they must be in one
function). */
tree allocation_function_decl;
@@ -303,7 +303,7 @@ struct matrix_info
/* An array of the accesses to be flattened.
elements are of type "struct access_site_info *". */
- VEC (access_site_info_p, heap) * access_l;
+ VEC (access_site_info_p, heap) * access_l;
/* A map of how the dimensions will be organized at the end of
the analyses. */
diff --git a/gcc/rtl.h b/gcc/rtl.h
index 7e80603dd53..e8d42c8cc61 100644
--- a/gcc/rtl.h
+++ b/gcc/rtl.h
@@ -141,10 +141,10 @@ typedef struct
stricter alignment; OFFSET is the offset of the MEM within that object. */
typedef struct mem_attrs GTY(())
{
- alias_set_type alias; /* Memory alias set. */
tree expr; /* expr corresponding to MEM. */
rtx offset; /* Offset from start of DECL, as CONST_INT. */
rtx size; /* Size in bytes, as a CONST_INT. */
+ alias_set_type alias; /* Memory alias set. */
unsigned int align; /* Alignment of MEM in bits. */
} mem_attrs;
diff --git a/gcc/tree-data-ref.h b/gcc/tree-data-ref.h
index 6477542879d..4a12f3946d8 100644
--- a/gcc/tree-data-ref.h
+++ b/gcc/tree-data-ref.h
@@ -291,14 +291,6 @@ struct data_dependence_relation
struct data_reference *a;
struct data_reference *b;
- /* When the dependence relation is affine, it can be represented by
- a distance vector. */
- bool affine_p;
-
- /* Set to true when the dependence relation is on the same data
- access. */
- bool self_reference_p;
-
/* A "yes/no/maybe" field for the dependence relation:
- when "ARE_DEPENDENT == NULL_TREE", there exist a dependence
@@ -320,18 +312,26 @@ struct data_dependence_relation
/* The analyzed loop nest. */
VEC (loop_p, heap) *loop_nest;
- /* An index in loop_nest for the innermost loop that varies for
- this data dependence relation. */
- unsigned inner_loop;
-
/* The classic direction vector. */
VEC (lambda_vector, heap) *dir_vects;
/* The classic distance vector. */
VEC (lambda_vector, heap) *dist_vects;
+ /* An index in loop_nest for the innermost loop that varies for
+ this data dependence relation. */
+ unsigned inner_loop;
+
/* Is the dependence reversed with respect to the lexicographic order? */
bool reversed_p;
+
+ /* When the dependence relation is affine, it can be represented by
+ a distance vector. */
+ bool affine_p;
+
+ /* Set to true when the dependence relation is on the same data
+ access. */
+ bool self_reference_p;
};
typedef struct data_dependence_relation *ddr_p;
diff --git a/gcc/tree-ssa-loop-ivopts.c b/gcc/tree-ssa-loop-ivopts.c
index c7bfa07be80..fcaf7846458 100644
--- a/gcc/tree-ssa-loop-ivopts.c
+++ b/gcc/tree-ssa-loop-ivopts.c
@@ -1,6 +1,6 @@
/* Induction variable optimizations.
- Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 Free Software
- Foundation, Inc.
+ Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009
+ Free Software Foundation, Inc.
This file is part of GCC.
@@ -219,15 +219,12 @@ struct ivopts_data
/* The currently optimized loop. */
struct loop *current_loop;
- /* Are we optimizing for speed? */
- bool speed;
+ /* Numbers of iterations for all exits of the current loop. */
+ struct pointer_map_t *niters;
/* Number of registers used in it. */
unsigned regs_used;
- /* Numbers of iterations for all exits of the current loop. */
- struct pointer_map_t *niters;
-
/* The size of version_info array allocated. */
unsigned version_info_size;
@@ -237,9 +234,6 @@ struct ivopts_data
/* The bitmap of indices in version_info whose value was changed. */
bitmap relevant;
- /* The maximum invariant id. */
- unsigned max_inv_id;
-
/* The uses of induction variables. */
VEC(iv_use_p,heap) *iv_uses;
@@ -249,9 +243,15 @@ struct ivopts_data
/* A bitmap of important candidates. */
bitmap important_candidates;
+ /* The maximum invariant id. */
+ unsigned max_inv_id;
+
/* Whether to consider just related and important candidates when replacing a
use. */
bool consider_all_candidates;
+
+ /* Are we optimizing for speed? */
+ bool speed;
};
/* An assignment of iv candidates to uses. */
diff --git a/libcpp/ChangeLog b/libcpp/ChangeLog
index d86092b677c..acffe8e39e0 100644
--- a/libcpp/ChangeLog
+++ b/libcpp/ChangeLog
@@ -1,3 +1,7 @@
+2009-03-18 Jakub Jelinek <jakub@redhat.com>
+
+ * include/cpplib.h (struct cpp_dir): Reorder fields for 64-bit hosts.
+
2009-02-21 Joseph Myers <joseph@codesourcery.com>
* lex.c (lex_string): Return a CPP_LESS token for missing '>' in a
diff --git a/libcpp/include/cpplib.h b/libcpp/include/cpplib.h
index 5720c6fc8ea..e2c505c3869 100644
--- a/libcpp/include/cpplib.h
+++ b/libcpp/include/cpplib.h
@@ -1,6 +1,6 @@
/* Definitions for CPP library.
Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
- 2004, 2005, 2007, 2008
+ 2004, 2005, 2007, 2008, 2009
Free Software Foundation, Inc.
Written by Per Bothner, 1994-95.
@@ -516,14 +516,17 @@ struct cpp_dir
char *name;
unsigned int len;
- /* The canonicalized NAME as determined by lrealpath. This field
- is only used by hosts that lack reliable inode numbers. */
- char *canonical_name;
-
/* One if a system header, two if a system header that has extern
"C" guards for C++. */
unsigned char sysp;
+ /* Is this a user-supplied directory? */
+ bool user_supplied_p;
+
+ /* The canonicalized NAME as determined by lrealpath. This field
+ is only used by hosts that lack reliable inode numbers. */
+ char *canonical_name;
+
/* Mapping of file names for this directory for MS-DOS and related
platforms. A NULL-terminated array of (from, to) pairs. */
const char **name_map;
@@ -538,9 +541,6 @@ struct cpp_dir
directories in the search path. */
ino_t ino;
dev_t dev;
-
- /* Is this a user-supplied directory? */
- bool user_supplied_p;
};
/* Name under which this program was invoked. */