aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gcc.dg/lto/const-uniq_0.c
blob: 1bbc7f45f8d42aef706a006c66132003745cb01b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
/* The 3 constant initializers should be uniquized.  */

/* { dg-lto-do run } */
/* { dg-lto-options {{-Os -flto -flto-partition=none} {-Os -flto -flto-partition=1to1} } } */

int lookup1 (int i)
{
  int a[] = { 0, 1, 2, 3, 4, 5, 6, 7 };
  return a[i];
}

int lookup2 (int i)
{
  int a[] = { 0, 1, 2, 3, 4, 5, 6, 7 };
  return a[i+1];
}