PR tree-optimization/83369 - Missing diagnostics during inlining
[official-gcc.git] / gcc / testsuite / gcc.dg / pr31866.c
blob4081c0e6ad955d23a569937db70e4413bc5d2ce3
1 /* PR tree-optimization/31866 */
2 /* { dg-do compile { target alpha*-*-* cris-*-* crisv32-*-* i?86-*-* mmix-*-* powerpc*-*-* rs6000-*-* x86_64-*-* } } */
3 /* { dg-options "-O2" } */
5 #if defined (__alpha__)
6 # define REG "$1"
7 #elif defined (__CRIS__)
8 # define REG "r10"
9 #elif defined (__i386__)
10 # define REG "%eax"
11 #elif defined (__MMIX__)
12 # define REG "$8"
13 #elif defined (__powerpc__) || defined (__PPC__) || defined (__ppc__) \
14 || defined (__POWERPC__) || defined (PPC) || defined (_IBMR2)
15 # define REG "6"
16 #elif defined (__x86_64__)
17 # define REG "rax"
18 #endif
20 long int
21 foo (void)
23 unsigned long int s;
24 long int a = (long int) 0;
25 register long int r asm (REG) = a;
26 asm ("" : "=r" (s) : "0" (r));
27 return s;