1 /* { dg-additional-options "-O" } */
2 /* { dg-final { check-function-bodies "**" "" } } */
3
4 #include <arm_sve.h>
5
6 #ifdef __cplusplus
7 extern "C" {
8 #endif
9
10 /*
11 ** cmp1:
12 ** ptrue (p[0-7])\.b(?:[^\n]*)
13 ** cmple p0\.b, \1/z, z0\.b, z1\.d
14 ** ret
15 */
16 svbool_t
cmp1(svint8_t x,svint64_t y)17 cmp1 (svint8_t x, svint64_t y)
18 {
19 svbool_t res = svcmple_wide (svptrue_b8 (), x, y);
20 svuint8_t res_u8 = svdup_u8_z (res, 1);
21 return svcmpne (svptrue_b8 (), res_u8, 0);
22 }
23
24 /*
25 ** cmp2:
26 ** ptrue (p[0-7])\.b(?:[^\n]*)
27 ** cmplt p0\.b, \1/z, z0\.b, z1\.d
28 ** ret
29 */
30 svbool_t
cmp2(svint8_t x,svint64_t y)31 cmp2 (svint8_t x, svint64_t y)
32 {
33 svbool_t res = svcmplt_wide (svptrue_b8 (), x, y);
34 svuint8_t res_u8 = svdup_u8_z (res, 42);
35 return svcmpeq (svptrue_b8 (), res_u8, 42);
36 }
37
38 #ifdef __cplusplus
39 }
40 #endif
41