summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/pr82929.c
blob: bb84f2b21a3ea216a4af69da8e172a71dc78eafb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/* PR tree-optimization/82929 */
/* { dg-do compile { target store_merge } } */
/* { dg-options "-O2 -fdump-tree-store-merging" } */

void
foo (short *p, short *q, short *r)
{
  short a = q[0];
  short b = q[1];
  short c = ~a;
  short d = r[0];
  short e = r[1];
  short f = ~b;
  p[0] = c & d;
  p[1] = e & f;
}

/* { dg-final { scan-tree-dump-times "Merging successful" 1 "store-merging" { target { ! arm*-*-* } } } } */