aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/c-c++-common/Wunused-var-16.c
blob: 31c7db30f9fafc62cccf7c1eb073d2cb3e695fda (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/* PR c++/78949 */
/* { dg-do compile } */
/* { dg-options "-Wunused -fdump-tree-optimized" } */
/* { dg-additional-options "-fno-common" { target hppa*-*-hpux* } } */

typedef unsigned char V __attribute__((vector_size(16)));
V v;

void
foo ()
{
  V y = {};
  V x = {};	// { dg-bogus "set but not used" }
  y &= ~x;
  v = y;
}

/* { dg-final { scan-tree-dump-not " ~0" "optimized" } } */