+2017-02-24 Segher Boessenkool <segher@kernel.crashing.org>
+
+ * config/arc/arc.c (arc_ccfsm_advance): Only take the PATTERN of
+ this_insn if it is an INSN or JUMP_INSN.
+ (force_offsettable): Look at base, not at addr.
+ * config/arc/predicates.md (brcc_nolimm_operator): Don't call INTVAL
+ on things that aren't necessarily CONST_INTs.
+
2017-02-24 Uros Bizjak <ubizjak@gmail.com>
* doc/invoke.texi (x86 Options, -mfpmath=sse): Mention that
break;
}
- scanbody = PATTERN (this_insn);
-
switch (GET_CODE (this_insn))
{
case CODE_LABEL:
break;
case JUMP_INSN:
+ scanbody = PATTERN (this_insn);
+
/* If this is an unconditional branch to the same label, succeed.
If it is to another label, do nothing. If it is conditional,
fail. */
break;
case INSN:
+ scanbody = PATTERN (this_insn);
+
/* We can only do this with insns that can use the condition
codes (and don't set them). */
if (GET_CODE (scanbody) == SET
}
if (!REG_P (base)
|| (REGNO (base) != STACK_POINTER_REGNUM
- && REGNO_PTR_FRAME_P (REGNO (addr)))
+ && REGNO_PTR_FRAME_P (REGNO (base)))
|| !CONST_INT_P (offs) || !SMALL_INT (INTVAL (offs))
|| !SMALL_INT (INTVAL (offs) + size))
{
(define_predicate "brcc_nolimm_operator"
(ior (match_test "REG_P (XEXP (op, 1))")
(and (match_code "eq, ne, lt, ge, ltu, geu")
+ (match_test "CONST_INT_P (XEXP (op, 1))")
(match_test "u6_immediate_operand (XEXP (op, 1), SImode)"))
(and (match_code "le, gt, leu, gtu")
+ (match_test "CONST_INT_P (XEXP (op, 1))")
(match_test "UNSIGNED_INT6 (INTVAL (XEXP (op, 1)) + 1)"))))
;; Return TRUE if this is the condition code register, if we aren't given