1 /* PR debug/29609 */ 2 /* Verify that breakpoint on both goto failure; stmts is hit. */ 3 /* { dg-do compile } */ 4 /* { dg-options "-O0 -gdwarf -dA" } */ 5 6 extern void abort (void); 7 int x; 8 9 int foo(void)10foo (void) 11 { 12 return 0 ^ x; 13 } 14 15 int bar(void)16bar (void) 17 { 18 return 1 ^ x; 19 } 20 21 int baz(void)22baz (void) 23 { 24 int c; 25 26 if (!foo ()) 27 goto failure; 28 29 if (!bar ()) 30 goto failure; 31 32 return 0; 33 34 failure: 35 return 1; 36 } 37 38 int main(void)39main (void) 40 { 41 if (baz () != 1) 42 abort (); 43 x = 1; 44 if (baz () != 1) 45 abort (); 46 x = 2; 47 if (baz () != 0) 48 abort (); 49 return 0; 50 } 51 52 /* { dg-final { scan-assembler "pr29609-2.c:27" } } */ 53 /* { dg-final { scan-assembler "pr29609-2.c:30" } } */ 54