blob: 895c243aaf86de925ce93bd86ed54ec60c19bae9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
/* { dg-require-effective-target powerpc_p9vector_ok } */
/* { dg-options "-mdejagnu-cpu=power9 -O2 -ftree-vectorize -fno-vect-cost-model -fdump-tree-vect-details" } */
/* As PR104015, we don't expect vectorizer will re-try some vector modes
for epilogues on Power9, since Power9 doesn't support partial vector
by defaut. */
#include <stdarg.h>
#define N 200
void __attribute__((noinline))
foo (unsigned short *__restrict__ pInput, unsigned short *__restrict__ pOutput)
{
unsigned short i, a, b, c;
for (i = 0; i < N / 3; i++)
{
a = *pInput++;
b = *pInput++;
c = *pInput++;
*pOutput++ = a + b + c + 3;
*pOutput++ = a + b + c + 12;
*pOutput++ = a + b + c + 1;
}
}
/* { dg-final { scan-tree-dump-not "Re-trying epilogue analysis with vector mode" "vect" } } */
|