2 /* { dg-require-effective-target int128 } */
3 /* { dg-additional-options "-Wno-psabi" } */
5 typedef __attribute__((__vector_size__ (64))) unsigned char VC
;
6 typedef __attribute__((__vector_size__ (64))) unsigned short VS
;
7 typedef __attribute__((__vector_size__ (64))) unsigned int VI
;
8 typedef __attribute__((__vector_size__ (64))) unsigned long long VL
;
9 typedef __attribute__((__vector_size__ (64))) unsigned __int128 VV
;
17 foo (unsigned long long x
, VV vv
)
19 #if __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
21 #elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
22 x
&= -((VC
) vv
)[sizeof (__int128
) - 1];
24 x
&= -(unsigned char) (vv
[0]);
26 vi
*= (VI
) (VS
){ -vs
[0], vc
[0], vs
[1], vi
[7], vs
[7], vl
[7], x
, vi
[5] };
33 VV v
= foo (0x01aabbccdd, (VV
) { -0xff });
34 if (v
[0] != 0x01aabbccdd - 0xff)
36 if (v
[1] != 0x01aabbccdd)
38 if (v
[2] != 0x01aabbccdd)
40 if (v
[3] != 0x01aabbccdd)