regrename: Fix -fcompare-debug issue in find_rename_reg [PR103756]
The r12-5978 change caused a -fcompare-debug issue, because without -g a chain might start with a noop move, but with -g there could be one or more DEBUG_INSNs in the chain before the noop move and so regrename could make different decisions between -g and -g0. Note, I must say I don't really understand the original change much, if we want to make sure the noop moves are removed, couldn't regrename during building of those du chains simply remove the noop moves instead? 2021-12-30 Jakub Jelinek <jakub@redhat.com> PR rtl-optimization/103756 * regrename.c (find_rename_reg): Test noop_move_p on the first non-debug insn in the chain rather than on the first insn. * g++.dg/opt/pr103756.C: New test.
Loading
Please register or sign in to comment