diff options
Diffstat (limited to 'gcc/profile.c')
-rw-r--r-- | gcc/profile.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/gcc/profile.c b/gcc/profile.c index 625a904a428..b7b39a2f5a8 100644 --- a/gcc/profile.c +++ b/gcc/profile.c @@ -502,7 +502,7 @@ compute_branch_probabilities (void) } for (e = bb->succ; e; e = e->succ_next) { - /* Function may return twice in the cased the called fucntion is + /* Function may return twice in the cased the called function is setjmp or calls fork, but we can't represent this by extra edge from the entry, since extra edge from the exit is already present. We get negative frequency from the entry @@ -512,10 +512,10 @@ compute_branch_probabilities (void) || (e->count > bb->count && e->dest != EXIT_BLOCK_PTR)) { - rtx insn = bb->end; + rtx insn = BB_END (bb); while (GET_CODE (insn) != CALL_INSN - && insn != bb->head + && insn != BB_HEAD (bb) && keep_with_call_p (insn)) insn = PREV_INSN (insn); if (GET_CODE (insn) == CALL_INSN) @@ -534,7 +534,7 @@ compute_branch_probabilities (void) for (e = bb->succ; e; e = e->succ_next) e->probability = (e->count * REG_BR_PROB_BASE + bb->count / 2) / bb->count; if (bb->index >= 0 - && any_condjump_p (bb->end) + && any_condjump_p (BB_END (bb)) && bb->succ->succ_next) { int prob; @@ -554,15 +554,15 @@ compute_branch_probabilities (void) index = 19; hist_br_prob[index]++; - note = find_reg_note (bb->end, REG_BR_PROB, 0); + note = find_reg_note (BB_END (bb), REG_BR_PROB, 0); /* There may be already note put by some other pass, such as builtin_expect expander. */ if (note) XEXP (note, 0) = GEN_INT (prob); else - REG_NOTES (bb->end) + REG_NOTES (BB_END (bb)) = gen_rtx_EXPR_LIST (REG_BR_PROB, GEN_INT (prob), - REG_NOTES (bb->end)); + REG_NOTES (BB_END (bb))); num_branches++; } } @@ -594,7 +594,7 @@ compute_branch_probabilities (void) e->probability = REG_BR_PROB_BASE / total; } if (bb->index >= 0 - && any_condjump_p (bb->end) + && any_condjump_p (BB_END (bb)) && bb->succ->succ_next) num_branches++, num_never_executed; } @@ -892,7 +892,7 @@ branch_prob (void) FOR_EACH_BB (bb) { - rtx insn = bb->head; + rtx insn = BB_HEAD (bb); int ignore_next_note = 0; offset = 0; @@ -905,7 +905,7 @@ branch_prob (void) else insn = NEXT_INSN (insn); - while (insn != bb->end) + while (insn != BB_END (bb)) { if (GET_CODE (insn) == NOTE) { |