| 1 |
// { dg-options "" } |
| 2 |
|
| 3 |
#pragma GCC target "+nosme" |
| 4 |
|
| 5 |
void ns_callee (); |
| 6 |
void s_callee () [[arm::streaming]]; |
| 7 |
void sc_callee () [[arm::streaming_compatible]]; |
| 8 |
|
| 9 |
struct callbacks { |
| 10 |
void (*ns_ptr) (); |
| 11 |
void (*s_ptr) () [[arm::streaming]]; |
| 12 |
void (*sc_ptr) () [[arm::streaming_compatible]]; |
| 13 |
}; |
| 14 |
|
| 15 |
void |
| 16 |
n_caller (struct callbacks *c) |
| 17 |
{ |
| 18 |
ns_callee (); |
| 19 |
s_callee (); // { dg-error "calling a streaming function requires the ISA extension 'sme'" } |
| 20 |
sc_callee (); |
| 21 |
|
| 22 |
c->ns_ptr (); |
| 23 |
c->s_ptr (); // { dg-error "calling a streaming function requires the ISA extension 'sme'" } |
| 24 |
c->sc_ptr (); |
| 25 |
} |
| 26 |
|
| 27 |
void |
| 28 |
sc_caller_sme (struct callbacks *c) [[arm::streaming_compatible]] |
| 29 |
{ |
| 30 |
ns_callee (); |
| 31 |
s_callee (); // { dg-error "calling a streaming function requires the ISA extension 'sme'" } |
| 32 |
sc_callee (); |
| 33 |
|
| 34 |
c->ns_ptr (); |
| 35 |
c->s_ptr (); // { dg-error "calling a streaming function requires the ISA extension 'sme'" } |
| 36 |
c->sc_ptr (); |
| 37 |
} |