| 1 |
/* PR c/41045 */ |
| 2 |
/* { dg-do compile } */ |
| 3 |
/* { dg-options "-O0" } */ |
| 4 |
/* { dg-additional-options "-fno-pie" { target pie } } */ |
| 5 |
|
| 6 |
int v[42], w[42], x; |
| 7 |
|
| 8 |
asm ("# %0" : "+m" (v)); /* { dg-error "'\\\+' in output operand outside of a function" } */ |
| 9 |
asm ("# %0" : "=&m" (v)); /* { dg-error "'&' in output operand outside of a function" } */ |
| 10 |
asm ("# %0, %1" : "=%m" (v), "=m" (w)); /* { dg-error "'%' in output operand outside of a function" } */ |
| 11 |
asm ("# %0, %1" : : "%m" (v), "m" (w)); /* { dg-error "'%' in input operand outside of a function" } */ |