diff options
-rw-r--r-- | gcc/genrecog.c | 8 | ||||
-rw-r--r-- | gcc/reload1.c | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/gcc/genrecog.c b/gcc/genrecog.c index f8b2169..bb12d06 100644 --- a/gcc/genrecog.c +++ b/gcc/genrecog.c @@ -588,7 +588,7 @@ not_both_true (d1, d2, toplevel) for D1's predicate. */ if (d2->code != UNKNOWN) { - for (i = 0; i < NUM_RTX_CODE && preds[d1->pred].codes[i]; i++) + for (i = 0; i < NUM_RTX_CODE && preds[d1->pred].codes[i] != 0; i++) if (preds[d1->pred].codes[i] == d2->code) break; @@ -600,7 +600,7 @@ not_both_true (d1, d2, toplevel) else if (d2->pred >= 0) { - for (i = 0; i < NUM_RTX_CODE && preds[d1->pred].codes[i]; i++) + for (i = 0; i < NUM_RTX_CODE && preds[d1->pred].codes[i] != 0; i++) { for (j = 0; j < NUM_RTX_CODE; j++) if (preds[d2->pred].codes[j] == 0 @@ -1117,7 +1117,7 @@ write_tree_1 (tree, prevpos, afterward, type) if (p->pred >= 0) { - for (i = 0; i < NUM_RTX_CODE && preds[p->pred].codes[i]; i++) + for (i = 0; i < NUM_RTX_CODE && preds[p->pred].codes[i] != 0; i++) if (codemap[(int) preds[p->pred].codes[i]]) break; @@ -1140,7 +1140,7 @@ write_tree_1 (tree, prevpos, afterward, type) if (code == MATCH_OPERAND) { - for (i = 0; i < NUM_RTX_CODE && preds[p->pred].codes[i]; i++) + for (i = 0; i < NUM_RTX_CODE && preds[p->pred].codes[i] != 0; i++) { printf ("%scase ", indents[indent - 2]); print_code (preds[p->pred].codes[i]); diff --git a/gcc/reload1.c b/gcc/reload1.c index 845883a..8eee024 100644 --- a/gcc/reload1.c +++ b/gcc/reload1.c @@ -2496,7 +2496,7 @@ eliminate_regs (x, mem_mode, insn) We special-case the commonest situation in eliminate_regs_in_insn, so just replace a PLUS with a PLUS here, unless inside a MEM. */ - if (mem_mode && GET_CODE (XEXP (x, 1)) == CONST_INT + if (mem_mode != 0 && GET_CODE (XEXP (x, 1)) == CONST_INT && INTVAL (XEXP (x, 1)) == - ep->previous_offset) return ep->to_rtx; else |