PR inline-asm/84742
[official-gcc.git] / gcc / testsuite / gcc.target / i386 / 20020218-1.c
blob4d3d256afcca6ffa248d8cbb9410a04cf01bcfbe
1 /* Verify that X86-64 only SSE registers aren't restored on IA-32. */
2 /* { dg-do compile } */
3 /* { dg-require-effective-target ia32 } */
4 /* { dg-options "-O2 -msse" } */
5 /* { dg-final { scan-assembler-not "xmm8" } } */
7 extern void abort (void);
8 extern void exit (int);
10 void *bar (void *p, void *q)
12 if (p != (void *) 26 || q != (void *) 35)
13 abort ();
14 return (void *) 76;
17 void *foo (void **args)
19 void *argcookie = &args[1];
21 __builtin_return (__builtin_apply (args[0], &argcookie,
22 2 * sizeof (void *)));
25 int main (void)
27 void *args[3];
29 args[0] = (void *) bar;
30 args[1] = (void *) 26;
31 args[2] = (void *) 35;
32 if (foo (args) != (void *) 76)
33 abort ();
34 exit (0);