1/* { dg-do compile { target { ! x32 } } } */
2/* { dg-options "-fcheck-pointer-bounds -mmpx -O2 -fdump-tree-optimized" } */
3/* { dg-final { scan-tree-dump-not "bndint" "optimized" } } */
4/* { dg-final { cleanup-tree-dump "optimized" } } */
5
6struct S
7{
8  int a;
9  int b;
10  int c;
11};
12
13int test (struct S *ps)
14{
15  int *pi = &ps->b;
16  return *pi;
17}
18