| 1 |
/* { dg-do compile } */ |
| 2 |
/* { dg-skip-if "no register windows" { *-*-* } { "-mflat" } { "" } } */ |
| 3 |
/* { dg-skip-if "prevents expected asm" { *-*-* } { "-mfix-ut699" } { "" } } */ |
| 4 |
/* { dg-require-effective-target ilp32 } */ |
| 5 |
/* { dg-options "-mcpu=ultrasparc -O" } */ |
| 6 |
|
| 7 |
/* Make sure that Ultrasparc return insn do not read below the stack. */ |
| 8 |
|
| 9 |
void toto (int *); |
| 10 |
|
| 11 |
int bar (int a, int b, int c, int d, int e, int f, int g, int h) |
| 12 |
{ |
| 13 |
int res; |
| 14 |
|
| 15 |
toto (&res); |
| 16 |
return h; |
| 17 |
} |
| 18 |
/* { dg-final { scan-assembler "return\[ \t\]*%i7\\+8\n\[^\n\]*ld\[ \t\]*\\\[%sp\\+96\\\]" } } */ |
| 19 |
|
| 20 |
int bar2 () |
| 21 |
{ |
| 22 |
int res; |
| 23 |
|
| 24 |
toto (&res); |
| 25 |
return res; |
| 26 |
} |
| 27 |
/* { dg-final { scan-assembler "return\[ \t\]*%i7\\+8\n\[^\n\]*nop" } } */ |