https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90197
--- Comment #11 from Jakub Jelinek <jakub at gcc dot gnu.org> --- Author: jakub Date: Fri May 17 19:52:06 2019 New Revision: 271353 URL: https://gcc.gnu.org/viewcvs?rev=271353&root=gcc&view=rev Log: Backported from mainline 2019-05-15 Jakub Jelinek <ja...@redhat.com> PR debug/90197 * cp-gimplify.c (genericize_cp_loop): Emit a DEBUG_BEGIN_STMT before the condition (or if missing or constant non-zero at the end of the loop. Emit a DEBUG_BEGIN_STMT before the increment expression if any. Don't call protected_set_expr_location on incr if it already has a location. Modified: branches/gcc-9-branch/gcc/cp/ChangeLog branches/gcc-9-branch/gcc/cp/cp-gimplify.c