| 1 |
/* { dg-do compile } */ |
| 2 |
/* { dg-require-effective-target vect_int } */ |
| 3 |
/* { dg-options "-O2 -mdejagnu-cpu=power9" } */ |
| 4 |
|
| 5 |
/* Verify it emits error message on inlining even without LTO. */ |
| 6 |
|
| 7 |
vector int c, a, b; |
| 8 |
|
| 9 |
static inline void __attribute__ ((__always_inline__)) |
| 10 |
foo () /* { dg-error "inlining failed in call to .* target specific option mismatch" } */ |
| 11 |
{ |
| 12 |
c = a + b; |
| 13 |
} |
| 14 |
|
| 15 |
__attribute__ ((target ("cpu=power8"))) |
| 16 |
int main () |
| 17 |
{ |
| 18 |
foo (); /* { dg-message "called from here" } */ |
| 19 |
c = a + b; |
| 20 |
} |