aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKaz Kojima <kkojima@gcc.gnu.org>2010-02-28 23:23:50 +0000
committerKaz Kojima <kkojima@gcc.gnu.org>2010-02-28 23:23:50 +0000
commit826159e51b35c350042c7b925e630856b3998a4a (patch)
tree2a666e28ff6ec07a5ca4360a04cdaeb250724b98
parent746ecbcda2f373c62317ce86e4e23f9df50b2254 (diff)
downloadgcc-826159e51b35c350042c7b925e630856b3998a4a.zip
gcc-826159e51b35c350042c7b925e630856b3998a4a.tar.gz
gcc-826159e51b35c350042c7b925e630856b3998a4a.tar.bz2
sh.c (unspec_bbr_uid): New.
* config/sh/sh.c (unspec_bbr_uid): New. (gen_block_redirect): Use it instead of INSN_UID. (gen_far_branch): Likewise. From-SVN: r157128
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/config/sh/sh.c13
2 files changed, 14 insertions, 5 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index da1fd40..0e34ccc 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+2010-02-28 Kaz Kojima <kkojima@gcc.gnu.org>
+
+ * config/sh/sh.c (unspec_bbr_uid): New.
+ (gen_block_redirect): Use it instead of INSN_UID.
+ (gen_far_branch): Likewise.
+
2010-02-28 H.J. Lu <hongjiu.lu@intel.com>
* config/i386/darwin.h (TARGET_SUBTARGET32_ISA_DEFAULT): Make
diff --git a/gcc/config/sh/sh.c b/gcc/config/sh/sh.c
index 3e8ff24..d1105e3 100644
--- a/gcc/config/sh/sh.c
+++ b/gcc/config/sh/sh.c
@@ -107,6 +107,9 @@ static int skip_cycles = 0;
and returned from sh_reorder2. */
static short cached_can_issue_more;
+/* Unique number for UNSPEC_BBR pattern. */
+static unsigned int unspec_bbr_uid = 1;
+
/* Provides the class number of the smallest class containing
reg number. */
@@ -5012,8 +5015,8 @@ gen_block_redirect (rtx jump, int addr, int need_block)
branch; simplejump_p fails for indirect jumps even if they have
a JUMP_LABEL. */
rtx insn = emit_insn_before (gen_indirect_jump_scratch
- (reg, GEN_INT (INSN_UID (JUMP_LABEL (jump))))
- , jump);
+ (reg, GEN_INT (unspec_bbr_uid++)),
+ jump);
/* ??? We would like this to have the scope of the jump, but that
scope will change when a delay slot insn of an inner scope is added.
Hence, after delay slot scheduling, we'll have to expect
@@ -5028,8 +5031,8 @@ gen_block_redirect (rtx jump, int addr, int need_block)
/* We can't use JUMP_LABEL here because it might be undefined
when not optimizing. */
return emit_insn_before (gen_block_branch_redirect
- (GEN_INT (INSN_UID (XEXP (SET_SRC (PATTERN (jump)), 0))))
- , jump);
+ (GEN_INT (unspec_bbr_uid++)),
+ jump);
return prev;
}
@@ -5088,7 +5091,7 @@ gen_far_branch (struct far_branch *bp)
if (bp->far_label)
(emit_insn_after
(gen_stuff_delay_slot
- (GEN_INT (INSN_UID (XEXP (SET_SRC (PATTERN (jump)), 0))),
+ (GEN_INT (unspec_bbr_uid++),
GEN_INT (recog_memoized (insn) == CODE_FOR_branch_false)),
insn));
/* Prevent reorg from undoing our splits. */