1 /* Verify that overloaded built-ins for vec_cmp with short
2 inputs produce the right code. */
4 /* { dg-do compile } */
5 /* { dg-require-effective-target powerpc_p8vector_ok } */
6 /* { dg-options "-mpower8-vector -O2" } */
11 test3_eq (vector
signed short x
, vector
signed short y
)
13 return vec_cmpeq (x
, y
);
17 test6_eq (vector
unsigned short x
, vector
unsigned short y
)
19 return vec_cmpeq (x
, y
);
23 test3_ge (vector
signed short x
, vector
signed short y
)
25 return vec_cmpge (x
, y
);
29 test6_ge (vector
unsigned short x
, vector
unsigned short y
)
31 return vec_cmpge (x
, y
);
35 test3_gt (vector
signed short x
, vector
signed short y
)
37 return vec_cmpgt (x
, y
);
41 test6_gt (vector
unsigned short x
, vector
unsigned short y
)
43 return vec_cmpgt (x
, y
);
48 test3_le (vector
signed short x
, vector
signed short y
)
50 return vec_cmple (x
, y
);
54 test6_le (vector
unsigned short x
, vector
unsigned short y
)
56 return vec_cmple (x
, y
);
60 test3_lt (vector
signed short x
, vector
signed short y
)
62 return vec_cmplt (x
, y
);
66 test6_lt (vector
unsigned short x
, vector
unsigned short y
)
68 return vec_cmplt (x
, y
);
72 test3_ne (vector
signed short x
, vector
signed short y
)
74 return vec_cmpne (x
, y
);
78 test6_ne (vector
unsigned short x
, vector
unsigned short y
)
80 return vec_cmpne (x
, y
);