Hi!

I've noticed this test started failing with newer gdb.
The actual problem is that the store to v got optimized away completely some
time ago and so the breakpoint on that line is problematic.

Fixed thusly, bootstrapped/regtested on x86_64-linux and i686-linux,
committed to trunk as obvious.

2015-01-20  Jakub Jelinek  <ja...@redhat.com>

        * gcc.dg/guality/pr49888.c (v): Add __attribute__((used)).

--- gcc/testsuite/gcc.dg/guality/pr49888.c.jj   2012-06-28 13:33:21.000000000 
+0200
+++ gcc/testsuite/gcc.dg/guality/pr49888.c      2015-01-20 12:32:11.136906646 
+0100
@@ -2,7 +2,7 @@
 /* { dg-do run } */
 /* { dg-options "-g" } */
 
-static int v;
+static int v __attribute__((used));
 
 static void __attribute__((noinline, noclone))
 f (int *p)

        Jakub

Reply via email to