diff options
author | Jakub Jelinek <jakub@redhat.com> | 2020-03-24 09:36:32 +0100 |
---|---|---|
committer | Jakub Jelinek <jakub@redhat.com> | 2020-03-24 09:36:32 +0100 |
commit | 565ab7efbdc68cca5a2a81d872015f33359048b4 (patch) | |
tree | 3c7e293b8b9e7ef24e590d2a79d11bc41dd03680 /intl/aclocal.m4 | |
parent | a5a9400a846244d040caa6d1531434eee8fc8ec7 (diff) | |
download | gcc-565ab7efbdc68cca5a2a81d872015f33359048b4.zip gcc-565ab7efbdc68cca5a2a81d872015f33359048b4.tar.gz gcc-565ab7efbdc68cca5a2a81d872015f33359048b4.tar.bz2 |
loop-manip: Avoid -fcompare-debug issues in create_iv [PR94285]
The following testcase FAILs with -fcompare-debug. The problem is that
create_iv behaves differently when inserting after into an empty bb (in that
case sets location to goto_locus), or when inserting before gsi_end_p (i.e.
at the end of bb; in that case it will not set location, otherwise it will
set it to the location of next stmt).
This isn't -fcompare-debug friendly, because if inserting after and the
bb contains only debug stmts, then the location will not be set with -g
and will be with -g0, or when inserting before, the location might either
be set from the following debug stmt rather than some non-debug stmt after
that, or might not be set with -g0 if it is to be inserted at the end of bb,
while with -g would be set to location of debug stmt.
2020-03-24 Jakub Jelinek <jakub@redhat.com>
PR debug/94285
* tree-ssa-loop-manip.c (create_iv): If after, set stmt location to
e->goto_locus even if gsi_bb (*incr_pos) contains only debug stmts.
If not after and at *incr_pos is a debug stmt, set stmt location to
location of next non-debug stmt after it if any.
* gfortran.dg/pr94285.f90: New test.
Diffstat (limited to 'intl/aclocal.m4')
0 files changed, 0 insertions, 0 deletions