function.h (rtl_data): Add a dbr_scheduled_p field.
gcc/ * function.h (rtl_data): Add a dbr_scheduled_p field. * reorg.c (dbr_schedule): Set it. (gate_handle_delay_slots): Check it. * config/mips/mips.c (mips_base_delayed_branch): Delete. (mips_reorg): Check flag_delayed_branch instead of mips_base_delayed_branch. (mips_override_options): Don't set mips_base_delayed_branch or flag_delayed_branch. From-SVN: r143136
This commit is contained in:
parent
ace984c851
commit
84b9b87220
@ -1,3 +1,14 @@
|
||||
2009-01-06 Richard Sandiford <rdsandiford@googlemail.com>
|
||||
|
||||
* function.h (rtl_data): Add a dbr_scheduled_p field.
|
||||
* reorg.c (dbr_schedule): Set it.
|
||||
(gate_handle_delay_slots): Check it.
|
||||
* config/mips/mips.c (mips_base_delayed_branch): Delete.
|
||||
(mips_reorg): Check flag_delayed_branch instead of
|
||||
mips_base_delayed_branch.
|
||||
(mips_override_options): Don't set mips_base_delayed_branch
|
||||
or flag_delayed_branch.
|
||||
|
||||
2009-01-06 Richard Sandiford <rdsandiford@googlemail.com>
|
||||
|
||||
PR rtl-optimization/38426.
|
||||
|
@ -453,7 +453,6 @@ static int mips_base_target_flags;
|
||||
bool mips_base_mips16;
|
||||
|
||||
/* The ambient values of other global variables. */
|
||||
static int mips_base_delayed_branch; /* flag_delayed_branch */
|
||||
static int mips_base_schedule_insns; /* flag_schedule_insns */
|
||||
static int mips_base_reorder_blocks_and_partition; /* flag_reorder... */
|
||||
static int mips_base_move_loop_invariants; /* flag_move_loop_invariants */
|
||||
@ -13297,7 +13296,7 @@ mips_reorg (void)
|
||||
mips16_lay_out_constants ();
|
||||
if (mips_r10k_cache_barrier != R10K_CACHE_BARRIER_NONE)
|
||||
r10k_insert_cache_barriers ();
|
||||
if (mips_base_delayed_branch)
|
||||
if (flag_delayed_branch)
|
||||
dbr_schedule (get_insns ());
|
||||
mips_reorg_process_insns ();
|
||||
if (!TARGET_MIPS16
|
||||
@ -14058,7 +14057,6 @@ mips_override_options (void)
|
||||
|
||||
/* Save base state of options. */
|
||||
mips_base_target_flags = target_flags;
|
||||
mips_base_delayed_branch = flag_delayed_branch;
|
||||
mips_base_schedule_insns = flag_schedule_insns;
|
||||
mips_base_reorder_blocks_and_partition = flag_reorder_blocks_and_partition;
|
||||
mips_base_move_loop_invariants = flag_move_loop_invariants;
|
||||
@ -14071,9 +14069,6 @@ mips_override_options (void)
|
||||
Do all CPP-sensitive stuff in non-MIPS16 mode; we'll switch to
|
||||
MIPS16 mode afterwards if need be. */
|
||||
mips_set_mips16_mode (false);
|
||||
|
||||
/* We call dbr_schedule from within mips_reorg. */
|
||||
flag_delayed_branch = 0;
|
||||
}
|
||||
|
||||
/* Swap the register information for registers I and I + 1, which
|
||||
|
@ -444,6 +444,9 @@ struct rtl_data GTY(())
|
||||
/* Nonzero if function stack realignment has been finalized, namely
|
||||
stack_realign_needed flag has been set and finalized after reload. */
|
||||
bool stack_realign_finalized;
|
||||
|
||||
/* True if dbr_schedule has already been called for this function. */
|
||||
bool dbr_scheduled_p;
|
||||
};
|
||||
|
||||
#define return_label (crtl->x_return_label)
|
||||
|
@ -4038,6 +4038,7 @@ dbr_schedule (rtx first)
|
||||
}
|
||||
|
||||
#endif
|
||||
crtl->dbr_scheduled_p = true;
|
||||
}
|
||||
#endif /* DELAY_SLOTS */
|
||||
|
||||
@ -4045,7 +4046,7 @@ static bool
|
||||
gate_handle_delay_slots (void)
|
||||
{
|
||||
#ifdef DELAY_SLOTS
|
||||
return flag_delayed_branch;
|
||||
return flag_delayed_branch && !crtl->dbr_scheduled_p;
|
||||
#else
|
||||
return 0;
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user