aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKaz Kojima <kkojima@gcc.gnu.org>2006-03-20 22:58:32 +0000
committerKaz Kojima <kkojima@gcc.gnu.org>2006-03-20 22:58:32 +0000
commitc6d5644365d3e0ee9bf85580058df12f4dfe1540 (patch)
tree01e2a3441de8aa9c91bfa440349b5a00c0c1db54
parent97a62038664e3b5f7e46ce900b2a090c79bb03bd (diff)
downloadgcc-c6d5644365d3e0ee9bf85580058df12f4dfe1540.zip
gcc-c6d5644365d3e0ee9bf85580058df12f4dfe1540.tar.gz
gcc-c6d5644365d3e0ee9bf85580058df12f4dfe1540.tar.bz2
sh.c (untangle_mova): Initialize n_addr and n_target.
* config/sh/sh.c (untangle_mova): Initialize n_addr and n_target. * config/sh/sh.c (find_regmode_weight): Change the type of the first parameter and use get_ebb_head_tail. (sh_md_init_global): Adjust uses of find_regmode_weight. From-SVN: r112231
-rw-r--r--gcc/ChangeLog8
-rw-r--r--gcc/config/sh/sh.c14
2 files changed, 15 insertions, 7 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 613fb84..37f3533 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,11 @@
+2006-03-20 Kaz Kojima <kkojima@gcc.gnu.org>
+
+ * config/sh/sh.c (untangle_mova): Initialize n_addr and n_target.
+
+ * config/sh/sh.c (find_regmode_weight): Change the type of the first
+ parameter and use get_ebb_head_tail.
+ (sh_md_init_global): Adjust uses of find_regmode_weight.
+
2006-03-20 Steven Bosscher <stevenb.gcc@gmail.com>
* function.h (struct function) <x_tail_recursion_reentry>:
diff --git a/gcc/config/sh/sh.c b/gcc/config/sh/sh.c
index b2d18eb..b4a4dd1 100644
--- a/gcc/config/sh/sh.c
+++ b/gcc/config/sh/sh.c
@@ -208,7 +208,7 @@ static int sh_issue_rate (void);
static int sh_dfa_new_cycle (FILE *, int, rtx, int, int, int *sort_p);
static short find_set_regmode_weight (rtx, enum machine_mode);
static short find_insn_regmode_weight (rtx, enum machine_mode);
-static void find_regmode_weight (int, enum machine_mode);
+static void find_regmode_weight (basic_block, enum machine_mode);
static void sh_md_init_global (FILE *, int, int);
static void sh_md_finish_global (FILE *, int);
static int rank_for_reorder (const void *, const void *);
@@ -3446,8 +3446,8 @@ fixup_mova (rtx mova)
static int
untangle_mova (int *num_mova, rtx *first_mova, rtx new_mova)
{
- int n_addr;
- int f_target, n_target;
+ int n_addr = 0; /* Initialization to shut up spurious warning. */
+ int f_target, n_target = 0; /* Likewise. */
if (optimize)
{
@@ -8748,11 +8748,11 @@ find_insn_regmode_weight (rtx insn, enum machine_mode mode)
/* Calculate regmode weights for all insns of a basic block. */
static void
-find_regmode_weight (int b, enum machine_mode mode)
+find_regmode_weight (basic_block b, enum machine_mode mode)
{
rtx insn, next_tail, head, tail;
- get_block_head_tail (b, &head, &tail);
+ get_ebb_head_tail (b, b, &head, &tail);
next_tail = NEXT_INSN (tail);
for (insn = head; insn != next_tail; insn = NEXT_INSN (insn))
@@ -8833,8 +8833,8 @@ sh_md_init_global (FILE *dump ATTRIBUTE_UNUSED,
FOR_EACH_BB_REVERSE (b)
{
- find_regmode_weight (b->index, SImode);
- find_regmode_weight (b->index, SFmode);
+ find_regmode_weight (b, SImode);
+ find_regmode_weight (b, SFmode);
}
CURR_REGMODE_PRESSURE (SImode) = 0;