Debian Codegraph @

gcc/testsuite/gcc.target/riscv/rvv/autovec/no-segment.c

raw
1 /* { dg-do compile } */
2 /* { dg-options "-march=rv64gcv -mabi=lp64d -mrvv-vector-bits=scalable -O3 -mno-autovec-segment" } */
3
4 enum e { c, d };
5 enum g { f };
6
7 struct h
8 {
9 float x, w;
10 };
11
12 struct k
13 {
14 short z, y, i, j;
15 };
16
17 long r;
18 struct h m, p;
19 struct k *q;
20
21 short
22 l (float s)
23 {
24 if (s <= 0.0f)
25 return 0;
26
27 if (s >= 5)
28 return 5;
29
30 return s;
31 }
32
33 struct n
34 {
35 enum g colorspace;
36 };
37
38 struct n o (struct k *s, struct h *t)
39 {
40 t->w = s->z;
41 }
42
43 void
44 ClutImageChannel (struct n *s, enum e t)
45 {
46
47 while (s)
48 for (; r; r++)
49 {
50 o (q, &p);
51
52 if (t & d)
53 q->y = (&m + q->y)->x;
54
55 if (t)
56 q->z = l ((&m + q->z)->w);
57
58 if (s->colorspace)
59 q++;
60 }
61 }