aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/pch/faltivec-1.c
blob: 5824d4155cc31faed4ccb1e2662a2e23a51356a3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
/* APPLE LOCAL file AltiVec */
/* { dg-do compile { target powerpc-*-darwin* } } */
/* { dg-options "-faltivec -I. -mcpu=G5" } */

#include "faltivec-1.h" 
/* { dg-error "No such file or directory" "" { target *-*-* } 5 } */
/* { dg-error "one or more PCH files were found" "" { target *-*-* } 5 } */
/* { dg-error "use -Winvalid-pch for more information" "" { target *-*-* } 5 } */

/* Test for correct PCH validation of -faltivec.  */
void foo()
{
  const vector signed short vconst = (vector signed short) (0,0,0,0,0,0,0,0);
  const vector signed short vconst2 = vec_splat(vconst, 0);
  bar();
}