aboutsummaryrefslogtreecommitdiff
path: root/gcc/config
diff options
context:
space:
mode:
authorJoern Rennecke <joern.rennecke@embecosm.com>2013-10-24 17:11:01 +0000
committerJoern Rennecke <amylaar@gcc.gnu.org>2013-10-24 18:11:01 +0100
commit53ea364f185e47fc3622f9a12e898140d0c54f92 (patch)
treee60ebfe5f77d9a5eb935a99857c9aff9ba1615ac /gcc/config
parent2ca4e2c2296e9b0690501d80ab8cdca25c30de08 (diff)
downloadgcc-53ea364f185e47fc3622f9a12e898140d0c54f92.zip
gcc-53ea364f185e47fc3622f9a12e898140d0c54f92.tar.gz
gcc-53ea364f185e47fc3622f9a12e898140d0c54f92.tar.bz2
arc.c (arc_ccfsm_post_advance): Also handle TYPE_UNCOND_BRANCH.
* gcc/config/arc/arc.c (arc_ccfsm_post_advance): Also handle TYPE_UNCOND_BRANCH. From-SVN: r204024
Diffstat (limited to 'gcc/config')
-rw-r--r--gcc/config/arc/arc.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/gcc/config/arc/arc.c b/gcc/config/arc/arc.c
index 83f92eb..7c39d53 100644
--- a/gcc/config/arc/arc.c
+++ b/gcc/config/arc/arc.c
@@ -3711,12 +3711,16 @@ arc_ccfsm_record_condition (rtx cond, bool reverse, rtx jump,
static void
arc_ccfsm_post_advance (rtx insn, struct arc_ccfsm *state)
{
+ enum attr_type type;
+
if (LABEL_P (insn))
arc_ccfsm_at_label ("L", CODE_LABEL_NUMBER (insn), state);
else if (JUMP_P (insn)
&& GET_CODE (PATTERN (insn)) != ADDR_VEC
&& GET_CODE (PATTERN (insn)) != ADDR_DIFF_VEC
- && get_attr_type (insn) == TYPE_BRANCH)
+ && ((type = get_attr_type (insn)) == TYPE_BRANCH
+ || (type == TYPE_UNCOND_BRANCH
+ && ARC_CCFSM_BRANCH_DELETED_P (state))))
{
if (ARC_CCFSM_BRANCH_DELETED_P (state))
ARC_CCFSM_RECORD_BRANCH_DELETED (state);
@@ -8120,6 +8124,7 @@ arc_ifcvt (void)
basic_block succ_bb
= BLOCK_FOR_INSN (NEXT_INSN (NEXT_INSN (PREV_INSN (insn))));
arc_ccfsm_post_advance (insn, statep);
+ gcc_assert (!IN_RANGE (statep->state, 1, 2));
rtx seq = NEXT_INSN (PREV_INSN (insn));
if (seq != insn)
{