Mercurial > hg > CbC > CbC_gcc
view gcc/testsuite/gcc.dg/guality/pr43177.c @ 145:1830386684a0
gcc-9.2.0
author | anatofuz |
---|---|
date | Thu, 13 Feb 2020 11:34:05 +0900 |
parents | 84e7813d76e9 |
children |
line wrap: on
line source
/* { dg-do run } */ /* { dg-options "-g" } */ void __attribute__((noinline)) bar (long x) { asm volatile ("" : : "r" (x) : "memory"); } long __attribute__((noinline)) foo (long x) { long l = x + 3; bar (l);/* { dg-final { gdb-test .+1 "l" "10" } } */ bar (l);/* { dg-final { gdb-test . "x" "7" } } */ return l; } long __attribute__((noinline)) baz (int x) { long l = x + 3; bar (l);/* { dg-final { gdb-test .+1 "l" "10" } } */ bar (l);/* { dg-final { gdb-test . "x" "7" } } */ return l; } int main (void) { int i; asm volatile ("" : "=r" (i) : "0" (7)); foo (i); baz (i); return 0; }