+2001-07-17 Andreas Jaeger <aj@suse.de>
+
+ * config/i386/unix.h (ASM_OUTPUT_MI_THUNK): Fix output format for
+ x86-64 pic support.
+
+ * lcm.c (optimize_mode_switching): Avoid warning for unused
+ variable if !NORMAL_MODE
+
+ * flow.c (try_crossjump_to_edge): Remove unused variable.
+
2001-07-16 John David Anglin <dave@hiauly1.hia.nrc.ca>
* inclhack.def (ultrix_atexit_param): New hack to fix ultrix 4.3
2001-07-16 Daniel Berlin <dan@cgsoftware.com>
- * gcse.c: Update comment at top.
+ * gcse.c: Update comment at top.
Update comment on mem handling.
mem_last_set, mem_first_set, mem_set_in_block: gone.
Declaration of reg_set_info: gone.
(oprs_unchanged_p): Don't use mem_*set_* anymore. They are
pointless with load_killed_in_block_p (they are *more*
conservative then it, not less, and less accurate).
- (oprs_not_set_p): Ditto.
+ (oprs_not_set_p): Ditto.
(alloc_gcse_mem): Don't allocate mem_set_in_block
(free_gcse_mem): Don't free it, either.
(record_last_mem_set_info): Update comment in front, remove
mem_*set_* references.
(reset_opr_set_tables): Remove mem_*set_* references.
(mark_call): Ditto.
- (mark_set): Ditto. Also remove double sets of bitmaps for REG's.
+ (mark_set): Ditto. Also remove double sets of bitmaps for REG's.
(mark_clobber): Ditto (on both parts, we double set here too).
(expr_killed_p): Remove mem_set_in_block test.
(compute_transp): Remove mem_set_in_block test.
* ssa-ccp.c: (optimize_unexecutable_edges): Add note about removal
- of edge, and removal of phi alternative to dump file.
+ of edge, and removal of phi alternative to dump file.
(ssa_ccp_substitute_constants): Add note about register now being
constant, and which uses were replaced in what insns to dump file.
Boston, MA 02111-1307, USA. */
/* These routines are meant to be used by various optimization
- passes which can be modeled as lazy code motion problems.
+ passes which can be modeled as lazy code motion problems.
Including, but not limited to:
* Traditional partial redundancy elimination.
\f
/* Edge based lcm routines. */
-/* Compute expression anticipatability at entrance and exit of each block.
- This is done based on the flow graph, and not on the pred-succ lists.
+/* Compute expression anticipatability at entrance and exit of each block.
+ This is done based on the flow graph, and not on the pred-succ lists.
Other than that, its pretty much identical to compute_antinout. */
static void
*qin++ = BASIC_BLOCK (bb);
BASIC_BLOCK (bb)->aux = BASIC_BLOCK (bb);
}
-
+
qin = worklist;
qend = &worklist[n_basic_blocks];
qlen = n_basic_blocks;
sbitmap *antin, *antout, *avout, *kill, *earliest;
{
sbitmap difference, temp_bitmap;
- int x, num_edges;
+ int x, num_edges;
basic_block pred, succ;
num_edges = NUM_EDGES (edge_list);
sbitmap_zero (earliest[x]);
else
{
- sbitmap_difference (difference, antin[succ->index],
- avout[pred->index]);
+ sbitmap_difference (difference, antin[succ->index],
+ avout[pred->index]);
sbitmap_not (temp_bitmap, antout[pred->index]);
sbitmap_a_and_b_or_c (earliest[x], difference,
kill[pred->index], temp_bitmap);
EXIT block are handled in the normal fashion inside the loop. However,
the insertion/deletion computation needs LATERIN(EXIT), so we have
to compute it. */
-
+
static void
compute_laterin (edge_list, earliest, antloc, later, laterin)
struct edge_list *edge_list;
for (x = 0; x < n_basic_blocks; x++)
sbitmap_difference (delete[x], antloc[x], laterin[x]);
-
+
for (x = 0; x < NUM_EDGES (edge_list); x++)
{
basic_block b = INDEX_EDGE_SUCC_BB (edge_list, x);
void
compute_available (avloc, kill, avout, avin)
- sbitmap *avloc, *kill, *avout, *avin;
+ sbitmap *avloc, *kill, *avout, *avin;
{
int bb;
edge e;
*qin++ = BASIC_BLOCK (bb);
BASIC_BLOCK (bb)->aux = BASIC_BLOCK (bb);
}
-
+
qin = worklist;
qend = &worklist[n_basic_blocks];
qlen = n_basic_blocks;
/* Compute the farthest vector for edge based lcm. */
static void
-compute_farthest (edge_list, n_exprs, st_avout, st_avin, st_antin,
+compute_farthest (edge_list, n_exprs, st_avout, st_avin, st_antin,
kill, farthest)
struct edge_list *edge_list;
int n_exprs;
sbitmap *st_avout, *st_avin, *st_antin, *kill, *farthest;
{
sbitmap difference, temp_bitmap;
- int x, num_edges;
+ int x, num_edges;
basic_block pred, succ;
num_edges = NUM_EDGES (edge_list);
sbitmap_zero (farthest[x]);
else
{
- sbitmap_difference (difference, st_avout[pred->index],
+ sbitmap_difference (difference, st_avout[pred->index],
st_antin[succ->index]);
sbitmap_not (temp_bitmap, st_avin[succ->index]);
- sbitmap_a_and_b_or_c (farthest[x], difference,
+ sbitmap_a_and_b_or_c (farthest[x], difference,
kill[succ->index], temp_bitmap);
}
}
*tos++ = b;
b->aux = b;
}
-
+
/* Iterate until the worklist is empty. */
while (tos != worklist)
{
for (x = 0; x < n_basic_blocks; x++)
sbitmap_difference (delete[x], st_avloc[x], nearerout[x]);
-
+
for (x = 0; x < NUM_EDGES (edge_list); x++)
{
basic_block b = INDEX_EDGE_PRED_BB (edge_list, x);
}
}
-/* Given local properties TRANSP, ST_AVLOC, ST_ANTLOC, KILL return the
+/* Given local properties TRANSP, ST_AVLOC, ST_ANTLOC, KILL return the
insert and delete vectors for edge based reverse LCM. Returns an
edgelist which is used to map the insert vector to what edge
an expression should be inserted on. */
struct edge_list *
-pre_edge_rev_lcm (file, n_exprs, transp, st_avloc, st_antloc, kill,
+pre_edge_rev_lcm (file, n_exprs, transp, st_avloc, st_antloc, kill,
insert, delete)
FILE *file ATTRIBUTE_UNUSED;
int n_exprs;
/* Compute farthestness. */
farthest = sbitmap_vector_alloc (num_edges, n_exprs);
- compute_farthest (edge_list, n_exprs, st_avout, st_avin, st_antin,
+ compute_farthest (edge_list, n_exprs, st_avout, st_avin, st_antin,
kill, farthest);
#ifdef LCM_DEBUG_INFO
#ifdef LCM_DEBUG_INFO
if (file)
{
- dump_sbitmap_vector (file, "nearerout", "", nearerout,
+ dump_sbitmap_vector (file, "nearerout", "", nearerout,
n_basic_blocks + 1);
dump_sbitmap_vector (file, "nearer", "", nearer, num_edges);
}
More details are located in the code for optimize_mode_switching(). */
/* This structure contains the information for each insn which requires
- either single or double mode to be set.
+ either single or double mode to be set.
MODE is the mode this insn must be executed in.
INSN_PTR is the insn to be executed (may be the note that marks the
beginning of a basic block).
BBNUM is the flow graph basic block this insn occurs in.
NEXT is the next insn in the same basic block. */
-struct seginfo
+struct seginfo
{
int mode;
rtx insn_ptr;
return ptr;
}
-/* Add a seginfo element to the end of a list.
+/* Add a seginfo element to the end of a list.
HEAD is a pointer to the list beginning.
INFO is the structure to be linked in. */
{
rtx insn;
int bb, e;
- edge eg;
int need_commit = 0;
sbitmap *kill;
struct edge_list *edge_list;
REG_SET_TO_HARD_REG_SET (live_now,
BASIC_BLOCK (bb)->global_live_at_start);
- for (insn = BLOCK_HEAD (bb);
+ for (insn = BLOCK_HEAD (bb);
insn != NULL && insn != NEXT_INSN (BLOCK_END (bb));
insn = NEXT_INSN (insn))
{
if (mode != no_mode)
{
+ edge eg;
+
for (eg = ENTRY_BLOCK_PTR->succ; eg; eg = eg->succ_next)
{
bb = eg->dest->index;
{
int m = current_mode[j] = MODE_PRIORITY_TO_MODE (entity_map[j], i);
struct bb_info *info = bb_info[j];
-
+
for (bb = 0 ; bb < n_basic_blocks; bb++)
{
if (info[bb].seginfo->mode == m)
VARRAY_POP (basic_block_info);
EXIT_BLOCK_PTR->index = EXIT_BLOCK;
#endif
-
+
/* Now output the remaining mode sets in all the segments. */
for (j = n_entities - 1; j >= 0; j--)
{
insert_insn_on_edge (mode_set, eg);
}
}
-
+
}
#endif
&& (NOTE_LINE_NUMBER (ptr->insn_ptr)
== NOTE_INSN_BASIC_BLOCK))
emit_block_insn_after (mode_set, ptr->insn_ptr,
- BASIC_BLOCK (ptr->bbnum));
+ BASIC_BLOCK (ptr->bbnum));
else
emit_block_insn_before (mode_set, ptr->insn_ptr,
BASIC_BLOCK (ptr->bbnum));
}
/* Finished. Free up all the things we've allocated. */
-
+
sbitmap_vector_free (kill);
sbitmap_vector_free (antic);
sbitmap_vector_free (transp);