2018-06-05 Richard Biener <rguenther@suse.de>
[official-gcc.git] / gcc / testsuite / gcc.dg / pr32370.c
blobfc3d724e6c48134e6c0bea1548b958f17f30b8a5
1 /* PR middle-end/32370 */
2 /* { dg-do compile { target i?86-*-* x86_64-*-* ia64-*-* } } */
3 /* { dg-options "" { target ia64-*-* } } */
4 /* { dg-options "-ffixed-esi" { target i?86-*-* x86_64-*-* } } */
5 /* { dg-options "-mabi=sysv -ffixed-esi" { target x86_64-*-mingw* } } */
7 #if (defined __i386__ || defined __x86_64__) && ! defined _WIN64
8 # define C "=S"
9 # define TYPE unsigned long
10 #elif defined __ia64__ || defined _WIN64
11 # define C "=a"
12 # define TYPE unsigned long long
13 #endif
15 #ifdef _WIN64
16 __extension__
17 #endif
18 unsigned int
19 foo (TYPE port)
21 unsigned int v;
22 __asm__ __volatile__ ("" : C (v) : "Nd" (port)); /* { dg-error "while reloading\|has impossible\|inconsistent operand constraints" } */
23 return v;
26 void
27 bar (void)
29 foo (0);