1/* { dg-do compile } */
2/* { dg-options "-O3 -mzarch -march=z13" } */
3/* { dg-require-effective-target int128 } */
4
5typedef unsigned char     uv16qi __attribute__((vector_size(16)));
6typedef unsigned short     uv8hi __attribute__((vector_size(16)));
7typedef unsigned int       uv4si __attribute__((vector_size(16)));
8typedef unsigned long long uv2di __attribute__((vector_size(16)));
9typedef unsigned __int128  uv1ti __attribute__((vector_size(16)));
10
11/* The elements differ.  */
12uv2di __attribute__((noinline))
13foo1 ()
14{
15  return (uv2di){ 0x000fffffffffff00, 0x0000ffffffffff00 };
16}
17
18/* Non-contiguous bitmasks */
19
20uv4si __attribute__((noinline))
21foo2 ()
22{
23  return (uv4si){ 0xff00100f, 0xff00100f, 0xff00100f, 0xff00100f };
24}
25
26uv8hi __attribute__((noinline))
27foo3a ()
28{
29  return (uv8hi){ 0xf700, 0xf700, 0xf700, 0xf700,
30      0xf700, 0xf700, 0xf700, 0xf700 };
31}
32
33uv8hi __attribute__((noinline))
34foo3b ()
35{
36  return (uv8hi){ 0x10ff, 0x10ff, 0x10ff, 0x10ff,
37      0x10ff, 0x10ff, 0x10ff, 0x10ff };
38}
39
40uv16qi __attribute__((noinline))
41foo4 ()
42{
43  return (uv16qi){ 0x82, 0x82, 0x82, 0x82,
44      0x82, 0x82, 0x82, 0x82,
45      0x82, 0x82, 0x82, 0x82,
46      0x82, 0x82, 0x82, 0x82 };
47}
48
49/* We do not have vgmq.  */
50uv1ti
51foo5()
52{
53  return (uv1ti){ ((unsigned __int128)1 << 53) - 1 };
54}
55/* { dg-final { scan-assembler-not "vgm" } } */
56