[backport from gcc-4.8/trunk r189038 ] gcc/testsuite/ 2012-06-28 Alexandre Oliva PR debug/53671 PR debug/49888 * gcc.dg/guality/pr49888.c: Account for the possibility that the variable is optimized out at the first test. --- gcc-4.7.1/gcc/testsuite/gcc.dg/guality/pr49888.c.~1~ 2012-08-12 13:11:31.000000000 +0200 +++ gcc-4.7.1/gcc/testsuite/gcc.dg/guality/pr49888.c 2012-08-12 13:26:37.000000000 +0200 @@ -9,12 +9,13 @@ f (int *p) { int c = *p; v = c; - *p = 1; /* { dg-final { gdb-test 12 "c" "0" } } */ + *p = 1; /* { dg-final { gdb-test 12 "!!c" "0" } } */ /* c may very well be optimized out at this point, so we test !c, which will evaluate to the expected value. We just want to make sure it doesn't remain bound to *p as it did before, in which - case !c would evaluate to 0. */ - v = 0; /* { dg-final { gdb-test 17 "!c" "1" } } */ + case !c would evaluate to 0. *p may also be regarded as aliasing + register saves, thus the !!c above. */ + v = 0; /* { dg-final { gdb-test 18 "!c" "1" } } */ } int main ()