| 1 |
/* { dg-do compile } */ |
| 2 |
/* { dg-require-effective-target powerpc_elfv2 } */ |
| 3 |
/* { dg-require-effective-target power10_ok } */ |
| 4 |
/* { dg-options "-O2 -mdejagnu-cpu=power10" } */ |
| 5 |
|
| 6 |
/* At present, -mcpu=power10 does not enable pc-relative mode. Enable it here |
| 7 |
explicitly until it is turned on by default. */ |
| 8 |
#pragma GCC target ("cpu=power10,pcrel") |
| 9 |
int localentry1 () { return 5; } |
| 10 |
|
| 11 |
#pragma GCC target ("cpu=power9,no-pcrel") |
| 12 |
int localentry2 () { return 5; } |
| 13 |
|
| 14 |
/* { dg-final { scan-assembler {\.localentry\tlocalentry1,1\M} } } */ |
| 15 |
/* { dg-final { scan-assembler-not {\.localentry\tlocalentry2,1\M} } } */ |