summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/i386/mpx/builtin-bnd-set-ptr-bounds-1.c
blob: 8abb2576654604cab24e77e2f4d67aae1dc93e2b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
/* { dg-do run } */
/* { dg-options "-fcheck-pointer-bounds -mmpx" } */


#include "mpx-check.h"

int buf[100];

int mpx_test (int argc, const char **argv)
{
  assert (buf + 10 == __bnd_set_ptr_bounds (buf + 10, 4));
  return 0;
}