On 12/14/2015 01:14 PM, Jakub Jelinek wrote:
Hi!
rtx_renumbered_equal_p considers two LABEL_REFs equivalent if they
have the same next_real_insn, unfortunately next_real_insn doesn't ignore
debug insns. It ignores BARRIERs/JUMP_TABLE_DATA insns too, which is IMHO
not desirable either, so this patch uses next_nonnote_nondebug_insn instead
(which stops at CODE_LABEL) and keeps iterating if CODE_LABELs are found.
Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk?
2015-12-14 Jakub Jelinek <ja...@redhat.com>
PR rtl-optimization/65980
* jump.c (rtx_renumbered_equal_p) <case LABEL_REF>: Use
next_nonnote_nondebug_insn instead of next_real_insn and
skip over CODE_LABELs too.
* gcc.dg/pr65980.c: New test.
OK.
jeff