| 1 |
/* Verify that overloaded built-ins for vec_st with float |
| 2 |
inputs produce the right code. */ |
| 3 |
|
| 4 |
/* { dg-do compile } */ |
| 5 |
/* { dg-options "-maltivec -O2" } */ |
| 6 |
/* { dg-require-effective-target powerpc_altivec } */ |
| 7 |
|
| 8 |
#include <altivec.h> |
| 9 |
|
| 10 |
void |
| 11 |
testst_1 (vector float vf1, int i1, vector float * vfp) |
| 12 |
{ |
| 13 |
return vec_st(vf1, i1, vfp); |
| 14 |
} |
| 15 |
|
| 16 |
void |
| 17 |
testst_2 (vector float vf1, int i1, float * fp) |
| 18 |
{ |
| 19 |
return vec_st(vf1, i1, fp); |
| 20 |
} |
| 21 |
|
| 22 |
void |
| 23 |
testst_cst1 (vector float vf1, int i1, vector float * vfp) |
| 24 |
{ |
| 25 |
return vec_st(vf1, 16, vfp); |
| 26 |
} |
| 27 |
|
| 28 |
void |
| 29 |
testst_cst2 (vector float vf1, int i1, float * fp) |
| 30 |
{ |
| 31 |
return vec_st(vf1, 24, fp); |
| 32 |
} |
| 33 |
|
| 34 |
/* { dg-final { scan-assembler-times {\m(?:stvx|stxv|stxvx)\M} 4 } } */ |