Debian Codegraph @

gcc/testsuite/gcc.dg/vect/pr121049.c

raw
1 /* { dg-additional-options "--param vect-partial-vector-usage=1" } */
2 /* { dg-additional-options "-march=x86-64-v4" { target avx512f_runtime } } */
3
4 #include "tree-vect.h"
5
6 int mon_lengths[12] = { 1, 10, 100 };
7
8 __attribute__ ((noipa)) long
9 transtime (int mon)
10 {
11 long value = 0;
12 for (int i = 0; i < mon; ++i)
13 value += mon_lengths[i] * 2l;
14 return value;
15 }
16
17 int
18 main ()
19 {
20 check_vect ();
21 if (transtime (3) != 222)
22 __builtin_abort ();
23 return 0;
24 }
25