https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83419
Jakub Jelinek <jakub at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Last reconfirmed| |2017-12-14 CC| |jakub at gcc dot gnu.org Ever confirmed|0 |1 --- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> --- This goes away with -gno-statement-frontiers. The bug is there already during gimplification: --- pr83419.c.004t.gimple 2017-12-14 10:59:42.640759216 +0100 +++ pr83419.c.gk.004t.gimple 2017-12-14 10:59:42.760757522 +0100 @@ -1,13 +1,19 @@ bar () [pr83419.c:4:1] { + [pr83419.c:5:3] # DEBUG BEGIN_STMT [pr83419.c:5:7] a.0_1 = a; - [pr83419.c:5:6] if (a.0_1 != 0) goto <D.1897>; else goto <D.1899>; - <D.1899>: + [pr83419.c:5:6] if (a.0_1 != 0) goto <D.1897>; else goto <D.1900>; + <D.1900>: [pr83419.c:5:14] b.1_2 = b; [pr83419.c:5:9] if (b.1_2 == 1) goto <D.1897>; else goto <D.1898>; <D.1897>: + [pr83419.c:6:5] # DEBUG BEGIN_STMT [pr83419.c:6:5] foo (); + [pr83419.c:6:5] goto <D.1899>; <D.1898>: + [pr83419.c:8:5] # DEBUG BEGIN_STMT + <D.1899>: + [pr83419.c:9:3] # DEBUG BEGIN_STMT [pr83419.c:9:3] foo (1, 0); } see the extra label and goto if -g. While it is mostly optimized away afterwards, it affects goto_locus on an edge. Alex, will leave this to you.