Debian Codegraph @

gcc/testsuite/gcc.target/riscv/rvv/autovec/reduc/extract_last_run-7.c

raw
1 /* { dg-do run { target { riscv_v } } } */
2 /* { dg-additional-options "-mrvv-vector-bits=zvl -fno-vect-cost-model" } */
3
4 #include "extract_last-7.c"
5
6 extern void abort (void) __attribute__ ((noreturn));
7
8 int __attribute__ ((optimize (1)))
9 main (void)
10 {
11 TYPE a[N] = {
12 11, 12, 13, 14, 15, 16, 17, 18, 19, 20,
13 1, 2, 3, 4, 5, 6, 7, 8, 9, 10,
14 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
15 31, 32
16 };
17 __builtin_memset (a+32, 43, (N-32)*sizeof (TYPE));
18
19 TYPE ret = condition_reduction (a, 16);
20
21 if (ret != 10)
22 abort ();
23
24 return 0;
25 }