Debian Codegraph @

gcc/testsuite/gcc.target/aarch64/sve/acle/general-c/unary_to_int_1.c

raw
1 /* { dg-do compile } */
2
3 #include <arm_sve.h>
4
5 #pragma GCC target ("arch=armv8.2-a+sve2")
6
7 void
8 f1 (svbool_t pg, svint32_t s32, svuint32_t u32, svfloat32_t f32,
9 svint64_t s64, svuint64_t u64, svfloat64_t f64)
10 {
11 svlogb_m (s32, pg); /* { dg-error {too few arguments to function 'svlogb_m'} } */
12 svlogb_m (s32, pg, f32, s32); /* { dg-error {too many arguments to function 'svlogb_m'} } */
13 svlogb_m (0, pg, f32); /* { dg-error {passing 'int' to argument 1 of 'svlogb_m', which expects an SVE type rather than a scalar} } */
14 svlogb_m (s32, u32, f32); /* { dg-error {passing 'svuint32_t' to argument 2 of 'svlogb_m', which expects 'svbool_t'} } */
15 svlogb_m (s32, 0, f32); /* { dg-error {passing 'int' to argument 2 of 'svlogb_m', which expects 'svbool_t'} } */
16 svlogb_m (s32, pg, s32); /* { dg-error {'svlogb_m' has no form that takes 'svint32_t' arguments} } */
17 svlogb_m (s32, pg, u32); /* { dg-error {'svlogb_m' has no form that takes 'svuint32_t' arguments} } */
18 svlogb_m (s32, pg, f32);
19 svlogb_m (s32, pg, pg); /* { dg-error {'svlogb_m' has no form that takes 'svbool_t' arguments} } */
20
21 svlogb_m (pg, pg, f32); /* { dg-error {passing 'svbool_t' to argument 1 of 'svlogb_m', which expects a vector of signed integers} } */
22 svlogb_m (u32, pg, f32); /* { dg-error {passing 'svuint32_t' to argument 1 of 'svlogb_m', which expects a vector of signed integers} } */
23 svlogb_m (f32, pg, f32); /* { dg-error {passing 'svfloat32_t' to argument 1 of 'svlogb_m', which expects a vector of signed integers} } */
24 svlogb_m (u64, pg, f32); /* { dg-error {passing 'svuint64_t' to argument 1 of 'svlogb_m', which expects a vector of signed integers} } */
25 svlogb_m (s64, pg, f32); /* { dg-error {arguments 1 and 3 of 'svlogb_m' must have the same element size, but the values passed here have type 'svint64_t' and 'svfloat32_t' respectively} } */
26 svlogb_m (s32, pg, f64); /* { dg-error {arguments 1 and 3 of 'svlogb_m' must have the same element size, but the values passed here have type 'svint32_t' and 'svfloat64_t' respectively} } */
27 }