1 /* { dg-do assemble { target aarch64_asm_sve_ok } } */
2 /* { dg-options "-O3 --save-temps" } */
3 
4 #include <stdint.h>
5 
6 void __attribute__ ((noinline, noclone))
vfcvtz_16(uint16_t * dst,_Float16 * src1,int size)7 vfcvtz_16 (uint16_t *dst, _Float16 *src1, int size)
8 {
9   for (int i = 0; i < size; i++)
10     dst[i] = (uint16_t) src1[i];
11 }
12 
13 void __attribute__ ((noinline, noclone))
vfcvtz_32(uint32_t * dst,float * src1,int size)14 vfcvtz_32 (uint32_t *dst, float *src1, int size)
15 {
16   for (int i = 0; i < size; i++)
17     dst[i] = (uint32_t) src1[i];
18 }
19 
20 void __attribute__ ((noinline, noclone))
vfcvtz_64(uint64_t * dst,double * src1,int size)21 vfcvtz_64 (uint64_t *dst, double *src1, int size)
22 {
23   for (int i = 0; i < size; i++)
24     dst[i] = (uint64_t) src1[i];
25 }
26 
27 /* { dg-final { scan-assembler-times {\tfcvtzu\tz[0-9]+\.h, p[0-7]/m, z[0-9]+\.h\n} 1 } } */
28 /* { dg-final { scan-assembler-times {\tfcvtzu\tz[0-9]+\.s, p[0-7]/m, z[0-9]+\.s\n} 1 } } */
29 /* { dg-final { scan-assembler-times {\tfcvtzu\tz[0-9]+\.d, p[0-7]/m, z[0-9]+\.d\n} 1 } } */
30