https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100148

--- Comment #10 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-8 branch has been updated by Jakub Jelinek
<ja...@gcc.gnu.org>:

https://gcc.gnu.org/g:bef3ed832a97b0cdfb540fc5c5dee923ccdc540a

commit r8-10944-gbef3ed832a97b0cdfb540fc5c5dee923ccdc540a
Author: Jakub Jelinek <ja...@redhat.com>
Date:   Wed Apr 21 12:31:45 2021 +0200

    cprop: Fix -fcompare-debug bug in constprop_register [PR100148]

    The following testcase shows different behavior between -g and -g0
    in constprop_register, if a flags register setter is separated
    from a conditional jump using those flags with -g by a DEBUG_INSN.
    As it uses just NEXT_INSN, for -g it will look at the DEBUG_INSN which is
    not a conditional jump, while otherwise it would look at the conditional
    jump and call cprop_jump.

    2021-04-21  Jakub Jelinek  <ja...@redhat.com>

            PR rtl-optimization/100148
            * cprop.c (constprop_register): Use next_nondebug_insn instead of
            NEXT_INSN.

            * g++.dg/opt/pr100148.C: New test.

    (cherry picked from commit 022f6ee3ad67ee30f62c8c2aeeb4156494f3284e)

Reply via email to